LocationClosestSelector Class

Defines a join of customer data with public data using the criteria of closest spherical distance.

Initialize with location granularity.

Inheritance
LocationClosestSelector

Constructor

LocationClosestSelector(_granularity: LocationClosestGranularity, enable_telemetry: bool = True)

Parameters

Name Description
_granularity
Required

A location granularity to use in the joining of data.

enable_telemetry

Indicates whether to enable telemetry.

default value: True

Remarks

The static method process(self, env, customer_data, public_data, aggregator, join_keys, debug) is used to join the data based on this selector where:

  • customer_data is an instance of azureml.opendatasets.accessories.location_data.LocationData

  • public_data is an instance of azureml.opendatasets.accessories.location_data.LocationData

  • aggregator is one of azureml.opendatasets.aggregators.aggregator.Aggregator

  • join_keys is a list of join key pairs

  • debug indicates whether to print debug logs.

This method returns a tuple of: altered customer data class instance, altered public data class instance, and a list of join key pairs.

Methods

process

Join customer data and public data using the specified aggregator.

process

Join customer data and public data using the specified aggregator.

process(env: SparkEnv | PandasEnv, customer_data: LocationData, public_data: LocationData, aggregator: Aggregator, join_keys: list, debug: bool)

Parameters

Name Description
env
Required

The runtime environment.

customer_data
Required

An instance of a LocationData derived class.

public_data
Required

An instance of a LocationData derived class.

aggregator
Required

An aggregator.

join_keys
Required

A list of join key pairs.

debug
Required

Indicates whether to print debug logs.

Returns

Type Description

A tuple of: altered customer data class instance, altered public data class instance, and a list of join key pairs.