replay_trajectory_classification.environments.get_track_interior#
- get_track_interior(position: ndarray, bins: int, fill_holes: bool = False, dilate: bool = False, bin_count_threshold: int = 0) ndarray[source]#
Infers the interior bins of the track given positions.
- Parameters:
position (np.ndarray, shape (n_time, n_position_dims))
bins (sequence or int, optional) –
The bin specification:
A sequence of arrays describing the bin edges along each dimension.
The number of bins for each dimension (nx, ny, … =bins)
The number of bins for all dimensions (nx=ny=…=bins).
fill_holes (bool, optional) – Fill any holes in the extracted track interior bins
dialate (bool, optional) – Inflate the extracted track interior bins
bin_count_threshold (int, optional) – Greater than this number of samples should be in the bin for it to be considered on the track.
- Returns:
is_track_interior – The interior bins of the track as inferred from position
- Return type:
np.ndarray, optional