zincware / ZnTrack

Create, visualize, run & benchmark DVC pipelines in Python & Jupyter notebooks.
https://zntrack.readthedocs.io
Apache License 2.0
44 stars 4 forks source link

Allow `grp.__getitem__` #773

Closed PythonFZ closed 4 months ago

PythonFZ commented 4 months ago

https://github.com/zincware/ZnTrack/blob/ce2a5722dada57291852bdb57f2a9e7e87ecb9b5/zntrack/project/zntrack_project.py#L476-L489

In the __getitem and __contains__ support names without the group name prefix, such that all of the following work

"AL0_MLModel" in grp
"MLModel" in grp
grp["AL0_MLModel"]
grp["MLModel"]