mrhan1993 / Fooocus-API

FastAPI powered API for Fooocus
GNU General Public License v3.0
581 stars 154 forks source link

[CUDA] Unexpected error from cudaGetDeviceCount(). #45

Closed sebastien247 closed 1 year ago

sebastien247 commented 1 year ago

Hello,

Thanks for the API.

I obtain an error when I try to send a request text-to-prompt:

(fooocus-api_env) seb@seb:~/*****/Fooocus-API$ CUDA_VISIBLE_DEVICES=0 python main.py Python 3.10.13 (main, Aug 25 2023, 13:20:03) [GCC 9.4.0] Fooocus-API version: 0.3.7 Fooocus exists and URL is correct. Fooocus checkout finished for 759bfadefacb1d7827843c35cf22f5996508bb2e. INFO: Started server process [91295] INFO: Waiting for application startup. INFO: Application startup complete. INFO: Uvicorn running on http://127.0.0.1:8888 (Press CTRL+C to quit) Import default pipeline error: Unexpected error from cudaGetDeviceCount(). Did you run some cuda functions before calling NumCudaDevices() that might have already set an error? Error 804: forward compatibility was attempted on non supported HW [Task Queue] Finish task with error, seq=1 INFO: 127.0.0.1:36740 - "POST /v1/generation/text-to-image HTTP/1.1" 200 OK

I have no problem to run and use original Fooocus repo

Thanks

konieshadow commented 1 year ago

Please run nvidia-smi in terminal, and tell me if you get any error.

sebastien247 commented 1 year ago

Thanks for your reply. The problem seems to be solved just by restarting the computer. So no error with nvidia-smi