Metadata-Version: 2.1
Name: minx
Version: 0.0.2
Summary: It's a test
Author-email: Minx <minxinm@foxmail.com>
License: MIT License
        
        Copyright (c) [year] [fullname]
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENSE

#### 1.Estimator

```
功能：计算分类结果的precision,recall,f1,auc,mAP,(precision=recall)'s threshold
用法示例：
    from minx import Estimator
    labels_name = ['label1', 'label2', 'label3']
    est = estimator(labels_name)
    pred_scores = [[0.1,0.3,0.6],[0.2,0.7,0.1],[0.5,0.8,0.1]]
    true_labels = [2,1,0]
    result, values = est.estimate(pred_scores, true_labels)
其中,result={"report":report, "auc_text":auc_text, "mAP_text":mAP_text, "p_r_equal_text":p_r_equal_text}，里面所有value均为格式化后的string，可直接打印
而values与result格式基本一致，但字典中的value为list，保存了每个标签具体的值
```
#### 2.Dialogue

```
功能：对话文本处理
用法示例：
    from minx import Dialogue
    test_dg = Dialogue()
    input_data = [{"id": 1, "time": 100, "text": "1"}, {"id": 2, "time": 100, "text": "2"},
                  {"id": 3, "time": 100, "text": "3"}, {"id": 2, "time": 102, "text": "21"},
                  {"id": 2, "time": 10200, "text": "22"},{"id":2, "time":10211, "text":"23"}]
    ## 按某一关键字从jsonl中聚合对话，支持jsonl中的item为dict或list
    results = test_dg.merge_by_key(input_data, merge_key="id", sort_key="time")
```
