Exemplo n.º 1
0
 def get_op_model(self, op_info: OpInfo,
                  dataset: Collection[OpTrace], **kwargs) -> Optional[TrainableSerializableModel]:
     try:
         return resolve_operator(self.model_definitions, op_info)(self, op_info, dataset=dataset, **kwargs)
     except ValueError:
         #  None implies that no model is defined for this operator
         return None
Exemplo n.º 2
0
 def get_op_handler(self, op_info: OpInfo):
     return resolve_operator(self.known_ops, op_info)
Exemplo n.º 3
0
 def get_encoder(self, op_info: OpInfo):
     return resolve_operator(self.encoder_definitions, op_info)