# InterpreTS
InterpreTS is a Python library designed for extracting meaningful and interpretable features from time series data to support the creation of interpretable and explainable predictive models.
## Overview
With the growing importance of interpretability in machine learning and AI, InterpreTS focuses on creating feature representations that facilitate the development of interpretable and explainable predictive models.
## Key Features
- **Statistical Features**: Extract basic statistics like mean, standard deviation, minimum, and maximum values.
- **Frequency Features**: Calculate features in the frequency domain, such as Fourier Transform coefficients.
- **Relational Features**: Generate features describing relationships between different time series, such as correlation.
- **Parallel Computing Support**: Efficiently compute features with parallel processing.
- **Data Format Flexibility**: Easily convert and process data in `pandas.DataFrame` or `numpy.array` formats.
## Requirements
- Python 3.8 or above
- `pandas`
- `numpy`
- `statsmodels`
## Installation Guide
Follow these steps to install InterpreTS and its dependencies:
1. **Clone the Repository**
Clone the InterpreTS repository to your local machine:
```bash
git clone https://github.com/ruleminer/InterpreTS.git
cd InterpreTS
```
2. Install dependencies: Install the required packages listed in the `requirements.txt` file:
```python
pip install -r requirements.txt
```
3. Install InterpreTS: Run the following command to install InterpreTS:
```python
pip install interpreTS
```
## Verifying Installation
Once installed, you can verify the installation by running a simple feature extraction example:
```python
from interpreTS.core.feature_extractor import FeatureExtractor, Features
import pandas as pd
# Sample time series data
data = pd.DataFrame({'value': [1, 2, 3, 4, 5]})
extractor = FeatureExtractor(features=[Features.LENGTH, Features.MEAN, Features.VARIANCE])
features = extractor.extract_features(data)
print("Extracted Features:\n", features)
```
## Additional Usage Example with Time Series Data
You can also use InterpreTS with time-indexed data:
```python
from interpreTS.core.time_series_data import TimeSeriesData
from interpreTS.core.feature_extractor import FeatureExtractor, Features
import pandas as pd
# Time-indexed data
data_with_date = pd.Series(
[5, 3, 6, 2, 7, 4, 8, 3, 9, 1],
index=pd.date_range("2023-01-01", periods=10, freq="D")
)
ts_data = TimeSeriesData(data_with_date)
# Feature extraction
extractor = FeatureExtractor(features=[Features.LENGTH, Features.MEAN, Features.VARIANCE])
features = extractor.extract_features(ts_data.data)
print("\nExtracted Features from Time Series Data:\n", features)
```
## Documentation
Complete documentation is available on [GitHub Pages](https://ruleminer.github.io/InterpreTS/).
## Issues and Support
For any issues, please consult our [Issue Tracker](https://github.com/ruleminer/InterpreTS/issues) on GitHub.
Raw data
{
"_id": null,
"home_page": "https://github.com/ruleminer/InterpreTS",
"name": "InterpreTS",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": null,
"keywords": "time series feature extraction interpretability explainability machine learning",
"author": "['\u0141ukasz Wr\u00f3bel', 'S\u0142awomir Put', 'Martyna \u017bur', 'Martyna Kramarz', 'Jaros\u0142aw Strzelczyk', 'Weronika Wo\u0142owczyk', 'Piotr Krupi\u0144ski']",
"author_email": null,
"download_url": "https://files.pythonhosted.org/packages/4b/e6/7f04d6fd9ee8f84cc6100b8c53169419a177372b3b47270cb2c30e55a28c/interprets-0.3.0.tar.gz",
"platform": null,
"description": "# InterpreTS\r\n\r\nInterpreTS is a Python library designed for extracting meaningful and interpretable features from time series data to support the creation of interpretable and explainable predictive models.\r\n\r\n## Overview\r\nWith the growing importance of interpretability in machine learning and AI, InterpreTS focuses on creating feature representations that facilitate the development of interpretable and explainable predictive models.\r\n\r\n## Key Features\r\n- **Statistical Features**: Extract basic statistics like mean, standard deviation, minimum, and maximum values.\r\n- **Frequency Features**: Calculate features in the frequency domain, such as Fourier Transform coefficients.\r\n- **Relational Features**: Generate features describing relationships between different time series, such as correlation.\r\n- **Parallel Computing Support**: Efficiently compute features with parallel processing.\r\n- **Data Format Flexibility**: Easily convert and process data in `pandas.DataFrame` or `numpy.array` formats.\r\n\r\n## Requirements\r\n- Python 3.8 or above\r\n- `pandas`\r\n- `numpy`\r\n- `statsmodels`\r\n\r\n## Installation Guide\r\nFollow these steps to install InterpreTS and its dependencies:\r\n\r\n1. **Clone the Repository** \r\n Clone the InterpreTS repository to your local machine:\r\n \r\n```bash\r\ngit clone https://github.com/ruleminer/InterpreTS.git\r\ncd InterpreTS\r\n```\r\n\r\n2. Install dependencies: Install the required packages listed in the `requirements.txt` file:\r\n\r\n ```python\r\n pip install -r requirements.txt\r\n ```\r\n\r\n3. Install InterpreTS: Run the following command to install InterpreTS:\r\n\r\n ```python\r\n pip install interpreTS\r\n ```\r\n\r\n## Verifying Installation\r\nOnce installed, you can verify the installation by running a simple feature extraction example:\r\n\r\n ```python\r\n from interpreTS.core.feature_extractor import FeatureExtractor, Features\r\n import pandas as pd\r\n\r\n # Sample time series data\r\n data = pd.DataFrame({'value': [1, 2, 3, 4, 5]})\r\n extractor = FeatureExtractor(features=[Features.LENGTH, Features.MEAN, Features.VARIANCE])\r\n features = extractor.extract_features(data)\r\n print(\"Extracted Features:\\n\", features)\r\n ```\r\n\r\n## Additional Usage Example with Time Series Data\r\nYou can also use InterpreTS with time-indexed data:\r\n\r\n ```python\r\n\r\n from interpreTS.core.time_series_data import TimeSeriesData\r\n from interpreTS.core.feature_extractor import FeatureExtractor, Features\r\n import pandas as pd\r\n\r\n # Time-indexed data\r\n data_with_date = pd.Series(\r\n [5, 3, 6, 2, 7, 4, 8, 3, 9, 1],\r\n index=pd.date_range(\"2023-01-01\", periods=10, freq=\"D\")\r\n )\r\n ts_data = TimeSeriesData(data_with_date)\r\n\r\n # Feature extraction\r\n extractor = FeatureExtractor(features=[Features.LENGTH, Features.MEAN, Features.VARIANCE])\r\n features = extractor.extract_features(ts_data.data)\r\n print(\"\\nExtracted Features from Time Series Data:\\n\", features)\r\n ```\r\n\r\n## Documentation\r\n\r\nComplete documentation is available on [GitHub Pages](https://ruleminer.github.io/InterpreTS/).\r\n\r\n\r\n## Issues and Support\r\n\r\nFor any issues, please consult our [Issue Tracker](https://github.com/ruleminer/InterpreTS/issues) on GitHub.\r\n",
"bugtrack_url": null,
"license": null,
"summary": "Feature extraction from time series to support the creation of interpretable and explainable predictive models.",
"version": "0.3.0",
"project_urls": {
"Documentation": "https://github.com/ruleminer/InterpreTS/docs",
"Homepage": "https://github.com/ruleminer/InterpreTS",
"Source": "https://github.com/ruleminer/InterpreTS",
"Tracker": "https://github.com/ruleminer/InterpreTS/issues"
},
"split_keywords": [
"time",
"series",
"feature",
"extraction",
"interpretability",
"explainability",
"machine",
"learning"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "79fc3e2118236167c25f962b89ad4daa999a8e03473819f11cc56e79f5ce3706",
"md5": "f9bb44d0a4215c5cc00445da83379cee",
"sha256": "53ecd8f6a3562a6c8a5e52c1842259acd2a6fc89073ff06027dbee09eeb620b5"
},
"downloads": -1,
"filename": "InterpreTS-0.3.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "f9bb44d0a4215c5cc00445da83379cee",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8",
"size": 64239,
"upload_time": "2024-12-11T23:19:47",
"upload_time_iso_8601": "2024-12-11T23:19:47.648738Z",
"url": "https://files.pythonhosted.org/packages/79/fc/3e2118236167c25f962b89ad4daa999a8e03473819f11cc56e79f5ce3706/InterpreTS-0.3.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "4be67f04d6fd9ee8f84cc6100b8c53169419a177372b3b47270cb2c30e55a28c",
"md5": "bba303af2c885250d339740fdb76a179",
"sha256": "a3927de4ab69ac9259966c0538f34c0c5d5aca7edb0958feb8a6e96d6c7102cc"
},
"downloads": -1,
"filename": "interprets-0.3.0.tar.gz",
"has_sig": false,
"md5_digest": "bba303af2c885250d339740fdb76a179",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 33813,
"upload_time": "2024-12-11T23:19:50",
"upload_time_iso_8601": "2024-12-11T23:19:50.017720Z",
"url": "https://files.pythonhosted.org/packages/4b/e6/7f04d6fd9ee8f84cc6100b8c53169419a177372b3b47270cb2c30e55a28c/interprets-0.3.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-12-11 23:19:50",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "ruleminer",
"github_project": "InterpreTS",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [],
"lcname": "interprets"
}