RAI.certificates

Submodules

RAI.certificates.certificate module

class RAI.certificates.certificate.Certificate[source]

Bases: object

Certificate Objects contain information about a particular certificate. Certificates are automatically loaded in by CertificateManagers and perform evaluation using metric data they are provided in combination with the certificate data loaded in.

evaluate(metrics, certs)[source]

From the certificate json file condition key is selected and based on that evalutions will happen

Parameters:
  • metrics – metrics data is provided based on that evaluation will happen

  • certs – certificate data is provided based on that evaluation will happen

Returns:

Returns the evaluation result based on the input data

load_from_json(json_file)[source]

opens the certificate json file and load all the information

Parameters:

json_file – json_file file path of the certificate json file is shared

Returns:

None

RAI.certificates.certificate_manager module

class RAI.certificates.certificate_manager.CertificateManager[source]

Bases: object

CertificateManager is a class automatically created by AISystems. This class loads a file containing information on which certificates to use, before creating associated Certificate Objects, as well as prompting their associated evaluations.

compute(metric_values)[source]

Accepts the metric values and returns the value as per the name of the certificate

Parameters:

metric_values(dict)

Returns:

metric results(list)

get_metadata() dict[source]

return the certificate metadata information

Parameters:

self – None

Returns:

metadata(dict)

load_custom_certificates(filename)[source]

Loads all certificates found in a custom filepath

Parameters:

filename – where we need to get the details

Returns:

None

load_stock_certificates()[source]

Loads all certificates found in the stock certificate file

Parameters:

self – None

Returns:

None