I am trying to import functions from a file inside a folder linked to a parent folder of the file I'm currently in. To clarify, here is the schema of my folders:
/root
/Math
linear_algebra.py
/Algorithms
gradient_descent.py
Inside the gradient_descent.py file, I want to import a function Vector which is within the linear_algebra.py file. I tried that using:
from ..Math.linear_algebra import Vector
But I get the error:
ImportError: attempted relative import with no known parent package
Is there any way to make this import without using another import, such os or sys?