CloseToGPSTrace

class CloseToGPSTrace<T> @JvmOverloads constructor(randomGenerator: RandomGenerator, environment: Environment<T, GeoPosition>, nodeCount: Int, variance: Double, from: Time = Time.ZERO, interval: Time = DoubleTime(1.0), val to: Time = Time.INFINITY, gpsFilePath: String, normalizerClass: String, normalizerArguments: Any) : AbstractCloseTo<T, GeoPosition>

This it.unibo.alchemist.model.Deployment displaces nodes in the proximity of a GPS trace. Given a time interval from some time to another, it creates a TraceLoader, then uses the points in the interval to generate the sources for a Gaussian bivariate function and uses its probability density to deploy. Higher variance spreads nodes farther away from the trace with higher probability.

Constructors

Link copied to clipboard
constructor(randomGenerator: RandomGenerator, environment: Environment<T, GeoPosition>, nodeCount: Int, variance: Double, from: Time = Time.ZERO, interval: Time = DoubleTime(1.0), to: Time = Time.INFINITY, gpsFilePath: String, normalizerClass: String, vararg normalizerArguments: Any)

Properties

Link copied to clipboard
val to: Time

Functions

Link copied to clipboard
open fun forEach(p0: Consumer<in GeoPosition>)
Link copied to clipboard
Link copied to clipboard
open operator override fun iterator(): MutableIterator<GeoPosition>
Link copied to clipboard
fun <R> Iterable<R>.randomElement(randomGenerator: RandomGenerator): R

Returns a random element of the Iterable using the provided randomGenerator.

Link copied to clipboard
fun <R> Iterable<R>.shuffled(randomGenerator: RandomGenerator): Iterable<R>

Fisher–Yates shuffle algorithm using a RandomGenerator. More information on Wikipedia.

Link copied to clipboard
Link copied to clipboard
override fun stream(): Stream<GeoPosition>