{"id":18508847,"url":"https://github.com/hfawaz/inceptiontime","last_synced_at":"2025-04-04T10:09:50.413Z","repository":{"id":37612188,"uuid":"208274179","full_name":"hfawaz/InceptionTime","owner":"hfawaz","description":"InceptionTime: Finding AlexNet for Time Series Classification","archived":false,"fork":false,"pushed_at":"2023-10-16T09:30:10.000Z","size":761,"stargazers_count":657,"open_issues_count":30,"forks_count":152,"subscribers_count":21,"default_branch":"master","last_synced_at":"2025-03-28T09:09:21.720Z","etag":null,"topics":["alexnet","deep-learning","inception","inceptionv3","neural-networks","scalable","time-series-analysis","time-series-classification"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hfawaz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2019-09-13T13:50:21.000Z","updated_at":"2025-03-18T21:36:28.000Z","dependencies_parsed_at":"2023-01-24T07:15:12.557Z","dependency_job_id":"d74e1152-c0f1-42a5-8ab6-94f13d43279e","html_url":"https://github.com/hfawaz/InceptionTime","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hfawaz%2FInceptionTime","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hfawaz%2FInceptionTime/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hfawaz%2FInceptionTime/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hfawaz%2FInceptionTime/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hfawaz","download_url":"https://codeload.github.com/hfawaz/InceptionTime/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247157283,"owners_count":20893220,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["alexnet","deep-learning","inception","inceptionv3","neural-networks","scalable","time-series-analysis","time-series-classification"],"created_at":"2024-11-06T15:15:36.610Z","updated_at":"2025-04-04T10:09:50.383Z","avatar_url":"https://github.com/hfawaz.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# InceptionTime: Finding AlexNet for Time Series Classification\nThis is the companion repository for our paper titled [InceptionTime: Finding AlexNet for Time Series Classification](https://link.springer.com/article/10.1007/s10618-020-00710-y) published in [Data Mining and Knowledge Discovery](https://www.springer.com/journal/10618) and also available on [ArXiv](https://arxiv.org/pdf/1909.04939.pdf). \n\n## Inception module\n![inception module](https://github.com/hfawaz/InceptionTime/blob/master/pngs/inception-module.png)\n\n## Data\nThe data used in this project comes from the [UCR/UEA archive](http://timeseriesclassification.com/TSC.zip). \nWe used the 85 datasets listed [here](https://www.cs.ucr.edu/~eamonn/time_series_data/).  \n\n## Requirements\nYou will need to install the following packages present in the [requirements.txt](https://github.com/hfawaz/InceptionTime/blob/master/requirements.txt) file. \n\n## Code\nThe code is divided as follows: \n* The [main.py](https://github.com/hfawaz/InceptionTime/blob/master/main.py) python file contains the necessary code to run an experiement. \n* The [utils](https://github.com/hfawaz/InceptionTime/tree/master/utils) folder contains the necessary functions to read the datasets and visualize the plots.\n* The [classifiers](https://github.com/hfawaz/InceptionTime/tree/master/classifiers) folder contains two python files: (1) [inception.py](https://github.com/hfawaz/InceptionTime/tree/master/classifiers/inception.py) contains the inception network; (2) [nne.py](https://github.com/hfawaz/InceptionTime/tree/master/classifiers/nne.py) contains the code that ensembles a set of Inception networks. \n\n### Adapt the code for your PC\nYou should first consider changing the following [line](https://github.com/hfawaz/InceptionTime/blob/c9a323c789984e3fb56e82ebb4eea6438611e59c/main.py#L83). \nThis is the root file of everything (data and results) let's call it ```root_dir```. \n\nAfter that you should create a folder called ```archives``` inside your ```root_dir```, which should contain the folder ```UCR_TS_Archive_2015```. \nThe latter will contain a folder for each dataset called ```dataset_name```, which can be downloaded from this [website](https://www.cs.ucr.edu/~eamonn/time_series_data/).\n\nThe names of the datasets are present [here](https://github.com/hfawaz/InceptionTime/blob/c9a323c789984e3fb56e82ebb4eea6438611e59c/utils/constants.py#L1). \nYou can comment [this line](https://github.com/hfawaz/InceptionTime/blob/c9a323c789984e3fb56e82ebb4eea6438611e59c/utils/constants.py#L19) to run the experiments on all datasets. \n\nOnce you have done all that, you can proceed to run on a single archive. \n\n### Run InceptionTime on a single Archive\nYou should issue the following command ```python3 main.py InceptionTime```. \n\n### Run the hyperparameter search for InceptionTime on a single Archive\nYou should issue the following command ```python3 main.py InceptionTime_xp```. \n\n### Run the length experiment on the InlineSkate dataset\nYou should first issue the following command ```python3 main.py run_length_xps``` to generate the resamples.\nThen you should issue the following command ```python3 main.py InceptionTime``` but make sure that the ```InlineSkateXPs``` is chosen [here](https://github.com/hfawaz/InceptionTime/blob/690aa776081e77214db95ddd5c53c7ec3ac79d61/utils/constants.py#L22). \n\n### Receptive field\nTo run the experiments on the synthetic dataset, you should issue the following command ```python3 receptive.py```. \n\n## Results\nThe result (i.e. accuracy) for each dataset will be present in ```root_dir/results/nne/incepton-0-1-2-4-/UCR_TS_Archive_2015/dataset_name/df_metrics.csv```.\n\nThe raw results can be found [here](https://github.com/hfawaz/InceptionTime/blob/master/results-InceptionTime-85.csv) and generated using the following command ```python3 main.py generate_results_csv```.\n\nWe added the full results for the 128 datasets from the UCR archive, they can be found [here](https://github.com/hfawaz/InceptionTime/blob/master/results-InceptionTime-128.csv). \n\n\u003c!-- We have added the full results for the 30 datasets from the [MTS UEA archive](http://www.timeseriesclassification.com/), they can be found [here](https://github.com/hfawaz/InceptionTime/blob/master/results-mts.csv). \n --\u003e\n\nThe [results-inception-128.csv](https://github.com/hfawaz/InceptionTime/blob/master/results-inception-128.csv) file contains five individual runs of the Inception model over the 128 datasets from the UCR 2018 archive. \n\n### Critical difference diagrams\nIf you would like to generate such a diagram, take a look at [this code](https://github.com/hfawaz/cd-diagram)!\n\n![cd diagram](https://github.com/hfawaz/InceptionTime/blob/master/pngs/cd-diagram.png)\n\n### Training time plots\nThese plots were generated using the [matplotlib](https://matplotlib.org/) library. \n\nTraining time vs train size             |  Training time vs series length\n:-------------------------:|:-------------------------:\n![training time size](https://github.com/hfawaz/InceptionTime/blob/master/pngs/train-time-size.png) | ![training time length](https://github.com/hfawaz/InceptionTime/blob/master/pngs/train-time-length.png)\n\n### Receptive field\nThis plot was generated by issuing this command ```python3 receptive.py plot_results```.\n\n\nReceptive field effect             |  Depth effect\n:-------------------------:|:-------------------------:\n![receptive field](https://github.com/hfawaz/InceptionTime/blob/master/pngs/plot-receptive-field.png) | ![training time length](https://github.com/hfawaz/InceptionTime/blob/master/pngs/depth-vs-length.png)\n\n## Reference\n\nIf you re-use this work, please cite:\n\n```\n@article{IsmailFawaz2020inceptionTime,\n  Title                    = {InceptionTime: Finding AlexNet for Time Series Classification},\n  Author                   = {Ismail Fawaz, Hassan and Lucas, Benjamin and Forestier, Germain and Pelletier, Charlotte and Schmidt, Daniel F. and Weber, Jonathan and Webb, Geoffrey I. and Idoumghar, Lhassane and Muller, Pierre-Alain and Petitjean, François},\n  journal                  = {Data Mining and Knowledge Discovery},\n  Year                     = {2020}\n}\n```\n\n## Acknowledgement\n\nWe would like to thank the providers of the [UCR/UEA archive](http://timeseriesclassification.com/TSC.zip). \nWe would also like to thank NVIDIA Corporation for the Quadro P6000 grant and the Mésocentre of Strasbourg for providing access to the cluster.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhfawaz%2Finceptiontime","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhfawaz%2Finceptiontime","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhfawaz%2Finceptiontime/lists"}