Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to deal with "multiprocessing.pool.RemoteTraceback" #375

Open
Destroy95 opened this issue Feb 19, 2023 · 6 comments
Open

How to deal with "multiprocessing.pool.RemoteTraceback" #375

Destroy95 opened this issue Feb 19, 2023 · 6 comments

Comments

@Destroy95
Copy link

Destroy95 commented Feb 19, 2023

Hello!
When I configured the environment and then wanted to test it, when I entered the following command in the terminal

python run_tracker.py atom default --dataset_name otb --sequence Soccer --debug 1 --threads 8 --use_visdom False

such an error occurred

multiprocessing.pool.RemoteTraceback: 
"""
Traceback (most recent call last):
  File "/home/fm/anaconda3/envs/pytracking/lib/python3.7/multiprocessing/pool.py", line 121, in worker
    result = (True, func(*args, **kwds))
  File "/home/fm/anaconda3/envs/pytracking/lib/python3.7/multiprocessing/pool.py", line 47, in starmapstar
    return list(itertools.starmap(args[0], args[1]))
  File "/home/fm/VOT/pytracking/pytracking/evaluation/running.py", line 148, in run_sequence
    output = tracker.run_sequence(seq, debug=debug, visdom_info=visdom_info)
  File "/home/fm/VOT/pytracking/pytracking/evaluation/tracker.py", line 148, in run_sequence
    output = self._track_sequence(tracker, seq, init_info)
  File "/home/fm/VOT/pytracking/pytracking/evaluation/tracker.py", line 183, in _track_sequence
    self.visualize(image, init_info.get('init_bbox'))
  File "/home/fm/VOT/pytracking/pytracking/evaluation/tracker.py", line 656, in visualize
    rect = patches.Rectangle((box[0], box[1]), box[2], box[3], linewidth=1, edgecolor=col, facecolor='none')
IndexError: invalid index to scalar variable.
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/fm/VOT/pytracking/pytracking/run_tracker.py", line 77, in <module>
    main()
  File "/home/fm/VOT/pytracking/pytracking/run_tracker.py", line 73, in main
    args.threads, {'use_visdom': args.use_visdom, 'server': args.visdom_server, 'port': args.visdom_port})
  File "/home/fm/VOT/pytracking/pytracking/run_tracker.py", line 37, in run_tracker
    run_dataset(dataset, trackers, debug, threads, visdom_info=visdom_info)
  File "/home/fm/VOT/pytracking/pytracking/evaluation/running.py", line 203, in run_dataset
    pool.starmap(run_sequence, param_list)
  File "/home/fm/anaconda3/envs/pytracking/lib/python3.7/multiprocessing/pool.py", line 276, in starmap
    return self._map_async(func, iterable, starmapstar, chunksize).get()
  File "/home/fm/anaconda3/envs/pytracking/lib/python3.7/multiprocessing/pool.py", line 657, in get
    raise self._value
IndexError: invalid index to scalar variable.

Process finished with exit code 1

ubuntu 22.04, cuda 11.0, pytorch 1.7.1

@2006pmach
Copy link
Collaborator

2006pmach commented Feb 19, 2023

Have you tried running with a --thread 0 ? Does this work?

@Destroy95
Copy link
Author

Have you tried running with a --thread 0 ? Does this work?

I tried, but it also has similar problems

Traceback (most recent call last):
  File "/home/fm/VOT/pytracking/pytracking/run_tracker.py", line 77, in <module>
    main()
  File "/home/fm/VOT/pytracking/pytracking/run_tracker.py", line 73, in main
    args.threads, {'use_visdom': args.use_visdom, 'server': args.visdom_server, 'port': args.visdom_port})
  File "/home/fm/VOT/pytracking/pytracking/run_tracker.py", line 37, in run_tracker
    run_dataset(dataset, trackers, debug, threads, visdom_info=visdom_info)
  File "/home/fm/VOT/pytracking/pytracking/evaluation/running.py", line 199, in run_dataset
    run_sequence(seq, tracker_info, debug=debug, visdom_info=visdom_info)
  File "/home/fm/VOT/pytracking/pytracking/evaluation/running.py", line 148, in run_sequence
    output = tracker.run_sequence(seq, debug=debug, visdom_info=visdom_info)
  File "/home/fm/VOT/pytracking/pytracking/evaluation/tracker.py", line 148, in run_sequence
    output = self._track_sequence(tracker, seq, init_info)
  File "/home/fm/VOT/pytracking/pytracking/evaluation/tracker.py", line 183, in _track_sequence
    self.visualize(image, init_info.get('init_bbox'))
  File "/home/fm/VOT/pytracking/pytracking/evaluation/tracker.py", line 656, in visualize
    rect = patches.Rectangle((box[0], box[1]), box[2], box[3], linewidth=1, edgecolor=col, facecolor='none')
IndexError: invalid index to scalar variable.

Process finished with exit code 1

@2006pmach
Copy link
Collaborator

2006pmach commented Feb 19, 2023

Looks like something could be wrong with your init_info.get('init_box'). Can you try printing it? or the box array? Alternatively you can try to run dimp or another dataset to debug this further... Btw. did you change the default.py parameter file? In particular did you set params.visualizaton = True here? I don't understand why the function self.visualize() is called in your case... Using visdom is preferable and much nicer to use than matplotlib...

@Destroy95
Copy link
Author

Looks like something could be wrong with your init_info.get('init_box'). Can you try printing it? or the box array? Alternatively you can try to run dimp or another dataset to debug this further... Btw. did you change the default.py parameter file? In particular did you set params.visualizaton = True here? I don't understand why the function self.visualize() is called in your case... Using visdom is preferable and much nicer to use than matplotlib...

OK, thank you so much! I'll try printing it out to see the result.

@llxxdu
Copy link

llxxdu commented Mar 29, 2023

看起来您的.你能尝试打印它吗?还是阵列?或者,您可以尝试运行 dimp 或其他数据集来进一步调试...顺便说一句,您是否更改了参数文件?特别是你设置在这里吗?我不明白为什么在您的情况下调用该函数...使用 visdom 比 matplotlib 更可取,而且使用起来更好......init_info.get('init_box')``box``default.py`` params.visualizaton = True``self.visualize()

I have the same question,how can I do to solve it

@chenyucheng0221
Copy link

Does anyone solve this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants