patches/ppml: small optimisations.
Kazuhiko Shiozaki authored
* stop using deprecated string functions.
* reduce lambda creation inside functions.
* move import statements outside of function.
a65d8425