datamaestro 1.7.1__py3-none-any.whl → 1.7.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.
@@ -646,7 +646,7 @@ class reference(Resource):
646
646
  For function-based datasets, the reference is already a DatasetWrapper.
647
647
  """
648
648
  ref = self.reference
649
- if hasattr(ref, "__dataset__"):
649
+ if isinstance(ref, type) and hasattr(ref, "__dataset__"):
650
650
  return ref.__dataset__
651
651
  return ref
652
652
 
@@ -2,6 +2,30 @@ import logging
2
2
  import importlib
3
3
  import inspect
4
4
  from datamaestro.context import Context
5
+ from experimaestro.tools.documentation import DocumentationAnalyzer
6
+
7
+
8
+ class DatamaestroAnalyzer(DocumentationAnalyzer):
9
+ """Documentation analyzer that excludes @dataset-annotated classes.
10
+
11
+ Dataset definitions (classes decorated with ``@dataset``) are documented
12
+ via ``dm:datasets`` Sphinx directives, not ``autoxpmconfig``. This
13
+ subclass filters them from the undocumented list after analysis.
14
+ """
15
+
16
+ def analyze(self):
17
+ super().analyze()
18
+ filtered = []
19
+ for fqn in self.undocumented:
20
+ module_name, class_name = fqn.rsplit(".", 1)
21
+ try:
22
+ mod = importlib.import_module(module_name)
23
+ cls = getattr(mod, class_name)
24
+ if not hasattr(cls, "__dataset__"):
25
+ filtered.append(fqn)
26
+ except (ImportError, AttributeError):
27
+ filtered.append(fqn)
28
+ self.undocumented = filtered
5
29
 
6
30
 
7
31
  class DatasetTests:
datamaestro/version.py CHANGED
@@ -1,4 +1,4 @@
1
1
  # This file is auto-generated by Hatchling. As such, do not:
2
2
  # - modify
3
3
  # - track in version control e.g. be sure to add to .gitignore
4
- __version__ = VERSION = '1.7.1'
4
+ __version__ = VERSION = '1.7.3'
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: datamaestro
3
- Version: 1.7.1
3
+ Version: 1.7.3
4
4
  Summary: Add your description here
5
5
  Author-email: Benjamin Piwowarski <benjamin@piwowarski.fr>
6
6
  License-File: LICENSE
@@ -9,7 +9,7 @@ datamaestro/settings.py,sha256=NuUbe_C31GDlzdio2ryz7tPzuo4hsmmdCM5Cyuhqbzs,1294
9
9
  datamaestro/sphinx.py,sha256=WWXB63gd0ZgEwFr_YwO2Hmuly5OoiFlu9mDvJSHFYuY,6966
10
10
  datamaestro/utils.py,sha256=JUrvtVYnjNKRo0_ZypmXSQ9R4uOyImDjW1GZ14MYzKM,6547
11
11
  datamaestro/v2.md,sha256=pLCxQUdfVkd4CM9Ie0ZxCnxUntqoA7k_0m7x1etcr7Y,9801
12
- datamaestro/version.py,sha256=Hy65VR_YBBs2cTGjk4KdU_bIDh0FtKY39zpOkoQNGIE,171
12
+ datamaestro/version.py,sha256=qbNPC0YY-TxmiwHVzSS5pF2Eykd0T9k-YiM7b0ut3i4,171
13
13
  datamaestro/annotations/__init__.py,sha256=jLprrxSBa5QIqc--vqycEcxU4CR9WjVNRaqR5lH0EuE,39
14
14
  datamaestro/annotations/agreement.py,sha256=xEH0ddZxdJ_oG_150PoOa-WjY_OaeQja3FzMzY5IB6k,955
15
15
  datamaestro/commands/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -20,7 +20,7 @@ datamaestro/data/csv.py,sha256=jcXFVBOEQoSi3YL60bqtwjCf2YXHboaMpUmiXZpzuPM,2506
20
20
  datamaestro/data/huggingface.py,sha256=rCMiMqVgNI9zRAgm9PYnbwb7musYryBoIP3HuJmH4sg,691
21
21
  datamaestro/data/ml.py,sha256=4PlH6FJFZwtfTEStkOjOucV8t8yY8LFaPsnDBvEqAPs,710
22
22
  datamaestro/data/tensor.py,sha256=in36UQz4cdUEVmCS62pInu9RNekohRON667Z_JqNdhk,2254
23
- datamaestro/download/__init__.py,sha256=az_H9i5ynY_tsnjYiBiFMzTzeaOoEMaxh-knj57tSLc,20087
23
+ datamaestro/download/__init__.py,sha256=uFBD-xuTVbMpLQEHTGpVXnKxL8G0VcLuX-gTRKYWXBM,20113
24
24
  datamaestro/download/archive.py,sha256=fz1ElRggB9gYb6F7fek0Tkw9eAj6Glotc_Mit9OcCZU,6986
25
25
  datamaestro/download/custom.py,sha256=dxyvwbweVuz0xveExtvta8xycoqTjpDZz_P98ucintA,1287
26
26
  datamaestro/download/huggingface.py,sha256=inZbB5EdVvczW9CfM59SqL1Nl-H4y3bWxv1SWjrYeOs,1996
@@ -36,14 +36,14 @@ datamaestro/stream/compress.py,sha256=0ViFGpJc6pdvZGUNERE-3XV8jAOTSvhJurb2t0NW2e
36
36
  datamaestro/stream/lines.py,sha256=DhptjIqhhAJ1tu3e-uoOepHHNALSXS8qz8ASUAyaSkM,2074
37
37
  datamaestro/templates/dataset.py,sha256=5065rTMAIl4gtzQ96GFiV1_46tY08miIx3WspTP8yGA,346
38
38
  datamaestro/test/__init__.py,sha256=9xXqLvUgiIn74AY6k8qyYX7rq6hWz7dOJFBrUgwuX88,61
39
- datamaestro/test/checks.py,sha256=1eTkz4YJhAPOcnQSsz4vPnvzwwfrEnpn6H_s1ADISpo,1704
39
+ datamaestro/test/checks.py,sha256=yoL7SjasWPD95ieyTcEYeBffZkTwohJZpj1aWgU2wWA,2629
40
40
  datamaestro/test/conftest.py,sha256=z8rF0OIKVuCgIYJ-4fQxQL8KhgIfg_4kfkIZNETfNJ0,793
41
41
  datamaestro/test/test_annotations.py,sha256=XUjDWb3FJimSD91wcItJ0lLwTBmvN4wVu_EgTKSvV2c,278
42
42
  datamaestro/test/test_download_handlers.py,sha256=-Gofr89zqIyeI8C4rZqfYR3JfiZVImdcSz9s6q361zQ,641
43
43
  datamaestro/test/test_record.py,sha256=hNZ3uo2i5FZ0VsOHRwvLO1Z6Zce92PdipAF65UptPB8,1156
44
44
  datamaestro/test/test_resource.py,sha256=QbwmZkGv_8O_jI0CKcatJSUs3IKbMfBrk0T_aTC1KcE,51124
45
- datamaestro-1.7.1.dist-info/METADATA,sha256=7voV0DURyp-8ShRiMFK1wGE5SoMrTHL4U6if3dYvB9I,7433
46
- datamaestro-1.7.1.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
47
- datamaestro-1.7.1.dist-info/entry_points.txt,sha256=8qMhwSRvFG2iBqtJYVD22Zd4s4c3YkODtcp0Ajw1knw,133
48
- datamaestro-1.7.1.dist-info/licenses/LICENSE,sha256=WJ7YI-moTFb-uVrFjnzzhGJrnL9P2iqQe8NuED3hutI,35141
49
- datamaestro-1.7.1.dist-info/RECORD,,
45
+ datamaestro-1.7.3.dist-info/METADATA,sha256=9EfCsWxYzjfZgcNi2_1dNoD8s-MijuQVdeK_7L6TEZY,7433
46
+ datamaestro-1.7.3.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
47
+ datamaestro-1.7.3.dist-info/entry_points.txt,sha256=8qMhwSRvFG2iBqtJYVD22Zd4s4c3YkODtcp0Ajw1knw,133
48
+ datamaestro-1.7.3.dist-info/licenses/LICENSE,sha256=WJ7YI-moTFb-uVrFjnzzhGJrnL9P2iqQe8NuED3hutI,35141
49
+ datamaestro-1.7.3.dist-info/RECORD,,