tfx.components.trainer.rewriting.rewriter.BaseRewriter

View source on GitHub

Base class from which all rewriters should inherit.

name Name of the rewriter.

Should not be None nor empty.

Methods

perform_rewrite

View source

Invoke all validations and perform the rewrite.

Args
original_model A base_rewriter.ModelDescription object describing the original model.
rewritten_model A base_rewriter.ModelDescription object describing the location and type of the rewritten model.

Raises
ValueError if the model was not successfully rewritten.