()
return cs
It builds the configuration space with the needed hyperparameters.
		It is easily possible to implement different types of hyperparameters.
		Beside float-hyperparameters on a log scale, it is also able to handle categorical input parameter.
		:return: ConfigurationsSpace-Object
It builds the configuration space with the needed hyperparameters.
		It is easily possible to implement different types of hyperparameters.
		Beside float-hyperparameters on a log scale, it is also able to handle categorical input parameter.
		:return: ConfigurationsSpace-Object
It builds the configuration space with the needed hyperparameters . It is easily possible to implement different types of hyperparameters . Beside float - hyperparameters on a log scale it is also able to handle categorical input parameter . : return : ConfigurationsSpace - Object
def get_configspace():
		"""
		It builds the configuration space with the needed hyperparameters.
		It is easily possible to implement different types of hyperparameters.
		Beside float-hyperparameters on a log scale, it is also able to handle categorical input parameter.
		:return: ConfigurationsSpace-Object
		"""
		cs = CS.ConfigurationSpace()

		lr = CSH.UniformFloatHyperparameter('lr', lower=1e-6, upper=1e-1, default_value='1e-2', log=True)

		# For demonstration purposes, we add different optimizers as categorical hyperparameters.
		# To show how to use conditional hyperparameters with ConfigSpace, we'll add the optimizers 'Adam' and 'SGD'.
		# SGD has a different parameter 'momentum'.
		optimizer = CSH.CategoricalHyperparameter('optimizer', ['Adam', 'SGD'])

		sgd_momentum = CSH.UniformFloatHyperparameter('sgd_momentum', lower=0.0, upper=0.99, default_value=0.9, log=False)

		cs.add_hyperparameters([lr, optimizer, sgd_momentum])



		num_conv_layers =  CSH.UniformIntegerHyperparameter('num_conv_layers', lower=1, upper=3, default_value=2)
		
		num_filters_1 = CSH.UniformIntegerHyperparameter('num_filters_1', lower=4, upper=64, default_value=16, log=True)
		num_filters_2 = CSH.UniformIntegerHyperparameter('num_filters_2', lower=4, upper=64, default_value=16, log=True)
		num_filters_3 = CSH.UniformIntegerHyperparameter('num_filters_3', lower=4, upper=64, default_value=16, log=True)

		cs.add_hyperparameters([num_conv_layers, num_filters_1, num_filters_2, num_filters_3])


		dropout_rate = CSH.UniformFloatHyperparameter('dropout_rate', lower=0.0, upper=0.9, default_value=0.5, log=False)
		num_fc_units = CSH.UniformIntegerHyperparameter('num_fc_units', lower=8, upper=256, default_value=32, log=True)

		cs.add_hyperparameters([dropout_rate, num_fc_units])


		# The hyperparameter sgd_momentum will be used,if the configuration
		# contains 'SGD' as optimizer.
		cond = CS.EqualsCondition(sgd_momentum, optimizer, 'SGD')
		cs.add_condition(cond)
		
		# You can also use inequality conditions:
		cond = CS.GreaterThanCondition(num_filters_2, num_conv_layers, 1)
		cs.add_condition(cond)

		cond = CS.GreaterThanCondition(num_filters_3, num_conv_layers, 2)
		cs.add_condition(cond)

		return cs
def get_configspace ( ) : cs = CS . ConfigurationSpace ( ) lr = CSH . UniformFloatHyperparameter ( 'lr' , lower = 1e-6 , upper = 1e-1 , default_value = '1e-2' , log = True ) # For demonstration purposes, we add different optimizers as categorical hyperparameters. # To show how to use conditional hyperparameters with ConfigSpace, we'll add the optimizers 'Adam' and 'SGD'. # SGD has a different parameter 'momentum'. optimizer = CSH . CategoricalHyperparameter ( 'optimizer' , [ 'Adam' , 'SGD' ] ) sgd_momentum = CSH . UniformFloatHyperparameter ( 'sgd_momentum' , lower = 0.0 , upper = 0.99 , default_value = 0.9 , log = False ) cs . add_hyperparameters ( [ lr , optimizer , sgd_momentum ] ) num_conv_layers = CSH . UniformIntegerHyperparameter ( 'num_conv_layers' , lower = 1 , upper = 3 , default_value = 2 ) num_filters_1 = CSH . UniformIntegerHyperparameter ( 'num_filters_1' , lower = 4 , upper = 64 , default_value = 16 , log = True ) num_filters_2 = CSH . UniformIntegerHyperparameter ( 'num_filters_2' , lower = 4 , upper = 64 , default_value = 16 , log = True ) num_filters_3 = CSH . UniformIntegerHyperparameter ( 'num_filters_3' , lower = 4 , upper = 64 , default_value = 16 , log = True ) cs . add_hyperparameters ( [ num_conv_layers , num_filters_1 , num_filters_2 , num_filters_3 ] ) dropout_rate = CSH . UniformFloatHyperparameter ( 'dropout_rate' , lower = 0.0 , upper = 0.9 , default_value = 0.5 , log = False ) num_fc_units = CSH . UniformIntegerHyperparameter ( 'num_fc_units' , lower = 8 , upper = 256 , default_value = 32 , log = True ) cs . add_hyperparameters ( [ dropout_rate , num_fc_units ] ) # The hyperparameter sgd_momentum will be used,if the configuration # contains 'SGD' as optimizer. cond = CS . EqualsCondition ( sgd_momentum , optimizer , 'SGD' ) cs . add_condition ( cond ) # You can also use inequality conditions: cond = CS . GreaterThanCondition ( num_filters_2 , num_conv_layers , 1 ) cs . add_condition ( cond ) cond = CS . GreaterThanCondition ( num_filters_3 , num_conv_layers , 2 ) cs . add_condition ( cond ) return cs