MIC-DKFZ / HD-BET

MRI brain extraction tool
Apache License 2.0
255 stars 61 forks source link

ModuleNotFoundError: No module named 'imp' with Python v3.12 #58

Open appukuttan-shailesh opened 3 weeks ago

appukuttan-shailesh commented 3 weeks ago

The imp module has been removed in Python3.12 in favor of importlib. Ref: https://docs.python.org/3.11/library/imp.html

Deprecated since version 3.4, will be removed in version 3.12: The imp module is deprecated in favor of importlib.

Currently this throws the following error:

Traceback (most recent call last): File "/home/sappukuttan/miniconda3/bin/hd-bet", line 7, in exec(compile(f.read(), file, 'exec')) File "/<>/HD-BET/HD_BET/hd-bet", line 4, in from HD_BET.run import run_hd_bet File "/<>/HD-BET/HD_BET/run.py", line 6, in import imp ModuleNotFoundError: No module named 'imp'