BpeTrainer implementation in Python

Hi there,

So I was perusing through the tokenizer library in order pick some knowledge about the nitty gritty of the BpeTrainer, although I was only able to find the rust implementation (github.com), after bit more of digging I came across the fact that the tokenizer library only offers bindings for other languages not any native implementations, so my question is, is there any good implementation of the BpeTrainer or similar functionality in python, which one can refer

Thanks in advance.