rachana219 commited on
Commit
59aac49
·
1 Parent(s): f4dffd1

Update track.py

Browse files
Files changed (1) hide show
  1. track.py +6 -5
track.py CHANGED
@@ -72,7 +72,8 @@ def run(
72
  augment=False, # augmented inference
73
  visualize=False, # visualize features
74
  update=False, # update all models
75
- project=ROOT / 'runs' / 'track', # save results to project/name
 
76
  name='exp', # save results to project/name
77
  exist_ok=True, # existing project/name ok, do not increment
78
  line_thickness=2, # bounding box thickness (pixels)
@@ -343,9 +344,9 @@ def parse_opt():
343
  parser.add_argument('--augment', action='store_true', help='augmented inference')
344
  parser.add_argument('--visualize', action='store_true', help='visualize features')
345
  parser.add_argument('--update', action='store_true', help='update all models')
346
- parser.add_argument('--project', default=ROOT / 'runs' / 'track', help='save results to project/name')
347
- parser.add_argument('--name', default='exp', help='save results to project/name')
348
- parser.add_argument('--exist-ok', action='store_true', help='existing project/name ok, do not increment')
349
  parser.add_argument('--line-thickness', default=2, type=int, help='bounding box thickness (pixels)')
350
  parser.add_argument('--hide-labels', default=False, action='store_true', help='hide labels')
351
  parser.add_argument('--hide-conf', default=False, action='store_true', help='hide confidences')
@@ -381,7 +382,7 @@ def MOT(yoloweights, trackingmethod, sourceVideo):
381
  opt.tracking_config = ROOT / 'trackers' / opt.tracking_method / 'configs' / (opt.tracking_method + '.yaml')
382
  print_args(vars(opt))
383
  main(opt)
384
- save_dir = increment_path('runs/track/exp', exist_ok=True)
385
  input = os.path.join(save_dir,'out.mp4')
386
  outpath = 'output.mp4' #'output/'+ 'output.mp4'
387
  command = f"ffmpeg -i {input} -vf fps=30 -vcodec libx264 {outpath}"
 
72
  augment=False, # augmented inference
73
  visualize=False, # visualize features
74
  update=False, # update all models
75
+ #project=ROOT / 'runs' / 'track', # save results to project/name
76
+ project=ROOT # save results to project/name
77
  name='exp', # save results to project/name
78
  exist_ok=True, # existing project/name ok, do not increment
79
  line_thickness=2, # bounding box thickness (pixels)
 
344
  parser.add_argument('--augment', action='store_true', help='augmented inference')
345
  parser.add_argument('--visualize', action='store_true', help='visualize features')
346
  parser.add_argument('--update', action='store_true', help='update all models')
347
+ parser.add_argument('--project', default=ROOT , help='save results to project/name')
348
+ parser.add_argument('--name', default='exp', help='save results to ROOT')
349
+ parser.add_argument('--exist-ok', default='True', action='store_true', help='existing project/name ok, do not increment')
350
  parser.add_argument('--line-thickness', default=2, type=int, help='bounding box thickness (pixels)')
351
  parser.add_argument('--hide-labels', default=False, action='store_true', help='hide labels')
352
  parser.add_argument('--hide-conf', default=False, action='store_true', help='hide confidences')
 
382
  opt.tracking_config = ROOT / 'trackers' / opt.tracking_method / 'configs' / (opt.tracking_method + '.yaml')
383
  print_args(vars(opt))
384
  main(opt)
385
+ save_dir = increment_path('exp', exist_ok=True)
386
  input = os.path.join(save_dir,'out.mp4')
387
  outpath = 'output.mp4' #'output/'+ 'output.mp4'
388
  command = f"ffmpeg -i {input} -vf fps=30 -vcodec libx264 {outpath}"