Closed jbeaurepaire closed 3 years ago
Bonjour et merci beaucoup d'avoir regardé et pris le temps de charger le code, et de faire une issue! Je suis désolé pour cette erreur, et je vais regarder. Pourrais tu m'envoyer le fichier gpx à cette adresse email: jl.auge@yahoo.com car ton lien est bloqué par mon proxy? Encore merci!
I disabled the proxy and managed to retrieve your file: it runs fine with me... I will investigate. Meanwhile I have pushed a tag v1.0 and a master branch to ensure that we know which version is running. Please try again with the latest version. Maybe I need to put a version for the libraries used in the requirements.
Meanwhile, here are your results by the way
description result n doppler_ratio sampling_ratio std
vmax_1s 25 1 0 100
vmax_10s 24,7 1 0 100 0,09
vmax_10s 24,6 2 0 100 0,28
vmax_10s 24,5 3 0 100 0,15
vmax_10s 24,4 4 0 100 0,24
vmax_10s 24,4 5 0 100 0,16
vmax_500m 24,5 1 0 100 0,29
vmax_1000m 24,2 1 0 100 0,36
planning_ratio>12 93 1
Vmoy>12 19,4 1
vmax_jibe 12 1 0 100 2,29
vmax_jibe 11,2 2 0 100 1,82
vmax_jibe 11,1 3 0 100 2,02
vmax_jibe 0 4 0 100 2,02
vmax_jibe 0 5 0 100 2,02
planning_distance>12 31,9 1
But please try again with code from tag v1.0 or master branch. I see you are not using the latest code. Thanks!
After looking at the code, I may have an explanation for the error, though it's not clear why it's working on my machine, but possibly a different version of pandas that is less touchy. Pandas is a great framework but very difficult to master... I think I was wrong when doing this:
doppler_ratio = int(
100
* len(self.thd[self.thd > 0][item_range].dropna())
/ len(self.thd[item_range])
)
which means I'm 1st selecting parts of the thd (has_doppler? time serie) on thd>1 (has_doppler=yes) before applying a restrictive time item_range. I should rather invert and do that: self.thd[item_range][self.thd > 0] I will push this change.
It works !
Some smalls fixes : requirements.txt : yaml->pyyaml readme.md : use, remove one python3
First run, if all_results.csv does not exist : CALLING FUNCTION compile_results
ERROR:root: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! all_results.csv is missing => a new file will be created !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Traceback (most recent call last): File "/home/juju/gpsanapy/gpsanapy/src/core/utils.py", line 116, in load_results all_results = pd.read_csv(all_results_filename) File "/home/juju/.local/lib/python3.8/site-packages/pandas/io/parsers.py", line 605, in read_csv return _read(filepath_or_buffer, kwds) File "/home/juju/.local/lib/python3.8/site-packages/pandas/io/parsers.py", line 457, in _read parser = TextFileReader(filepath_or_buffer, kwds) File "/home/juju/.local/lib/python3.8/site-packages/pandas/io/parsers.py", line 814, in init self._engine = self._make_engine(self.engine) File "/home/juju/.local/lib/python3.8/site-packages/pandas/io/parsers.py", line 1045, in _make_engine return mapping[engine](self.f, self.options) # type: ignore[call-arg] File "/home/juju/.local/lib/python3.8/site-packages/pandas/io/parsers.py", line 1862, in init self._open_handles(src, kwds) File "/home/juju/.local/lib/python3.8/site-packages/pandas/io/parsers.py", line 1357, in _open_handles self.handles = get_handle( File "/home/juju/.local/lib/python3.8/site-packages/pandas/io/common.py", line 639, in get_handle handle = open( FileNotFoundError: [Errno 2] No such file or directory: 'all_results.csv'
OK, if the file exist !
Thanks! ok for pyyaml: sorry I should have checked and test it in a venv or docker. For the error traceback: it's not a bug, it's a feature :) I have a try/except but I wanted to report the original exception, however it's true that the full traceback is too much. I used "logger.exception" that I will replace with a "logger.error(str(e))": str(e) only reports "FileNotFoundError: [Errno 2] No such file or directory: 'all_results.csv'" instead of the full traceback that we don't really need. Encore merci d'avoir regardé et testé et n'hesite pas à soumettre des pull request sur le code pour de nouvelles features par exemple, elles seront bien accueillies!
issue solved
Salut Jean-Luc, J'ai une erreur en exécutant le script. Je n'ai pas pris le temps de regarder le code plus en détail. Lien vers le fichier gpx
Et le résultat :