Mercurial > hg > nsaunier > traffic-intelligence
annotate scripts/nomad/README.md @ 1187:25c85a7ecf09
merged
| author | Nicolas Saunier <nicolas.saunier@polymtl.ca> |
|---|---|
| date | Tue, 21 Jun 2022 17:06:21 -0400 |
| parents | 7117a31555c1 |
| children |
| rev | line source |
|---|---|
|
1186
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
1 # Optimization tool |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
2 |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
3 ---- |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
4 ## usage |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
5 1. Make sure your data is structured like so: |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
6 ``` |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
7 Data # Folder containing all the data |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
8 └── <Intersection name> # Intersection (e.g. montcalm-chartwell) |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
9 ├── <tracking configuration file>.cfg |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
10 ├── <Date 1> |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
11 │ ├── <Other subdirectories> # There can be as many subdirectories as you want |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
12 │ ├── <Video 1> |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
13 │ ├── <Ground truth database 1>_gt.sqlite |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
14 │ ├── homography.txt |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
15 │ ├── image.pg |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
16 │ ├── mask.png |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
17 │ └── point-correspondences.txt |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
18 ├── <Date 2> |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
19 └── <Date 3> |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
20 . |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
21 . |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
22 . |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
23 ``` |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
24 |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
25 > Please note : You should have at least one ground truth database (with a name ending with "_gt.sqlite") for each date of the intersection. |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
26 |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
27 2. Select an intersection or several intersections for which you wish to find optimal tracking parameters, for instance: |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
28 |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
29 $ python3 optimize-with-nomad.py -t /media/disk2/etienne/Data/montcalm-chartwell/ /media/disk2/etienne/Data/montcalm-victorin/ --optimize-grouping-only |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
30 |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
31 > Please note : You cannot find the optimal parameters only for the grouping algorithm if there is not a database already created. You should first execute the tracking algorithm with basic parameters. |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
32 |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
33 3. Once the optimal parameters are found, tracking may be launched: |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
34 |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
35 $ cd $HOME/Data/montcalm-chartwell |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
36 $ feature-based-tracking tracking-visible.cfg --tf --video-filename 2019-11-27/Visible/2019-11-27T12\:20-05\:00.MP4 --database-filename 2019-11-27/Visible/2019-11-27T12\:20-05\:00.sqlite --homography-filename 2019-11-27/Visible/homography.txt --mask-filename 2019-11-27/Visible/mask.png --feature-quality 0.1 --min-feature-distanceklt 3.54964337411 --window-size 6 --min-tracking-error 0.01 --min-feature-time 15 |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
37 $ feature-based-tracking tracking-visible.cfg --gf --video-filename 2019-11-27/Visible/2019-11-27T12\:20-05\:00.MP4 --database-filename 2019-11-27/Visible/2019-11-27T12\:20-05\:00.sqlite --homography-filename 2019-11-27/Visible/homography.txt --mask-filename 2019-11-27/Visible/mask.png --mm-connection-distance 2 --mm-segmentation-distance 1.9 --min-nfeatures-group 4 |
|
7117a31555c1
Etienne Beauchamp s work on optimization with Nomad software
Nicolas Saunier <nicolas.saunier@polymtl.ca>
parents:
diff
changeset
|
38 |
