https://github.com/andreasgrv/mlconf
A config module with machine learning in mind
https://github.com/andreasgrv/mlconf
argparse config machine-learning reflection yaml
Last synced: 9 months ago
JSON representation
A config module with machine learning in mind
- Host: GitHub
- URL: https://github.com/andreasgrv/mlconf
- Owner: andreasgrv
- License: other
- Created: 2017-09-13T23:49:12.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2024-12-16T14:34:11.000Z (over 1 year ago)
- Last Synced: 2025-04-13T15:04:22.349Z (about 1 year ago)
- Topics: argparse, config, machine-learning, reflection, yaml
- Language: Python
- Homepage:
- Size: 37.1 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
## [](https://travis-ci.org/andreasgrv/mlconf) mlconf
Because in machine learning, sensible defaults don't last long. Especially when choosing hyperparameters:

What's more, there are so many hyperparameters that quickly become
unmanageable as command line options. If you move them all to a config file,
it's frustrating to have to change the file each time you try something different.
So why not enjoy the best of both worlds?
**Dynamic argparse arguments with sensible defaults from a yaml file
that can be modified on the fly from the command line.**
### mlconf in a nutshell
* Dynamically set a lot of sane defaults from a [YAML](http://yaml.org) file.
* Be able to override any number of the defaults from the command line.
* Make the returned object easily accessible using . notation.
* Allows for instantiation of classes with reflection using the $classname
and $module parameters at a later time by using the blueprint's *build()* command.
### Installation
>
pip install mlconf
### Example
For example usage see [my post](https://grv.unargmaxable.ai/posts/mlconf).
### Tests
Tests are run using tox. Versions of python tested are Python 3.6+
To run the tests, run the following:
>
git clone https://github.com/andreasgrv/mlconf
cd mlconf
pip install -r requirements.txt
pip install .
tox
### License
3 clause BSD, see LICENSE.txt file
### Credits
Image is a [neural styled](https://tenso.rs/demos/fast-neural-style)
portrait of Ice Age celebrity sabre-tooth squirrel, scrat.