Giter Club home page Giter Club logo

trajectory-analysis-and-classification-in-python-pandas-and-scikit-learn-'s Introduction

Trajectory Analysis and Classification in Python (Pandas and Scikit Learn)

A university project for the postgraduate class of Data Mining.

We were given a train_set with geographical points paired with the time interval. Firstly, we cleaned the dataset and then we formed the trajectories (with the corresponding route id).

The goal of this project was firstly to compute trajectory similarity between trajectories of test_set_a1/a2.csv and the train_set.csv.

The algorithms used for that were :

  1. Fast Dynamic Time Warping (Fast-DTW), taken from https://github.com/slaypni/fastdtw
  2. Longest Common Subsequence algorithm, which i implemented.

The distance taken into account each time, was the Havershine distance of the points. Files lcss_neighbors.py and fast_dtw_neighbors.py read the corresponding trajectories from test_set_a1/a2.csv and find the 5 most 'similar' trajectories from the cleaned dataset. Finally, they plot them with some specific metrics of similarity.

The second part of the project was to train KNN,Random Forest, and Logistic Regression classifiers and predict the routes of trajectories of the test_set.csv . The first step was to assign each trajectory to a string (composed of cell codes) via a grid representation. In the second step, 10-cross-fold-validation was used to train the classifiers with grid strings of the dataset with accuracy metric . I conducted various experiments, by changing each classifier's parameters.

Lastly,the classifiers with the best accuracy were bunched together in the Voting Classifier. The final classifier was used to find labels for the trajectories of the test_set.csv .

trajectory-analysis-and-classification-in-python-pandas-and-scikit-learn-'s People

Contributors

jim-spyropoulos avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.