Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 97940fb

Browse files
committed
Fix issue for code-blocks not rendering correctly on readthedocs + Minor updates
1 parent 5c2c986 commit 97940fb

File tree

4 files changed

+136
-138
lines changed

4 files changed

+136
-138
lines changed

‎docs/source/index.rst‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ The software tools which we shall use throughout this tutorial are listed in the
3232

3333
.. toctree::
3434
:maxdepth: 4
35-
:caption: Contents:
35+
:caption: Contents
3636

3737
install
3838
training

‎docs/source/install.rst‎

Lines changed: 9 additions & 126 deletions
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ Verify the installation
220220

221221
- Run the following command in a **NEW** `Terminal` window:
222222

223-
.. code-block:: posh
223+
.. code-block:: bash
224224
225225
python -c "import tensorflow as tf;print(tf.reduce_sum(tf.random.normal([1000, 1000])))"
226226
@@ -230,7 +230,7 @@ Verify the installation
230230

231231
- Once the above is run, you should see a print-out similar to the one bellow:
232232

233-
.. code-block:: posh
233+
.. code-block:: bash
234234
:emphasize-lines: 1,2,6,7,8,9,10,11,12,20,21,22,23,24,25,26,31
235235
236236
2020年06月22日 20:24:31.355541: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library cudart64_101.dll
@@ -311,7 +311,7 @@ This should be done as follows:
311311
- Add ``<PATH_TO_PB>`` to your ``Path`` environment variable (see :ref:`set_env`)
312312
- In a new `Terminal` [#]_, ``cd`` into ``TensorFlow/models/research/`` directory and run the following command:
313313

314-
.. code-block:: python
314+
.. code-block:: bash
315315
316316
# From within TensorFlow/models/research/
317317
protoc object_detection/protos/*.proto --python_out=.
@@ -324,15 +324,15 @@ This should be done as follows:
324324

325325
.. tab:: Windows Powershell
326326

327-
.. code-block::
327+
.. code-block::bash
328328
329329
# From within TensorFlow/models/research/
330330
Get-ChildItem object_detection/protos/*.proto | foreach {protoc "object_detection/protos/$($_.Name)" --python_out=.}
331331
332332
333333
.. tab:: Command Prompt
334334

335-
.. code-block::
335+
.. code-block::bash
336336
337337
# From within TensorFlow/models/research/
338338
for /f %i in ('dir /b object_detection\protos\*.proto') do protoc object_detection\protos\%i --python_out=.
@@ -386,7 +386,7 @@ Install the Object Detection API
386386
********************************
387387
Installation of the Object Detection API is achieved by installing the ``object_detection`` package. This is done by running the following commands from within ``Tensorflow\models\research``:
388388
389-
.. code-block::
389+
.. code-block:: bash
390390
391391
# From within TensorFlow/models/research/
392392
cp object_detection/packages/tf2/setup.py .
@@ -396,7 +396,7 @@ Installation of the Object Detection API is achieved by installing the ``object_
396396
397397
During the above installation, you may observe the following error:
398398
399-
.. code-block::
399+
.. code-block:: bash
400400
401401
ERROR: Command errored out with exit status 1:
402402
command: 'C:\Users\sglvladi\Anaconda3\envs\tf2\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\sglvladi\\AppData\\Local\\Temp\\pip-install-yn46ecei\\pycocotools\\setup.py'"'"'; __file__='"'"'C:\\Users\\sglvladi\\AppData\\Local\\Temp\\pip-install-yn46ecei\\pycocotools\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\sglvladi\AppData\Local\Temp\pip-record-wpn7b6qo\install-record.txt' --single-version-externally-managed --compile --install-headers 'C:\Users\sglvladi\Anaconda3\envs\tf2\Include\pycocotools'
@@ -429,15 +429,15 @@ Test your Installation
429429
430430
To test the installation, run the following command from within ``Tensorflow\models\research``:
431431
432-
.. code-block::
432+
.. code-block:: bash
433433
434434
# From within TensorFlow/models/research/
435435
python object_detection/builders/model_builder_tf2_test.py
436436
437437
Once the above is run, allow some time for the test to complete and once done you should observe a
438438
printout similar to the one below:
439439
440-
.. code-block::
440+
.. code-block:: bash
441441
442442
...
443443
[ OK ] ModelBuilderTF2Test.test_create_ssd_models_from_config
@@ -471,121 +471,4 @@ If you want to play around with some examples to see how this can be done, now w
471471
time to have a look at the :ref:`examples` section.
472472
473473
474-
.. _labelImg_install:
475-
476-
LabelImg Installation
477-
---------------------
478-
479-
There exist several ways to install ``labelImg``. Below are 3 of the most common.
480-
481-
Get from PyPI (Recommended)
482-
***************************
483-
1. Open a new `Terminal` window and activate the `tensorflow_gpu` environment (if you have not done so already)
484-
2. Run the following command to install ``labelImg``:
485-
486-
.. code-block:: bash
487-
488-
pip install labelImg
489-
490-
3. ``labelImg`` can then be run as follows:
491-
492-
.. code-block:: bash
493-
494-
labelImg
495-
# or
496-
labelImg [IMAGE_PATH] [PRE-DEFINED CLASS FILE]
497-
498-
Use precompiled binaries (Easy)
499-
*******************************
500-
Precompiled binaries for both Windows and Linux can be found `here <http://tzutalin.github.io/labelImg/>`_ .
501-
502-
Installation is the done in three simple steps:
503-
504-
1. Inside you ``TensorFlow`` folder, create a new directory, name it ``addons`` and then ``cd`` into it.
505-
506-
2. Download the latest binary for your OS from `here <http://tzutalin.github.io/labelImg/>`_. and extract its contents under ``Tensorflow/addons/labelImg``.
507-
508-
3. You should now have a single folder named ``addons/labelImg`` under your ``TensorFlow`` folder, which contains another 4 folders as such:
509-
510-
.. code-block:: bash
511-
512-
TensorFlow/
513-
├─ addons/
514-
│ └─ labelImg/
515-
└─ models/
516-
├─ community/
517-
├─ official/
518-
├─ orbit/
519-
├─ research/
520-
└─ ...
521-
522-
4. ``labelImg`` can then be run as follows:
523-
524-
.. code-block:: bash
525-
526-
# From within Tensorflow/addons/labelImg
527-
labelImg
528-
# or
529-
labelImg [IMAGE_PATH] [PRE-DEFINED CLASS FILE]
530-
531-
Build from source (Hard)
532-
************************
533-
The steps for installing from source follow below.
534-
535-
**1. Download labelImg**
536-
537-
- Inside you ``TensorFlow`` folder, create a new directory, name it ``addons`` and then ``cd`` into it.
538-
- To download the package you can either use `Git <https://git-scm.com/downloads>`_ to clone the `labelImg repo <https://github.com/tzutalin/labelImg>`_ inside the ``TensorFlow\addons`` folder, or you can simply download it as a `ZIP <https://github.com/tzutalin/labelImg/archive/master.zip>`_ and extract it's contents inside the ``TensorFlow\addons`` folder. To keep things consistent, in the latter case you will have to rename the extracted folder ``labelImg-master`` to ``labelImg``. [#]_
539-
- You should now have a single folder named ``addons\labelImg`` under your ``TensorFlow`` folder, which contains another 4 folders as such:
540-
541-
.. code-block:: bash
542-
543-
TensorFlow/
544-
├─ addons
545-
│ └─ labelImg/
546-
└─ models/
547-
├─ community/
548-
├─ official/
549-
├─ orbit/
550-
├─ research/
551-
└─ ...
552-
553-
.. [#] The latest repo commit when writing this tutorial is `8d1bd68 <https://github.com/tzutalin/labelImg/commit/8d1bd68ab66e8c311f2f45154729bba301a81f0b>`_.
554-
555-
**2. Install dependencies and compiling package**
556-
557-
- Open a new `Terminal` window and activate the `tensorflow_gpu` environment (if you have not done so already)
558-
- ``cd`` into ``TensorFlow/addons/labelImg`` and run the following commands:
559-
560-
.. tabs::
561-
562-
.. tab:: Windows
563-
564-
.. code-block:: bash
565-
566-
conda install pyqt=5
567-
pyrcc5 -o libs/resources.py resources.qrc
568-
569-
.. tab:: Linux
570-
571-
.. code-block:: bash
572-
573-
sudo apt-get install pyqt5-dev-tools
574-
sudo pip install -r requirements/requirements-linux-python3.txt
575-
make qt5py3
576-
577-
578-
**3. Test your installation**
579-
580-
- Open a new `Terminal` window and activate the `tensorflow_gpu` environment (if you have not done so already)
581-
- ``cd`` into ``TensorFlow/addons/labelImg`` and run the following command:
582-
583-
.. code-block:: posh
584-
585-
# From within Tensorflow/addons/labelImg
586-
python labelImg.py
587-
# or
588-
python labelImg.py [IMAGE_PATH] [PRE-DEFINED CLASS FILE]
589-
590-
591474

‎docs/source/issues.rst‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ It is possible that when executing ``from object_detection.utils import label_ma
6666
get the above error. As per the discussion is in `this Stack Overflow thread <https://stackoverflow.com/a/61961016/3474873>`_,
6767
upgrading the Python protobuf version seems to solve this issue:
6868
69-
.. code-block::
69+
.. code-block:: bash
7070
7171
pip install --upgrade protobuf
7272
@@ -77,7 +77,7 @@ upgrading the Python protobuf version seems to solve this issue:
7777
When trying to export oyu trained model using the ``exporter_main_v2.py`` script, you may come
7878
across an error that looks like this:
7979
80-
.. code-block::
80+
.. code-block:: bash
8181
:linenos:
8282
:emphasize-lines: 9
8383

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /