Skip to content

ProximitySortPlayerDataTrimAlg

Samuel Gomes edited this page Jul 4, 2024 · 4 revisions

ProximitySortPlayerDataTrimAlg

This class is a child of PlayerDataTrimAlg, which trims a list of states based on the age and proximity of the elements. The older states are discarded, and if there are close points they are also discarded to avoid redundancy and increase exploration. It also supports that the residue between two phases is discarded first (this is informed by the stateType in each PlayerState). GIMME can benefit from the latter when bootstrapping the system because simulated data needs to be discarded as real data is added.

Constructor and Attributes

Constructor

+ ProximitySortPlayerDataTrimAlg(maxNumModelElements: int, epsilon: decimal = 0.01, accStateResidue: bool =  False): void

Attributes

Name: expected type Default value Description
maxNumModelElements: int - The maximum number of states in the trimmed list.
epsilon: decimal 0.01 A limit to the distance considered to be close.
accStateResidue: bool False Informs the algorithm if it should consider stateType (see above).

Methods

+ considerStateResidue(accStateResidue: bool): void

Description

Sets the accStateResidue flag.

- proximitySort(elem: PlayerState): decimal

Description

Comparer to sort a list by proximity.

- creationTimeSort(elem: PlayerState): decimal

Description

Comparer to sort a list by age.

Overrides trimmedList(pastModelIncs: PlayerState[]): PlayerState[] (see PlayerDataTrimAlg).

Clone this wiki locally