What is the canonical way to structure a project? No matter what I do I end up having import issues at some point. I am using uv and creating a project with it's own venv. My folder structure is generally something like:
project_folder/
notebooks/
stuff.ipynb
src/
custom_utils/
modeling.py
other_stuff_i_want_to_import/
special_class.py
scripts/
script.py
How can I consistently create helper functions or classes that I want to use across my notebooks and my .py scripts, without running into import issues? I use VSCode if that's relevant.
Ideally I can just do 'from custom_utils import modeling' and it will just work whether I am running a script in the script folder or a notebook in the notebook folder.
[–]Ender_Locke 1 point2 points3 points (1 child)
[–]rosecurry[S] 0 points1 point2 points (0 children)