cyang-kth / fmm

Fast map matching, an open source framework in C++
https://fmm-wiki.github.io/
Apache License 2.0
891 stars 215 forks source link

Ubodt.txt is extremely large #220

Closed tlian-lainie closed 2 years ago

tlian-lainie commented 2 years ago

Describe the bug Hi, Can. Thanks for providing a good open-source algorithm for map matching. I am using the algorithm to match Taxi GPS with roads, while encountered some problems when using the full dataset. When I ran "fmm_example.ipynb" (in this folder: ../example/notebook) using my own dataset: 1) Road network reconstructed based on your standard with 70884 nodes and 126217 edges 2) GPS trajectory: 3553 points organized in a LineString of one vehicle. I found the ubodt.txt generated by this line: status = ubodt_gen.generate_ubodt("../data/test_data/ubodt.txt", 4, binary=False, use_omp=True) is extremely large (~136GB, have run for several hours and still running). It seems that something went wrong, but I failed to identify the error. Could you please give me some suggestions? Many thanks.

Screenshots The code line with problem: image The structure of my road network: image The structure of my GPS trajectory: image

cyang-kth commented 2 years ago

If your data is in unit of lat, lng, the delta of 4 in ubodt is 400km, you should try 3km if possible, which should be 0.03 degree in your case.

cyang-kth commented 2 years ago

Check this note https://github.com/cyang-kth/fmm/issues/138#issuecomment-739834242

tlian-lainie commented 2 years ago

Thanks a lot for your prompt feedback!! It worked now!! Thanks!