forked from lukas-blecher/LaTeX-OCR
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
174403a
commit cac7f3a
Showing
10 changed files
with
170 additions
and
128 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
Installation | ||
============ | ||
|
||
Python package | ||
-------------- | ||
|
||
To run the model you need Python 3.7+ | ||
|
||
If you don't have PyTorch installed. Follow their instructions [here](https://pytorch.org/get-started/locally/). | ||
|
||
Install the package `pix2tex`: | ||
|
||
``` | ||
pip install pix2tex[gui] | ||
``` | ||
|
||
Model checkpoints will be downloaded automatically when first running the script. | ||
|
||
To install | ||
- with GUI dependencies use tag `[gui]`. | ||
- with training dependencies use tag `[train]`. | ||
- with api dependencies use tag `[api]`. | ||
- all dependencies use tag `[all]`. | ||
|
||
Docker | ||
------ | ||
|
||
The API can be used from a docker container, available on [DockerHub](https://hub.docker.com/r/lukasblecher/pix2tex) | ||
``` | ||
docker pull lukasblecher/pix2tex:api | ||
docker run -p 8502:8502 lukasblecher/pix2tex:api | ||
``` | ||
This starts the API which is available at port 8502. | ||
|
||
To use the [Streamlit](https://streamlit.io/) demo run instead | ||
``` | ||
docker run -it -p 8501:8501 --entrypoint python lukasblecher/pix2tex:api pix2tex/api/run.py | ||
``` | ||
and navigate to [http://localhost:8501/](http://localhost:8501/) |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,123 @@ | ||
pix2tex | ||
======= | ||
|
||
pix2tex.cli package | ||
------------------- | ||
|
||
.. automodule:: pix2tex.cli | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
|
||
pix2tex.gui package | ||
------------------- | ||
|
||
.. automodule:: pix2tex.gui | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
pix2tex.api package | ||
------------------- | ||
|
||
Submodules | ||
~~~~~~~~~~ | ||
|
||
pix2tex.api.app module | ||
~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
.. automodule:: pix2tex.api.app | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
|
||
pix2tex.api.streamlit module | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
.. automodule:: pix2tex.api.streamlit | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
pix2tex.dataset package | ||
----------------------- | ||
|
||
Submodules | ||
~~~~~~~~~~ | ||
|
||
pix2tex.dataset.arxiv module | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
.. automodule:: pix2tex.dataset.arxiv | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
pix2tex.dataset.dataset module | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
.. automodule:: pix2tex.dataset.dataset | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
pix2tex.dataset.demacro module | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
.. automodule:: pix2tex.dataset.demacro | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
pix2tex.dataset.extract\_latex module | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
.. automodule:: pix2tex.dataset.extract_latex | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
pix2tex.dataset.latex2png module | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
.. automodule:: pix2tex.dataset.latex2png | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
pix2tex.dataset.render module | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
.. automodule:: pix2tex.dataset.render | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
pix2tex.dataset.scraping module | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
.. automodule:: pix2tex.dataset.scraping | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
pix2tex.models package | ||
---------------------- | ||
|
||
.. automodule:: pix2tex.models | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: | ||
|
||
pix2tex.utils package | ||
--------------------- | ||
|
||
pix2tex.utils.utils module | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
.. automodule:: pix2tex.utils.utils | ||
:members: | ||
:no-undoc-members: | ||
:show-inheritance: |
This file was deleted.
Oops, something went wrong.