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
Right now sample subtype objects can be installed or loaded by importing a file; sample subtype classes must define a __library__ attribute, like in this code:
for _, module in inspect.getmembers(sys.modules["pipelines"], lambda member: inspect.ismodule(member)):
st = inspect.getmembers(module, lambda member: inspect.isclass(member) and hasattr(member, "__library__"))
sample_types += st
Instead, we could:
simply search the modules for class members that extend Sample
eliminate __library__
perhaps indicate in pipeline_interface if such a class exists ?
Currently in make_samplehere each sample re-loads and re-imports modules, which is inefficient.
The pipeline interface has this information and could be used to map a sample to its specific Sample child classes.
In the future, we need to continue to allow 2 ways of doing this:
easy-user way, where users clone pipelines and then analysis scripts can load sample child classes as needed from those files, which may differ from project to project
developer mode, where python-savvy user uses virtual environments per project and installs pipeline scripts, so they need to be imported.
The text was updated successfully, but these errors were encountered:
Right now sample subtype objects can be installed or loaded by importing a file; sample subtype classes must define a
__library__
attribute, like in this code:Instead, we could:
Sample
__library__
Currently in
make_sample
here each sample re-loads and re-imports modules, which is inefficient.The pipeline interface has this information and could be used to map a sample to its specific Sample child classes.
In the future, we need to continue to allow 2 ways of doing this:
The text was updated successfully, but these errors were encountered: