Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Updated folder hierarchy of doc source and nootbooks to rst file #862

Merged
merged 19 commits into from
Mar 18, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/source/contributing/code_of_conduct.md
1 change: 1 addition & 0 deletions docs/source/contributing/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,30 +37,38 @@ Install the last stable release of the package using `pip <https://pip.pypa.io/e

We strive towards reducing framework-specific dependencies to a minimum, but some necessary features are developed by third-parties for specific frameworks. To avoid missing some dependencies for a specific framework, you can install specific builds as follows:

.. code:: bash
.. tabs::

.. tab:: TensorFlow

.. code:: bash

pip install python-doctr[tensorflow]

.. tab:: PyTorch

# for TensorFlow
pip install "python-doctr[tf]"
# for PyTorch
pip install "python-doctr[torch]"
.. code:: bash

pip install python-doctr[pytorch]


Via Git
=======

Install the library in developper mode:

.. code:: bash
.. tabs::

git clone https://github.com/mindee/doctr.git
pip install -e doctr/.
.. tab:: TensorFlow

Again, for framework-specific builds:
.. code:: bash

.. code:: bash
git clone https://github.com/mindee/doctr.git
pip install -e doctr/.[tf]

.. tab:: PyTorch

.. code:: bash

git clone https://github.com/mindee/doctr.git
# for TensorFlow
pip install -e doctr/.[tf]
# for PyTorch
pip install -e doctr/.[torch]
git clone https://github.com/mindee/doctr.git
pip install -e doctr/.[torch]
26 changes: 18 additions & 8 deletions docs/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ Main Features
:caption: Getting started
:hidden:

installing
getting_started/installing
notebooks


Expand Down Expand Up @@ -60,27 +60,37 @@ Supported datasets
* SVHN from `"Reading Digits in Natural Images with Unsupervised Feature Learning" <http://ufldl.stanford.edu/housenumbers/nips2011_housenumbers.pdf>`_.
* IC03 from `ICDAR 2003 <http://www.iapr-tc11.org/mediawiki/index.php?title=ICDAR_2003_Robust_Reading_Competitions>`_.
* IC13 from `ICDAR 2013 <http://dagdata.cvc.uab.es/icdar2013competition/>`_.
* IMGUR5K from `"TextStyleBrush: Transfer of Text Aesthetics from a Single Example" <https://github.com/facebookresearch/IMGUR5K-Handwriting-Dataset>`_.


.. toctree::
:maxdepth: 2
:caption: Using docTR
:hidden:

using_models
using_model_export
using_doctr/using_models
using_doctr/using_model_export


.. toctree::
:maxdepth: 2
:caption: Package Reference
:hidden:

datasets
io
models
transforms
utils
modules/datasets
modules/io
modules/models
modules/transforms
modules/utils


.. toctree::
:maxdepth: 2
:caption: Contributing
:hidden:

contributing/code_of_conduct
contributing/contributing


.. toctree::
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
1 change: 0 additions & 1 deletion docs/source/notebooks.md

This file was deleted.

1 change: 1 addition & 0 deletions docs/source/notebooks.rst
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ The following architectures are currently supported:
* `db_mobilenet_v3_large <models.html#doctr.models.detection.db_mobilenet_v3_large>`_

We also provide 2 models working with any kind of rotated documents:

* `linknet_resnet18_rotation <models.html#doctr.models.detection.linknet_resnet18_rotation>`_
* `db_resnet50_rotation <models.html#doctr.models.detection.db_resnet50_rotation>`_

Expand Down Expand Up @@ -73,7 +74,7 @@ You can pass specific boolean arguments to the predictor:

For instance, this snippet will instantiates a detection predictor able to detect text on rotated documents while preserving the aspect ratio:

>>> from doctr.models import detection_predictor
>>> from doctr.models import detection_predictor
>>> predictor = detection_predictor('db_resnet50_rotation', pretrained=True, assume_straight_pages=False, preserve_aspect_ratio=True)

NB: for the moment, `db_resnet50_rotation` is pretrained in Pytorch only and `linknet_resnet18_rotation` in Tensorflow only.
Expand Down Expand Up @@ -360,4 +361,4 @@ For reference, here is a sample XML byte string output::
</p>
</div>
</body>
</html>
</html>
9 changes: 0 additions & 9 deletions notebooks/README.md

This file was deleted.

17 changes: 17 additions & 0 deletions notebooks/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
docTR Notebooks
===============

Here are some notebooks compiled for users to better leverage the library capabilities:

+--------------------------------------------------------------------------------------------------------+----------------------------------------------+---------------------------------------------------------------------------------------------------------------------+
| Notebook | Description | Colab |
+--------------------------------------------------------------------------------------------------------+----------------------------------------------+---------------------------------------------------------------------------------------------------------------------+
| `[Quicktour] <https://github.com/mindee/notebooks/blob/main/doctr/quicktour.ipynb>`_ | A presentation of the main features of docTR | .. image:: https://colab.research.google.com/assets/colab-badge.svg |
| | | :target: https://colab.research.google.com/github/mindee/notebooks/blob/main/doctr/quicktour.ipynb |
+--------------------------------------------------------------------------------------------------------+----------------------------------------------+---------------------------------------------------------------------------------------------------------------------+
| `[Export as PDF/A] <https://github.com/mindee/notebooks/blob/main/doctr/export_as_pdfa.ipynb>`_ | Produce searchable PDFs from docTR results | .. image:: https://colab.research.google.com/assets/colab-badge.svg |
| | | :target: https://colab.research.google.com/github/mindee/notebooks/blob/main/doctr/export_as_pdfa.ipynb |
+--------------------------------------------------------------------------------------------------------+----------------------------------------------+---------------------------------------------------------------------------------------------------------------------+
| `[Artefact detection] <https://github.com/mindee/notebooks/blob/main/doctr/artefact_detection.ipynb>`_ | Object detection for artefacts in documents | .. image:: https://colab.research.google.com/assets/colab-badge.svg |
| | | :target: https://colab.research.google.com/github/mindee/notebooks/blob/main/doctr/artefact_detection.ipynb |
+--------------------------------------------------------------------------------------------------------+----------------------------------------------+---------------------------------------------------------------------------------------------------------------------+