scistackplotdb 0.1.48__tar.gz → 0.1.49__tar.gz
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.
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/PKG-INFO +5 -5
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/src/scistackplotdb/load.py +0 -53
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/.gitignore +0 -0
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/README.md +0 -0
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/pyproject.toml +0 -0
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/src/scistackplotdb/__init__.py +0 -0
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/src/scistackplotdb/_versioned.py +0 -0
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/src/scistackplotdb/bundle_section.py +0 -0
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/src/scistackplotdb/endpoint.py +0 -0
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/src/scistackplotdb/hierarchy.py +0 -0
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/src/scistackplotdb/presets.py +0 -0
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/src/scistackplotdb/saved.py +0 -0
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/src/scistackplotdb/source.py +0 -0
- {scistackplotdb-0.1.48 → scistackplotdb-0.1.49}/src/scistackplotdb/variants.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: scistackplotdb
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.49
|
|
4
4
|
Summary: scidb-backed plotting: load variables into long tables and plot them with scistackplot
|
|
5
5
|
Author: SciStack Contributors
|
|
6
6
|
License-Expression: MIT
|
|
@@ -17,10 +17,10 @@ Classifier: Programming Language :: Python :: 3.13
|
|
|
17
17
|
Classifier: Topic :: Scientific/Engineering :: Visualization
|
|
18
18
|
Classifier: Typing :: Typed
|
|
19
19
|
Requires-Python: >=3.10
|
|
20
|
-
Requires-Dist: sciduckdb==0.1.
|
|
21
|
-
Requires-Dist: scistack-db==0.1.
|
|
22
|
-
Requires-Dist: scistacklog==0.1.
|
|
23
|
-
Requires-Dist: scistackplot==0.1.
|
|
20
|
+
Requires-Dist: sciduckdb==0.1.49
|
|
21
|
+
Requires-Dist: scistack-db==0.1.49
|
|
22
|
+
Requires-Dist: scistacklog==0.1.49
|
|
23
|
+
Requires-Dist: scistackplot==0.1.49
|
|
24
24
|
Provides-Extra: dev
|
|
25
25
|
Requires-Dist: matplotlib>=3.6; extra == 'dev'
|
|
26
26
|
Requires-Dist: pytest-cov>=4.0; extra == 'dev'
|
|
@@ -519,9 +519,6 @@ def load_variable(
|
|
|
519
519
|
if columns and len(frame):
|
|
520
520
|
with timer.phase("field_coverage"):
|
|
521
521
|
_log_field_coverage(variable, frame, column_types, levels)
|
|
522
|
-
if len(frame) > 1:
|
|
523
|
-
with timer.phase("identical_content"):
|
|
524
|
-
_log_identical_content(db, variable, frame, keys)
|
|
525
522
|
return VariableFrame(
|
|
526
523
|
name=variable,
|
|
527
524
|
frame=frame,
|
|
@@ -684,56 +681,6 @@ def _log_field_coverage(
|
|
|
684
681
|
Log.debug("field coverage of %s failed: %s", variable, exc, layer=LAYER)
|
|
685
682
|
|
|
686
683
|
|
|
687
|
-
def _log_identical_content(db, variable: str, frame: pd.DataFrame, keys) -> None:
|
|
688
|
-
"""Warn when records of ``variable`` hold byte-identical payloads, naming
|
|
689
|
-
the schema keys that vary across each duplicate group.
|
|
690
|
-
|
|
691
|
-
This is the one thing a plot cannot show you. N records with the same data
|
|
692
|
-
render as N traces drawn exactly on top of each other: the figure looks
|
|
693
|
-
like a single line in whatever colour was drawn last, and filtering to any
|
|
694
|
-
one value of the colour factor shows the same curve again. That is the
|
|
695
|
-
signature of a step that ran with ``distribute=False`` when it should have
|
|
696
|
-
distributed — every location of the key got the whole result instead of
|
|
697
|
-
its own slice — so it belongs in the log at load time rather than being
|
|
698
|
-
re-derived from a confusing figure.
|
|
699
|
-
|
|
700
|
-
Never raises: duplicate content is legal, and a diagnostic must not be able
|
|
701
|
-
to break a load.
|
|
702
|
-
"""
|
|
703
|
-
try:
|
|
704
|
-
from scidb.provenance_query import identical_content_groups
|
|
705
|
-
|
|
706
|
-
groups = identical_content_groups(db._duck, variable)
|
|
707
|
-
if not groups:
|
|
708
|
-
return
|
|
709
|
-
varying: set = set()
|
|
710
|
-
indexed = frame.set_index("record_id")
|
|
711
|
-
for _hash, record_ids in groups:
|
|
712
|
-
present = [rid for rid in record_ids if rid in indexed.index]
|
|
713
|
-
if len(present) < 2:
|
|
714
|
-
continue
|
|
715
|
-
for key in keys:
|
|
716
|
-
values = {indexed.at[rid, key] for rid in present}
|
|
717
|
-
if len(values) > 1:
|
|
718
|
-
varying.add(key)
|
|
719
|
-
Log.warn(
|
|
720
|
-
"%s: %d group(s) of records hold IDENTICAL data "
|
|
721
|
-
"(%d record(s) total); they differ only by %s. Plots colored or "
|
|
722
|
-
"faceted by those keys will draw overlapping identical traces. "
|
|
723
|
-
"This is what a step that should have run with distribute=True "
|
|
724
|
-
"looks like.",
|
|
725
|
-
variable,
|
|
726
|
-
len(groups),
|
|
727
|
-
sum(len(rids) for _h, rids in groups),
|
|
728
|
-
sorted(varying) or "no schema key",
|
|
729
|
-
layer=LAYER,
|
|
730
|
-
)
|
|
731
|
-
except Exception as e: # diagnostics must never break a load
|
|
732
|
-
Log.debug(
|
|
733
|
-
"identical-content check skipped for %s: %s", variable, e, layer=LAYER
|
|
734
|
-
)
|
|
735
|
-
|
|
736
|
-
|
|
737
684
|
def attach_variants(
|
|
738
685
|
db, frame: pd.DataFrame
|
|
739
686
|
) -> tuple[pd.DataFrame, list[str], str | None, list[dict]]:
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|