model_card_toolkit.BaseModelCardField

Model card field base class.

This is an abstract class. All the model card fields should inherit this class and override the _proto_type property to the corresponding proto type. This abstract class provides methods copy_from_proto, merge_from_proto and to_proto to convert the class from and to proto. The child class does not need to override this unless it needs some special process.

Methods

clear

View source

Clear the subfields of this BaseModelCardField.

copy_from_proto

View source

Copies the contents of the model card proto into current object.

merge_from_proto

View source

Merges the contents of the model card proto into current object.

to_dict

View source

Convert your model card to a python dictionary.

to_json

View source

Convert this class object to json.

to_proto

View source

Convert this class object to the proto.