qos_steer Adapter#

#

class network_gym_client.envs.qos_steer.Adapter(config_json)[source]#

qos_steer environment adapter.

Parameters:

Adapter (network_gym_client.adapter.Adapter) – base class.

Initialize the adapter.

Parameters:

config_json (json) – the configuration file

Methods#

network_gym_client.envs.qos_steer.Adapter.get_observation(self, df)#

Prepare observation for qos_steer env.

This function should return the same number of features defined in the get_observation_space().

Parameters:

df (pd.DataFrame) – network stats measurement

Returns:

spaces – observation spaces

network_gym_client.envs.qos_steer.Adapter.get_reward(self, df)#

Prepare reward for qos_steer env.

Parameters:

df (pd.DataFrame]) – network stats measurement

Returns:

spaces – reward space

network_gym_client.envs.qos_steer.Adapter.get_policy(self, action)#

Prepare network policy for qos_steer env.

Parameters:

action (spaces) – action from RL agent

Returns:

json – network policy

Reward Methods#

network_gym_client.envs.qos_steer.Adapter.calculate_wifi_qos_user_num(self, qos_rate)#

Calculate the number of QoS users over Wi-Fi. Default reward function.

Parameters:

qos_rate (pandas.DataFrame) – qos data rate per user

Returns:

double – reward

Additional Methods#

network_gym_client.envs.qos_steer.Adapter.get_action_space(self)#

Get action space for qos_steer env.

Returns:

spaces – action spaces

network_gym_client.envs.qos_steer.Adapter.get_observation_space(self)#

Get observation space for qos_steer env.

Returns:

spaces – observation spaces