Update Pipline

Hamza 2026-03-29 08:43:27 +02:00
parent 95ae3e768c
commit 166b47a8db

@ -20,7 +20,7 @@ M --> N[Render in Leaflet]
# Why C/C++
What we're building here is a **GPS Trajectory Reconstruction and Stop-Detection Engine**, engines demand high performance code, it's a critical thing. We could've choose a different approach we could've decided to use Python and call Skitlearn library to use DBSCAN, then use OSRM as REST API service, or a different approach integrate DBSCAN into TrizDistribution using Java then use API calls for OSRM.
The Python approach one seems good, we don't need to implement DBSCAN ourselves, well imagine install with your current project an entire additional python interpreter to call an entire library like Skitlearn just for a sake of one algorithm, it's too much resources for a simple thing. Also because we didn't implement the algorithm ourselves we lose control over the implementation, so if you want to implement T-DBSCAN, Adaptive eps or any variants, you will either need to use to ask Skitlearn to implement it for us or we will need to understand how Skitlearn is implemented and do it ourselves.
The Python approach one seems good, we don't need to implement DBSCAN ourselves, well imagine install with your current project an entire additional python interpreter to call an entire library like Skitlearn just for a sake of one algorithm, it's too much resources for a simple thing. Also because we didn't implement the algorithm ourselves we lose control over the implementation, so if you want to implement T-DBSCAN, Adaptive eps or any variants, you will either need to use to ask Sklearn to implement it for us or we will need to understand how Sklearn is implemented and do it ourselves.
The Java approach seems good, but Java is not fast of language also due to everything is an object in Java it will cause the engine to run in slower speeds and the existence of Garbage Collector will make us loose performance, also if we want further optimizations like SIMD Java is not going to help, also we want from our engine to be separated from the project so we use the engine in other projects.
@ -39,10 +39,16 @@ let's say we passed by a place **A** at **08:00AM**, and then we passed by the s
By adding the time aspect the algorithm becomes spatiotemporal, and will fix the issue above.
### Intuition (all together)
Two points belong to the same cluster only if:
- they are close in space (ε)
- close in time (Δt)
- and part of a dense neighborhood (MinPts)
### Parameter
- MinPts:
- eps:
- delte_eps:
- MinPts: Minimum number of points required to form a dense region (core point).
- ε: Maximum spatial distance between two points to be considered neighbors.
- Δt: Maximum time difference allowed between points for them to be considered neighbors in time.
### Optimization
The T-DBSCAN algorithm is optimized with KD-Tree, this will help find the nearest points faster, if further optimizations are needed then we should look into improving the **Cash Hits** and maybe change the algorithm to use **SIMD** and **Multi-Threading**.