Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

what is the double dot operator(..) in the python?

Before installing the package, I read the code and I got a question.

There is double dot in the code when the code calls a module, the module is tools.

What is the double dot in python? The code wrote from ..tools import *.

You can find it here, https://github.com/synergetics/spectrum/blob/master/src/conventional/cum2x.py

The code is computing the bispectrum.

And do you know the other code analysing a wave interaction for python such as HOSA in MATLAB?

like image 732
Lee Avatar asked Jun 11 '26 18:06

Lee


1 Answers

In python, The . is just accessing an attribute. The attribute could be a class, an instance, a method/function, etc and The .. is just specify an relative address in Linux environment. It means go to ../tools folder and import everything inside it.