huggingface / autotrain-advanced

🤗 AutoTrain Advanced
https://huggingface.co/autotrain
Apache License 2.0
3.63k stars 438 forks source link

[BUG] ModuleNotFoundError: No module named '_ctypes' #694

Open fre2mansur opened 5 days ago

fre2mansur commented 5 days ago

Prerequisites

Backend

Local

Interface Used

CLI

CLI Command

conda create -n autotrain python=3.10 conda activate autotrain pip install autotrain-advanced conda install pytorch torchvision torchaudio pytorch-cuda=12.1 -c pytorch -c nvidia conda install -c "nvidia/label/cuda-12.1.0" cuda-nvcc Once done, you can start the application using:

autotrain app --port 8080 --host 127.0.0.1

UI Screenshots & Parameters

No response

Error Logs

(autotrain) dell@dell-Latitude-E7470:~/projects/ai$ autotrain app --port 8080 --host 127.0.0.1 Traceback (most recent call last): File "/home/dell/.pyenv/versions/3.9.7/bin/autotrain", line 5, in from autotrain.cli.autotrain import main File "/home/dell/.pyenv/versions/3.9.7/lib/python3.9/site-packages/autotrain/init.py", line 28, in import torch._dynamo File "/home/dell/.pyenv/versions/3.9.7/lib/python3.9/site-packages/torch/init.py", line 17, in import ctypes File "/home/dell/.pyenv/versions/3.9.7/lib/python3.9/ctypes/init.py", line 8, in from _ctypes import Union, Structure, Array ModuleNotFoundError: No module named '_ctypes'

Additional Information

I haven't clone this repo. it's not needed right?

abhishekkrthakur commented 3 days ago

does this work: https://stackoverflow.com/questions/27022373/python3-importerror-no-module-named-ctypes-when-using-value-from-module-mul ?