Skip to content

Commit

Permalink
docs: Updated folder hierarchy of doc source and nootbooks to rst file (
Browse files Browse the repository at this point in the history
mindee#862)

* backup

* structure

* fix notebooks add imgur to list
  • Loading branch information
felixdittrich92 authored Mar 18, 2022
1 parent 6552d1f commit 6903bce
Show file tree
Hide file tree
Showing 15 changed files with 64 additions and 35 deletions.
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 @@ -31,7 +31,7 @@ Main Features
:caption: Getting started
:hidden:

installing
getting_started/installing
notebooks


Expand Down Expand Up @@ -61,27 +61,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
File renamed without changes.
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 |
+--------------------------------------------------------------------------------------------------------+----------------------------------------------+---------------------------------------------------------------------------------------------------------------------+

0 comments on commit 6903bce

Please sign in to comment.