Repository: Project-MONAI/MONAI

Issue:
Sphinx documentation warning
**Describe the bug**
A clear and concise description of what the bug is.

Two warnings produced:
```
Users/johnsonhj/.venv/build/src/monai/docs/source/index.rst:46: WARNING: toctree contains reference to nonexisting document 'modules'
lchecking consistency... /Users/johnsonhj/.venv/build/src/monai/docs/source/apidocs/modules.rst: WARNING: document isn't included in any toctree
done
preparing documents... done
assembling single document... highlights transforms losses networks metrics data engines handlers visualize utils done
writing... /Users/johnsonhj/.venv/build/src/monai/docs/source/index.rst:15: WARNING: Could not lex literal_block as "python". Highlighting skipped.
```

**To Reproduce**
```
cd docs
make singlehtml
````

**Expected behavior**
No warnings.

**Environment (please complete the following information):**
 - OS: OSX
 - Python: version 3.7
 - MONAI version: a3a450820a47f581bad5efb83f56496a8e755a41

**Additional context**
Having a mechanism for clean sphinx building will ease the development burden on future documentation additions.


Discussion:

Resolving patch:
diff --git a/docs/source/conf.py b/docs/source/conf.py
--- a/docs/source/conf.py
+++ b/docs/source/conf.py
@@ -59,7 +59,7 @@ def generate_apidocs(*args):
     print(f"output_path {output_path}")
     print(f"module_path {module_path}")
     subprocess.check_call(
-        [apidoc_command_path, "-f", "-e"]
+        [apidoc_command_path, "-e"]
         + ["-o", output_path]
         + [module_path]
         + [os.path.join(module_path, p) for p in exclude_patterns]
diff --git a/monai/data/dataset.py b/monai/data/dataset.py
--- a/monai/data/dataset.py
+++ b/monai/data/dataset.py
@@ -73,25 +73,24 @@ class PersistentDataset(Dataset):
              'extra': 123                 'extra': 456                 'extra': 789
          },                           },                           }]
 
-    For a composite transform like 
+    For a composite transform like
 
     .. code-block:: python
 
         [ LoadNiftid(keys=['image', 'label']),
           Orientationd(keys=['image', 'label'], axcodes='RAS'),
           ScaleIntensityRanged(keys=['image'], a_min=-57, a_max=164, b_min=0.0, b_max=1.0, clip=True),
-          RandCropByPosNegLabeld(keys=['image', 'label'], label_key='label', size=(96, 96, 96), 
+          RandCropByPosNegLabeld(keys=['image', 'label'], label_key='label', size=(96, 96, 96),
                                  pos=1, neg=1, num_samples=4, image_key='image', image_threshold=0),
           ToTensord(keys=['image', 'label'])]
 
-     Upon first use a filename based dataset will be processed by the transform for the
-     [LoadNiftid, Orientationd, ScaleIntensityRanged] and the resulting tensor written to
-     the `cache_dir` before applying the remainging random dependant transforms
-     [RandCropByPosNegLabeld, ToTensord] elements for use in the analysis.
-
-     Subsequent uses of a dataset directly read pre-processed results from `cache_dir`
-     followed by applying the random dependant parts of transform processing.
+    Upon first use a filename based dataset will be processed by the transform for the
+    [LoadNiftid, Orientationd, ScaleIntensityRanged] and the resulting tensor written to
+    the `cache_dir` before applying the remainging random dependant transforms
+    [RandCropByPosNegLabeld, ToTensord] elements for use in the analysis.
 
+    Subsequent uses of a dataset directly read pre-processed results from `cache_dir`
+    followed by applying the random dependant parts of transform processing.
     """
 
     def __init__(self, data, transform=None, cache_dir=None):


Test patch: