action_processor
action_processor
¶
Action processing module for episodic dataset.
Handles all action-related computations including: - Computing actions from observations - Orientation delta computation - Action denoising
ActionProcessor
¶
Computes actions from robot observations with denoising support.
Initialize action processor.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
action_space
|
ActionSpace
|
TaskSpace action space configuration (contains all action-related settings) |
required |
Source code in src/versatil/data/processing/action_processor.py
requires_denoising_setup
property
¶
Check if denoising is enabled but thresholds haven't been computed.
Returns:
| Type | Description |
|---|---|
bool
|
True if denoise_actions is enabled but thresholds haven't been computed yet. |
compute_denoising_threshold
¶
Compute denoising thresholds from observation deltas of proprioceptive positions.
Source code in src/versatil/data/processing/action_processor.py
compute_sample_actions
¶
Compute actions from a sampled sequence of the zarr replay buffer.
Precomputed actions are extracted directly from the buffer. On-the-fly actions are computed from current & next observations. Additionally, denoising is applied to on-the-fly actions if enabled.
Source code in src/versatil/data/processing/action_processor.py
log_movement_distribution
¶
Log movement (observation delta) distribution stats.
Source code in src/versatil/data/processing/action_processor.py
compute_action_on_the_fly
¶
Compute action from current and next observations.
Source code in src/versatil/data/processing/action_processor.py
compute_position_action_from_observation
staticmethod
¶
Compute position action from current and next positions.
Source code in src/versatil/data/processing/action_processor.py
compute_gripper_action_from_observation
staticmethod
¶
compute_gripper_action_from_observation(current_gripper, next_gripper, method=value, gripper_type=value)
Compute gripper action from current and next gripper states.
Source code in src/versatil/data/processing/action_processor.py
compute_orientation_action_from_observation
¶
compute_orientation_action_from_observation(current_orientation, next_orientation, method=value, representation=value)
Compute orientation action from current and next orientations.
Source code in src/versatil/data/processing/action_processor.py
apply_delta_denoising
¶
Apply denoising threshold to the magnitudes of delta movements between a quantity at time t and t+1.
Raises:
| Type | Description |
|---|---|
RuntimeError
|
If denoising thresholds haven't been computed. |
Source code in src/versatil/data/processing/action_processor.py
plot_action_magnitude_distribution
¶
Plot magnitude distributions of the actions before/after denoising.
Returns:
| Type | Description |
|---|---|
Figure | None
|
The matplotlib figure, or None if no data available. |