deriva-ml 1.14.38__py3-none-any.whl → 1.14.39__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.
deriva_ml/core/base.py CHANGED
@@ -134,8 +134,10 @@ class DerivaML(Dataset):
134
134
  this argument must be provided a value.
135
135
  ml_schema: Schema name for ML schema. Used if you have a non-standard configuration of deriva-ml.
136
136
  project_name: Project name. Defaults to name of domain schema.
137
- cache_dir: Directory path for caching data downloaded from the Deriva server as bdbag.
138
- working_dir: Directory path for storing data used by or generated by any computations.
137
+ cache_dir: Directory path for caching data downloaded from the Deriva server as bdbag. If not provided,
138
+ will default to working_dir.
139
+ working_dir: Directory path for storing data used by or generated by any computations. If no value is
140
+ provided, will default to ${HOME}/deriva_ml
139
141
  use_minid: Use the MINID service when downloading dataset bags.
140
142
  """
141
143
  # Get or use provided credentials for server access
@@ -320,6 +320,11 @@ class Workflow(BaseModel):
320
320
  if not (filename.exists() or Workflow._in_repl()):
321
321
  # Being called from the command line interpreter.
322
322
  filename = Path.cwd() / Path("REPL")
323
+ # Get the caller's filename, which is two up the stack from here.
324
+ elif "PYTEST_CURRENT_TEST" in os.environ:
325
+ filename = Path.cwd() / Path("pytest")
326
+ else:
327
+ raise DerivaMLException("Looking for caller failed") # Stack is too shallow
323
328
  return filename, is_notebook
324
329
 
325
330
  @staticmethod
@@ -1,4 +1,3 @@
1
- # your_pkg/install_kernel.py
2
1
  import re
3
2
  import sys
4
3
  from argparse import ArgumentParser
@@ -326,7 +326,7 @@ class DatabaseModel(DerivaModel, metaclass=DatabaseModelMeta):
326
326
  except ValueError:
327
327
  tname = table
328
328
  for sname in [self.domain_schema, self.ml_schema, "WWW"]: # Be careful of File table.
329
- if table in self.model.schemas[sname].tables:
329
+ if sname in self.model.schemas and table in self.model.schemas[sname].tables:
330
330
  break
331
331
  try:
332
332
  _ = self.model.schemas[sname].tables[tname]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: deriva-ml
3
- Version: 1.14.38
3
+ Version: 1.14.39
4
4
  Summary: Utilities to simplify use of Dervia and Pandas to create reproducable ML pipelines
5
5
  Author-email: ISRD <isrd-dev@isi.edu>
6
6
  Requires-Python: >=3.10
@@ -2,10 +2,10 @@ deriva_ml/__init__.py,sha256=_aMdxGG4mRTcXodLZLNpXqH8v5uqMbqFUryE9KqNSB8,1158
2
2
  deriva_ml/bump_version.py,sha256=KpHmkpEztly2QHYL4dyaIGdEMyP4F0D89rawyh5EDTs,3982
3
3
  deriva_ml/demo_catalog.py,sha256=JjPAIac_hKPh5krEhGJydjXquRnivi7kQoR8W4Khp-s,14928
4
4
  deriva_ml/feature.py,sha256=6-aphkxdKjWa9oPSGFWxHcwAc_8hmWj-7I4M178YG5Y,8470
5
- deriva_ml/install_kernel.py,sha256=KP1CLOp5eDd2MGWZCpVIIB1DeDH3rQdqW4rba2EYsA0,2194
5
+ deriva_ml/install_kernel.py,sha256=b62XY0SLViYO_Zye5r1Pl9qhYZyu_fk4KAO8NS1pxgM,2165
6
6
  deriva_ml/run_notebook.py,sha256=XPZPtGDLv0Ej6dcqIwA1dx_ya1Z9kzsP7um473WtLpU,6519
7
7
  deriva_ml/core/__init__.py,sha256=V_i90pc5PB1F4UdOO6DZWzpEFaZDTaPRU-EzKXQ19eI,787
8
- deriva_ml/core/base.py,sha256=uG7xyVk12fXXWipusRmaBGplxbdlnN9sIOGAEHWD8i8,61090
8
+ deriva_ml/core/base.py,sha256=5H0GEMlKXUVRXBYXJQ25kxdscB6uX1wIKSUAM_CBOhI,61228
9
9
  deriva_ml/core/constants.py,sha256=6wBJ8qMxe-dbCjRGrjUIX-RK0mTWrLDTeUpaVbLFoM8,888
10
10
  deriva_ml/core/definitions.py,sha256=uq_8uYFBVBVHS691Ri2kdQsN37z0GNYTaZskJIb_ocM,1385
11
11
  deriva_ml/core/enums.py,sha256=sSN4B4OynbB-AXwxRszoFr-KWIWIAfhVa06EzAEHwVc,7194
@@ -22,10 +22,10 @@ deriva_ml/execution/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSu
22
22
  deriva_ml/execution/environment.py,sha256=B7nywqxFTRUWgyu8n7rFoKcVC9on422kjeFG2FPQfvg,9302
23
23
  deriva_ml/execution/execution.py,sha256=NJT4qzZvvBXAlh73NVM39VE-uinSVBu2mHtuZD35G1M,44591
24
24
  deriva_ml/execution/execution_configuration.py,sha256=Rw4VWkBCZN9yatvSKdTqEWTfu470lpcVKfHFR0uN0jI,6248
25
- deriva_ml/execution/workflow.py,sha256=-dX2Yyd9PWRO0Lcr-ji-e7KmlOShE795B5PvJKacz2Q,13293
25
+ deriva_ml/execution/workflow.py,sha256=3GkmydZFk0zVPHdfiqIeJqNO73ocfUw22miB8tcado8,13591
26
26
  deriva_ml/model/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
27
27
  deriva_ml/model/catalog.py,sha256=dzTBcRlqgEVkPY32AUax_iu75RgFiT4Pu5au7rmrv8k,14068
28
- deriva_ml/model/database.py,sha256=MlXQQFgFmGxZbRx-unRFoRttXwpJspV4v2AIgppttCU,14805
28
+ deriva_ml/model/database.py,sha256=SBkYFf0qwbGmvL0Xtn_n5DCz4roGfrhuYrM8G69Cy9Y,14837
29
29
  deriva_ml/model/sql_mapper.py,sha256=_0QsJEVSgSPtxrWKSgjfPZCQ1aMVcjR_Tk2OxLhWEvY,1696
30
30
  deriva_ml/schema/__init__.py,sha256=yV-MfzCF3FA4OOz7mZwMM2q6-x1vgOJ057kUvikFF6E,130
31
31
  deriva_ml/schema/annotations.py,sha256=TuQ3vWFnK0160fRmtvsCkHx9qAcRa63MSyERB4x5a98,18197
@@ -34,9 +34,9 @@ deriva_ml/schema/create_schema.py,sha256=IrnSfN0ufS3M31MD8M6ZWyfJidKllLPqDFBUDAI
34
34
  deriva_ml/schema/deriva-ml-reference.json,sha256=AEOMIgwKO3dNMMWHb0lxaXyamvfAEbUPh8qw0aAtsUQ,242460
35
35
  deriva_ml/schema/policy.json,sha256=5ykB8nnZFl-oCHzlAwppCFKJHWJFIkYognUMVEanfY8,1826
36
36
  deriva_ml/schema/table_comments_utils.py,sha256=4flCqnZAaqg_uSZ9I18pNUWAZoLfmMCXbmI5uERY5vM,2007
37
- deriva_ml-1.14.38.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
38
- deriva_ml-1.14.38.dist-info/METADATA,sha256=Z2qErsTtCIH_vjaNUxRurxmNeeY4ElkhbcdtjtGWAVM,1122
39
- deriva_ml-1.14.38.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
40
- deriva_ml-1.14.38.dist-info/entry_points.txt,sha256=XsHSbfp7S1cKMjHoPUdFIaFcp9lHXHS6CV1zb_MEXkg,463
41
- deriva_ml-1.14.38.dist-info/top_level.txt,sha256=I1Q1dkH96cRghdsFRVqwpa2M7IqJpR2QPUNNc5-Bnpw,10
42
- deriva_ml-1.14.38.dist-info/RECORD,,
37
+ deriva_ml-1.14.39.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
38
+ deriva_ml-1.14.39.dist-info/METADATA,sha256=LvYoN3NRrXXEaNfFnTH9w6CPpCvFtrZ-kkh0iFLcE7Q,1122
39
+ deriva_ml-1.14.39.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
40
+ deriva_ml-1.14.39.dist-info/entry_points.txt,sha256=XsHSbfp7S1cKMjHoPUdFIaFcp9lHXHS6CV1zb_MEXkg,463
41
+ deriva_ml-1.14.39.dist-info/top_level.txt,sha256=I1Q1dkH96cRghdsFRVqwpa2M7IqJpR2QPUNNc5-Bnpw,10
42
+ deriva_ml-1.14.39.dist-info/RECORD,,