Skip to content

Commit

Permalink
Added more Darts models (#38)
Browse files Browse the repository at this point in the history
* Split wrappers into their own files, added N-HiTS

* Clean up notebook and flake8 config

* Remove powerline

* Update gitpython for dependabot

* Update jinja2 for dependabot

* Started TCN

* Add random_state for NN darts models

* disable duplicate code checks for subclasses, __int__ needs to be written out like this

* Reorg

* More duplicate code

* Add TransformerModel

* Added TFT

* Added DLinear

* Fix dropped params

* Add type attribute to hyperparam defs

* linting

* Added NLinear

* Added TiDE

* kernel_size needs to be fixed

* No dropout for D- and N-Linear models

* TODO note

* poetry update

* update darts

* TODO note

* Hide make commands from terminal

* Start adding conditions for hyperparams

Fixed TCN kernel_size

Also switch to using a logger for messages

* Fixed TCN model

* Fix TiDE, fix bug where hyperparam value is not actually set

* Remove comment

* Update comment

* Added RNNModel

* Change print format

* Remove allowed_variable_hyperparams from __str__, it is too long to be useful

* Add comment on model types

* Added BlockRNN

* Fix RNN

* Update missing data log message

* Clean up notebook

* Fix url

* Fix text
  • Loading branch information
mepland authored Jan 20, 2024
1 parent ee4e329 commit 9a78906
Show file tree
Hide file tree
Showing 18 changed files with 2,564 additions and 1,039 deletions.
56 changes: 28 additions & 28 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,60 +2,60 @@

.PHONY: setupDAQ
setupDAQ:
poetry install --with daq,web,dev --no-root
poetry run pre-commit install
@poetry install --with daq,web,dev --no-root
@poetry run pre-commit install

.PHONY: setupANA
setupANA:
poetry install --with ana,dev --no-root
poetry run pre-commit install
@poetry install --with ana,dev --no-root
@poetry run pre-commit install

.PHONY: poetry
poetry:
poetry check
poetry lock
@poetry check
@poetry lock

.PHONY: pre-commit
pre-commit:
poetry run pre-commit run --all-files
@poetry run pre-commit run --all-files

.PHONY: pre-commit-this-commit
pre-commit-this-commit:
poetry run pre-commit run
@poetry run pre-commit run

.PHONY: pre-commit-update
pre-commit-update:
poetry run pre-commit autoupdate
@poetry run pre-commit autoupdate

.PHONY: isort
isort:
poetry run isort .
@poetry run isort .

.PHONY: black
black:
poetry run black .
poetry run blacken-docs --line-length=100 $(shell git ls-files '*.py') $(shell git ls-files '*.md') $(shell git ls-files '*.rst')
@poetry run black .
@poetry run blacken-docs --line-length=100 $(shell git ls-files '*.py') $(shell git ls-files '*.md') $(shell git ls-files '*.rst')

.PHONY: flake8
flake8:
poetry run flake8
@poetry run flake8

.PHONY: mypy
mypy:
poetry run mypy .
@poetry run mypy .

# https://stackoverflow.com/a/63044665
.PHONY: pylint
pylint:
poetry run pylint $(shell git ls-files '*.py')
@poetry run pylint $(shell git ls-files '*.py')

.PHONY: bandit
bandit:
poetry run bandit -q -r .
@poetry run bandit -q -r .

.PHONY: vulture
vulture:
poetry run vulture
@poetry run vulture

# Note: Returns an error signal, but .dev_config/.vulture_ignore.py is built fine
.PHONY: vulture-update_ignore
Expand All @@ -67,48 +67,48 @@ vulture-update_ignore:

.PHONY: pyupgrade
pyupgrade:
poetry run pyupgrade $(shell git ls-files '*.py')
@poetry run pyupgrade $(shell git ls-files '*.py')

.PHONY: detect-secrets
detect-secrets:
poetry run detect-secrets-hook --exclude-lines 'integrity='
@poetry run detect-secrets-hook --exclude-lines 'integrity='

.PHONY: yamllint
yamllint:
poetry run yamllint -c .dev_config/.yamllint.yaml --strict .
@poetry run yamllint -c .dev_config/.yamllint.yaml --strict .

# Renamed to bklint so "make bl" autocompletes to "make black"
.PHONY: bklint
bklint:
poetry run blocklint --skip-files=poetry.lock --max-issue-threshold=1
@poetry run blocklint --skip-files=poetry.lock --max-issue-threshold=1

.PHONY: markdownlint
markdownlint:
markdownlint --config .dev_config/.markdownlint.yaml --ignore LICENSE.md --dot --fix .
@markdownlint --config .dev_config/.markdownlint.yaml --ignore LICENSE.md --dot --fix .

.PHONY: standard
standard:
standard --fix
@standard --fix

.PHONY: html5validator
html5validator:
html5validator --config .dev_config/.html5validator.yaml
@html5validator --config .dev_config/.html5validator.yaml

.PHONY: fmt_prettier
fmt_prettier:
prettier --ignore-path .dev_config/.prettierignore --ignore-path .gitignore --config .dev_config/.prettierrc.yaml --write .
@prettier --ignore-path .dev_config/.prettierignore --ignore-path .gitignore --config .dev_config/.prettierrc.yaml --write .

.PHONY: checkmake
checkmake:
pre-commit run checkmake --all-files
@pre-commit run checkmake --all-files

.PHONY: shellcheck
shellcheck:
shellcheck $(shell git ls-files | grep -vE '.*\..*' | grep -v 'Makefile')
@shellcheck $(shell git ls-files | grep -vE '.*\..*' | grep -v 'Makefile')

.PHONY: shfmt
shfmt:
shfmt -bn -ci -sr -s -w $(shell git ls-files | grep -vE '.*\..*' | grep -v 'Makefile')
@shfmt -bn -ci -sr -s -w $(shell git ls-files | grep -vE '.*\..*' | grep -v 'Makefile')

# isort ~ isort:
# flake8 ~ noqa
Expand Down
Loading

0 comments on commit 9a78906

Please sign in to comment.