Last active
September 2, 2021 09:35
-
-
Save elisim/010234cbb2a34d8e1c44bb300c7a5a22 to your computer and use it in GitHub Desktop.
Hydra-Sklearn Blog - Code example 6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import hydra | |
from omegaconf import DictConfig | |
@hydra.main(config_path="configs/", config_name="config.yaml") | |
def main(config: DictConfig): | |
# instantiate our preprocessing pipeline to | |
# sklearn Pipeline object using hydra configuration | |
preprocessing_pipeline = hydra.utils.instantiate( | |
config.preprocessing_pipeline, _recursive_=False | |
) | |
if __name__ == "__main__": | |
main() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment