Any2HRTF / Mesh2HRTF

Open software for the numerical calculation of head-related transfer functions
European Union Public License 1.2
111 stars 14 forks source link

finalize_hrtf_simulation.py error #68

Closed terrainer closed 1 year ago

terrainer commented 1 year ago

Using the develop branch, and the mesh2hrtf-tools linked in the v1 tutorial.

Getting this error:

Merging HRTF SOFA files from: "myHRTF_project_L" and "myHRTF_project_R"
Traceback (most recent call last):
  File "C:\Mesh2HRTF\mesh2hrtf-tools\Finalize_HRTF_simulation\finalize_hrtf_simulation.py", line 605, in <module>
    Full_Ref_Path, m_SOFA = merge_write_sofa(sofa_read_L, sofa_read_R, BasePath, AllSofaFiles_L[ii], SOFA_Type)
  File "C:\Mesh2HRTF\mesh2hrtf-tools\Finalize_HRTF_simulation\finalize_hrtf_simulation.py", line 152, in merge_write_sofa
    sf.write_sofa(path, sofa, version='latest', compression=9)  # max compression
TypeError: write_sofa() got an unexpected keyword argument 'version'

(mesh2hrtf) C:\Mesh2HRTF\mesh2hrtf-tools\Finalize_HRTF_simulation>python finalize_hrtf_simulation.py
finalize_hrtf_simulation.py v3.00 started with SavePath = "C:\Mesh2HRTF\mesh2hrtf-tools\Finalize_HRTF_simulation"

   Search_Folder = "C:\Mesh2HRTF\mesh2hrtf-tools\Finalize_HRTF_simulation"
ERROR: More than 2 folders found in the Search_Folder! (Hit Enter key to exit)
Traceback (most recent call last):
  File "C:\Mesh2HRTF\mesh2hrtf-tools\Finalize_HRTF_simulation\finalize_hrtf_simulation.py", line 399, in <module>
    raise Exception("see Error above")
Exception: see Error above

Fixed by removing "version = 'latest'" in line 152 and line 645 of Finalize_HRTF_simulation.py.

f-brinkmann commented 1 year ago

That's related to the sofar 1.0 release which broke backwards compatability. But the code you are referring to is not part of Mesh2HRTF and maintained here: https://sourceforge.net/p/mesh2hrtf-tools/code/ci/master/tree/