Repository: ARM-DOE/pyart (language: python)

Issue:
Determine Better Method of Dealing with Test Data
Currently, the data are hosted on an ANL server, requiring users to download the data manually, move the data to the necessary directories, then build the docs. It would be useful to use a tool such as [Pooch](https://www.fatiando.org/pooch/latest/index.html) to help with this process, making it possible to build the example docs on Github Actions instead of running locally, then adding that to the docs.


Discussion / hints:
For now, I created a demo repo [here](https://github.com/mgrover1/pyart-data-demo) to test this out - once it is ready, Ill submit a PR
Alrighty... [the prototype](https://github.com/mgrover1/pyart-data-demo) works 👍 with the syntax:

```python
import pyart
from pyart_datasets import get_test_data

radar = pyart.io.read_mdv(get_test_data('110635.mdv'))
```

This will make building the docs _much_ easier, especially the example gallery.

One of the remaining questions is whether this should be its own package (ex. `pyart_datasets`) or a module within PyART... 

@scollis @AdamTheisen @rcjackson @zssherman what are your thoughts here?

@mgrover1 Sweet, I think this will be much better. Think jjhelmus link is going to be removed. We're going to use https://adc.arm.gov/pyart/example_data/ instead, as a heads up. I think for the actually code itself is pooch a python native package or does it have to be installed as a dependency? Trying to think if it's the later how to go about that to avoid increasing the dependency count.
@zssherman Sounds good! 

Pooch **does** need to installed as a dependency, but this is where we could think about whether we want this to be a _module_ within PyART, or create a separate package... I put some pros/cons to these approaches in [this afternoon's meeting notes](https://hackmd.io/eXMjluMdRMOEscaleNWYmQ)
Just wanted to add that Pooch is pure Python and has been pretty stable. MetPy has had 0 problems depending on it.
@dopplershift Sweet sounds good! Yeah then I'm all for it being added. We can discuss more on the call today, but I have an idea of where to put it within pyart @mgrover1 

Fix patch:
diff --git a/appveyor.yml b/appveyor.yml
index e6f1ba9af3..2893ede726 100644
--- a/appveyor.yml
+++ b/appveyor.yml
@@ -31,7 +31,7 @@ install:
   - cmd: conda config --add channels conda-forge
 
   # Install Py-ART dependecies
-  - cmd: conda create -y -q -n matrix_env python=%PYTHON_VERSON% numpy scipy matplotlib netcdf4 pytest pytest-cov cython cartopy xarray
+  - cmd: conda create -y -q -n matrix_env python=%PYTHON_VERSON% numpy scipy matplotlib netcdf4 pytest pytest-cov cython cartopy xarray pooch
   - cmd: activate matrix_env
 
   # Check that we have the expected version and architecture for Python
diff --git a/doc/environment.yml b/doc/environment.yml
index 48f48bfea3..e984ab3e95 100644
--- a/doc/environment.yml
+++ b/doc/environment.yml
@@ -26,4 +26,5 @@ dependencies:
       - sphinx_rtd_theme
       - sphinx_gallery
       - sphinx-copybutton
-      - nbsphinx
\ No newline at end of file
+      - nbsphinx
+      - pooch
\ No newline at end of file


Test patch:
diff --git a/pyart/testing/__init__.py b/pyart/testing/__init__.py
index 73236cf455..6d58bd906a 100644
--- a/pyart/testing/__init__.py
+++ b/pyart/testing/__init__.py
@@ -24,5 +24,6 @@
 from. sample_objects import make_target_spectra_radar
 from .tmpdirs import InTemporaryDirectory
 from .sample_objects import make_normal_storm
+from .example_data import get_test_data
 
 __all__ = [s for s in dir() if not s.startswith('_')]
diff --git a/pyart/testing/example_data.py b/pyart/testing/example_data.py
new file mode 100644
index 0000000000..db4bf183a2
--- /dev/null
+++ b/pyart/testing/example_data.py
@@ -0,0 +1,43 @@
+import pkg_resources
+import pooch
+
+DATASETS = pooch.create(
+    path=pooch.os_cache('pyart-datasets'),
+    base_url='https://adc.arm.gov/pyart/example_data/',
+    env='PYART_DATASETS_DIR',
+)
+
+
+with pkg_resources.resource_stream('pyart.testing', 'registry.txt') as registry_file:
+    DATASETS.load_registry(registry_file)
+
+
+def locate():
+    """The absolute path to the sample data storage location on disk.
+    This is where the data are saved on your computer. The location is
+    dependent on the operating system. The folder locations are defined by the
+    ``appdirs``  package (see the `appdirs documentation
+    <https://github.com/ActiveState/appdirs>`__).
+    The location can be overwritten by the ``PYTHIA_DATASETS_DIR`` environment
+    variable to the desired destination.
+    Returns
+    -------
+    path : str
+        The local data storage location.
+    """
+    return str(DATASETS.abspath)
+
+
+def get_test_data(file):
+    """
+    Accesses the desired test data storage
+    Parameters
+    ----------
+    file = str
+        The name of the desired file
+    Returns
+    -------
+    path_to_file = str
+        Local path to the desired file
+    """
+    return DATASETS.fetch(file)
\ No newline at end of file
diff --git a/pyart/testing/registry.txt b/pyart/testing/registry.txt
new file mode 100644
index 0000000000..91c5554d39
--- /dev/null
+++ b/pyart/testing/registry.txt
@@ -0,0 +1,20 @@
+034142.mdv a6b9c25ce6c4122b087464e528c4c0b9d86ca5da3c786fa155e1d14e153c29d8
+095636.mdv f6785fb0f781fab4e7469204f50d26e921cfcb085d8df1624d3cb0ed92b8739e
+110041.mdv edcc255e02edc3aff7fa0f02306c4092a383dac7c7df9b1b9d47b9427be53b9c
+110635.mdv f9412e55ec63df1ff8e8a81ab5e076d29016de754e6d1dd450d34705667cb578
+20110520100000_nex_3d.nc cc3a3acdcb767c97e71a950bdfe1e36ad56d5671878ca7bab27ba762f099b52a
+20110520100000_nexrad_grid.nc 539d1cd0bce5d34c97a6e7cce489e073d6e649df3ee22e1c13d07ca37c6bd15d
+220629.mdv c4ac8f6a83f5b5f0b9e8c49ecd28933a9003c5d6332734451c663ebb01497d9b
+KATX20130717_195021_V06 10824fb0b296ae27035ee848bfc17d3c5ad53a116bd4667f09a9c5cd28f1c5a3
+Level2_KATX_20130717_1950.ar2v 57dcfebd79d25e042a498a6dd3f79c15634442910918ce16796408be8dbe8a1b
+XSW110520105408.RAW7HHF 93e230fffaea00dd098c89d68838f71831b8084b8928919f9f993e59f162ba55
+XSW110520113537.RAW7HHL 46efb5f8f7fc239bf40853387abff875628cb7f97d930aa743f5ebd759b23935
+narr-a_221_20110520_0000_000.nc 027fdc3bfd81f88a6d5108139a798851e78a083c499abfcf85051363e7506940
+nsaxsaprppiC1.a1.20140201.184802.nc 7063636743689eb1ff3fd6e4f2e19edf688ff85f5dc36304c1b1e1afd2477f37
+preprocessed.nc 11344439b55cc5ca13dc725392bf26f8b940214c49284794030a315b7d192da6
+pvcwsacrhsrhiM1.b1.20121105.201200_modified.nc d1cae366d6e4a7af6e90a35747faef50f5cbc33fd5dc205dca1b185b61883b49
+sex_20120520_0641.nc 96e6eb3b0b46dbdd2465b7ab633cfa96365d28f0e72f1e733dcef0a4f7fb7482
+sgpcsaprsurcmacI7.c0.20110520.095101.nc 15bddc066fcdbfc31fc0749e212c2200ecf0740c89b6b4001660cba332ba190a
+sgpinterpolatedsondeC1.c1.20110510.000000.cdf a3cd8c5c70c1b72abc23b323d74e6cf4b7f1dc25fa2e9aaf565798b2523783fd
+sgpxsaprrhicmacI5.c0.20110524.015604_NC4.nc da904e2363d7c15f4bf1ed511fa8acbbd41dde36fe4e9565b12c39028184e58a
+swx_20120520_0641.nc 83c7c0df0d398d297a00328ee45423736864e89db8d7abb255cfd25bd33f6386
\ No newline at end of file
diff --git a/pyart/testing/tests/test_example_datasets.py b/pyart/testing/tests/test_example_datasets.py
new file mode 100644
index 0000000000..bfa92ba4e2
--- /dev/null
+++ b/pyart/testing/tests/test_example_datasets.py
@@ -0,0 +1,21 @@
+import pathlib
+
+from pyart.testing.example_data import DATASETS, locate, get_test_data
+
+
+def test_registry():
+    files = DATASETS.registry_files
+    assert len(files) > 0
+
+
+def test_locate():
+    p = locate()
+    print(p)
+    assert 'datasets' in p
+    assert pathlib.Path(p).exists
+
+
+def test_get_test_data():
+    test_file = '034142.mdv'
+    file_path = get_test_data(test_file)
+    assert pathlib.Path(file_path).exists