Coder Social home page Coder Social logo

lyapunovstability / dtw-pool Goto Github PK

View Code? Open in Web Editor NEW

This project forked from donalee/dtw-pool

0.0 0.0 0.0 1.2 MB

Implementation of dynamic temporal pooling (DTP) for time series classification

License: GNU General Public License v3.0

Python 11.35% TypeScript 88.65%

dtw-pool's Introduction

Learnable Dynamic Temporal Pooling for Time Series Classification

Overview

The global pooling layer (i.e., global average/max pooling) that has been mainly adopted by existing CNN classifiers simply aggregates all hidden vectors, whereas our dynamic temporal pooling (DTP) layer effectively reduces the temporal size based on semantic segmentation. A CNN classifier with the DTP layer utilizes the segment-level representation and segment-level fully-connected layer for its classification, which allows to extract further class-discriminative features and improves the classification accruacy.

Running the codes

STEP 1. Install the following python libraries / packages

  • numpy
  • numba
  • sktime
  • pytorch

STEP 2. Download the benchmark datasets for time series classification

  • We provide a small univariate time series dataset, GunPoint, as default.
  • The datatsets can be downloaded from the UCR/UEA repository: http://www.timeseriesclassification.com.
  • Place DATASET_TRAIN.ts and DATASET_TEST.ts files in ./data/Univariate/DATASET or ./data/Multivariate/DATASET.

STEP 3. Train the CNN classifier with the DTP layer

You can simply run the code by the following command.

python train_classifier.py

You can further specify the details of the classifier and its optimization by input arguments.

python train_classifier.py --dataset GunPoint --model fcn --pooling_op max --n_segments 4 --gamma 1.0

Citation

@inproceedings{lee2021learnable,
  title={Learnable Dynamic Temporal Pooling for Time Series Classification},
  author={Lee, Dongha and Lee, Seonghyeon and Yu, Hwanjo},
  booktitle={Proceedings of the AAAI Conference on Artificial Intelligence},
  volume={35},
  number={9},
  pages={8288--8296},
  year={2021}
}

dtw-pool's People

Contributors

donalee 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.