Closed 3019234115 closed 3 years ago
我按照readme配置的相关环境和相关代码,我是一个学生,想要知道还有特别的要求吗?
我按照readme配置的相关环境和相关代码,我是一个学生,想要知道还有特别的要求吗?
控制台是否输出什么错误,界面是卡死还是没响应?
界面没有响应了,我改成cpu运行的,在作弊检测中点击摄像头以后就没有响应。(其他两个功能也是有别的错误。) 输出了很多:好像是cuda不行,我将cheating_detection_app.py中的device改为'cpu‘ created: <pipeline_module.video_modules.VideoModule object at 0x7f929808ea10> created: <pipeline_module.yolo_modules.YoloV5Module object at 0x7f929808e710> Exception in thread Thread-3: Traceback (most recent call last): File "/Users/wodejiaoao/opt/anaconda3/envs/smartclass/lib/python3.7/threading.py", line 926, in _bootstrap_inner self.run() File "/Users/wodejiaoao/opt/anaconda3/envs/smartclass/lib/python3.7/threading.py", line 870, in run self._target(*self._args, **self._kwargs) File "/Users/wodejiaoao/Desktop/表情识别/smart_classroom_demo-master/smart_classroom/cheating_detection_app.py", line 154, in open_source_func .set_next_module(YoloV5Module(yolov5_weight, device)) \ File "/Users/wodejiaoao/Desktop/表情识别/smart_classroom_demo-master/pipeline_module/yolo_modules.py", line 10, in init self.detector = YoloV5Detector(self.weights, device) File "/Users/wodejiaoao/Desktop/表情识别/smart_classroom_demo-master/models/yolo_detector.py", line 45, in init self.model = torch.jit.load(weights).to(device) File "/Users/wodejiaoao/opt/anaconda3/envs/smartclass/lib/python3.7/site-packages/torch/jit/_serialization.py", line 161, in load cpp_module = torch._C.import_ir_module(cu, str(f), map_location, _extra_files) NotImplementedError: Could not run 'aten::empty_strided' 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. 'aten::empty_strided' is only available for these backends: [CPU, Meta, BackendSelect, Named, ADInplaceOrView, AutogradOther, AutogradCPU, AutogradCUDA, AutogradXLA, UNKNOWN_TENSOR_TYPE_ID, AutogradMLC, AutogradHPU, AutogradNestedTensor, AutogradPrivateUse1, AutogradPrivateUse2, AutogradPrivateUse3, Tracer, Autocast, Batched, VmapMode].
CPU: registered at aten/src/ATen/RegisterCPU.cpp:16286 [kernel] Meta: registered at aten/src/ATen/RegisterMeta.cpp:9460 [kernel] BackendSelect: registered at aten/src/ATen/RegisterBackendSelect.cpp:609 [kernel] Named: registered at ../aten/src/ATen/core/NamedRegistrations.cpp:7 [backend fallback] ADInplaceOrView: fallthrough registered at ../aten/src/ATen/core/VariableFallbackKernel.cpp:60 [backend fallback] AutogradOther: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradCPU: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradCUDA: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradXLA: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] UNKNOWN_TENSOR_TYPE_ID: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradMLC: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradHPU: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradNestedTensor: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradPrivateUse1: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradPrivateUse2: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradPrivateUse3: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] Tracer: registered at ../torch/csrc/autograd/generated/TraceType_0.cpp:9750 [kernel] Autocast: fallthrough registered at ../aten/src/ATen/autocast_mode.cpp:255 [backend fallback] Batched: registered at ../aten/src/ATen/BatchingRegistrations.cpp:1019 [backend fallback] VmapMode: fallthrough registered at ../aten/src/ATen/VmapModeRegistrations.cpp:33 [backend fallback]
界面没有响应了,我改成cpu运行的,在作弊检测中点击摄像头以后就没有响应。(其他两个功能也是有别的错误。) 输出了很多:好像是cuda不行,我将cheating_detection_app.py中的device改为'cpu‘ created: <pipeline_module.video_modules.VideoModule object at 0x7f929808ea10> created: <pipeline_module.yolo_modules.YoloV5Module object at 0x7f929808e710> Exception in thread Thread-3: Traceback (most recent call last): File "/Users/wodejiaoao/opt/anaconda3/envs/smartclass/lib/python3.7/threading.py", line 926, in _bootstrap_inner self.run() File "/Users/wodejiaoao/opt/anaconda3/envs/smartclass/lib/python3.7/threading.py", line 870, in run self._target(*self._args, self._kwargs) File "/Users/wodejiaoao/Desktop/表情识别/smart_classroom_demo-master/smart_classroom/cheating_detection_app.py", line 154, in open_source_func .set_next_module(YoloV5Module(yolov5_weight, device)) File "/Users/wodejiaoao/Desktop/表情识别/smart_classroom_demo-master/pipeline_module/yolo_modules.py", line 10, in init self.detector = YoloV5Detector(self.weights, device) File "/Users/wodejiaoao/Desktop/表情识别/smart_classroom_demo-master/models/yolo_detector.py", line 45, in init** self.model = torch.jit.load(weights).to(device) File "/Users/wodejiaoao/opt/anaconda3/envs/smartclass/lib/python3.7/site-packages/torch/jit/_serialization.py", line 161, in load cpp_module = torch._C.import_ir_module(cu, str(f), map_location, _extra_files) NotImplementedError: Could not run 'aten::empty_strided' 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. 'aten::empty_strided' is only available for these backends: [CPU, Meta, BackendSelect, Named, ADInplaceOrView, AutogradOther, AutogradCPU, AutogradCUDA, AutogradXLA, UNKNOWN_TENSOR_TYPE_ID, AutogradMLC, AutogradHPU, AutogradNestedTensor, AutogradPrivateUse1, AutogradPrivateUse2, AutogradPrivateUse3, Tracer, Autocast, Batched, VmapMode].
CPU: registered at aten/src/ATen/RegisterCPU.cpp:16286 [kernel] Meta: registered at aten/src/ATen/RegisterMeta.cpp:9460 [kernel] BackendSelect: registered at aten/src/ATen/RegisterBackendSelect.cpp:609 [kernel] Named: registered at ../aten/src/ATen/core/NamedRegistrations.cpp:7 [backend fallback] ADInplaceOrView: fallthrough registered at ../aten/src/ATen/core/VariableFallbackKernel.cpp:60 [backend fallback] AutogradOther: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradCPU: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradCUDA: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradXLA: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] UNKNOWN_TENSOR_TYPE_ID: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradMLC: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradHPU: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradNestedTensor: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradPrivateUse1: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradPrivateUse2: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] AutogradPrivateUse3: registered at ../torch/csrc/autograd/generated/VariableType_0.cpp:9848 [autograd kernel] Tracer: registered at ../torch/csrc/autograd/generated/TraceType_0.cpp:9750 [kernel] Autocast: fallthrough registered at ../aten/src/ATen/autocast_mode.cpp:255 [backend fallback] Batched: registered at ../aten/src/ATen/BatchingRegistrations.cpp:1019 [backend fallback] VmapMode: fallthrough registered at ../aten/src/ATen/VmapModeRegistrations.cpp:33 [backend fallback]
yolov5的模型不知道什么情况转换成torchscript后无法在代码中切换设备,我项目给的模型是gpu版本的模型,所以现在只能用gpu跑,你这个是不是torch安装不对?自己按官网安装一下
from smart_classroom.cheating_detection_app import CheatingDetectionApp ModuleNotFoundError: No module named 'smart_classroom.cheating_detection_app'; 'smart_classroom' is not a package 请问这是怎么回事啊
按照要求配置完成之后,运行时界面卡死,无法加载出来摄像头或是本地视频,人脸注册等其他功能也无法使用,请问是否还需要别的相关代码或要求吗?
按照要求配置完成之后,运行时界面卡死,无法加载出来摄像头或是本地视频,人脸注册等其他功能也无法使用,请问是否还需要别的相关代码或要求吗?
你看一下控制台的报错是不是缺文件夹了,有几个文件夹需要手动创建一下。我这边也改了一下代码,你可以下载新的代码试一下
要求完成之后,运行时运行时屏幕界面死掉,无法加载出来,如果想自己配置卡本地视频,人脸注册等其他功能也无法使用,请问是否还需要相关或要求吗?
你看一下演示的错误,是不是缺了一个有五个需要下载手动创建一下。我也可以改一下代码,你新的代码试一下
新的代码下载后,还是会界面卡死,摄像头无法使用,人脸注册的功能,完成进度也始终没有往前推进,报错有下面这些: NotImplementedError: Could not run 'aten::empty_strided' 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. 'aten::empty_strided' is only available for these backends: [CPU, Meta, BackendSelect, Named, ADInplaceOrView, AutogradOther, AutogradCPU, AutogradCUDA, AutogradXLA, UNKNOWN_TENSOR_TYPE_ID, AutogradMLC, AutogradHPU, AutogradNestedTensor, AutogradPrivateUse1, AutogradPrivateUse2, AutogradPrivateUse3, Tracer, Autocast, Batched, VmapMode].
CPU: registered at aten\src\ATen\RegisterCPU.cpp:16286 [kernel] Meta: registered at aten\src\ATen\RegisterMeta.cpp:9460 [kernel] BackendSelect: registered at aten\src\ATen\RegisterBackendSelect.cpp:609 [kernel] Named: registered at ..\aten\src\ATen\core\NamedRegistrations.cpp:7 [backend fallback] ADInplaceOrView: fallthrough registered at ..\aten\src\ATen\core\VariableFallbackKernel.cpp:60 [backend fallback] AutogradOther: registered at ..\torch\csrc\autograd\generated\VariableType_0.cpp:9848 [autograd kernel] AutogradCPU: registered at ..\torch\csrc\autograd\generated\VariableType_0.cpp:9848 [autograd kernel] AutogradCUDA: registered at ..\torch\csrc\autograd\generated\VariableType_0.cpp:9848 [autograd kernel] AutogradXLA: registered at ..\torch\csrc\autograd\generated\VariableType_0.cpp:9848 [autograd kernel] UNKNOWN_TENSOR_TYPE_ID: registered at ..\torch\csrc\autograd\generated\VariableType_0.cpp:9848 [autograd kernel] AutogradMLC: registered at ..\torch\csrc\autograd\generated\VariableType_0.cpp:9848 [autograd kernel] AutogradHPU: registered at ..\torch\csrc\autograd\generated\VariableType_0.cpp:9848 [autograd kernel] AutogradNestedTensor: registered at ..\torch\csrc\autograd\generated\VariableType_0.cpp:9848 [autograd kernel] AutogradPrivateUse1: registered at ..\torch\csrc\autograd\generated\VariableType_0.cpp:9848 [autograd kernel] AutogradPrivateUse2: registered at ..\torch\csrc\autograd\generated\VariableType_0.cpp:9848 [autograd kernel] AutogradPrivateUse3: registered at ..\torch\csrc\autograd\generated\VariableType_0.cpp:9848 [autograd kernel] Tracer: registered at ..\torch\csrc\autograd\generated\TraceType_0.cpp:9750 [kernel] Autocast: fallthrough registered at ..\aten\src\ATen\autocast_mode.cpp:255 [backend fallback] Batched: registered at ..\aten\src\ATen\BatchingRegistrations.cpp:1019 [backend fallback] VmapMode: fallthrough registered at ..\aten\src\ATen\VmapModeRegistrations.cpp:33 [backend fallback]
按照要求配置完成之后,运行时界面卡死,无法加载出来摄像头或是本地视频,人脸注册等其他功能也无法使用,请问是否还需要别的相关代码或要求吗?
你看一下控制台的报错是不是缺文件夹了,有几个文件夹需要手动创建一下。我这边也改了一下代码,你可以下载新的代码试一下
Exception in thread Thread-1: Traceback (most recent call last): File "D:\Anaconda2\envs\env_4\lib\threading.py", line 926, in _bootstrap_inner self.run() File "D:\Anaconda2\envs\env_4\lib\threading.py", line 870, in run self._target(*self._args, **self._kwargs) File "D:\Documents\Desktop\smart_classroom_demo-master\smart_classroom\cheating_detection_app.py", line 157, in open_source_func .set_next_module(YoloV5Module(yolov5_weight, device)) \ File "D:\Documents\Desktop\smart_classroom_demo-master\pipeline_module\yolo_modules.py", line 10, in init self.detector = YoloV5Detector(self.weights, device) File "D:\Documents\Desktop\smart_classroom_demo-master\models\yolo_detector.py", line 45, in init self.model = torch.jit.load(weights).to(device) File "D:\Anaconda2\envs\env_4\lib\site-packages\torch\jit_serialization.py", line 161, in load cpp_module = torch._C.import_ir_module(cu, str(f), map_location, _extra_files) NotImplementedError: Could not run 'aten::empty_strided' 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. 'aten::empty_strided' is only available for these backends: [CPU, Meta, BackendSelect, Named, ADInplaceOrView, AutogradOther, AutogradCPU, AutogradCUDA, AutogradXLA, UNKNOWN_TENSOR_TYPE_ID, AutogradMLC, AutogradHPU, AutogradNestedTensor, AutogradPrivateUse1, AutogradPrivateUse2, AutogradPrivateUse3, Tracer, Autocast, Batched, VmapMode].
按照要求配置完成之后,运行时界面卡死,无法加载出来摄像头或是本地视频,人脸注册等其他功能也无法使用,请问是否还需要别的相关代码或要求吗?
你看一下控制台的报错是不是缺文件夹了,有几个文件夹需要手动创建一下。我这边也改了一下代码,你可以下载新的代码试一下
Exception in thread Thread-1: Traceback (most recent call last): File "D:\Anaconda2\envs\env_4\lib\threading.py", line 926, in _bootstrap_inner self.run() File "D:\Anaconda2\envs\env_4\lib\threading.py", line 870, in run self._target(*self._args, self._kwargs) File "D:\Documents\Desktop\smart_classroom_demo-master\smart_classroom\cheating_detection_app.py", line 157, in open_source_func .set_next_module(YoloV5Module(yolov5_weight, device)) File "D:\Documents\Desktop\smart_classroom_demo-master\pipeline_module\yolo_modules.py", line 10, in init self.detector = YoloV5Detector(self.weights, device) File "D:\Documents\Desktop\smart_classroom_demo-master\models\yolo_detector.py", line 45, in init** self.model = torch.jit.load(weights).to(device) File "D:\Anaconda2\envs\env_4\lib\site-packages\torch\jit_serialization.py", line 161, in load cpp_module = torch._C.import_ir_module(cu, str(f), map_location, _extra_files) NotImplementedError: Could not run 'aten::empty_strided' 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. 'aten::empty_strided' is only available for these backends: [CPU, Meta, BackendSelect, Named, ADInplaceOrView, AutogradOther, AutogradCPU, AutogradCUDA, AutogradXLA, UNKNOWN_TENSOR_TYPE_ID, AutogradMLC, AutogradHPU, AutogradNestedTensor, AutogradPrivateUse1, AutogradPrivateUse2, AutogradPrivateUse3, Tracer, Autocast, Batched, VmapMode].
你按照pytorch官网的安装命令安装了gpu版的pytorch了吗?
按照要求配置完成之后,运行时界面卡死,无法加载出来摄像头或是本地视频,人脸注册等其他功能也无法使用,请问是否还需要别的相关代码或要求吗?
你看一下控制台的报错是不是缺文件夹了,有几个文件夹需要手动创建一下。我这边也改了一下代码,你可以下载新的代码试一下
Exception in thread Thread-1: Traceback (most recent call last): File "D:\Anaconda2\envs\env_4\lib\threading.py", line 926, in _bootstrap_inner self.run() File "D:\Anaconda2\envs\env_4\lib\threading.py", line 870, in run self._target(*self._args, self._kwargs) File "D:\Documents\Desktop\smart_classroom_demo-master\smart_classroom\cheating_detection_app.py", line 157, in open_source_func .set_next_module(YoloV5Module(yolov5_weight, device)) File "D:\Documents\Desktop\smart_classroom_demo-master\pipeline_module\yolo_modules.py", line 10, in init self.detector = YoloV5Detector(self.weights, device) File "D:\Documents\Desktop\smart_classroom_demo-master\models\yolo_detector.py", line 45, in init** self.model = torch.jit.load(weights).to(device) File "D:\Anaconda2\envs\env_4\lib\site-packages\torch\jit_serialization.py", line 161, in load cpp_module = torch._C.import_ir_module(cu, str(f), map_location, _extra_files) NotImplementedError: Could not run 'aten::empty_strided' 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. 'aten::empty_strided' is only available for these backends: [CPU, Meta, BackendSelect, Named, ADInplaceOrView, AutogradOther, AutogradCPU, AutogradCUDA, AutogradXLA, UNKNOWN_TENSOR_TYPE_ID, AutogradMLC, AutogradHPU, AutogradNestedTensor, AutogradPrivateUse1, AutogradPrivateUse2, AutogradPrivateUse3, Tracer, Autocast, Batched, VmapMode].
你按照pytorch官网的安装命令安装了gpu版的pytorch了吗?
啊,之前没安装上,现在安装成功了,摄像头和本地视频可以打开了,但是打开的一瞬间就立马闪退了,程序直接自己结束了 OMP: Error #15: Initializing libiomp5md.dll, but found libiomp5md.dll already initialized. OMP: Hint This means that multiple copies of the OpenMP runtime have been linked into the program. That is dangerous, since it can degrade performance or cause incorrect results. The best thing to do is to ensure that only a single OpenMP runtime is linked into the process, e.g. by avoiding static linking of the OpenMP runtime in any library. As an unsafe, unsupported, undocumented workaround you can set the environment variable KMP_DUPLICATE_LIB_OK=TRUE to allow the program to continue to execute, but that may cause crashes or silently produce incorrect results. For more information, please see http://www.intel.com/software/products/support/.
按照要求配置完成之后,运行时界面卡死,无法加载出来摄像头或是本地视频,人脸注册等其他功能也无法使用,请问是否还需要别的相关代码或要求吗?
你看一下控制台的报错是不是缺文件夹了,有几个文件夹需要手动创建一下。我这边也改了一下代码,你可以下载新的代码试一下
Exception in thread Thread-1: Traceback (most recent call last): File "D:\Anaconda2\envs\env_4\lib\threading.py", line 926, in _bootstrap_inner self.run() File "D:\Anaconda2\envs\env_4\lib\threading.py", line 870, in run self._target(*self._args, self._kwargs) File "D:\Documents\Desktop\smart_classroom_demo-master\smart_classroom\cheating_detection_app.py", line 157, in open_source_func .set_next_module(YoloV5Module(yolov5_weight, device)) File "D:\Documents\Desktop\smart_classroom_demo-master\pipeline_module\yolo_modules.py", line 10, in init self.detector = YoloV5Detector(self.weights, device) File "D:\Documents\Desktop\smart_classroom_demo-master\models\yolo_detector.py", line 45, in init** self.model = torch.jit.load(weights).to(device) File "D:\Anaconda2\envs\env_4\lib\site-packages\torch\jit_serialization.py", line 161, in load cpp_module = torch._C.import_ir_module(cu, str(f), map_location, _extra_files) NotImplementedError: Could not run 'aten::empty_strided' 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. 'aten::empty_strided' is only available for these backends: [CPU, Meta, BackendSelect, Named, ADInplaceOrView, AutogradOther, AutogradCPU, AutogradCUDA, AutogradXLA, UNKNOWN_TENSOR_TYPE_ID, AutogradMLC, AutogradHPU, AutogradNestedTensor, AutogradPrivateUse1, AutogradPrivateUse2, AutogradPrivateUse3, Tracer, Autocast, Batched, VmapMode].
你按照pytorch官网的安装命令安装了gpu版的pytorch了吗?
啊,之前没安装上,现在安装成功了,摄像头和本地视频可以打开了,但是打开的一瞬间就立马闪退了,程序直接自己结束了 OMP: Error #15: Initializing libiomp5md.dll, but found libiomp5md.dll already initialized. OMP: Hint This means that multiple copies of the OpenMP runtime have been linked into the program. That is dangerous, since it can degrade performance or cause incorrect results. The best thing to do is to ensure that only a single OpenMP runtime is linked into the process, e.g. by avoiding static linking of the OpenMP runtime in any library. As an unsafe, unsupported, undocumented workaround you can set the environment variable KMP_DUPLICATE_LIB_OK=TRUE to allow the program to continue to execute, but that may cause crashes or silently produce incorrect results. For more information, please see http://www.intel.com/software/products/support/.
你这些是属于环境问题,用搜索引擎解决就可以了蛤😂
按照要求配置完成之后,运行时界面卡死,无法加载出来摄像头或是本地视频,人脸注册等其他功能也无法使用,请问是否还需要别的相关代码或要求吗?
你看一下控制台的报错是不是缺文件夹了,有几个文件夹需要手动创建一下。我这边也改了一下代码,你可以下载新的代码试一下
Exception in thread Thread-1: Traceback (most recent call last): File "D:\Anaconda2\envs\env_4\lib\threading.py", line 926, in _bootstrap_inner self.run() File "D:\Anaconda2\envs\env_4\lib\threading.py", line 870, in run self._target(*self._args, self._kwargs) File "D:\Documents\Desktop\smart_classroom_demo-master\smart_classroom\cheating_detection_app.py", line 157, in open_source_func .set_next_module(YoloV5Module(yolov5_weight, device)) File "D:\Documents\Desktop\smart_classroom_demo-master\pipeline_module\yolo_modules.py", line 10, in init self.detector = YoloV5Detector(self.weights, device) File "D:\Documents\Desktop\smart_classroom_demo-master\models\yolo_detector.py", line 45, in init** self.model = torch.jit.load(weights).to(device) File "D:\Anaconda2\envs\env_4\lib\site-packages\torch\jit_serialization.py", line 161, in load cpp_module = torch._C.import_ir_module(cu, str(f), map_location, _extra_files) NotImplementedError: Could not run 'aten::empty_strided' 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. 'aten::empty_strided' is only available for these backends: [CPU, Meta, BackendSelect, Named, ADInplaceOrView, AutogradOther, AutogradCPU, AutogradCUDA, AutogradXLA, UNKNOWN_TENSOR_TYPE_ID, AutogradMLC, AutogradHPU, AutogradNestedTensor, AutogradPrivateUse1, AutogradPrivateUse2, AutogradPrivateUse3, Tracer, Autocast, Batched, VmapMode].
你按照pytorch官网的安装命令安装了gpu版的pytorch了吗?
啊,之前没安装上,现在安装成功了,摄像头和本地视频可以打开了,但是打开的一瞬间就立马闪退了,程序直接自己结束了 OMP: Error #15: Initializing libiomp5md.dll, but found libiomp5md.dll already initialized. OMP: Hint This means that multiple copies of the OpenMP runtime have been linked into the program. That is dangerous, since it can degrade performance or cause incorrect results. The best thing to do is to ensure that only a single OpenMP runtime is linked into the process, e.g. by avoiding static linking of the OpenMP runtime in any library. As an unsafe, unsupported, undocumented workaround you can set the environment variable KMP_DUPLICATE_LIB_OK=TRUE to allow the program to continue to execute, but that may cause crashes or silently produce incorrect results. For more information, please see http://www.intel.com/software/products/support/.
你这些是属于环境问题,用搜索引擎解决就可以了蛤😂
噢噢,好的好的,还有一个问题,人脸注册的功能仍然无法实现,控制台也没有报错,可以识别出来人脸,但下面的完成进度条始终为零,请问这是哪里的问题呢?
按照要求配置完成之后,运行时界面卡死,无法加载出来摄像头或是本地视频,人脸注册等其他功能也无法使用,请问是否还需要别的相关代码或要求吗?
你看一下控制台的报错是不是缺文件夹了,有几个文件夹需要手动创建一下。我这边也改了一下代码,你可以下载新的代码试一下
Exception in thread Thread-1: Traceback (most recent call last): File "D:\Anaconda2\envs\env_4\lib\threading.py", line 926, in _bootstrap_inner self.run() File "D:\Anaconda2\envs\env_4\lib\threading.py", line 870, in run self._target(*self._args, self._kwargs) File "D:\Documents\Desktop\smart_classroom_demo-master\smart_classroom\cheating_detection_app.py", line 157, in open_source_func .set_next_module(YoloV5Module(yolov5_weight, device)) File "D:\Documents\Desktop\smart_classroom_demo-master\pipeline_module\yolo_modules.py", line 10, in init self.detector = YoloV5Detector(self.weights, device) File "D:\Documents\Desktop\smart_classroom_demo-master\models\yolo_detector.py", line 45, in init** self.model = torch.jit.load(weights).to(device) File "D:\Anaconda2\envs\env_4\lib\site-packages\torch\jit_serialization.py", line 161, in load cpp_module = torch._C.import_ir_module(cu, str(f), map_location, _extra_files) NotImplementedError: Could not run 'aten::empty_strided' 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. 'aten::empty_strided' is only available for these backends: [CPU, Meta, BackendSelect, Named, ADInplaceOrView, AutogradOther, AutogradCPU, AutogradCUDA, AutogradXLA, UNKNOWN_TENSOR_TYPE_ID, AutogradMLC, AutogradHPU, AutogradNestedTensor, AutogradPrivateUse1, AutogradPrivateUse2, AutogradPrivateUse3, Tracer, Autocast, Batched, VmapMode].
你按照pytorch官网的安装命令安装了gpu版的pytorch了吗?
啊,之前没安装上,现在安装成功了,摄像头和本地视频可以打开了,但是打开的一瞬间就立马闪退了,程序直接自己结束了 OMP: Error #15: Initializing libiomp5md.dll, but found libiomp5md.dll already initialized. OMP: Hint This means that multiple copies of the OpenMP runtime have been linked into the program. That is dangerous, since it can degrade performance or cause incorrect results. The best thing to do is to ensure that only a single OpenMP runtime is linked into the process, e.g. by avoiding static linking of the OpenMP runtime in any library. As an unsafe, unsupported, undocumented workaround you can set the environment variable KMP_DUPLICATE_LIB_OK=TRUE to allow the program to continue to execute, but that may cause crashes or silently produce incorrect results. For more information, please see http://www.intel.com/software/products/support/.
你这些是属于环境问题,用搜索引擎解决就可以了蛤😂
噢噢,好的好的,还有一个问题,人脸注册的功能仍然无法实现,控制台也没有报错,可以识别出来人脸,但下面的完成进度条始终为零,请问这是哪里的问题呢?
左上角有红色文字提示,要符合单人、正脸、真脸、在框内四个条件
按照要求配置完成之后,运行时界面卡死,无法加载出来摄像头或是本地视频,人脸注册等其他功能也无法使用,请问是否还需要别的相关代码或要求吗?
你看一下控制台的报错是不是缺文件夹了,有几个文件夹需要手动创建一下。我这边也改了一下代码,你可以下载新的代码试一下
Exception in thread Thread-1: Traceback (most recent call last): File "D:\Anaconda2\envs\env_4\lib\threading.py", line 926, in _bootstrap_inner self.run() File "D:\Anaconda2\envs\env_4\lib\threading.py", line 870, in run self._target(*self._args, self._kwargs) File "D:\Documents\Desktop\smart_classroom_demo-master\smart_classroom\cheating_detection_app.py", line 157, in open_source_func .set_next_module(YoloV5Module(yolov5_weight, device)) File "D:\Documents\Desktop\smart_classroom_demo-master\pipeline_module\yolo_modules.py", line 10, in init self.detector = YoloV5Detector(self.weights, device) File "D:\Documents\Desktop\smart_classroom_demo-master\models\yolo_detector.py", line 45, in init** self.model = torch.jit.load(weights).to(device) File "D:\Anaconda2\envs\env_4\lib\site-packages\torch\jit_serialization.py", line 161, in load cpp_module = torch._C.import_ir_module(cu, str(f), map_location, _extra_files) NotImplementedError: Could not run 'aten::empty_strided' 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. 'aten::empty_strided' is only available for these backends: [CPU, Meta, BackendSelect, Named, ADInplaceOrView, AutogradOther, AutogradCPU, AutogradCUDA, AutogradXLA, UNKNOWN_TENSOR_TYPE_ID, AutogradMLC, AutogradHPU, AutogradNestedTensor, AutogradPrivateUse1, AutogradPrivateUse2, AutogradPrivateUse3, Tracer, Autocast, Batched, VmapMode].
你按照pytorch官网的安装命令安装了gpu版的pytorch了吗?
啊,之前没安装上,现在安装成功了,摄像头和本地视频可以打开了,但是打开的一瞬间就立马闪退了,程序直接自己结束了 OMP: Error #15: Initializing libiomp5md.dll, but found libiomp5md.dll already initialized. OMP: Hint This means that multiple copies of the OpenMP runtime have been linked into the program. That is dangerous, since it can degrade performance or cause incorrect results. The best thing to do is to ensure that only a single OpenMP runtime is linked into the process, e.g. by avoiding static linking of the OpenMP runtime in any library. As an unsafe, unsupported, undocumented workaround you can set the environment variable KMP_DUPLICATE_LIB_OK=TRUE to allow the program to continue to execute, but that may cause crashes or silently produce incorrect results. For more information, please see http://www.intel.com/software/products/support/.
你这些是属于环境问题,用搜索引擎解决就可以了蛤😂
噢噢,好的好的,还有一个问题,人脸注册的功能仍然无法实现,控制台也没有报错,可以识别出来人脸,但下面的完成进度条始终为零,请问这是哪里的问题呢?
左上角有红色文字提示,要符合单人、正脸、真脸、在框内四个条件
大意了大意了,是我一直没有对准,基本功能都差不多了可以实现了,太太太太感谢大佬了!!!感谢指点!!!
我配好环境了,也出现了图形界面,但是导入视频就卡死,请问有完整的项目吗?