View source on GitHub
|
Abstract base class for representing constraints.
tf_agents.bandits.policies.constraints.BaseConstraint(
time_step_spec: tf_agents.typing.types.TimeStep,
action_spec: tf_agents.typing.types.BoundedTensorSpec,
name: Optional[Text] = None
)
The constraint class provides feasibility computation functionality for computing the probability of actions being feasible.
Args | |
|---|---|
time_step_spec
|
A TimeStep spec of the expected time_steps.
|
action_spec
|
A nest of BoundedTensorSpec representing the actions.
|
name
|
Python str name of this constraint. |
Methods
__call__
@abc.abstractmethod__call__( observation:tf_agents.typing.types.NestedTensor, actions: Optional[types.Tensor] = None ) ->tf_agents.typing.types.Tensor
Returns the probability of input actions being feasible.
View source on GitHub