ParameterRange: ParameterRange Class

ParameterRangeR Documentation

ParameterRange Class

Description

Base class for representing parameter ranges. This is used to define what hyperparameters to tune for an Amazon SageMaker hyperparameter tuning job and to verify hyperparameters for Marketplace Algorithms.

Public fields

.all_types

All types of child class

min_value

The minimum value for the range

max_value

The maximum value for the rang

scaling_type

The scale used for searching the range during tuning

Methods

Public methods


Method new()

Initialize a parameter range.

Usage
ParameterRange$new(
  min_value,
  max_value,
  scaling_type = c("Auto", "Linear", "Logarithmic", "ReverseLogarithmic")
)
Arguments
min_value

(float or int): The minimum value for the range.

max_value

(float or int): The maximum value for the range.

scaling_type

(str): The scale used for searching the range during tuning (default: 'Auto'). Valid values: 'Auto', 'Linear', Logarithmic' and 'ReverseLogarithmic'.


Method is_valid()

Determine if a value is valid within this ParameterRange.

Usage
ParameterRange$is_valid(value)
Arguments
value

(float or int): The value to be verified.

Returns

bool: True if valid, False otherwise.


Method cast_to_type()

cast value to numeric

Usage
ParameterRange$cast_to_type(value)
Arguments
value

The value to be verified.


Method as_tuning_range()

Represent the parameter range as a dicionary suitable for a request to create an Amazon SageMaker hyperparameter tuning job.

Usage
ParameterRange$as_tuning_range(name)
Arguments
name

(str): The name of the hyperparameter.

Returns

dict[str, str]: A dictionary that contains the name and values of the hyperparameter.


Method format()

format class

Usage
ParameterRange$format()

Method clone()

The objects of this class are cloneable with this method.

Usage
ParameterRange$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.


DyfanJones/sagemaker-r-mlcore documentation built on May 3, 2022, 10:08 a.m.