You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Inference ----------------------------------------
Traceback (most recent call last):
File "mmocr\cv2demo\detect_text.py", line 11, in
inferencer(img, save_vis=True,return_vis=True)
File "mmocr\mmocr\apis\inferencers\base_mmocr_inferencer.py", line 194, in call
visualization = self.visualize(
File "\mmocr\mmocr\apis\inferencers\base_mmocr_inferencer.py", line 304, in visualize
visualization = self.visualizer.add_datasample(
File "mmocr\mmocr\visualization\textspotting_visualizer.py", line 120, in add_datasample
pred_instances.scores > pred_score_thr].cpu().numpy()
TypeError: '>' not supported between instances of 'list' and 'float'
Process finished with exit code 1
Additional information
No response
The text was updated successfully, but these errors were encountered:
Prerequisite
Task
I have modified the scripts/configs, or I'm working on my own tasks/models/datasets.
Branch
main branch https://github.com/open-mmlab/mmocr
Environment
sys.platform: win32
Python: 3.8.17 (default, Jul 5 2023, 20:44:21) [MSC v.1916 64 bit (AMD64)]
CUDA available: True
numpy_random_seed: 2147483648
GPU 0: NVIDIA GeForce GTX 1080 Ti
CUDA_HOME: C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v12.2
NVCC: Cuda compilation tools, release 12.2, V12.2.140
MSVC: 用于 x64 的 Microsoft (R) C/C++ 优化编译器 19.35.32217.1 版
GCC: n/a
PyTorch: 1.10.2
PyTorch compiling details: PyTorch built with:
-gencode;arch=compute_61,code=sm_61;-gencode;arch=compute_70,code=sm_70;-gencode;arch=compute_75,code=sm_75;-gencode;arch=compute_80,code
=sm_80;-gencode;arch=compute_86,code=sm_86;-gencode;arch=compute_37,code=compute_37
ork/tmp_bin/sccache-cl.exe, CXX_FLAGS=/DWIN32 /D_WINDOWS /GR /EHsc /w /bigobj -DUSE_PTHREADPOOL -openmp:experimental -IC:/cb/pytorch_1000
000000000/work/mkl/include -DNDEBUG -DUSE_KINETO -DLIBKINETO_NOCUPTI -DUSE_FBGEMM -DUSE_XNNPACK -DSYMBOLICATE_MOBILE_DEBUG_HANDLE -DEDGE_
PROFILER_USE_KINETO, LAPACK_INFO=mkl, PERF_WITH_AVX=1, PERF_WITH_AVX2=1, PERF_WITH_AVX512=1, TORCH_VERSION=1.10.2, USE_CUDA=ON, USE_CUDNN
=ON, USE_EXCEPTION_PTR=1, USE_GFLAGS=OFF, USE_GLOG=OFF, USE_MKL=ON, USE_MKLDNN=ON, USE_MPI=OFF, USE_NCCL=OFF, USE_NNPACK=OFF, USE_OPENMP=
ON,
TorchVision: 0.11.3
OpenCV: 4.6.0
MMEngine: 0.8.4
MMOCR: 1.0.1+9551af6
Reproduces the problem - code sample
from mmocr.apis import MMOCRInferencer, TextSpotInferencer
读取图像
img_path = r'1.jpg'
img = cv2.imread(img_path)
inferencer = TextSpotInferencer(model=r'mmocr\work_dirs\spts_resnet50_8xb8-200e_icdar2015_original\spts_resnet50_8xb8-200e_icdar2015.py', weights=r'mmocr\work_dirs\spts_resnet50_8xb8-200e_icdar2015_original\best_generic_hmean_epoch_100.pth')
inferencer(img, save_vis=True,return_vis=True)
Reproduces the problem - command or script
from mmocr.apis import MMOCRInferencer, TextSpotInferencer
读取图像
img_path = r'1.jpg'
img = cv2.imread(img_path)
inferencer = TextSpotInferencer(model=r'mmocr\work_dirs\spts_resnet50_8xb8-200e_icdar2015_original\spts_resnet50_8xb8-200e_icdar2015.py', weights=r'mmocr\work_dirs\spts_resnet50_8xb8-200e_icdar2015_original\best_generic_hmean_epoch_100.pth')
inferencer(img, save_vis=True,return_vis=True)
Reproduces the problem - error message
Inference ----------------------------------------
Traceback (most recent call last):
File "mmocr\cv2demo\detect_text.py", line 11, in
inferencer(img, save_vis=True,return_vis=True)
File "mmocr\mmocr\apis\inferencers\base_mmocr_inferencer.py", line 194, in call
visualization = self.visualize(
File "\mmocr\mmocr\apis\inferencers\base_mmocr_inferencer.py", line 304, in visualize
visualization = self.visualizer.add_datasample(
File "mmocr\mmocr\visualization\textspotting_visualizer.py", line 120, in add_datasample
pred_instances.scores > pred_score_thr].cpu().numpy()
TypeError: '>' not supported between instances of 'list' and 'float'
Process finished with exit code 1
Additional information
No response
The text was updated successfully, but these errors were encountered: