Skip to content

Commit

Permalink
Merge branch 'main' of github.com:ARM-DOE/ACT into plot_v2
Browse files Browse the repository at this point in the history
  • Loading branch information
zssherman committed Nov 30, 2023
2 parents 928ce2d + edc3fe9 commit 2b83f4b
Show file tree
Hide file tree
Showing 105 changed files with 1,769 additions and 2,257 deletions.
1 change: 0 additions & 1 deletion .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,3 @@ omit =
act/*version*py
versioneer.py
setup.py

4 changes: 2 additions & 2 deletions .github/workflows/python-package-conda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11"]
python-version: ["3.9", "3.10", "3.11", "3.12"]
os: [macOS, ubuntu, Windows]
inlcude:
- os: macos-latest
Expand All @@ -43,7 +43,7 @@ jobs:
- name: Setup Conda Environment
uses: mamba-org/setup-micromamba@v1
with:
python-version: ${{ matrix.python-version }}
create-args: python=${{ matrix.python-version }}
environment-file: ./continuous_integration/environment_actions.yml
environment-name: act_env

Expand Down
16 changes: 14 additions & 2 deletions CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ An example:

.. code-block:: python
def read_netcdf(filenames, variables=None):
def read_arm_netcdf(filenames, variables=None):
"""
Returns `xarray.Dataset` with stored data and metadata from a
Expand Down Expand Up @@ -226,7 +226,7 @@ An example:
import act
the_ds, the_flag = act.io.armfiles.read_netcdf(
the_ds, the_flag = act.io.arm.read_arm_netcdf(
act.tests.sample_files.EXAMPLE_SONDE_WILDCARD)
print(the_ds.act.datastream)
"""
Expand Down Expand Up @@ -278,6 +278,18 @@ the tools documentation for details on this process.
- https://flake8.pycqa.org/en/latest/
- https://www.pylint.org/

Naming Convenction
----------------------------------------

Discovery
~~~~~~~~~
When adding discovery modules or functions please adhere to the following
* Filenames should just include the name of the organization (arm) or portal (airnow) and no other filler words like get or download
* Functions should follow [get/download]_[org/portal]_[data/other description]. If it is getting data but not downloading a file, it should start with get, like get_asos_data. If it downloads a file, it should start with download. The other description can vary depending on what you are retrieving. Please check out the existing functions for ideas.

Discovery
~~~~~~~~~
Similarly, for the io modules, the names should not have filler and just be the organization or portal name. The functions should clearly indicate what it is doing like read_arm_netcdf instead of read_netcdf if the function is specific to ARM files.

Adding Secrets and Environment Variables
----------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ environment based on the `environment.yml <https://github.com/ARM-DOE/ACT/blob/m

Or for a basic environment and downloading optional dependencies as needed::

conda create -n act_env -c conda-forge python=3.11 act-atmos
conda create -n act_env -c conda-forge python=3.12 act-atmos

Basic command in a terminal or command prompt to install the latest version of
ACT::
Expand Down
17 changes: 8 additions & 9 deletions act/discovery/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,14 @@

__getattr__, __dir__, __all__ = lazy.attach(
__name__,
submodules=['get_armfiles', 'get_cropscape', 'get_airnow', 'get_noaapsl', 'get_neon', 'get_surfrad'],
submodules=['arm', 'cropscape', 'airnow', 'noaapsl', 'neon', 'surfrad'],
submod_attrs={
'get_arm': ['download_arm_data'],
'get_armfiles': ['download_data', 'download_arm_data', 'get_arm_doi'],
'get_asos': ['get_asos'],
'get_airnow': ['get_airnow_bounded_obs', 'get_airnow_obs', 'get_airnow_forecast'],
'get_cropscape': ['croptype'],
'get_noaapsl': ['download_noaa_psl_data'],
'get_neon': ['get_site_products', 'get_product_avail', 'download_neon_data'],
'get_surfrad': ['download_surfrad']
'arm': ['download_arm_data', 'get_arm_doi'],
'asos': ['get_asos_data'],
'airnow': ['get_airnow_bounded_obs', 'get_airnow_obs', 'get_airnow_forecast'],
'cropscape': ['get_crop_type'],
'noaapsl': ['download_noaa_psl_data'],
'neon': ['get_neon_site_products', 'get_neon_product_avail', 'download_neon_data'],
'surfrad': ['download_surfrad_data']
},
)
261 changes: 0 additions & 261 deletions act/discovery/get_airnow.py

This file was deleted.

Loading

0 comments on commit 2b83f4b

Please sign in to comment.