franktpmvu / NeighborTrack

[CVPR 2023 workshop] NeighborTrack: Single Object Tracking by Bipartite Matching With Neighbor Tracklets and Its Applications to Sports
47 stars 1 forks source link

Using UAV123 dataset #4

Closed ukdarc closed 1 year ago

ukdarc commented 1 year ago

how to use UAV123 dataset in neighbortrack ostrack for training

franktpmvu commented 1 year ago

this code didn't need training

if you mean for testing:

1.download uav123 on your dataset path 2.change path from: https://github.com/franktpmvu/NeighborTrack/blob/452831e41b2b2d61297cead7db8b3a14f9cf7268/trackers/ostrack/lib/test/evaluation/local.py#L30

3.cd to NeighborTrack/trackers/ostrack/

4.python tracking/test.py ostrack vitb_384_mae_ce_32x4_ep300_neighbor --dataset uav --threads 16 --num_gpus 8 --neighbor 1

optional open ntracker.rev_frames and ntracker.test_probe_rev_frames = 27, more accuracy and lower fps: https://github.com/franktpmvu/NeighborTrack/blob/452831e41b2b2d61297cead7db8b3a14f9cf7268/trackers/ostrack/lib/test/evaluation/tracker.py#L364

ukdarc commented 1 year ago

I did change the uav path in local.py , i also changed settings.network_path to my '$PROJECT_ROOT$/output/checkpoints/train/ostrack/vitb_384_mae_ce_32x4_ep300_neighbor/' but the code throws this error

D:\track\NeighborTrack\trackers\ostrack>python tracking/test.py ostrack vitb_384_mae_ce_32x4_ep300_neighbor --dataset uav --threads 16 --num_gpus 8 --neighbor 1 Traceback (most recent call last): File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\environment.py", line 116, in env_settings env_module = importlib.import_module(env_module_name) File "C:\Users\HP\AppData\Local\Programs\Python\Python310\lib\importlib__init__.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1050, in _gcd_import File "", line 1027, in _find_and_load File "", line 1006, in _find_and_load_unlocked File "", line 688, in _load_unlocked File "", line 883, in exec_module File "", line 241, in _call_with_frames_removed File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\local.py", line 1, in from test.evaluation.environment import EnvSettings ModuleNotFoundError: No module named 'test.evaluation'; 'test' is not a package

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:\track\NeighborTrack\trackers\ostrack\tracking\test.py", line 87, in main() File "D:\track\NeighborTrack\trackers\ostrack\tracking\test.py", line 78, in main run_tracker_neighbor(args.tracker_name, args.tracker_param, args.runid, args.dataset_name, seq_name, args.debug, File "D:\track\NeighborTrack\trackers\ostrack\tracking\test.py", line 49, in run_tracker_neighbor dataset = get_dataset(dataset_name) File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\datasets.py", line 47, in get_dataset dset.extend(load_dataset(name)) File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\datasets.py", line 39, in load_dataset dataset = getattr(m, dset_info.class_name)(**dset_info.kwargs) # Call the constructor File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\uavdataset.py", line 16, in init super().init() File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\data.py", line 10, in init self.env_settings = env_settings() File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\environment.py", line 123, in env_settings raise RuntimeError('YOU HAVE NOT SETUP YOUR local.py!!!\n Go to "{}" and set all the paths you need. ' RuntimeError: YOU HAVE NOT SETUP YOUR local.py!!! Go to "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\local.py" and set all the paths you need. Then try to run again.

franktpmvu commented 1 year ago

hi:

Did you can let me see your local.py

I think you have some paths not setting up.

Best

Yuhsi.

2023年5月8日(月) 14:29 ukdarc @.***>:

I did change the local path but it throws this error

D:\track\NeighborTrack\trackers\ostrack>python tracking/test.py ostrack vitb_384_mae_ce_32x4_ep300_neighbor --dataset uav --threads 16 --num_gpus 8 --neighbor 1 Traceback (most recent call last): File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\environment.py", line 116, in env_settings env_module = importlib.import_module(env_modulename) File "C:\Users\HP\AppData\Local\Programs\Python\Python310\lib\importlib init_.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1050, in _gcd_import File "", line 1027, in _find_and_load File "", line 1006, in _find_and_load_unlocked File "", line 688, in _load_unlocked File "", line 883, in exec_module File "", line 241, in _call_with_frames_removed File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\local.py", line 1, in from test.evaluation.environment import EnvSettings ModuleNotFoundError: No module named 'test.evaluation'; 'test' is not a package

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:\track\NeighborTrack\trackers\ostrack\tracking\test.py", line 87, in main() File "D:\track\NeighborTrack\trackers\ostrack\tracking\test.py", line 78, in main run_tracker_neighbor(args.tracker_name, args.tracker_param, args.runid, args.dataset_name, seq_name, args.debug, File "D:\track\NeighborTrack\trackers\ostrack\tracking\test.py", line 49, in run_tracker_neighbor dataset = get_dataset(dataset_name) File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\datasets.py", line 47, in get_dataset dset.extend(load_dataset(name)) File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\datasets.py", line 39, in load_dataset dataset = getattr(m, dset_info.class_name)(*dset_info.kwargs) # Call the constructor File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\uavdataset.py", line 16, in init super().init() File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\data.py", line 10, in init* self.env_settings = env_settings() File "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\environment.py", line 123, in env_settings raise RuntimeError('YOU HAVE NOT SETUP YOUR local.py!!!\n Go to "{}" and set all the paths you need. ' RuntimeError: YOU HAVE NOT SETUP YOUR local.py!!! Go to "D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\local.py" and set all the paths you need. Then try to run again.

— Reply to this email directly, view it on GitHub https://github.com/franktpmvu/NeighborTrack/issues/4#issuecomment-1537825391, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJJLQV7E7BFXWSLLWJBDOC3XFCHDPANCNFSM6AAAAAAXX473YM . You are receiving this because you commented.Message ID: @.***>

franktpmvu commented 1 year ago

did you run this line in path "NeighborTrack\trackers\ostrack"?

python tracking/create_default_local_file.py --workspace_dir {} --data_dir ./data --save_dir ./output

ukdarc commented 1 year ago

did you run this line in path "NeighborTrack\trackers\ostrack"?

python tracking/create_default_local_file.py --workspace_dir {} --data_dir ./data --save_dir ./output

yes i did

ukdarc commented 1 year ago

hi, this is my local python program

On Mon, May 8, 2023 at 12:18 PM franktpmvu @.***> wrote:

hi:

Did you can let me see your local.py

I think you have some paths not setting up.

Best

Yuhsi.

2023年5月8日(月) 14:29 ukdarc @.***>:

I did change the local path but it throws this error

D:\track\NeighborTrack\trackers\ostrack>python tracking/test.py ostrack vitb_384_mae_ce_32x4_ep300_neighbor --dataset uav --threads 16 --num_gpus 8 --neighbor 1 Traceback (most recent call last): File

"D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\environment.py", line 116, in env_settings env_module = importlib.import_module(env_modulename) File "C:\Users\HP\AppData\Local\Programs\Python\Python310\lib\importlib init_.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1050, in _gcd_import File "", line 1027, in _find_and_load File "", line 1006, in _find_and_load_unlocked File "", line 688, in _load_unlocked File "", line 883, in exec_module File "", line 241, in _call_with_frames_removed File

"D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\local.py", line 1, in from test.evaluation.environment import EnvSettings ModuleNotFoundError: No module named 'test.evaluation'; 'test' is not a package

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:\track\NeighborTrack\trackers\ostrack\tracking\test.py", line 87, in main() File "D:\track\NeighborTrack\trackers\ostrack\tracking\test.py", line 78, in main run_tracker_neighbor(args.tracker_name, args.tracker_param, args.runid, args.dataset_name, seq_name, args.debug, File "D:\track\NeighborTrack\trackers\ostrack\tracking\test.py", line 49, in run_tracker_neighbor dataset = get_dataset(dataset_name) File

"D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\datasets.py", line 47, in get_dataset dset.extend(load_dataset(name)) File

"D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\datasets.py", line 39, in load_dataset dataset = getattr(m, dset_info.class_name)(**dset_info.kwargs) # Call the constructor File

"D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\uavdataset.py", line 16, in init super().init() File

"D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\data.py", line 10, in init self.env_settings = env_settings() File

"D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\environment.py", line 123, in env_settings raise RuntimeError('YOU HAVE NOT SETUP YOUR local.py!!!\n Go to "{}" and set all the paths you need. ' RuntimeError: YOU HAVE NOT SETUP YOUR local.py!!! Go to

"D:\track\NeighborTrack\trackers\ostrack\tracking..\lib\test\evaluation\local.py" and set all the paths you need. Then try to run again.

— Reply to this email directly, view it on GitHub < https://github.com/franktpmvu/NeighborTrack/issues/4#issuecomment-1537825391 , or unsubscribe < https://github.com/notifications/unsubscribe-auth/AJJLQV7E7BFXWSLLWJBDOC3XFCHDPANCNFSM6AAAAAAXX473YM

. You are receiving this because you commented.Message ID: @.***>

— Reply to this email directly, view it on GitHub https://github.com/franktpmvu/NeighborTrack/issues/4#issuecomment-1537841389, or unsubscribe https://github.com/notifications/unsubscribe-auth/A4IERNKZYZMYOC22N6HIZUTXFCJM5ANCNFSM6AAAAAAXX473YM . You are receiving this because you authored the thread.Message ID: @.***>

from lib.test.evaluation.environment import EnvSettings

def local_env_settings(): settings = EnvSettings()

# Set your local paths here.

settings.davis_dir = ''
settings.got10k_lmdb_path = 'D:\track\NeighborTrack\trackers\ostrack\data\got10k_lmdb'
settings.got10k_path = 'D:\track\NeighborTrack\trackers\ostrack\data\got10k'
settings.got_packed_results_path = ''
settings.got_reports_path = ''
settings.itb_path = 'D:\track\NeighborTrack\trackers\ostrack\data\itb'
settings.lasot_extension_subset_path_path = 'D:\track\NeighborTrack\trackers\ostrack\data\lasot_extension_subset'
settings.lasot_lmdb_path = 'D:\track\NeighborTrack\trackers\ostrack\data\lasot_lmdb'
settings.lasot_path = 'D:\track\NeighborTrack\trackers\ostrack\data\lasot'
settings.network_path = 'D:\track\NeighborTrack\trackers\ostrack\output\checkpoints\train\ostrack\vitb_384_mae_ce_32x4_ep300_neighbor'    # Where tracking networks are stored.
settings.nfs_path = 'D:\track\NeighborTrack\trackers\ostrack\data\nfs'
settings.otb_path = 'D:\track\NeighborTrack\trackers\ostrack\data\otb'
settings.prj_dir = 'D:\track\NeighborTrack\trackers\ostrack'
settings.result_plot_path = 'D:\track\NeighborTrack\trackers\ostrack\output\test/result_plots'
settings.results_path = 'D:\track\NeighborTrack\trackers\ostrack\output\test/tracking_results'    # Where to store tracking results
settings.save_dir = 'D:\track\NeighborTrack\trackers\ostrack\output'
settings.segmentation_path = 'D:\track\NeighborTrack\trackers\ostrack\output\test/segmentation_results'
settings.tc128_path = 'D:\track\NeighborTrack\trackers\ostrack\data\TC128'
settings.tn_packed_results_path = ''
settings.tnl2k_path = 'D:\track\NeighborTrack\trackers\ostrack\data\tnl2k'
settings.tpl_path = ''
settings.trackingnet_path = 'D:\track\NeighborTrack\trackers\ostrack\data\trackingnet'
settings.uav_path = 'D:\track\NeighborTrack\trackers\ostrack\data\uav'
settings.vot18_path = 'D:\track\NeighborTrack\trackers\ostrack\data\vot2018'
settings.vot22_path = 'D:\track\NeighborTrack\trackers\ostrack\data\vot2022'
settings.vot_path = 'D:\track\NeighborTrack\trackers\ostrack\data\VOT2019'
settings.youtubevos_dir = ''

return settings
franktpmvu commented 1 year ago

ok, try add paths on tracking/test.py

D:\track\NeighborTrack\trackers\ostrack\lib\test\tracker\ D:\track\NeighborTrack\trackers\ostrack\tracking\ D:\track\

ukdarc commented 1 year ago

it's working now, thanks.