Closed wolfkingal2000 closed 3 weeks ago
NotImplementedError: Could not run 'torchvision::nms' with arguments from the 'CUDA' backend. This could be because the operator doesn't exist for this backend, or was omitted during the selective/custom build process (if using custom build).
I'm sorry, but your GPU is too old and weak to be used for this. Uninstall torchvision and torch and reinstall cpu-only versions. More details: https://pytorch.org/get-started/locally/
Hey, another guy in #119 had the same issue and solved it by upgrading to python 3.12, then the cuda packages just worked! Give it a try, there are even installation instructions in https://github.com/VoxelCubes/PanelCleaner/issues/119#issuecomment-2472871220
give this error 2024-11-02 13:30:31.793 | INFO | pcleaner.gui.launcher:launch:93 -
2024-11-02 13:30:31.793 | INFO | pcleaner.gui.launcher:launch:93 -
2024-11-02 13:30:32.987 | DEBUG | pcleaner.config:try_to_load:1374 - No option 'show_oom_warnings' in section: 'General' 2024-11-02 13:30:33.011 | DEBUG | pcleaner.config:try_to_load:1374 - No option 'show_oom_warnings' in section: 'General' 2024-11-02 13:30:34.673 | INFO | pcleaner.gui.launcher:launch:110 - Using locale en_US. 2024-11-02 13:30:34.684 | INFO | pcleaner.gui.launcher:launch:110 - Using locale en_US. 2024-11-02 13:30:34.876 | DEBUG | pcleaner.gui.launcher:launch:117 - Loaded built-in Qt translations for en_US. 2024-11-02 13:30:34.875 | DEBUG | pcleaner.gui.launcher:launch:117 - Loaded built-in Qt translations for en_US. 2024-11-02 13:30:34.919 | DEBUG | pcleaner.gui.launcher:launch:125 - Loaded built-in Qt base translations for en_US. 2024-11-02 13:30:34.919 | DEBUG | pcleaner.gui.launcher:launch:125 - Loaded built-in Qt base translations for en_US. 2024-11-02 13:33:56.032 | INFO | pcleaner.gui.model_downloader_driver:check_finished:125 - Finished downloading all models. 2024-11-02 13:34:06.062 | DEBUG | pcleaner.gui.mainwindow_driver:initialize_ui:277 - Purging missing profiles. 2024-11-02 13:34:06.063 | INFO | pcleaner.gui.mainwindow_driver:initialize_profiles:1014 - Found profiles: [('Default', None)] 2024-11-02 13:34:09.959 | DEBUG | pcleaner.config:load_profile:1238 - Loading profile None... 2024-11-02 13:34:09.960 | DEBUG | pcleaner.config:load_profile:1245 - Loading builtin default profile 2024-11-02 13:34:20.415 | DEBUG | pcleaner.gui.mainwindow_driver:load_current_profile:1178 - Loading current profile. 2024-11-02 13:34:20.416 | DEBUG | pcleaner.gui.profile_parser:set_profile_values:502 - Setting profile values 2024-11-02 13:34:55.314 | DEBUG | pcleaner.gui.mainwindow_driver:apply_profile:1310 - Applying profile. 2024-11-02 13:34:55.703 | ERROR | pcleaner.ocr.ocr_tesseract:available_langs:32 - Error checking Tesseract available language data: tesseract is not installed or it's not in your PATH. See README file for more information. 2024-11-02 13:34:55.927 | DEBUG | pcleaner.gui.mainwindow_driver:initialize_analytics_view:769 - Loading included font from C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\pcleaner\data\NotoMono-Regular.ttf 2024-11-02 13:34:57.063 | DEBUG | pcleaner.gui.mainwindow_driver:initialize_analytics_view:772 - Loaded included font 2024-11-02 13:34:58.532 | DEBUG | pcleaner.gui.mainwindow_driver:save_default_palette:166 - Placeholder color: #000000 2024-11-02 13:34:58.853 | INFO | pcleaner.gui.mainwindow_driver:save_default_palette:170 - Default Qt Style: windowsvista 2024-11-02 13:34:58.854 | INFO | pcleaner.gui.mainwindow_driver:save_default_palette:171 - Default Icon Theme: breeze 2024-11-02 13:34:58.857 | INFO | pcleaner.gui.mainwindow_driver:set_theme:194 - Using theme: breeze-dark 2024-11-02 13:35:03.230 | INFO | pcleaner.gui.mainwindow_driver:changeEvent:258 - Theme is dark: True 2024-11-02 13:35:03.414 | INFO | pcleaner.gui.mainwindow_driver:set_theme:235 - Theme is dark: True 2024-11-02 13:35:05.181 | DEBUG | pcleaner.gui.mainwindow_driver:post_init:497 - Char width: 6, columns: 74, required width: 444 2024-11-02 13:35:06.262 | DEBUG | pcleaner.gui.mainwindow_driver:post_init:528 - Splitter sizes: [400, 669, 460] 2024-11-02 13:35:09.134 | DEBUG | pcleaner.gui.state_saver:restore:106 - Restored state for Mainwindow 2024-11-02 13:35:09.136 | DEBUG | pcleaner.gui.mainwindow_driver:start_initialization_worker:657 - Worker Thread cleaning cache 2024-11-02 13:35:09.457 | DEBUG | pcleaner.gui.mainwindow_driver:start_initialization_worker:664 - Worker Thread loading OCR model. 2024-11-02 13:35:09.462 | INFO | pcleaner.gui.mainwindow_driver:clean_cache:754 - Cleaning image cache. 2024-11-02 13:35:09.463 | INFO | pcleaner.ocr.ocr_mangaocr:new:17 - Creating the MangaOcr instance 2024-11-02 13:35:09.465 | INFO | manga_ocr.ocr:init:15 - Loading OCR model from kha-white/manga-ocr-base 2024-11-02 13:38:53.794 | INFO | manga_ocr.ocr:init:25 - Using CUDA 2024-11-02 13:39:50.357 | INFO | manga_ocr.ocr:init:38 - OCR ready 2024-11-02 13:39:50.358 | INFO | pcleaner.gui.mainwindow_driver:load_ocr_model:680 - Loaded OCR model (280.89s) 2024-11-02 13:49:44.397 | DEBUG | pcleaner.gui.file_table:handleDrop:212 - Dropped D:/edit/kuro neko/The Legendary Beasts Animal Hospital/raw/New folder (3)/Official (low quality)_Chapter 24/001.jpg 2024-11-02 13:49:44.398 | DEBUG | pcleaner.gui.file_table:add_file:264 - Requesting to add "D:\edit\kuro neko\The Legendary Beasts Animal Hospital\raw\New folder (3)\Official (low quality)_Chapter 24\001.jpg" 2024-11-02 13:49:44.400 | DEBUG | pcleaner.gui.file_table:repopulate_table:330 - Repopulating table 2024-11-02 13:49:45.114 | INFO | pcleaner.gui.file_table:lazy_load_images:648 - Dispatching image loading workers 2024-11-02 13:49:45.115 | DEBUG | pcleaner.gui.file_table:lazy_load_images:654 - Worker Thread loading image D:\edit\kuro neko\The Legendary Beasts Animal Hospital\raw\New folder (3)\Official (low quality)_Chapter 24\001.jpg 2024-11-02 13:50:00.011 | DEBUG | pcleaner.gui.image_details_driver:init:130 - Opening details tab for D:\edit\kuro neko\The Legendary Beasts Animal Hospital\raw\New folder (3)\Official (low quality)_Chapter 24\001.jpg 2024-11-02 13:50:01.185 | DEBUG | pcleaner.gui.image_details_driver:init_sidebar:363 - Setting scroll area width to 262 2024-11-02 13:50:01.551 | INFO | pcleaner.gui.processing:generate_output:173 - Running text detection AI model for 1 images... 2024-11-02 13:50:10.736 | INFO | pcleaner.gui.processing:generate_output:562 - Finished processing 1 images. 2024-11-02 13:50:11.134 | DEBUG | pcleaner.gui.image_details_driver:generate_output:636 - Output 1 is unchanged. Worker will not run. 2024-11-02 13:50:11.386 | INFO | pcleaner.gui.image_details_driver:output_worker_result:652 - Output worker finished. 2024-11-02 13:50:11.456 | INFO | pcleaner.gui.image_details_driver:output_worker_result:652 - Output worker finished. 2024-11-02 13:50:20.622 | INFO | pcleaner.gui.processing:generate_output:173 - Running text detection AI model for 1 images... 2024-11-02 13:50:33.344 | CRITICAL | pcleaner.gui.image_details_driver:output_worker_error:656 - Output generation failed: Traceback (most recent call last):
File "C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\pcleaner\gui\image_details_driver.py", line 640, in generate_output prc.generate_output( │ └ <function generate_output at 0x000001D0D81F5BD0> └ <module 'pcleaner.gui.processing' from 'C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\pc...
File "C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\pcleaner\gui\processing.py", line 180, in generate_output ctm.model2annotations_gui( │ └ <function model2annotations_gui at 0x000001D0D81F6680> └ <module 'pcleaner.gui.ctd_interface_gui' from 'C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packa...
File "C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\pcleaner\gui\ctd_interface_gui.py", line 124, in model2annotations_gui process_image( └ <function process_image at 0x000001D0D671D5A0>
File "C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\pcleaner\ctd_interface.py", line 161, in process_image mask, mask_refined, blk_list = model( └ <pcleaner.comic_text_detector.inference.TextDetector object at 0x000001D0AF3F65F0>
File "C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\torch\utils_contextlib.py", line 115, in decorate_context return func(*args, **kwargs) │ │ └ {'refine_mode': 1, 'keep_undetected_mask': True} │ └ (<pcleaner.comic_text_detector.inference.TextDetector object at 0x000001D0AF3F65F0>, array([[[255, 255, 255], │ [255, 2... └ <function TextDetector.call at 0x000001D0D671CB80>
File "C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\pcleaner\comic_text_detector\inference.py", line 179, in call blks = postprocess_yolo(blks, self.conf_thresh, self.nms_thresh, resize_ratio) │ │ │ │ │ │ └ (3.2560975609756095, 3.2548828125) │ │ │ │ │ └ 0.35 │ │ │ │ └ <pcleaner.comic_text_detector.inference.TextDetector object at 0x000001D0AF3F65F0> │ │ │ └ 0.4 │ │ └ <pcleaner.comic_text_detector.inference.TextDetector object at 0x000001D0AF3F65F0> │ └ tensor([[[4.1113e+00, 4.1486e+00, 1.3738e+01, ..., 8.5079e-06, │ 5.6943e-01, 4.2261e-01], │ [1.3559e+01, 4.02... └ <function postprocess_yolo at 0x000001D0D671C9D0>
File "C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\pcleaner\comic_text_detector\inference.py", line 115, in postprocess_yolo det = non_max_suppression(det, conf_thresh, nms_thresh)[0] │ │ │ └ 0.35 │ │ └ 0.4 │ └ tensor([[[4.1113e+00, 4.1486e+00, 1.3738e+01, ..., 8.5079e-06, │ 5.6943e-01, 4.2261e-01], │ [1.3559e+01, 4.02... └ <function non_max_suppression at 0x000001D0D651F2E0>
File "C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\pcleaner\comic_text_detector\utils\yolov5_utils.py", line 263, in non_max_suppression i = torchvision.ops.nms(boxes, scores, iouthres) # NMS │ │ │ │ │ └ 0.35 │ │ │ │ └ tensor([0.8190, 0.6105, 0.7513, 0.6728, 0.5978, 0.7758, 0.4764, 0.7959, 0.6532, │ │ │ │ 0.5940, 0.5792, 0.9295, 0.9149, 0.795... │ │ │ └ tensor([[ 20.9205, 32.4549, 35.8621, 40.5598], │ │ │ [ 20.7076, 32.2962, 36.4273, 40.8136], │ │ │ [ 20.7033, 32.43... │ │ └ <function nms at 0x000001D0CF67F130> │ └ <module 'torchvision.ops' from 'C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\torchvisio... └ <module 'torchvision' from 'C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\torchvision\...
File "C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\torchvision\ops\boxes.py", line 41, in nms return torch.ops.torchvision.nms(boxes, scores, iou_threshold) │ │ │ │ │ │ └ 0.35 │ │ │ │ │ └ tensor([0.8190, 0.6105, 0.7513, 0.6728, 0.5978, 0.7758, 0.4764, 0.7959, 0.6532, │ │ │ │ │ 0.5940, 0.5792, 0.9295, 0.9149, 0.795... │ │ │ │ └ tensor([[ 20.9205, 32.4549, 35.8621, 40.5598], │ │ │ │ [ 20.7076, 32.2962, 36.4273, 40.8136], │ │ │ │ [ 20.7033, 32.43... │ │ │ └ <OpOverloadPacket(op='torchvision.nms')> │ │ └ <module 'torch.ops.torchvision' from 'torch.ops'> │ └ <module 'torch.ops' from '_ops.py'> └ <module 'torch' from 'C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\torch\init.py'>
File "C:\Users\aaa13\AppData\Local\Programs\Python\Python310\lib\site-packages\torch_ops.py", line 854, in call return self_._op(*args, **(kwargs or {})) │ │ │ └ {} │ │ └ (tensor([[ 20.9205, 32.4549, 35.8621, 40.5598], │ │ [ 20.7076, 32.2962, 36.4273, 40.8136], │ │ [ 20.7033, 32.4... │ └ <built-in method nms of PyCapsule object at 0x000001D0AF3D6A00> └ <OpOverloadPacket(op='torchvision.nms')>
NotImplementedError: Could not run 'torchvision::nms' with arguments from the 'CUDA' backend. This could be because the operator doesn't exist for this backend, or was omitted during the selective/custom build process (if using custom build). If you are a Facebook employee using PyTorch on mobile, please visit https://fburl.com/ptmfixes for possible resolutions. 'torchvision::nms' is only available for these backends: [CPU, Meta, QuantizedCPU, BackendSelect, Python, FuncTorchDynamicLayerBackMode, Functionalize, Named, Conjugate, Negative, ZeroTensor, ADInplaceOrView, AutogradOther, AutogradCPU, AutogradCUDA, AutogradXLA, AutogradMPS, AutogradXPU, AutogradHPU, AutogradLazy, AutogradMeta, Tracer, AutocastCPU, AutocastCUDA, FuncTorchBatched, BatchedNestedTensor, FuncTorchVmapMode, Batched, VmapMode, FuncTorchGradWrapper, PythonTLSSnapshot, FuncTorchDynamicLayerFrontMode, PreDispatch, PythonDispatcher].
CPU: registered at C:\actions-runner_work\vision\vision\pytorch\vision\torchvision\csrc\ops\cpu\nms_kernel.cpp:112 [kernel] Meta: registered at /dev/null:467 [kernel] QuantizedCPU: registered at C:\actions-runner_work\vision\vision\pytorch\vision\torchvision\csrc\ops\quantized\cpu\qnms_kernel.cpp:124 [kernel] BackendSelect: fallthrough registered at ..\aten\src\ATen\core\BackendSelectFallbackKernel.cpp:3 [backend fallback] Python: registered at ..\aten\src\ATen\core\PythonFallbackKernel.cpp:154 [backend fallback] FuncTorchDynamicLayerBackMode: registered at ..\aten\src\ATen\functorch\DynamicLayer.cpp:497 [backend fallback] Functionalize: registered at ..\aten\src\ATen\FunctionalizeFallbackKernel.cpp:324 [backend fallback] Named: registered at ..\aten\src\ATen\core\NamedRegistrations.cpp:7 [backend fallback] Conjugate: registered at ..\aten\src\ATen\ConjugateFallback.cpp:17 [backend fallback] Negative: registered at ..\aten\src\ATen\native\NegateFallback.cpp:18 [backend fallback] ZeroTensor: registered at ..\aten\src\ATen\ZeroTensorFallback.cpp:86 [backend fallback] ADInplaceOrView: fallthrough registered at ..\aten\src\ATen\core\VariableFallbackKernel.cpp:86 [backend fallback] AutogradOther: registered at ..\aten\src\ATen\core\VariableFallbackKernel.cpp:53 [backend fallback] AutogradCPU: registered at ..\aten\src\ATen\core\VariableFallbackKernel.cpp:57 [backend fallback] AutogradCUDA: registered at ..\aten\src\ATen\core\VariableFallbackKernel.cpp:65 [backend fallback] AutogradXLA: registered at ..\aten\src\ATen\core\VariableFallbackKernel.cpp:69 [backend fallback] AutogradMPS: registered at ..\aten\src\ATen\core\VariableFallbackKernel.cpp:77 [backend fallback] AutogradXPU: registered at ..\aten\src\ATen\core\VariableFallbackKernel.cpp:61 [backend fallback] AutogradHPU: registered at ..\aten\src\ATen\core\VariableFallbackKernel.cpp:90 [backend fallback] AutogradLazy: registered at ..\aten\src\ATen\core\VariableFallbackKernel.cpp:73 [backend fallback] AutogradMeta: registered at ..\aten\src\ATen\core\VariableFallbackKernel.cpp:81 [backend fallback] Tracer: registered at ..\torch\csrc\autograd\TraceTypeManual.cpp:297 [backend fallback] AutocastCPU: registered at C:\actions-runner_work\vision\vision\pytorch\vision\torchvision\csrc\ops\autocast\nms_kernel.cpp:34 [kernel] AutocastCUDA: registered at C:\actions-runner_work\vision\vision\pytorch\vision\torchvision\csrc\ops\autocast\nms_kernel.cpp:27 [kernel] FuncTorchBatched: registered at ..\aten\src\ATen\functorch\LegacyBatchingRegistrations.cpp:731 [backend fallback] BatchedNestedTensor: registered at ..\aten\src\ATen\functorch\LegacyBatchingRegistrations.cpp:758 [backend fallback] FuncTorchVmapMode: fallthrough registered at ..\aten\src\ATen\functorch\VmapModeRegistrations.cpp:27 [backend fallback] Batched: registered at ..\aten\src\ATen\LegacyBatchingRegistrations.cpp:1075 [backend fallback] VmapMode: fallthrough registered at ..\aten\src\ATen\VmapModeRegistrations.cpp:33 [backend fallback] FuncTorchGradWrapper: registered at ..\aten\src\ATen\functorch\TensorWrapper.cpp:202 [backend fallback] PythonTLSSnapshot: registered at ..\aten\src\ATen\core\PythonFallbackKernel.cpp:162 [backend fallback] FuncTorchDynamicLayerFrontMode: registered at ..\aten\src\ATen\functorch\DynamicLayer.cpp:493 [backend fallback] PreDispatch: registered at ..\aten\src\ATen\core\PythonFallbackKernel.cpp:166 [backend fallback] PythonDispatcher: registered at ..\aten\src\ATen\core\PythonFallbackKernel.cpp:158 [backend fallback]