MCPcopy Create free account
hub / github.com/FLC777/GLAT / encode

Method encode

fairseq/hub_utils.py:278–279  ·  view source on GitHub ↗
(self, sentence: str)

Source from the content-addressed store, hash-verified

276 assert self.bpe is not None
277
278 def encode(self, sentence: str) -> str:
279 return self.bpe.encode(sentence)
280
281 def decode(self, sentence: str) -> str:
282 return self.bpe.decode(sentence)

Callers 5

encode_fnFunction · 0.45
url_to_filenameFunction · 0.45
tokenizeMethod · 0.45
apply_bpeMethod · 0.45
encodeMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected