char_to_byte_map

Function char_to_byte_map 

Source
pub fn char_to_byte_map() -> &'static [i16; 324]
Expand description

The inverse of the GPT-2 bytes-to-unicode map.

char_to_byte_map()[codepoint] is the original byte, or -1 when no byte maps to that codepoint. The table has 324 entries, matching std::array<int, 324> in the C++ source verbatim.