Hello, could you tell me how the density map is generated
Transformer-man opened this issue · 5 comments
Hi~
Could you give me more information about this density map?
Please read Sec. 1.4, Sec. 1.4 4), & Sec. 1.1 in README. You should run eval.sh or eval_torch.sh under this directory: https://github.com/zhiyuanyou/SAFECount/blob/main/experiments/Mall/ for evaluation and visualization.
If your question is about the implementation details of visualization, you can see: https://github.com/zhiyuanyou/SAFECount/blob/main/utils/vis_helper.py
(safeCount) a@r4611:/media/a/2TB/SAFECount-main$ sh experiments/Mall/eval_torch.sh
/home/a/anaconda3/envs/safeCount/lib/python3.8/site-packages/torch/distributed/launch.py:181: FutureWarning: The module torch.distributed.launch is deprecated
and will be removed in future. Use torchrun.
Note that --use-env is set by default in torchrun.
If your script expects --local-rank
argument to be set, please
change it to read from os.environ['LOCAL_RANK']
instead. See
https://pytorch.org/docs/stable/distributed.html#launch-utility for
further instructions
warnings.warn(
Traceback (most recent call last):
File "/home/a/anaconda3/envs/safeCount/lib/python3.8/site-packages/torch/distributed/run.py", line 632, in determine_local_world_size
return int(nproc_per_node)
ValueError: invalid literal for int() with base 10: ''
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/a/anaconda3/envs/safeCount/lib/python3.8/runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/home/a/anaconda3/envs/safeCount/lib/python3.8/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/home/a/anaconda3/envs/safeCount/lib/python3.8/site-packages/torch/distributed/launch.py", line 196, in
main()
File "/home/a/anaconda3/envs/safeCount/lib/python3.8/site-packages/torch/distributed/launch.py", line 192, in main
launch(args)
File "/home/a/anaconda3/envs/safeCount/lib/python3.8/site-packages/torch/distributed/launch.py", line 177, in launch
run(args)
File "/home/a/anaconda3/envs/safeCount/lib/python3.8/site-packages/torch/distributed/run.py", line 784, in run
config, cmd, cmd_args = config_from_args(args)
File "/home/a/anaconda3/envs/safeCount/lib/python3.8/site-packages/torch/distributed/run.py", line 691, in config_from_args
nproc_per_node = determine_local_world_size(args.nproc_per_node)
File "/home/a/anaconda3/envs/safeCount/lib/python3.8/site-packages/torch/distributed/run.py", line 650, in determine_local_world_size
raise ValueError(f"Unsupported nproc_per_node value: {nproc_per_node}") from e
ValueError: Unsupported nproc_per_node value:
Please see Sec. 1.1 in README, which writes in detail:
- cd the experiment directory by
cd experiments/Mall
- eval by running
sh eval_torch.sh 1 0
with the format ofsh eval_torch.sh #NUM_GPUS #GPU_IDS
.