diff --git a/README.md b/README.md index 89ec0309aef0379be0ef54d425ca83fc031274b8..8682a07c1fbdeec5d9c0f00b544c8873d08f492c 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ the GSPR loss function with a second-order polynomial. Prerequisite ------------ -This program uses the following libraries (tested with the following version): +This program uses the following libraries (tested with the following version, but should work with other versions): * cython 0.29 * numpy 1.21 * scipy 1.7.1 @@ -17,6 +17,12 @@ This program uses the following libraries (tested with the following version): * pandas 1.3 (needed only for saving in a non CSV format) * tqdm 4.62 (optional if you want a progress bar) +`c_corr.pyx` will automaticly be compiled at the first run of `gsrp_tdoa_hyperres.py`. +In case the compilation fail, you can manually compile it with: +``` +python cython_setup.py build_ext --inplace +``` + Usage ----- ``` diff --git a/gsrp_tdoa_hyperres.py b/gsrp_tdoa_hyperres.py index 729225dfa41b0d7e35e684dc67633ade749d667b..5e51a559f4e4137349d2e5cc73d894835dfde4ea 100755 --- a/gsrp_tdoa_hyperres.py +++ b/gsrp_tdoa_hyperres.py @@ -29,7 +29,7 @@ try: except ModuleNotFoundError: print(f'{BColors.WARNING}Unable to load c_corr. Attempting to recompile...{BColors.ENDC}') from subprocess import run - run('python cython_setup.py build_ext --inplace'.split()) + run(f"python {os.path.join(os.path.dirname(__file__), 'cython_setup.py')} build_ext --inplace".split()) import c_corr print(f'{BColors.OKGREEN}Done{BColors.ENDC}') try: