nwojke / deep_sort

Simple Online Realtime Tracking with a Deep Association Metric
GNU General Public License v3.0
5.19k stars 1.46k forks source link

cost_matrix[cost_matrix > max_distance] = max_distance + 1e-5 #251

Closed wzwb closed 3 years ago

wzwb commented 3 years ago

Hi, Today, when I read your code ,I can't understand the 57 line in the deepsort/linear_assignment.py :cost_matrix[cost_matrix > max_distance] = max_distance + 1e-5 . Why change the cost larger than the max_distance to max_distance + 1e-5? For example if a cost is 0.3 ,it's similarity is 0.7 . And if we change it to 0.200001 ,its similarity becomes to 0.79999.