-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fixed python3 import pathes #48
Conversation
import dataloader as dl | ||
import config_tools as ct | ||
from dataloader import load_data | ||
from config_tools import get_config_dict |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why not "from .config_tools import get_config_dict" in this case ?
is the dot not required here ? and if so, why ?
upper = bins[inx][-1] # needs to return the next bin | ||
hist, bins = np.histogram(data, nbins, density=True) | ||
inx = hist > np.max(hist) * hist_height | ||
lower = bins[0:-1][inx][0] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice. this finally gets rid of the stupid warning message!
import thunderfish.powerspectrum as ps | ||
import thunderfish.harmonicgroups as hg | ||
import thunderfish.config_tools as ct | ||
from IPython import embed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hehe! I also always forget to remove it before pushing XD
I fixed the import pathes to make thunderfish running with python3 and python 2.7.
Important:
Install the likewise updated audioio package.
Run the modules for testing, as well as thunderfish and fishfinder as a package from the root directory of this package:
python -m thunderfish.thunderfish data.wav
python -m thunderfish.peakdetection
Calling them the usual way with "python thunderfish.py data.wav" will NOT work anymore. Ask google for "relative imports" to get an idea why...
In addition I added entrypoints to the setup.py. After you install thunderfish with
sudo python setup.py install
you can use thunderfish and fishfinder from any directory by simply calling
thunderfish somedata.wav
fishfinder cooldata.mp3
from your console.