datachain 0.26.2__py3-none-any.whl → 0.26.3__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.
Potentially problematic release.
This version of datachain might be problematic. Click here for more details.
- datachain/lib/convert/flatten.py +5 -3
- datachain/lib/signal_schema.py +1 -1
- datachain/lib/udf.py +1 -1
- {datachain-0.26.2.dist-info → datachain-0.26.3.dist-info}/METADATA +1 -1
- {datachain-0.26.2.dist-info → datachain-0.26.3.dist-info}/RECORD +9 -9
- {datachain-0.26.2.dist-info → datachain-0.26.3.dist-info}/WHEEL +0 -0
- {datachain-0.26.2.dist-info → datachain-0.26.3.dist-info}/entry_points.txt +0 -0
- {datachain-0.26.2.dist-info → datachain-0.26.3.dist-info}/licenses/LICENSE +0 -0
- {datachain-0.26.2.dist-info → datachain-0.26.3.dist-info}/top_level.txt +0 -0
datachain/lib/convert/flatten.py
CHANGED
|
@@ -6,12 +6,14 @@ from datachain.lib.model_store import ModelStore
|
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
def flatten(obj: BaseModel) -> tuple:
|
|
9
|
-
return tuple(_flatten_fields_values(obj.model_fields, obj))
|
|
9
|
+
return tuple(_flatten_fields_values(type(obj).model_fields, obj))
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
def flatten_list(obj_list: list[BaseModel]) -> tuple:
|
|
13
13
|
return tuple(
|
|
14
|
-
val
|
|
14
|
+
val
|
|
15
|
+
for obj in obj_list
|
|
16
|
+
for val in _flatten_fields_values(type(obj).model_fields, obj)
|
|
15
17
|
)
|
|
16
18
|
|
|
17
19
|
|
|
@@ -43,4 +45,4 @@ def _flatten_fields_values(fields: dict, obj: BaseModel) -> Generator:
|
|
|
43
45
|
|
|
44
46
|
|
|
45
47
|
def _flatten(obj: BaseModel) -> tuple:
|
|
46
|
-
return tuple(_flatten_fields_values(obj.model_fields, obj))
|
|
48
|
+
return tuple(_flatten_fields_values(type(obj).model_fields, obj))
|
datachain/lib/signal_schema.py
CHANGED
|
@@ -550,7 +550,7 @@ class SignalSchema:
|
|
|
550
550
|
) -> None:
|
|
551
551
|
if isinstance(obj, File):
|
|
552
552
|
obj._set_stream(catalog, caching_enabled=cache)
|
|
553
|
-
for field, finfo in obj.model_fields.items():
|
|
553
|
+
for field, finfo in type(obj).model_fields.items():
|
|
554
554
|
if ModelStore.is_pydantic(finfo.annotation):
|
|
555
555
|
SignalSchema._set_file_stream(getattr(obj, field), catalog, cache)
|
|
556
556
|
|
datachain/lib/udf.py
CHANGED
|
@@ -282,7 +282,7 @@ class UDFBase(AbstractUDF):
|
|
|
282
282
|
|
|
283
283
|
# Check all fields for nested File objects, but only for DataModel objects
|
|
284
284
|
if isinstance(obj, DataModel):
|
|
285
|
-
for field_name in obj.model_fields:
|
|
285
|
+
for field_name in type(obj).model_fields:
|
|
286
286
|
field_value = getattr(obj, field_name, None)
|
|
287
287
|
if isinstance(field_value, DataModel):
|
|
288
288
|
self._set_stream_recursive(field_value, catalog, cache, download_cb)
|
|
@@ -86,17 +86,17 @@ datachain/lib/namespaces.py,sha256=it52UbbwB8dzhesO2pMs_nThXiPQ1Ph9sD9I3GQkg5s,2
|
|
|
86
86
|
datachain/lib/projects.py,sha256=8lN0qV8czX1LGtWURCUvRlSJk-RpO9w9Rra_pOZus6g,2595
|
|
87
87
|
datachain/lib/pytorch.py,sha256=S-st2SAczYut13KMf6eSqP_OQ8otWI5TRmzhK5fN3k0,7828
|
|
88
88
|
datachain/lib/settings.py,sha256=9wi0FoHxRxNiyn99pR28IYsMkoo47jQxeXuObQr2Ar0,2929
|
|
89
|
-
datachain/lib/signal_schema.py,sha256=
|
|
89
|
+
datachain/lib/signal_schema.py,sha256=JMsL8c4iCRH9PoRumvjimsOLQQslTjm_aDR2jh1zT2Q,38558
|
|
90
90
|
datachain/lib/tar.py,sha256=MLcVjzIgBqRuJacCNpZ6kwSZNq1i2tLyROc8PVprHsA,999
|
|
91
91
|
datachain/lib/text.py,sha256=UNHm8fhidk7wdrWqacEWaA6I9ykfYqarQ2URby7jc7M,1261
|
|
92
|
-
datachain/lib/udf.py,sha256=
|
|
92
|
+
datachain/lib/udf.py,sha256=SUnJWRDC3TlLhvpi8iqqJbeZGn5DChot7DyH-0Q-z20,17305
|
|
93
93
|
datachain/lib/udf_signature.py,sha256=Yz20iJ-WF1pijT3hvcDIKFzgWV9gFxZM73KZRx3NbPk,7560
|
|
94
94
|
datachain/lib/utils.py,sha256=rG2y7NwTqZOuomZZRmrA-Q-ANM_j1cToQYqDJoOeGyU,1480
|
|
95
95
|
datachain/lib/video.py,sha256=u6fLJWj5G6QqsVkpfHnKGklBNpG3BRRg6v3izngnNcU,6767
|
|
96
96
|
datachain/lib/webdataset.py,sha256=CkW8FfGigNx6wo2EEK4KMjhEE8FamRHWGs2HZuH7jDY,7214
|
|
97
97
|
datachain/lib/webdataset_laion.py,sha256=xvT6m_r5y0KbOx14BUe7UC5mOgrktJq53Mh-H0EVlUE,2525
|
|
98
98
|
datachain/lib/convert/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
99
|
-
datachain/lib/convert/flatten.py,sha256=
|
|
99
|
+
datachain/lib/convert/flatten.py,sha256=_5rjGFnN6t1KCX5ftL5rG7tiiNat7j0SdNqajO15KUY,1539
|
|
100
100
|
datachain/lib/convert/python_to_sql.py,sha256=wg-O5FRKX3x3Wh8ZL1b9ntMlgf1zRO4djMP3t8CHJLo,3188
|
|
101
101
|
datachain/lib/convert/sql_to_python.py,sha256=Gxc4FylWC_Pvvuawuc2MKZIiuAWI7wje8pyeN1MxRrU,670
|
|
102
102
|
datachain/lib/convert/unflatten.py,sha256=ysMkstwJzPMWUlnxn-Z-tXJR3wmhjHeSN_P-sDcLS6s,2010
|
|
@@ -158,9 +158,9 @@ datachain/sql/sqlite/vector.py,sha256=ncW4eu2FlJhrP_CIpsvtkUabZlQdl2D5Lgwy_cbfqR
|
|
|
158
158
|
datachain/toolkit/__init__.py,sha256=eQ58Q5Yf_Fgv1ZG0IO5dpB4jmP90rk8YxUWmPc1M2Bo,68
|
|
159
159
|
datachain/toolkit/split.py,sha256=ktGWzY4kyzjWyR86dhvzw-Zhl0lVk_LOX3NciTac6qo,2914
|
|
160
160
|
datachain/torch/__init__.py,sha256=gIS74PoEPy4TB3X6vx9nLO0Y3sLJzsA8ckn8pRWihJM,579
|
|
161
|
-
datachain-0.26.
|
|
162
|
-
datachain-0.26.
|
|
163
|
-
datachain-0.26.
|
|
164
|
-
datachain-0.26.
|
|
165
|
-
datachain-0.26.
|
|
166
|
-
datachain-0.26.
|
|
161
|
+
datachain-0.26.3.dist-info/licenses/LICENSE,sha256=8DnqK5yoPI_E50bEg_zsHKZHY2HqPy4rYN338BHQaRA,11344
|
|
162
|
+
datachain-0.26.3.dist-info/METADATA,sha256=HdG_quEq0rfrdKJJ_teSViVCXbXI3SxLlnh6tu2Mgfs,13543
|
|
163
|
+
datachain-0.26.3.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
164
|
+
datachain-0.26.3.dist-info/entry_points.txt,sha256=0GMJS6B_KWq0m3VT98vQI2YZodAMkn4uReZ_okga9R4,49
|
|
165
|
+
datachain-0.26.3.dist-info/top_level.txt,sha256=lZPpdU_2jJABLNIg2kvEOBi8PtsYikbN1OdMLHk8bTg,10
|
|
166
|
+
datachain-0.26.3.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|