sintel-dev / draco Goto Github PK
View Code? Open in Web Editor NEWState space and deep generative models for time series.
Home Page: https://sintel-dev.github.io/Draco
License: MIT License
State space and deep generative models for time series.
Home Page: https://sintel-dev.github.io/Draco
License: MIT License
Please provide documentation to explain to users how to write functions to create custom features. For example, a subject matter expert may anticipate that a particular feature will be a good predictor for a particular predictive task, and wants to be able to easily write a function to generate that feature and integrate it into a pipeline.
The default datetime format used by the CSVLoader has a typo and has been written as '%m/%d/%y %M:%H:%S'
instead of '%m/%d/%y %H:%M:%S'
.
While this is not fixed, the right format can be passed to the CSVLoader
using the datetime_fmt
argument:
loader = CSVLoader(..., datetime_fmt='%m/%d/%y %H:%M:%S')
Modify the CSVLoader
to check that values are float only when resampling is used.
Change the mlprimitives
dependency to ml-stars
, which is a slimmed down version of MLPrimitives
.
Draco will mainly focus on time series modeling using deep learning models alone.
This change will have the following effects:
dfs
based pipelines will be deprecated.mlprimitives
primitives will be switched with ml-stars
Files to be removed:
dfs_xgb
pipelinespreprocessing
pipelinestutorials/pipelines/dfs_xgb_with_unstack_normalization.ipynb
tutorials/pipelines/dfs_xgb_with_double_normalization.ipynb
We want to upgrade to the new version of BTB which implements BTBSession
.
This change will improve the following aspects of the current pipeline:
Reorganize pipelines from types to be named pipelines.
Original organization
draco/pipelines
├── classes
├── normalize_dfs_xgb_classifier.json
├── unstack_dfs_xgb_classifier.json
├── unstack_double_lstm_timeseries_classifier.json
├── unstack_lstm_timeseries_classifier.json
└── unstack_normalize_dfs_xgb_classifier.json
├── probability
├── normalize_dfs_xgb_classifier.json
├── unstack_dfs_xgb_classifier.json
├── unstack_double_lstm_timeseries_classifier.json
├── unstack_lstm_timeseries_classifier.json
└── unstack_normalize_dfs_xgb_classifier.json
├── unstacked
├── unstacked_dfs_xgb_classifier.json
├── unstacked_double_lstm_timeseries_classifier.json
├── unstacked_lstm_timeseries_classifier.json
└── unstacked_normalize_dfs_xgb_classifier.json
Proposed organization
draco/pipelines
├── dfs_xgb
├── dfs_xgb.json
├── dfs_xgb_with_unstack.json
├── dfs_xgb_with_double_normalization.json
└── dfs_xgb_with_unstack_normalization.json
├── lstm
├── lstm.json
└── lstm_with_unstack.json
├── double_lstm
├── double_lstm.json
└── double_lstm_with_unstack.json
In addition, for each pipeline, create a documentation page describing the pipeline.
The function greenguard.targets.select_valid_targets
is using strict inequality operators,
which can make GreenGuard drop target_times that would actually have exactly the needed
data.
The strict inequality operators <
should be changed to non strict ones <=
.
Review draco
dependencies and make adjustments for easier installation.
After upgrading mlprimitives
there are packages that we can leave into default, including:
pandas
numpy
With respect to storage, we can convert cloudpickle
to default python pickle
.
Change all references from turbine_id
to entity_id
to be more general.
Add a metric that gives the false positive rate for a given/fixed true positive rate for failures. This provides us a single metric to track.
After the new mlprimitives
version release, our pipelines that use the keras
adapters fails due to the new feature. the new feature in mlprimitives
tries to infer the shape of the input and the shape of the output.
There is a subtle problem in the pipeline where y
gets converted into an array of shape (.., )
and therefore we get the following error in the keras adapter.
ERROR mlblocks.mlpipeline:mlpipeline.py:662 Exception caught fitting MLBlock keras.Sequential.LSTMTimeSeriesClassifier#1
Traceback (most recent call last):
File "/home/runner/work/GreenGuard/GreenGuard/.tox/unit/lib/python3.6/site-packages/mlblocks/mlpipeline.py", line 644, in _fit_block
block.fit(**fit_args)
File "/home/runner/work/GreenGuard/GreenGuard/.tox/unit/lib/python3.6/site-packages/mlblocks/mlblock.py", line 311, in fit
getattr(self.instance, self.fit_method)(**fit_kwargs)
File "/home/runner/work/GreenGuard/GreenGuard/.tox/unit/lib/python3.6/site-packages/mlprimitives/adapters/keras.py", line 99, in fit
self._augment_hyperparameters(y, 'target', kwargs)
File "/home/runner/work/GreenGuard/GreenGuard/.tox/unit/lib/python3.6/site-packages/mlprimitives/adapters/keras.py", line 90, in _augment_hyperparameters
length = shape[0]
IndexError: tuple index out of range
ERROR greenguard.benchmark:benchmark.py:444 Could not score template probability.unstack_lstm_timeseries_classifier
Traceback (most recent call last):
File "/home/runner/work/GreenGuard/GreenGuard/greenguard/benchmark.py", line 436, in evaluate_templates
cache_path=cache_path
File "/home/runner/work/GreenGuard/GreenGuard/greenguard/benchmark.py", line 179, in evaluate_template
pipeline.fit(train, readings)
File "/home/runner/work/GreenGuard/GreenGuard/greenguard/pipeline.py", line 561, in fit
start_=start_, output_=output_, **kwargs)
File "/home/runner/work/GreenGuard/GreenGuard/.tox/unit/lib/python3.6/site-packages/mlblocks/mlpipeline.py", line 802, in fit
self._fit_block(block, block_name, context, debug_info)
File "/home/runner/work/GreenGuard/GreenGuard/.tox/unit/lib/python3.6/site-packages/mlblocks/mlpipeline.py", line 644, in _fit_block
block.fit(**fit_args)
File "/home/runner/work/GreenGuard/GreenGuard/.tox/unit/lib/python3.6/site-packages/mlblocks/mlblock.py", line 311, in fit
getattr(self.instance, self.fit_method)(**fit_kwargs)
File "/home/runner/work/GreenGuard/GreenGuard/.tox/unit/lib/python3.6/site-packages/mlprimitives/adapters/keras.py", line 99, in fit
self._augment_hyperparameters(y, 'target', kwargs)
File "/home/runner/work/GreenGuard/GreenGuard/.tox/unit/lib/python3.6/site-packages/mlprimitives/adapters/keras.py", line 90, in _augment_hyperparameters
length = shape[0]
IndexError: tuple index out of range
Inside the CSVLoader, the resampling happens after the data from all the files has been loaded into memory and filtered by signal and timestamp.
As a consequence of this:
The resampling process should happen inside the for filename in filenames
loop, right after filtering by timestamp and signal_id.
At this moment the current csv format is %Y-%M-.csv
and should be %Y-%M.csv
or : 2010-10-.csv
-> 2010-10.csv
Change the code were this is being used and update the demo generated data to be using the new format.
Remove dfs
based pipelines from the Draco
repository.
Draco will be restricted to space state models and support deep learning based pipelines such as LSTM.
MLBlocks has a feature that allows running only a subset of the pipeline and capturing intermediate results.
Since GreenGuard wraps around the MLBlocks pipeline, this functionality is not fully exposed.
We should add arguments to expose it in the fit
and predict
methods.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.