scilens 0.3.2__py3-none-any.whl → 0.3.4__py3-none-any.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.
- scilens/components/compare_errors.py +10 -6
- scilens/components/compare_floats.py +1 -1
- scilens/readers/cols_dataset.py +15 -16
- scilens/report/templates/compare_13_section_numbers.html +16 -1
- {scilens-0.3.2.dist-info → scilens-0.3.4.dist-info}/METADATA +1 -1
- {scilens-0.3.2.dist-info → scilens-0.3.4.dist-info}/RECORD +8 -8
- {scilens-0.3.2.dist-info → scilens-0.3.4.dist-info}/WHEEL +0 -0
- {scilens-0.3.2.dist-info → scilens-0.3.4.dist-info}/entry_points.txt +0 -0
|
@@ -11,12 +11,16 @@ class CompareErrors:
|
|
|
11
11
|
if not B:A.root_group=C
|
|
12
12
|
A.groups.append(C);return id,C
|
|
13
13
|
def add(A,group,comp_res,info=_A):
|
|
14
|
-
|
|
15
|
-
if A.
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
if A.
|
|
14
|
+
G=True;D=comp_res;B=group
|
|
15
|
+
if A.limit_reached:
|
|
16
|
+
if not B.error:B.error=f"Limit errors reached ({A.nb_max})"
|
|
17
|
+
return G
|
|
18
|
+
E=D.severity;F=D.message;H=D.comp_err
|
|
19
|
+
if A.ignore_warnings and E==SEVERITY_WARNING:return _B
|
|
20
|
+
A.count+=1;C=A._messages_map.get(F)
|
|
21
|
+
if C is _A:C=len(A.messages);A.messages.append(F);A._messages_map[F]=C
|
|
22
|
+
A.errors[E].append(CompareErr(err=H,msg=C,group=B.id,info=info));B.incr(E)
|
|
23
|
+
if A.count>=A.nb_max:B.error=f"Limit errors reached ({A.nb_max})";A.limit_reached=G;return G
|
|
20
24
|
def get_data(B):
|
|
21
25
|
D=[{'id':A.id,'type':A.type,'name':A.name,'error':A.error,'total_diffs':A.total_diffs,'total_warnings':A.total_warnings,'total_errors':A.total_errors,'data':A.data,'info':A.info,'parent_id':A.parent.id if A.parent else _A}for A in B.groups];A={'messages':B.messages,'groups':D}
|
|
22
26
|
for(C,E)in B.errors.items():A[C]=[A.model_dump()for A in E];A[C+'_nb']=len(A[C])
|
|
@@ -62,7 +62,7 @@ class CompareFloats:
|
|
|
62
62
|
for j in range(test_nb_columns):
|
|
63
63
|
diff=test_mat[i][j]-ref_mat[i][j]
|
|
64
64
|
if diff==0:continue
|
|
65
|
-
else:diffs_count+=1
|
|
65
|
+
else:diffs_count+=1;group.incr('diff')
|
|
66
66
|
if err_limit_reached:continue
|
|
67
67
|
res_compare=self.compare_2_values(test_mat[i][j],ref_mat[i][j])
|
|
68
68
|
if res_compare:
|
scilens/readers/cols_dataset.py
CHANGED
|
@@ -26,22 +26,21 @@ def cols_dataset_get_curves_col_x(cols_dataset,col_x):
|
|
|
26
26
|
for D in J:B=A.data[C];K=A.data[D];L={I:A.names[D],'short_title':A.names[D],'series':[[B[A],K[A]]for A in range(A.rows_count)],_C:D};F+=[L];M={I:A.names[D],'type':'simple','xaxis':A.names[C],'yaxis':A.names[D],_B:[len(F)-1]};H+=[M]
|
|
27
27
|
return{_B:F,_E:H},E
|
|
28
28
|
def compare(group,compare_floats,reader_test,reader_ref,cols_curve):
|
|
29
|
-
|
|
30
|
-
if len(A.numeric_col_indexes)!=len(F.numeric_col_indexes):
|
|
31
|
-
|
|
32
|
-
if C and C.type==ReaderCurveParserNameConfig.COL_X:
|
|
33
|
-
|
|
29
|
+
O='Errors limit reached';F=reader_ref;D=group;C=cols_curve;A=reader_test;logging.debug(f"compare cols: {D.name}")
|
|
30
|
+
if len(A.numeric_col_indexes)!=len(F.numeric_col_indexes):D.error=f"Number Float columns indexes are different: {len(A.numeric_col_indexes)} != {len(F.numeric_col_indexes)}";return
|
|
31
|
+
E=[''for A in range(A.cols_count)];I=_A;G=_A
|
|
32
|
+
if C and C.type==ReaderCurveParserNameConfig.COL_X:J=C.info[_D];I=A.data[J];G=A.names[J]
|
|
33
|
+
K=False
|
|
34
34
|
for B in range(A.cols_count):
|
|
35
35
|
if B not in A.numeric_col_indexes:continue
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
if
|
|
39
|
-
if M.total_errors>0:D[B]=f"{M.total_errors} comparison errors"
|
|
36
|
+
P=A.data[B];Q=F.data[B];logging.debug(f"compare cols: {A.names[B]}");L,R,T=compare_floats.add_group_and_compare_vectors(A.names[B],D,{'info_prefix':G}if G else _A,P,Q,info_vector=I)
|
|
37
|
+
if R:K=True;E[B]=O;continue
|
|
38
|
+
if L.total_errors>0:E[B]=f"{L.total_errors} comparison errors"
|
|
40
39
|
if C:
|
|
41
|
-
for
|
|
42
|
-
|
|
43
|
-
for S in
|
|
44
|
-
|
|
45
|
-
if
|
|
46
|
-
|
|
47
|
-
|
|
40
|
+
for M in C.curves[_E]:
|
|
41
|
+
N=0
|
|
42
|
+
for S in M[_B]:
|
|
43
|
+
H=C.curves[_B][S]
|
|
44
|
+
if E[H[_C]]:H['comparison_error']=E[H[_C]];N+=1
|
|
45
|
+
M['comparison']={'curves_nb_with_error':N}
|
|
46
|
+
D.error=O if K else _A;D.info={'cols_has_error':E}
|
|
@@ -1,9 +1,24 @@
|
|
|
1
1
|
{% if file.comparison_errors %}
|
|
2
2
|
{% for group in file.comparison_errors.groups if group.type != 'node' %}
|
|
3
3
|
|
|
4
|
+
{% set group_status = 'ERROR' if group.error or group.total_errors else ('WARNING' if group.total_warnings else 'SUCCESS') %}
|
|
5
|
+
|
|
6
|
+
<h4>
|
|
7
|
+
{{ group.name }}
|
|
8
|
+
<span class="{{ group_status }}">{{ group_status }}</span>
|
|
9
|
+
<span class="text-xs rounded-lg mx-1 my-1">Err: {{ group.total_errors }}</span>
|
|
10
|
+
<span class="text-xs rounded-lg mx-1 my-1">Warn: {{ group.total_warnings }}</span>
|
|
11
|
+
<span class="text-xs rounded-lg mx-1 my-1">Diffs: {{ group.total_diffs }}</span>
|
|
12
|
+
</h4>
|
|
13
|
+
|
|
14
|
+
{% if group.error %}
|
|
15
|
+
<div>
|
|
16
|
+
<span class="ERROR"><code>{{ group.error }}</code></span>
|
|
17
|
+
</div>
|
|
18
|
+
{% endif %}
|
|
19
|
+
|
|
4
20
|
{% if group.total_warnings or group.total_errors %}
|
|
5
21
|
|
|
6
|
-
<h4>{{ group.name }}</h4>
|
|
7
22
|
{% include 'compare_13_section_numbers_table.html' with context %}
|
|
8
23
|
|
|
9
24
|
{% endif %}
|
|
@@ -9,8 +9,8 @@ scilens/cli/main.py,sha256=LljcS0s2E35y4YZpV01GhMhMK9HyRRHYmxc_q_kSurI,6004
|
|
|
9
9
|
scilens/components/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
10
|
scilens/components/analyse_folder.py,sha256=yqc-dscKaHLZJCYeXGak2v0c3F2aeX0E11AFPfya6r0,208
|
|
11
11
|
scilens/components/compare_2_files.py,sha256=U4xumE28ijFbnrTPH8FgRyR_b5f04jOjaCmegJvCvSE,1483
|
|
12
|
-
scilens/components/compare_errors.py,sha256=
|
|
13
|
-
scilens/components/compare_floats.py,sha256=
|
|
12
|
+
scilens/components/compare_errors.py,sha256=vGb4DWP89HMIeBm0dZU2nt-ksppAs_37xtCHaPd0w5Y,1640
|
|
13
|
+
scilens/components/compare_floats.py,sha256=p1lnnwkGJXIsb6Y5psQc_5FcOuB2vP_cIQHXhZjWPXc,5617
|
|
14
14
|
scilens/components/compare_folders.py,sha256=LZ1AuYxLVHMNbtXWXQrdms4vZgOQthvDy-8NFD_EFjc,2617
|
|
15
15
|
scilens/components/compare_models.py,sha256=SCPd747h_nd4ewZsqLB6CFr27v6q99NELJb-gpkdj0o,918
|
|
16
16
|
scilens/components/executor.py,sha256=j5xejkCaaPyl3V38Q4HxxXcAx4Tnj8CILAjSJ1G7OIE,3417
|
|
@@ -47,7 +47,7 @@ scilens/processors/models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJW
|
|
|
47
47
|
scilens/processors/models/results.py,sha256=KoWxh13Zgi7PuPql8hkf4VjCis42ZxAuzIgJxBWVaX8,119
|
|
48
48
|
scilens/processors/processor_interface.py,sha256=jzMp1529JXnMGTJijVy6b_1zmARAMNv70f2lgys7vn4,452
|
|
49
49
|
scilens/readers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
50
|
-
scilens/readers/cols_dataset.py,sha256=
|
|
50
|
+
scilens/readers/cols_dataset.py,sha256=C4N030_Iqq5KZVpQ0NVjAw4DctALuz_YBb6f6yi35Jk,2452
|
|
51
51
|
scilens/readers/exceptions.py,sha256=JzmxcjnR5sH-IOWVeCC5A1bSwxv-jCAtIJvDjzx1CTI,32
|
|
52
52
|
scilens/readers/mat_dataset.py,sha256=-2NJJxOu8qEMhni-kGT9F-MwDA98_Nrt2cC0TYMUNvw,1180
|
|
53
53
|
scilens/readers/reader_csv.py,sha256=aPd2IxFiUXYmH_EpNZkCHV1oMWctZW7YSPwC8q75SIo,3490
|
|
@@ -68,7 +68,7 @@ scilens/report/templates/body_99_footer.html,sha256=8cWebeWfZwZ-9bYAMZkZj8rbCWq3
|
|
|
68
68
|
scilens/report/templates/compare_11_summary.html,sha256=4rxBlOxTcn59ztYtqDbi6SRQXlaz30HkVl7dJpzCmZE,3776
|
|
69
69
|
scilens/report/templates/compare_12_sections.html,sha256=HWsfCmfdleyRK6IHJeMEheenOuyA0mLzOZ-0qLcuzJU,5952
|
|
70
70
|
scilens/report/templates/compare_13_section_numbers copy.html,sha256=0PWK_I2kNX3LjPLkkY4eSYIeB7YFkA28nk-PPLDhnaY,1753
|
|
71
|
-
scilens/report/templates/compare_13_section_numbers.html,sha256=
|
|
71
|
+
scilens/report/templates/compare_13_section_numbers.html,sha256=9etEMSqwrDyJIn_nMbKEVaDgnFL_hBxSjPR-hU2wgDI,851
|
|
72
72
|
scilens/report/templates/compare_13_section_numbers_table.html,sha256=sJy6ZYtjl80vM1b3oqZSXawZWp7KNIwLI_wCnvBwYPE,3270
|
|
73
73
|
scilens/report/templates/index.html,sha256=mNTu-CAzEJ2rhz81cHAdmT_KcQeOQ3b_FSC73NPEi0U,3670
|
|
74
74
|
scilens/report/templates/js_chartlibs_echarts.js,sha256=6YicVhTNIBmmBpV31XCVN5oBeiD0t29JIosJZRUv01M,907
|
|
@@ -97,7 +97,7 @@ scilens/utils/template.py,sha256=9dlXX3nmfzDRUwzPJOkoxk15UXivZ2SW-McdCwokFa4,443
|
|
|
97
97
|
scilens/utils/time_tracker.py,sha256=DdVBoMpVLXrX0qZZXyLm4g38EwDVLlRcBqcpNex1mYY,545
|
|
98
98
|
scilens/utils/vectors.py,sha256=4N2BZSC5n3HgZqPujDGF5NdjVmSL1rOHb_qw4OoABQY,103
|
|
99
99
|
scilens/utils/web.py,sha256=MAFWpIFOKz7QhqDoFh-Qwstvc76KpcxstSgHFT8FOL4,901
|
|
100
|
-
scilens-0.3.
|
|
101
|
-
scilens-0.3.
|
|
102
|
-
scilens-0.3.
|
|
103
|
-
scilens-0.3.
|
|
100
|
+
scilens-0.3.4.dist-info/METADATA,sha256=rLCgHhgfF0utkAo-hIq5y2IBXTV_GcLjdcQLSeqpnh0,1367
|
|
101
|
+
scilens-0.3.4.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
|
|
102
|
+
scilens-0.3.4.dist-info/entry_points.txt,sha256=DaKGgxUEUv34GJAoXtta6ecL37ercejep9sCSSRQK2s,48
|
|
103
|
+
scilens-0.3.4.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|