graphenv.examples.hallway.hallway_model.BaseHallwayModel

class BaseHallwayModel(*args, hidden_dim=1, **kwargs)[source]

Bases: graphenv.graph_model.GraphModel

An example GraphModel implementation for the HallwayEnv and HallwayState Graph. Uses a dense fully connected Keras network.

Parameters

hidden_dim (int, optional) – The number of hidden layers to use. Defaults to 1.

Methods

forward

Tensorflow/Keras style forward method.

forward_vertex

Forward function computing the evaluation of vertex observations.

value_function

returns

A tensor of current state values.

forward_vertex(input_dict)[source]

Forward function computing the evaluation of vertex observations.

Parameters

input_dict (TensorStructType) – vertex observations

Returns

Tensor of value and weights for each

input observation.

Return type

Tuple[TensorType, TensorType]