rail.interactive.estimation.algos.equal_count module

rail.interactive.estimation.algos.equal_count.equal_count_classifier(**kwargs)

Classifier that simply assign tomographic bins based on point estimate according to SRD

The main run method for the classifier, should be implemented in the specific subclass.

This will attach the input_data to this PZClassifier (for introspection and provenance tracking).

Then it will call the run() and finalize() methods, which need to be implemented by the sub-classes.

The run() method will need to register the data that it creates to this Classifier by using self.add_data(‘output’, output_data).

The run() method relies on the _process_chunk() method, which should be implemented by subclasses to perform the actual classification on each chunk of data. The results from each chunk are then combined in the _finalize_run() method. (Alternatively, override run() in a subclass to perform the classification without parallelization.)

Finally, this will return a TableHandle providing access to that output data.

This function was generated from the function rail.estimation.algos.equal_count.EqualCountClassifier.classify

Parameters:
  • input_data (qp.Ensemble, required) – Per-galaxy p(z), and any ancilary data associated with it

  • chunk_size (int, optional) – Number of objects per chunk for parallel processing or to evalute per loop in single node processing Default: 10000

  • object_id_col (str, optional) – name of object id column Default:

  • point_estimate_key (str, optional) – Which point estimate to use Default: zmode

  • zmin (float, optional) – The minimum redshift of the z grid or sample Default: 0.0

  • zmax (float, optional) – The maximum redshift of the z grid or sample Default: 3.0

  • n_tom_bins (int, optional) – Number of tomographic bins Default: 5

  • no_assign (int, optional) – Value for no assignment flag Default: -99

Returns:

Class assignment for each galaxy, typically in the form of a dictionary with IDs and class labels.

Return type:

A tablesio-compatible table