You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When installing SCDL for local development purposes, there is a missing dependency:
git clone https://github.com/nvidia/bionemo-framework.git
cd bionemo-framework/sub-packages/bionemo-scdl
pip install -e .
Running the above raises the following:
Traceback (most recent call last):
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/networks.py", line 865, in import_email_validator
import email_validator
ModuleNotFoundError: No module named 'email_validator'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/edawson/nv/bionemo-framework/sub-packages/bionemo-scdl/src/bionemo/scdl/scripts/convert_multiread.py", line 3, in <module>
from bionemo.core.data.load import load
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/bionemo/core/data/load.py", line 33, in <module>
from bionemo.core.data.resource import Resource, get_all_resources
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/bionemo/core/data/resource.py", line 39, in <module>
class Resource(pydantic.BaseModel):
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_model_construction.py", line 226, in __new__
complete_model_class(
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_model_construction.py", line 658, in complete_model_class
schema = cls.__get_pydantic_core_schema__(cls, handler)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/main.py", line 702, in __get_pydantic_core_schema__
return handler(source)
^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_schema_generation_shared.py", line 84, in __call__
schema = self._handler(source_type)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_generate_schema.py", line 612, in generate_schema
schema = self._generate_schema_inner(obj)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_generate_schema.py", line 881, in _generate_schema_inner
return self._model_schema(obj)
^^^^^^^^^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_generate_schema.py", line 693, in _model_schema
{k: self._generate_md_field_schema(k, v, decorators) for k, v in fields.items()},
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_generate_schema.py", line 693, in <dictcomp>
{k: self._generate_md_field_schema(k, v, decorators) for k, v in fields.items()},
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_generate_schema.py", line 1073, in _generate_md_field_schema
common_field = self._common_field_schema(name, field_info, decorators)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_generate_schema.py", line 1261, in _common_field_schema
schema = self._apply_annotations(
^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_generate_schema.py", line 2061, in _apply_annotations
schema = get_inner_schema(source_type)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_schema_generation_shared.py", line 84, in __call__
schema = self._handler(source_type)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_generate_schema.py", line 2040, in inner_handler
from_property = self._generate_schema_from_property(obj, source_type)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/_internal/_generate_schema.py", line 761, in _generate_schema_from_property
schema = get_schema(
^^^^^^^^^^^
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/networks.py", line 980, in __get_pydantic_core_schema__
import_email_validator()
File "/home/edawson/miniconda3/envs/scdl/lib/python3.11/site-packages/pydantic/networks.py", line 867, in import_email_validator
raise ImportError('email-validator is not installed, run `pip install pydantic[email]`') from e
ImportError: email-validator is not installed, run `pip install pydantic[email]`
Installing pydantic[email] fixes the issue. However, we shouldn't need the email parser is my assumption.
In addition, SCDL now has a dependency on bionemo-core, meaning it requires all of that package's dependencies. Is there a way to minimize the dependency surface so that users could easily install standalone SCDL without having to install all of bionemo-core, torch, nccl, etc?
The text was updated successfully, but these errors were encountered:
When installing SCDL for local development purposes, there is a missing dependency:
Running the above raises the following:
Installing
pydantic[email]
fixes the issue. However, we shouldn't need the email parser is my assumption.In addition, SCDL now has a dependency on bionemo-core, meaning it requires all of that package's dependencies. Is there a way to minimize the dependency surface so that users could easily install standalone SCDL without having to install all of bionemo-core, torch, nccl, etc?
The text was updated successfully, but these errors were encountered: