A library to generate LaTeX expression from Python code.
A library to generate LaTeX expression from Python code.
latexify is a Python package to compile a fragment of Python source code to a
corresponding $\LaTeX$ expression:
latexify provides the following functionalities:
Which Python versions are supported?
Syntaxes on Pythons 3.9 to 3.13 are officially supported, or will be supported.
Which technique is used?
latexify is implemented as a rule-based system on the official ast package.
Are "AI" techniques adopted?
latexify is based on traditional parsing techniques.
If the "AI" meant some techniques around machine learning, the answer is no.
See the example notebook, which provides several use-cases of this library.
You can also try the above notebook on Google Colaboratory.
See also the official documentation for more details.
To contribute to this project, please refer CONTRIBUTING.md.
This software is currently hosted on https://github.com/google, but not officially supported by Google.
If you have any issues and/or questions about this software, please visit the issue tracker or contact the main maintainer.
This software adopts the Apache License 2.0.
Add ability to generate latex from string that has the function definition
Escaping underscores can't be turned off
Support greek lambda character
math.pow not working properly on google colab
Be able to directly specify final latex representation of identifiers
Expand support to torch
OSS-Fuzz Integration
LatexifyNotSupportedError: Unsupported AST: Slice | tensorflow
Automatically detecting imported libraries
Expand support for Numpy NDArray functions