diff --git a/kraken/lib/vgsl.py b/kraken/lib/vgsl.py index 19238214b..ab95af783 100644 --- a/kraken/lib/vgsl.py +++ b/kraken/lib/vgsl.py @@ -414,7 +414,7 @@ def _serialize_layer(net, input, net_builder): mlmodel.user_defined_metadata['vgsl'] = '[' + ' '.join(self.named_spec) + ']' if self.codec: mlmodel.user_defined_metadata['codec'] = json.dumps({'type': 'SentencePiece', - 'spp': base64.b64encode(self.codec.spp.serialized_model_proto())}) + 'spp': str(base64.b64encode(self.codec.spp.serialized_model_proto()))}) if self.user_metadata: mlmodel.user_defined_metadata['kraken_meta'] = json.dumps(self.user_metadata) if self.aux_layers: