Tidy up the model subpackages
See original GitHub issue🚀 Refactoring
The structure in pl_bolts.models is not user-friendly due to:
-
an inconsistent structure, for example:
from pl_bolts.models.vision import SemSegment # This works fine. from pl_bolts.models.vision import ImageGPT # This doesn't work, from pl_bolts.models import ImageGPT # but this works. -
several ways to import a certain class, for example: <- (related: #423)
from pl_bolts.models import LogisticRegression from pl_bolts.models.regression import LogisticRegression from pl_bolts.models.regression.logistic_regression import LogisticRegression
Pitch
Two options I have in mind to make it consistent are:
-
Make all models available right under
pl_bolts.modelspl_bolts.models.VAE pl_bolts.models.AE pl_bolts.models.ImageGPT pl_bolts.models.PixelCNN pl_bolts.models.SwAV pl_bolts.models.SimCLR ... -
Split models into domains, e.g.
vision,self_supervised… (which I prefer)pl_bolts.models.autoencoders.VAE pl_bolts.models.autoencoders.AE pl_bolts.models.vision.ImageGPT pl_bolts.models.vision.PixelCNN pl_bolts.models.self_supervised.SwAV pl_bolts.models.self_supervised.SimCLR ...
@Borda @ananyahjha93 @annikabrundyn @oke-aditya I’d love to hear your opinions on if it should be as is or another interface :]
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:14 (14 by maintainers)
Top Results From Across the Web
How can I let Django load models from subpackages of apps?
Is there any way to let Django dynamically read all the model classes in all models.py files in all subpackages of app ?...
Read more >10.4. Creating Subpackages - Jeff's Home Page
In most cases, subpackages are created just as a means to partition the files produced by a package into separate packages. For example,...
Read more >Proper way of organizing code into subpackages - New to Julia
C. Build sub packages into actual packages. Do generate foo_dir/foo under Pkg mode and use dev foo_dir/foo in bar's environment.
Read more >SDist builds incorrectly auto detects subpackages of excluded ...
I just tested this on Poetry version 1.0.0b4 and I'm still seeing the same issue. ... fix: exclude subpackage from setup.py if __init__.py...
Read more >3.3. Providing syspaths Subpackages - Red Hat Customer Portal
The wrapper installed in /usr/bin/ sets up the correct environment and executes the target binary located withing the /opt/provider/%{scl} file system hierarchy ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Haha so true, it is not regression a task. But maybe put it under
pl_bolts.models.ml? Where we could have simple ml models.I am for some refactoring in this direction, just I would recommend stabilizing the state e have right now as 0.3 and do this refactor in 0.4 which can be even next week :]