Add support to define Hyperparameters Tuning parameters dynamically using placeholders
Fixes #85
Why is the change necessary?
Currently, it is not possible to use placeholders for Sagemaker Hyperparameters Tuning properties. The properties cannot be defined dynamically, as they need to be defined in the HyperparameterTuner which does not accept placeholders.
This change makes it possible to use placeholders for HyperparameterTuner properties by using the parameters field that are passed down from the TuningStep.
Solution
Use the parameters field that is compatible with placeholders to define TuningStep properties.
Merge the parameters that were generated from the HyperparameterTuner with the input parameters:
The input parameters will overwrite the parameters generated from the HyperparameterTuner if the properties were defined in both
All TuningStep properties will be placeholder compatible except for data - which requires RecordSets as data depending on the estimator used to define the tuner.
Description
Add support to define Hyperparameters Tuning parameters dynamically using placeholders
Fixes #85
Why is the change necessary?
Currently, it is not possible to use placeholders for Sagemaker Hyperparameters Tuning properties. The properties cannot be defined dynamically, as they need to be defined in the HyperparameterTuner which does not accept placeholders. This change makes it possible to use placeholders for HyperparameterTuner properties by using the parameters field that are passed down from the TuningStep.
Solution
Use the
parameters
field that is compatible with placeholders to define TuningStep properties. Merge the parameters that were generated from the HyperparameterTuner with the input parameters:The input parameters will overwrite the parameters generated from the HyperparameterTuner if the properties were defined in both
All TuningStep properties will be placeholder compatible except for
data
- which requires RecordSets as data depending on the estimator used to define the tuner.The input parameters should follow the schema described in CreateHyperParameterTuningJob API doc
Same solution was adopted for feat: Support placeholders for processing step
Testing
Added unit and integration tests
Pull Request Checklist
Please check all boxes (including N/A items)
Testing
Documentation
Title and description
Fixes #xxx
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license.