gridstats 2.0.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. gridstats-2.0.0/AUTHORS.rst +13 -0
  2. gridstats-2.0.0/CONTRIBUTING.rst +128 -0
  3. gridstats-2.0.0/HISTORY.rst +8 -0
  4. gridstats-2.0.0/MANIFEST.in +12 -0
  5. gridstats-2.0.0/PKG-INFO +192 -0
  6. gridstats-2.0.0/README.md +148 -0
  7. gridstats-2.0.0/docs/Makefile +20 -0
  8. gridstats-2.0.0/docs/authors.rst +1 -0
  9. gridstats-2.0.0/docs/conf.py +161 -0
  10. gridstats-2.0.0/docs/contributing.rst +1 -0
  11. gridstats-2.0.0/docs/history.rst +1 -0
  12. gridstats-2.0.0/docs/index.rst +20 -0
  13. gridstats-2.0.0/docs/installation.rst +51 -0
  14. gridstats-2.0.0/docs/make.bat +36 -0
  15. gridstats-2.0.0/docs/readme.rst +1 -0
  16. gridstats-2.0.0/docs/usage.rst +7 -0
  17. gridstats-2.0.0/gridstats/__init__.py +15 -0
  18. gridstats-2.0.0/gridstats/attributes.yml +213 -0
  19. gridstats-2.0.0/gridstats/cli.py +56 -0
  20. gridstats-2.0.0/gridstats/config.py +127 -0
  21. gridstats-2.0.0/gridstats/loaders/__init__.py +8 -0
  22. gridstats-2.0.0/gridstats/loaders/intake.py +52 -0
  23. gridstats-2.0.0/gridstats/loaders/xarray.py +90 -0
  24. gridstats-2.0.0/gridstats/ops/__init__.py +25 -0
  25. gridstats-2.0.0/gridstats/ops/aggregations.py +161 -0
  26. gridstats-2.0.0/gridstats/ops/directional.py +79 -0
  27. gridstats-2.0.0/gridstats/ops/distribution.py +290 -0
  28. gridstats-2.0.0/gridstats/ops/exceedance.py +173 -0
  29. gridstats-2.0.0/gridstats/ops/frequency_domain.py +111 -0
  30. gridstats-2.0.0/gridstats/ops/probability.py +65 -0
  31. gridstats-2.0.0/gridstats/ops/rpv.py +154 -0
  32. gridstats-2.0.0/gridstats/ops/windpower.py +76 -0
  33. gridstats-2.0.0/gridstats/output.py +227 -0
  34. gridstats-2.0.0/gridstats/pipeline.py +312 -0
  35. gridstats-2.0.0/gridstats/registry.py +114 -0
  36. gridstats-2.0.0/gridstats.egg-info/PKG-INFO +192 -0
  37. gridstats-2.0.0/gridstats.egg-info/SOURCES.txt +70 -0
  38. gridstats-2.0.0/gridstats.egg-info/dependency_links.txt +1 -0
  39. gridstats-2.0.0/gridstats.egg-info/entry_points.txt +2 -0
  40. gridstats-2.0.0/gridstats.egg-info/requires.txt +25 -0
  41. gridstats-2.0.0/gridstats.egg-info/top_level.txt +1 -0
  42. gridstats-2.0.0/pyproject.toml +76 -0
  43. gridstats-2.0.0/setup.cfg +4 -0
  44. gridstats-2.0.0/tests/catalog/era5_wind.zarr/.zattrs +5 -0
  45. gridstats-2.0.0/tests/catalog/era5_wind.zarr/.zgroup +3 -0
  46. gridstats-2.0.0/tests/catalog/era5_wind.zarr/.zmetadata +163 -0
  47. gridstats-2.0.0/tests/catalog/era5_wind.zarr/latitude/.zarray +20 -0
  48. gridstats-2.0.0/tests/catalog/era5_wind.zarr/latitude/.zattrs +7 -0
  49. gridstats-2.0.0/tests/catalog/era5_wind.zarr/latitude/0 +0 -0
  50. gridstats-2.0.0/tests/catalog/era5_wind.zarr/longitude/.zarray +20 -0
  51. gridstats-2.0.0/tests/catalog/era5_wind.zarr/longitude/.zattrs +7 -0
  52. gridstats-2.0.0/tests/catalog/era5_wind.zarr/longitude/0 +0 -0
  53. gridstats-2.0.0/tests/catalog/era5_wind.zarr/time/.zarray +20 -0
  54. gridstats-2.0.0/tests/catalog/era5_wind.zarr/time/.zattrs +8 -0
  55. gridstats-2.0.0/tests/catalog/era5_wind.zarr/time/0 +0 -0
  56. gridstats-2.0.0/tests/catalog/era5_wind.zarr/u10/.zarray +24 -0
  57. gridstats-2.0.0/tests/catalog/era5_wind.zarr/u10/.zattrs +10 -0
  58. gridstats-2.0.0/tests/catalog/era5_wind.zarr/u10/0.0.0 +0 -0
  59. gridstats-2.0.0/tests/catalog/era5_wind.zarr/v10/.zarray +24 -0
  60. gridstats-2.0.0/tests/catalog/era5_wind.zarr/v10/.zattrs +10 -0
  61. gridstats-2.0.0/tests/catalog/era5_wind.zarr/v10/0.0.0 +0 -0
  62. gridstats-2.0.0/tests/catalog/hindcast/hindcast.yml +26 -0
  63. gridstats-2.0.0/tests/catalog/oceanum.yml +13 -0
  64. gridstats-2.0.0/tests/config-hsig.yml +15 -0
  65. gridstats-2.0.0/tests/config.yml +161 -0
  66. gridstats-2.0.0/tests/test_cli.py +79 -0
  67. gridstats-2.0.0/tests/test_config.py +258 -0
  68. gridstats-2.0.0/tests/test_loaders.py +178 -0
  69. gridstats-2.0.0/tests/test_ops.py +241 -0
  70. gridstats-2.0.0/tests/test_output.py +115 -0
  71. gridstats-2.0.0/tests/test_pipeline.py +178 -0
  72. gridstats-2.0.0/tests/test_registry.py +117 -0
@@ -0,0 +1,13 @@
1
+ =======
2
+ Credits
3
+ =======
4
+
5
+ Development Lead
6
+ ----------------
7
+
8
+ * Oceanum Developers <developers@oceanum.science>
9
+
10
+ Contributors
11
+ ------------
12
+
13
+ None yet. Why not be the first?
@@ -0,0 +1,128 @@
1
+ .. highlight:: shell
2
+
3
+ ============
4
+ Contributing
5
+ ============
6
+
7
+ Contributions are welcome, and they are greatly appreciated! Every little bit
8
+ helps, and credit will always be given.
9
+
10
+ You can contribute in many ways:
11
+
12
+ Types of Contributions
13
+ ----------------------
14
+
15
+ Report Bugs
16
+ ~~~~~~~~~~~
17
+
18
+ Report bugs at https://github.com/oceanum/gridstats/issues.
19
+
20
+ If you are reporting a bug, please include:
21
+
22
+ * Your operating system name and version.
23
+ * Any details about your local setup that might be helpful in troubleshooting.
24
+ * Detailed steps to reproduce the bug.
25
+
26
+ Fix Bugs
27
+ ~~~~~~~~
28
+
29
+ Look through the GitHub issues for bugs. Anything tagged with "bug" and "help
30
+ wanted" is open to whoever wants to implement it.
31
+
32
+ Implement Features
33
+ ~~~~~~~~~~~~~~~~~~
34
+
35
+ Look through the GitHub issues for features. Anything tagged with "enhancement"
36
+ and "help wanted" is open to whoever wants to implement it.
37
+
38
+ Write Documentation
39
+ ~~~~~~~~~~~~~~~~~~~
40
+
41
+ gridstats could always use more documentation, whether as part of the
42
+ official gridstats docs, in docstrings, or even on the web in blog posts,
43
+ articles, and such.
44
+
45
+ Submit Feedback
46
+ ~~~~~~~~~~~~~~~
47
+
48
+ The best way to send feedback is to file an issue at https://github.com/oceanum/gridstats/issues.
49
+
50
+ If you are proposing a feature:
51
+
52
+ * Explain in detail how it would work.
53
+ * Keep the scope as narrow as possible, to make it easier to implement.
54
+ * Remember that this is a volunteer-driven project, and that contributions
55
+ are welcome :)
56
+
57
+ Get Started!
58
+ ------------
59
+
60
+ Ready to contribute? Here's how to set up `gridstats` for local development.
61
+
62
+ 1. Fork the `gridstats` repo on GitHub.
63
+ 2. Clone your fork locally::
64
+
65
+ $ git clone git@github.com:your_name_here/gridstats.git
66
+
67
+ 3. Install your local copy into a virtualenv. Assuming you have virtualenvwrapper installed, this is how you set up your fork for local development::
68
+
69
+ $ mkvirtualenv gridstats
70
+ $ cd gridstats/
71
+ $ python setup.py develop
72
+
73
+ 4. Create a branch for local development::
74
+
75
+ $ git checkout -b name-of-your-bugfix-or-feature
76
+
77
+ Now you can make your changes locally.
78
+
79
+ 5. When you're done making changes, check that your changes pass flake8 and the
80
+ tests, including testing other Python versions with tox::
81
+
82
+ $ flake8 gridstats tests
83
+ $ python setup.py test or py.test
84
+ $ tox
85
+
86
+ To get flake8 and tox, just pip install them into your virtualenv.
87
+
88
+ 6. Commit your changes and push your branch to GitHub::
89
+
90
+ $ git add .
91
+ $ git commit -m "Your detailed description of your changes."
92
+ $ git push origin name-of-your-bugfix-or-feature
93
+
94
+ 7. Submit a pull request through the GitHub website.
95
+
96
+ Pull Request Guidelines
97
+ -----------------------
98
+
99
+ Before you submit a pull request, check that it meets these guidelines:
100
+
101
+ 1. The pull request should include tests.
102
+ 2. If the pull request adds functionality, the docs should be updated. Put
103
+ your new functionality into a function with a docstring, and add the
104
+ feature to the list in README.rst.
105
+ 3. The pull request should work for Python 2.7, 3.4, 3.5 and 3.6, and for PyPy. Check
106
+ https://travis-ci.org/oceanum/gridstats/pull_requests
107
+ and make sure that the tests pass for all supported Python versions.
108
+
109
+ Tips
110
+ ----
111
+
112
+ To run a subset of tests::
113
+
114
+ $ py.test tests.test_stats
115
+
116
+
117
+ Deploying
118
+ ---------
119
+
120
+ A reminder for the maintainers on how to deploy.
121
+ Make sure all your changes are committed (including an entry in HISTORY.rst).
122
+ Then run::
123
+
124
+ $ bumpversion patch # possible: major / minor / patch
125
+ $ git push
126
+ $ git push --tags
127
+
128
+ Travis will then deploy to PyPI if tests pass.
@@ -0,0 +1,8 @@
1
+ =======
2
+ History
3
+ =======
4
+
5
+ 0.1.0 (2019-08-09)
6
+ ------------------
7
+
8
+ * First release on PyPI.
@@ -0,0 +1,12 @@
1
+ include AUTHORS.rst
2
+ include CONTRIBUTING.rst
3
+ include HISTORY.rst
4
+ include LICENSE
5
+ include README.rst
6
+ include gridstats/attributes.yml
7
+
8
+ recursive-include tests *
9
+ recursive-exclude * __pycache__
10
+ recursive-exclude * *.py[co]
11
+
12
+ recursive-include docs *.rst conf.py Makefile make.bat *.jpg *.png *.gif
@@ -0,0 +1,192 @@
1
+ Metadata-Version: 2.4
2
+ Name: gridstats
3
+ Version: 2.0.0
4
+ Summary: Oceanum library for computing gridded statistics on oceanographic datasets
5
+ Author-email: Oceanum Developers <developers@oceanum.science>
6
+ License: MIT
7
+ Project-URL: Homepage, https://github.com/oceanum/gridstats
8
+ Project-URL: Repository, https://github.com/oceanum/gridstats
9
+ Classifier: Development Status :: 4 - Beta
10
+ Classifier: Intended Audience :: Science/Research
11
+ Classifier: Natural Language :: English
12
+ Classifier: Programming Language :: Python :: 3
13
+ Classifier: Programming Language :: Python :: 3.10
14
+ Classifier: Programming Language :: Python :: 3.11
15
+ Classifier: Programming Language :: Python :: 3.12
16
+ Classifier: Topic :: Scientific/Engineering :: Atmospheric Science
17
+ Classifier: Topic :: Scientific/Engineering :: Oceanography
18
+ Requires-Python: >=3.10
19
+ Description-Content-Type: text/markdown
20
+ License-File: AUTHORS.rst
21
+ Requires-Dist: bottleneck
22
+ Requires-Dist: dask
23
+ Requires-Dist: distributed
24
+ Requires-Dist: flox
25
+ Requires-Dist: netcdf4
26
+ Requires-Dist: pydantic>=2
27
+ Requires-Dist: pyyaml
28
+ Requires-Dist: scipy
29
+ Requires-Dist: typer
30
+ Requires-Dist: xarray
31
+ Requires-Dist: zarr<3
32
+ Provides-Extra: extra
33
+ Requires-Dist: gcsfs; extra == "extra"
34
+ Requires-Dist: intake; extra == "extra"
35
+ Requires-Dist: intake-forecast; extra == "extra"
36
+ Provides-Extra: dev
37
+ Requires-Dist: pytest; extra == "dev"
38
+ Requires-Dist: pytest-cov; extra == "dev"
39
+ Provides-Extra: docs
40
+ Requires-Dist: mkdocs>=1.5; extra == "docs"
41
+ Requires-Dist: mkdocs-material>=9; extra == "docs"
42
+ Requires-Dist: mkdocstrings[python]>=0.24; extra == "docs"
43
+ Dynamic: license-file
44
+
45
+ # gridstats
46
+
47
+ **gridstats** is an Oceanum library for computing gridded statistics over large oceanographic and climate datasets. Pipelines are defined in YAML and run as a single CLI command. Computation is lazy and out-of-core via [xarray](https://xarray.dev) and [dask](https://dask.org), so datasets of arbitrary size are handled without loading them into memory.
48
+
49
+ ## Features
50
+
51
+ - **YAML-driven pipelines** — source, operations, and output are all declared in one config file
52
+ - **Out-of-core** — processes arbitrarily large grids lazily; spatial `tiles:` keeps peak memory bounded
53
+ - **Rich stat library** — aggregations, quantiles, exceedance, return period values, directional stats, distributions, and more
54
+ - **Multiple output formats** — NetCDF or Zarr
55
+ - **CF-compliant** — output variables are automatically annotated with standard names, units, and long names
56
+ - **Extensible** — register custom stat functions and loaders via decorator or package entry point
57
+
58
+ ## Installation
59
+
60
+ Requires Python ≥ 3.10.
61
+
62
+ ```bash
63
+ pip install gridstats
64
+ ```
65
+
66
+ For loading data from an [intake](https://intake.readthedocs.io) catalog:
67
+
68
+ ```bash
69
+ pip install "gridstats[intake]"
70
+ ```
71
+
72
+ ## Quick start
73
+
74
+ ### 1. Write a config file
75
+
76
+ ```yaml
77
+ # stats.yml
78
+ source:
79
+ type: xarray
80
+ urlpath: /data/hindcast/waves.zarr
81
+ engine: zarr
82
+ sel:
83
+ time: {start: "2000-01-01", stop: "2020-12-31"}
84
+ latitude: {start: -50, stop: -30}
85
+ longitude: {start: 160, stop: 180}
86
+
87
+ output:
88
+ outfile: ./wave_stats.zarr
89
+
90
+ calls:
91
+ - func: mean
92
+ dim: time
93
+ data_vars: [hs, tp]
94
+
95
+ - func: quantile
96
+ dim: time
97
+ data_vars: [hs]
98
+ q: [0.5, 0.90, 0.95, 0.99]
99
+
100
+ - func: rpv
101
+ dim: time
102
+ data_vars: [hs]
103
+ return_periods: [10, 50, 100]
104
+ distribution: gumbel_r
105
+ ```
106
+
107
+ ### 2. Run it
108
+
109
+ ```bash
110
+ gridstats run stats.yml
111
+ ```
112
+
113
+ The output dataset will contain variables like `hs_mean`, `tp_mean`, `hs_quantile`, and `hs_rpv`, each with CF-standard attributes.
114
+
115
+ ### 3. Use the result
116
+
117
+ ```python
118
+ import xarray as xr
119
+
120
+ ds = xr.open_zarr("wave_stats.zarr")
121
+ print(ds)
122
+ ```
123
+
124
+ ## Available stat functions
125
+
126
+ | Function | Description |
127
+ |---|---|
128
+ | `mean`, `max`, `min`, `std`, `count` | Basic aggregations |
129
+ | `quantile` | Quantiles at arbitrary probability levels |
130
+ | `pcount` | Count of non-NaN values per grid cell |
131
+ | `exceedance` / `nonexceedance` | Probability of exceeding a threshold |
132
+ | `range_probability` | Probability of a value falling in a range |
133
+ | `rpv` | Return period values via extreme value fitting |
134
+ | `distribution2` / `distribution3` | 2- and 3-parameter distribution fitting |
135
+ | `statdir` | Directional statistics (sector-binned) |
136
+ | `hmo` | Significant wave height from spectral moments |
137
+ | `winpow` | Wind power density |
138
+
139
+ All calls accept a `group:` key (`month`, `season`, `hour`, …) to compute statistics per calendar period.
140
+
141
+ ## Grouping and spatial tiling
142
+
143
+ ```yaml
144
+ calls:
145
+ # Monthly mean
146
+ - func: mean
147
+ dim: time
148
+ data_vars: [hs]
149
+ group: month
150
+
151
+ # Quantile with spatial tiling to control memory
152
+ - func: quantile
153
+ dim: time
154
+ data_vars: [hs]
155
+ q: [0.95, 0.99]
156
+ chunks: {time: -1, latitude: 50, longitude: 50}
157
+ tiles: {latitude: 10, longitude: 10}
158
+ ```
159
+
160
+ ## Plugin system
161
+
162
+ Register a custom stat function in your own package:
163
+
164
+ ```python
165
+ from gridstats.registry import register_stat
166
+ import xarray as xr
167
+
168
+ @register_stat("my_stat")
169
+ def my_stat(data: xr.Dataset, *, dim: str = "time", **kwargs) -> xr.Dataset:
170
+ ...
171
+ ```
172
+
173
+ Or declare it as a package entry point so it is discovered automatically:
174
+
175
+ ```toml
176
+ [project.entry-points."gridstats.stats"]
177
+ my_stat = "my_package.stats:my_stat"
178
+ ```
179
+
180
+ ## CLI
181
+
182
+ ```
183
+ Usage: gridstats [OPTIONS] COMMAND [ARGS]...
184
+
185
+ Commands:
186
+ run Run a stats pipeline from a YAML configuration file.
187
+ list-stats List all registered stat functions.
188
+ ```
189
+
190
+ ## License
191
+
192
+ MIT — see [LICENSE](LICENSE).
@@ -0,0 +1,148 @@
1
+ # gridstats
2
+
3
+ **gridstats** is an Oceanum library for computing gridded statistics over large oceanographic and climate datasets. Pipelines are defined in YAML and run as a single CLI command. Computation is lazy and out-of-core via [xarray](https://xarray.dev) and [dask](https://dask.org), so datasets of arbitrary size are handled without loading them into memory.
4
+
5
+ ## Features
6
+
7
+ - **YAML-driven pipelines** — source, operations, and output are all declared in one config file
8
+ - **Out-of-core** — processes arbitrarily large grids lazily; spatial `tiles:` keeps peak memory bounded
9
+ - **Rich stat library** — aggregations, quantiles, exceedance, return period values, directional stats, distributions, and more
10
+ - **Multiple output formats** — NetCDF or Zarr
11
+ - **CF-compliant** — output variables are automatically annotated with standard names, units, and long names
12
+ - **Extensible** — register custom stat functions and loaders via decorator or package entry point
13
+
14
+ ## Installation
15
+
16
+ Requires Python ≥ 3.10.
17
+
18
+ ```bash
19
+ pip install gridstats
20
+ ```
21
+
22
+ For loading data from an [intake](https://intake.readthedocs.io) catalog:
23
+
24
+ ```bash
25
+ pip install "gridstats[intake]"
26
+ ```
27
+
28
+ ## Quick start
29
+
30
+ ### 1. Write a config file
31
+
32
+ ```yaml
33
+ # stats.yml
34
+ source:
35
+ type: xarray
36
+ urlpath: /data/hindcast/waves.zarr
37
+ engine: zarr
38
+ sel:
39
+ time: {start: "2000-01-01", stop: "2020-12-31"}
40
+ latitude: {start: -50, stop: -30}
41
+ longitude: {start: 160, stop: 180}
42
+
43
+ output:
44
+ outfile: ./wave_stats.zarr
45
+
46
+ calls:
47
+ - func: mean
48
+ dim: time
49
+ data_vars: [hs, tp]
50
+
51
+ - func: quantile
52
+ dim: time
53
+ data_vars: [hs]
54
+ q: [0.5, 0.90, 0.95, 0.99]
55
+
56
+ - func: rpv
57
+ dim: time
58
+ data_vars: [hs]
59
+ return_periods: [10, 50, 100]
60
+ distribution: gumbel_r
61
+ ```
62
+
63
+ ### 2. Run it
64
+
65
+ ```bash
66
+ gridstats run stats.yml
67
+ ```
68
+
69
+ The output dataset will contain variables like `hs_mean`, `tp_mean`, `hs_quantile`, and `hs_rpv`, each with CF-standard attributes.
70
+
71
+ ### 3. Use the result
72
+
73
+ ```python
74
+ import xarray as xr
75
+
76
+ ds = xr.open_zarr("wave_stats.zarr")
77
+ print(ds)
78
+ ```
79
+
80
+ ## Available stat functions
81
+
82
+ | Function | Description |
83
+ |---|---|
84
+ | `mean`, `max`, `min`, `std`, `count` | Basic aggregations |
85
+ | `quantile` | Quantiles at arbitrary probability levels |
86
+ | `pcount` | Count of non-NaN values per grid cell |
87
+ | `exceedance` / `nonexceedance` | Probability of exceeding a threshold |
88
+ | `range_probability` | Probability of a value falling in a range |
89
+ | `rpv` | Return period values via extreme value fitting |
90
+ | `distribution2` / `distribution3` | 2- and 3-parameter distribution fitting |
91
+ | `statdir` | Directional statistics (sector-binned) |
92
+ | `hmo` | Significant wave height from spectral moments |
93
+ | `winpow` | Wind power density |
94
+
95
+ All calls accept a `group:` key (`month`, `season`, `hour`, …) to compute statistics per calendar period.
96
+
97
+ ## Grouping and spatial tiling
98
+
99
+ ```yaml
100
+ calls:
101
+ # Monthly mean
102
+ - func: mean
103
+ dim: time
104
+ data_vars: [hs]
105
+ group: month
106
+
107
+ # Quantile with spatial tiling to control memory
108
+ - func: quantile
109
+ dim: time
110
+ data_vars: [hs]
111
+ q: [0.95, 0.99]
112
+ chunks: {time: -1, latitude: 50, longitude: 50}
113
+ tiles: {latitude: 10, longitude: 10}
114
+ ```
115
+
116
+ ## Plugin system
117
+
118
+ Register a custom stat function in your own package:
119
+
120
+ ```python
121
+ from gridstats.registry import register_stat
122
+ import xarray as xr
123
+
124
+ @register_stat("my_stat")
125
+ def my_stat(data: xr.Dataset, *, dim: str = "time", **kwargs) -> xr.Dataset:
126
+ ...
127
+ ```
128
+
129
+ Or declare it as a package entry point so it is discovered automatically:
130
+
131
+ ```toml
132
+ [project.entry-points."gridstats.stats"]
133
+ my_stat = "my_package.stats:my_stat"
134
+ ```
135
+
136
+ ## CLI
137
+
138
+ ```
139
+ Usage: gridstats [OPTIONS] COMMAND [ARGS]...
140
+
141
+ Commands:
142
+ run Run a stats pipeline from a YAML configuration file.
143
+ list-stats List all registered stat functions.
144
+ ```
145
+
146
+ ## License
147
+
148
+ MIT — see [LICENSE](LICENSE).
@@ -0,0 +1,20 @@
1
+ # Minimal makefile for Sphinx documentation
2
+ #
3
+
4
+ # You can set these variables from the command line.
5
+ SPHINXOPTS =
6
+ SPHINXBUILD = python -msphinx
7
+ SPHINXPROJ = gridstats
8
+ SOURCEDIR = .
9
+ BUILDDIR = _build
10
+
11
+ # Put it first so that "make" without argument is like "make help".
12
+ help:
13
+ @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
14
+
15
+ .PHONY: help Makefile
16
+
17
+ # Catch-all target: route all unknown targets to Sphinx using the new
18
+ # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
19
+ %: Makefile
20
+ @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
@@ -0,0 +1 @@
1
+ .. include:: ../AUTHORS.rst
@@ -0,0 +1,161 @@
1
+ #!/usr/bin/env python
2
+ # -*- coding: utf-8 -*-
3
+ #
4
+ # gridstats documentation build configuration file, created by
5
+ # sphinx-quickstart on Fri Jun 9 13:47:02 2017.
6
+ #
7
+ # This file is execfile()d with the current directory set to its
8
+ # containing dir.
9
+ #
10
+ # Note that not all possible configuration values are present in this
11
+ # autogenerated file.
12
+ #
13
+ # All configuration values have a default; values that are commented out
14
+ # serve to show the default.
15
+
16
+ # If extensions (or modules to document with autodoc) are in another
17
+ # directory, add these directories to sys.path here. If the directory is
18
+ # relative to the documentation root, use os.path.abspath to make it
19
+ # absolute, like shown here.
20
+ #
21
+ import os
22
+ import sys
23
+
24
+ sys.path.insert(0, os.path.abspath(".."))
25
+
26
+ import gridstats
27
+
28
+ # -- General configuration ---------------------------------------------
29
+
30
+ # If your documentation needs a minimal Sphinx version, state it here.
31
+ #
32
+ # needs_sphinx = '1.0'
33
+
34
+ # Add any Sphinx extension module names here, as strings. They can be
35
+ # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
36
+ extensions = ["sphinx.ext.autodoc", "sphinx.ext.viewcode"]
37
+
38
+ # Add any paths that contain templates here, relative to this directory.
39
+ templates_path = ["_templates"]
40
+
41
+ # The suffix(es) of source filenames.
42
+ # You can specify multiple suffix as a list of string:
43
+ #
44
+ # source_suffix = ['.rst', '.md']
45
+ source_suffix = ".rst"
46
+
47
+ # The master toctree document.
48
+ master_doc = "index"
49
+
50
+ # General information about the project.
51
+ project = u"gridstats"
52
+ copyright = u"2019, Oceanum Developers"
53
+ author = u"Oceanum Developers"
54
+
55
+ # The version info for the project you're documenting, acts as replacement
56
+ # for |version| and |release|, also used in various other places throughout
57
+ # the built documents.
58
+ #
59
+ # The short X.Y version.
60
+ version = gridstats.__version__
61
+ # The full version, including alpha/beta/rc tags.
62
+ release = gridstats.__version__
63
+
64
+ # The language for content autogenerated by Sphinx. Refer to documentation
65
+ # for a list of supported languages.
66
+ #
67
+ # This is also used if you do content translation via gettext catalogs.
68
+ # Usually you set "language" from the command line for these cases.
69
+ language = None
70
+
71
+ # List of patterns, relative to source directory, that match files and
72
+ # directories to ignore when looking for source files.
73
+ # This patterns also effect to html_static_path and html_extra_path
74
+ exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]
75
+
76
+ # The name of the Pygments (syntax highlighting) style to use.
77
+ pygments_style = "sphinx"
78
+
79
+ # If true, `todo` and `todoList` produce output, else they produce nothing.
80
+ todo_include_todos = False
81
+
82
+
83
+ # -- Options for HTML output -------------------------------------------
84
+
85
+ # The theme to use for HTML and HTML Help pages. See the documentation for
86
+ # a list of builtin themes.
87
+ #
88
+ html_theme = "alabaster"
89
+
90
+ # Theme options are theme-specific and customize the look and feel of a
91
+ # theme further. For a list of options available for each theme, see the
92
+ # documentation.
93
+ #
94
+ # html_theme_options = {}
95
+
96
+ # Add any paths that contain custom static files (such as style sheets) here,
97
+ # relative to this directory. They are copied after the builtin static files,
98
+ # so a file named "default.css" will overwrite the builtin "default.css".
99
+ html_static_path = ["_static"]
100
+
101
+
102
+ # -- Options for HTMLHelp output ---------------------------------------
103
+
104
+ # Output file base name for HTML help builder.
105
+ htmlhelp_basename = "statsdoc"
106
+
107
+
108
+ # -- Options for LaTeX output ------------------------------------------
109
+
110
+ latex_elements = {
111
+ # The paper size ('letterpaper' or 'a4paper').
112
+ #
113
+ # 'papersize': 'letterpaper',
114
+ # The font size ('10pt', '11pt' or '12pt').
115
+ #
116
+ # 'pointsize': '10pt',
117
+ # Additional stuff for the LaTeX preamble.
118
+ #
119
+ # 'preamble': '',
120
+ # Latex figure (float) alignment
121
+ #
122
+ # 'figure_align': 'htbp',
123
+ }
124
+
125
+ # Grouping the document tree into LaTeX files. List of tuples
126
+ # (source start file, target name, title, author, documentclass
127
+ # [howto, manual, or own class]).
128
+ latex_documents = [
129
+ (
130
+ master_doc,
131
+ "gridstats.tex",
132
+ u"gridstats Documentation",
133
+ u"Oceanum Developers",
134
+ "manual",
135
+ )
136
+ ]
137
+
138
+
139
+ # -- Options for manual page output ------------------------------------
140
+
141
+ # One entry per manual page. List of tuples
142
+ # (source start file, name, description, authors, manual section).
143
+ man_pages = [(master_doc, "gridstats", u"gridstats Documentation", [author], 1)]
144
+
145
+
146
+ # -- Options for Texinfo output ----------------------------------------
147
+
148
+ # Grouping the document tree into Texinfo files. List of tuples
149
+ # (source start file, target name, title, author,
150
+ # dir menu entry, description, category)
151
+ texinfo_documents = [
152
+ (
153
+ master_doc,
154
+ "gridstats",
155
+ u"gridstats Documentation",
156
+ author,
157
+ "gridstats",
158
+ "One line description of project.",
159
+ "Miscellaneous",
160
+ )
161
+ ]
@@ -0,0 +1 @@
1
+ .. include:: ../CONTRIBUTING.rst
@@ -0,0 +1 @@
1
+ .. include:: ../HISTORY.rst