evalsuite-python 0.6.0__cp39-abi3-win_amd64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- evalsuite/__init__.py +268 -0
- evalsuite/__main__.py +5 -0
- evalsuite/_bench_metrics.py +2080 -0
- evalsuite/_core.pyd +0 -0
- evalsuite/_lazy.py +32 -0
- evalsuite/_native.py +60 -0
- evalsuite/api.py +275 -0
- evalsuite/benchmarks.py +946 -0
- evalsuite/calibration.py +392 -0
- evalsuite/classification/__init__.py +51 -0
- evalsuite/classification/_common.py +111 -0
- evalsuite/classification/metrics.py +945 -0
- evalsuite/cli/__init__.py +5 -0
- evalsuite/cli/main.py +606 -0
- evalsuite/clinical/__init__.py +18 -0
- evalsuite/clinical/metrics.py +342 -0
- evalsuite/clinical/report.py +366 -0
- evalsuite/core/__init__.py +1 -0
- evalsuite/core/context.py +199 -0
- evalsuite/core/exceptions.py +52 -0
- evalsuite/core/export.py +100 -0
- evalsuite/core/registry.py +90 -0
- evalsuite/core/result.py +379 -0
- evalsuite/core/types.py +23 -0
- evalsuite/core/validation.py +256 -0
- evalsuite/llmsys/__init__.py +189 -0
- evalsuite/llmsys/_common.py +215 -0
- evalsuite/llmsys/agents.py +384 -0
- evalsuite/llmsys/code.py +923 -0
- evalsuite/llmsys/efficiency.py +346 -0
- evalsuite/llmsys/longcontext.py +361 -0
- evalsuite/llmsys/multilingual.py +339 -0
- evalsuite/llmsys/robustness.py +504 -0
- evalsuite/llmsys/safety.py +509 -0
- evalsuite/llmsys/uncertainty.py +229 -0
- evalsuite/plot.py +651 -0
- evalsuite/py.typed +0 -0
- evalsuite/regression/__init__.py +41 -0
- evalsuite/regression/metrics.py +629 -0
- evalsuite/reporting.py +241 -0
- evalsuite/stats/__init__.py +46 -0
- evalsuite/stats/_resolve.py +229 -0
- evalsuite/stats/compare.py +420 -0
- evalsuite/stats/effect.py +159 -0
- evalsuite/stats/hypothesis.py +593 -0
- evalsuite/stats/intervals.py +338 -0
- evalsuite/stats/paired.py +214 -0
- evalsuite/stats/results.py +129 -0
- evalsuite/text/__init__.py +154 -0
- evalsuite/text/_common.py +97 -0
- evalsuite/text/factuality.py +469 -0
- evalsuite/text/generation.py +1346 -0
- evalsuite/text/judge.py +556 -0
- evalsuite/text/qa.py +108 -0
- evalsuite/text/rag.py +235 -0
- evalsuite/text/reasoning.py +215 -0
- evalsuite/text/report.py +158 -0
- evalsuite/text/retrieval.py +238 -0
- evalsuite/text/semantic.py +499 -0
- evalsuite/text/spice.py +162 -0
- evalsuite/text/structured.py +793 -0
- evalsuite/version.py +3 -0
- evalsuite/vision/__init__.py +47 -0
- evalsuite/vision/detection.py +696 -0
- evalsuite/vision/segmentation.py +1028 -0
- evalsuite_python-0.6.0.dist-info/METADATA +509 -0
- evalsuite_python-0.6.0.dist-info/RECORD +72 -0
- evalsuite_python-0.6.0.dist-info/WHEEL +4 -0
- evalsuite_python-0.6.0.dist-info/entry_points.txt +2 -0
- evalsuite_python-0.6.0.dist-info/licenses/LICENSE +21 -0
- evalsuite_python-0.6.0.dist-info/licenses/LICENSE-APACHE +191 -0
- evalsuite_python-0.6.0.dist-info/sboms/evalsuite-py.cyclonedx.json +576 -0
evalsuite/__init__.py
ADDED
|
@@ -0,0 +1,268 @@
|
|
|
1
|
+
"""EvalSuite: unified, reproducible evaluation for machine learning and research.
|
|
2
|
+
|
|
3
|
+
>>> import evalsuite as es
|
|
4
|
+
>>> result = es.evaluate([0, 1, 1, 0], [0, 1, 0, 0])
|
|
5
|
+
>>> print(result.summary()) # doctest: +SKIP
|
|
6
|
+
"""
|
|
7
|
+
|
|
8
|
+
from . import calibration, classification, clinical, llmsys, plot, regression, stats, text, vision
|
|
9
|
+
from .api import evaluate
|
|
10
|
+
from .calibration import (
|
|
11
|
+
CalibrationReport,
|
|
12
|
+
calibration_intercept,
|
|
13
|
+
calibration_report,
|
|
14
|
+
calibration_slope,
|
|
15
|
+
hosmer_lemeshow,
|
|
16
|
+
maximum_calibration_error,
|
|
17
|
+
)
|
|
18
|
+
from .classification import (
|
|
19
|
+
accuracy,
|
|
20
|
+
average_precision,
|
|
21
|
+
balanced_accuracy,
|
|
22
|
+
brier_score,
|
|
23
|
+
calibration_curve,
|
|
24
|
+
cohen_kappa,
|
|
25
|
+
confusion_matrix,
|
|
26
|
+
expected_calibration_error,
|
|
27
|
+
f1,
|
|
28
|
+
fbeta,
|
|
29
|
+
hamming_loss,
|
|
30
|
+
jaccard,
|
|
31
|
+
log_loss,
|
|
32
|
+
mcc,
|
|
33
|
+
npv,
|
|
34
|
+
pr_curve,
|
|
35
|
+
precision,
|
|
36
|
+
recall,
|
|
37
|
+
roc_auc,
|
|
38
|
+
roc_curve,
|
|
39
|
+
specificity,
|
|
40
|
+
top_k_accuracy,
|
|
41
|
+
)
|
|
42
|
+
from .clinical import (
|
|
43
|
+
DecisionCurve,
|
|
44
|
+
DiagnosticReport,
|
|
45
|
+
decision_curve,
|
|
46
|
+
diagnostic_odds_ratio,
|
|
47
|
+
diagnostic_report,
|
|
48
|
+
lr_negative,
|
|
49
|
+
lr_positive,
|
|
50
|
+
net_benefit,
|
|
51
|
+
ppv,
|
|
52
|
+
sensitivity,
|
|
53
|
+
youden_j,
|
|
54
|
+
)
|
|
55
|
+
from .core.exceptions import (
|
|
56
|
+
EvalSuiteError,
|
|
57
|
+
InputValidationError,
|
|
58
|
+
MetricInputError,
|
|
59
|
+
OptionalDependencyError,
|
|
60
|
+
StatisticalTestError,
|
|
61
|
+
UndefinedMetricWarning,
|
|
62
|
+
UnsupportedTaskError,
|
|
63
|
+
)
|
|
64
|
+
from .core.registry import MetricInfo, list_metrics, metric_info
|
|
65
|
+
from .core.result import EvaluationResult, MetricResult
|
|
66
|
+
from .llmsys import * # noqa: F403 (v0.5.0 LLM-systems functions, listed in llmsys.__all__)
|
|
67
|
+
from .llmsys import __all__ as _llmsys_all
|
|
68
|
+
from .regression import (
|
|
69
|
+
adjusted_r2,
|
|
70
|
+
explained_variance,
|
|
71
|
+
huber_loss,
|
|
72
|
+
mae,
|
|
73
|
+
mape,
|
|
74
|
+
max_error,
|
|
75
|
+
mean_bias_error,
|
|
76
|
+
median_absolute_error,
|
|
77
|
+
mse,
|
|
78
|
+
msle,
|
|
79
|
+
quantile_loss,
|
|
80
|
+
r2,
|
|
81
|
+
rae,
|
|
82
|
+
rmse,
|
|
83
|
+
rmsle,
|
|
84
|
+
rse,
|
|
85
|
+
smape,
|
|
86
|
+
)
|
|
87
|
+
from .reporting import ClassificationReport, classification_report
|
|
88
|
+
from .stats import (
|
|
89
|
+
ComparisonResult,
|
|
90
|
+
ConfidenceInterval,
|
|
91
|
+
TestResult,
|
|
92
|
+
accuracy_ci,
|
|
93
|
+
adjust_pvalues,
|
|
94
|
+
bootstrap_ci,
|
|
95
|
+
chi_square_test,
|
|
96
|
+
cliffs_delta,
|
|
97
|
+
cohens_d,
|
|
98
|
+
compare,
|
|
99
|
+
cramers_v,
|
|
100
|
+
delong_test,
|
|
101
|
+
fisher_exact_test,
|
|
102
|
+
friedman_test,
|
|
103
|
+
hedges_g,
|
|
104
|
+
kruskal_wallis_test,
|
|
105
|
+
mann_whitney_test,
|
|
106
|
+
mcnemar_test,
|
|
107
|
+
paired_bootstrap_test,
|
|
108
|
+
paired_t_test,
|
|
109
|
+
proportion_ci,
|
|
110
|
+
roc_auc_ci,
|
|
111
|
+
shapiro_wilk_test,
|
|
112
|
+
t_test,
|
|
113
|
+
wilcoxon_test,
|
|
114
|
+
)
|
|
115
|
+
from .text import * # noqa: F403 (every LLM-evaluation function, listed in text.__all__)
|
|
116
|
+
from .text import __all__ as _text_all
|
|
117
|
+
from .version import __version__
|
|
118
|
+
from .vision import (
|
|
119
|
+
DetectionReport,
|
|
120
|
+
SegmentationReport,
|
|
121
|
+
average_precision_detection,
|
|
122
|
+
average_surface_distance,
|
|
123
|
+
boundary_iou,
|
|
124
|
+
box_iou,
|
|
125
|
+
detection_pr_curve,
|
|
126
|
+
detection_report,
|
|
127
|
+
dice,
|
|
128
|
+
from_coco,
|
|
129
|
+
hausdorff_distance,
|
|
130
|
+
iou,
|
|
131
|
+
mean_average_precision,
|
|
132
|
+
mean_pixel_accuracy,
|
|
133
|
+
miou,
|
|
134
|
+
per_image_scores,
|
|
135
|
+
pixel_accuracy,
|
|
136
|
+
segmentation_confusion,
|
|
137
|
+
segmentation_report,
|
|
138
|
+
)
|
|
139
|
+
|
|
140
|
+
__all__ = [
|
|
141
|
+
"text",
|
|
142
|
+
"llmsys",
|
|
143
|
+
"SegmentationReport",
|
|
144
|
+
"segmentation_report",
|
|
145
|
+
"detection_pr_curve",
|
|
146
|
+
"vision",
|
|
147
|
+
"DetectionReport",
|
|
148
|
+
"average_precision_detection",
|
|
149
|
+
"average_surface_distance",
|
|
150
|
+
"boundary_iou",
|
|
151
|
+
"box_iou",
|
|
152
|
+
"detection_report",
|
|
153
|
+
"dice",
|
|
154
|
+
"from_coco",
|
|
155
|
+
"hausdorff_distance",
|
|
156
|
+
"iou",
|
|
157
|
+
"mean_average_precision",
|
|
158
|
+
"mean_pixel_accuracy",
|
|
159
|
+
"miou",
|
|
160
|
+
"per_image_scores",
|
|
161
|
+
"pixel_accuracy",
|
|
162
|
+
"segmentation_confusion",
|
|
163
|
+
"CalibrationReport",
|
|
164
|
+
"calibration_report",
|
|
165
|
+
"calibration",
|
|
166
|
+
"clinical",
|
|
167
|
+
"calibration_intercept",
|
|
168
|
+
"calibration_slope",
|
|
169
|
+
"hosmer_lemeshow",
|
|
170
|
+
"maximum_calibration_error",
|
|
171
|
+
"DecisionCurve",
|
|
172
|
+
"DiagnosticReport",
|
|
173
|
+
"decision_curve",
|
|
174
|
+
"diagnostic_odds_ratio",
|
|
175
|
+
"diagnostic_report",
|
|
176
|
+
"lr_negative",
|
|
177
|
+
"lr_positive",
|
|
178
|
+
"net_benefit",
|
|
179
|
+
"ppv",
|
|
180
|
+
"sensitivity",
|
|
181
|
+
"youden_j",
|
|
182
|
+
"chi_square_test",
|
|
183
|
+
"cramers_v",
|
|
184
|
+
"fisher_exact_test",
|
|
185
|
+
"friedman_test",
|
|
186
|
+
"kruskal_wallis_test",
|
|
187
|
+
"mann_whitney_test",
|
|
188
|
+
"paired_t_test",
|
|
189
|
+
"shapiro_wilk_test",
|
|
190
|
+
"t_test",
|
|
191
|
+
"wilcoxon_test",
|
|
192
|
+
"plot",
|
|
193
|
+
"expected_calibration_error",
|
|
194
|
+
"calibration_curve",
|
|
195
|
+
"classification_report",
|
|
196
|
+
"ClassificationReport",
|
|
197
|
+
"stats",
|
|
198
|
+
"roc_auc_ci",
|
|
199
|
+
"proportion_ci",
|
|
200
|
+
"paired_bootstrap_test",
|
|
201
|
+
"mcnemar_test",
|
|
202
|
+
"hedges_g",
|
|
203
|
+
"delong_test",
|
|
204
|
+
"compare",
|
|
205
|
+
"cohens_d",
|
|
206
|
+
"cliffs_delta",
|
|
207
|
+
"bootstrap_ci",
|
|
208
|
+
"adjust_pvalues",
|
|
209
|
+
"accuracy_ci",
|
|
210
|
+
"TestResult",
|
|
211
|
+
"ConfidenceInterval",
|
|
212
|
+
"ComparisonResult",
|
|
213
|
+
"EvalSuiteError",
|
|
214
|
+
"EvaluationResult",
|
|
215
|
+
"InputValidationError",
|
|
216
|
+
"MetricInfo",
|
|
217
|
+
"MetricInputError",
|
|
218
|
+
"MetricResult",
|
|
219
|
+
"OptionalDependencyError",
|
|
220
|
+
"StatisticalTestError",
|
|
221
|
+
"UndefinedMetricWarning",
|
|
222
|
+
"UnsupportedTaskError",
|
|
223
|
+
"__version__",
|
|
224
|
+
"accuracy",
|
|
225
|
+
"adjusted_r2",
|
|
226
|
+
"average_precision",
|
|
227
|
+
"balanced_accuracy",
|
|
228
|
+
"brier_score",
|
|
229
|
+
"classification",
|
|
230
|
+
"cohen_kappa",
|
|
231
|
+
"confusion_matrix",
|
|
232
|
+
"evaluate",
|
|
233
|
+
"explained_variance",
|
|
234
|
+
"f1",
|
|
235
|
+
"fbeta",
|
|
236
|
+
"hamming_loss",
|
|
237
|
+
"huber_loss",
|
|
238
|
+
"jaccard",
|
|
239
|
+
"list_metrics",
|
|
240
|
+
"log_loss",
|
|
241
|
+
"mae",
|
|
242
|
+
"mape",
|
|
243
|
+
"max_error",
|
|
244
|
+
"mcc",
|
|
245
|
+
"mean_bias_error",
|
|
246
|
+
"median_absolute_error",
|
|
247
|
+
"metric_info",
|
|
248
|
+
"mse",
|
|
249
|
+
"msle",
|
|
250
|
+
"npv",
|
|
251
|
+
"pr_curve",
|
|
252
|
+
"precision",
|
|
253
|
+
"quantile_loss",
|
|
254
|
+
"r2",
|
|
255
|
+
"rae",
|
|
256
|
+
"recall",
|
|
257
|
+
"regression",
|
|
258
|
+
"rmse",
|
|
259
|
+
"rmsle",
|
|
260
|
+
"roc_auc",
|
|
261
|
+
"roc_curve",
|
|
262
|
+
"rse",
|
|
263
|
+
"smape",
|
|
264
|
+
"specificity",
|
|
265
|
+
"top_k_accuracy",
|
|
266
|
+
]
|
|
267
|
+
__all__ += list(_text_all)
|
|
268
|
+
__all__ += list(_llmsys_all)
|