├── .github └── workflows │ ├── conda.yml │ └── pypi.yml ├── .gitignore ├── .no_travis.yml ├── .pre-commit-config.yaml ├── LICENSE ├── Makefile ├── README.md ├── conda ├── meta.yaml └── requirements.yml ├── deploy_conda.sh ├── docs ├── Description.rst ├── Makefile ├── Usage.rst ├── _build │ ├── doctrees │ │ ├── Description.doctree │ │ ├── Installation.doctree │ │ ├── Usage.doctree │ │ ├── api.doctree │ │ ├── api │ │ │ ├── imdlib.core.IMD.doctree │ │ │ ├── imdlib.core.get_data.doctree │ │ │ ├── imdlib.core.open_data.doctree │ │ │ ├── imdlib.util.LeapYear.doctree │ │ │ ├── imdlib.util.get_filename.doctree │ │ │ ├── imdlib.util.get_lat_lon.doctree │ │ │ └── imdlib.util.total_days.doctree │ │ ├── authors.doctree │ │ ├── cf-conventions.doctree │ │ ├── changelog.doctree │ │ ├── contributions.doctree │ │ ├── environment.pickle │ │ ├── external-links.doctree │ │ ├── faq.doctree │ │ └── index.doctree │ └── html │ │ ├── .buildinfo │ │ ├── .doctrees │ │ ├── Description.doctree │ │ ├── Installation.doctree │ │ ├── Usage.doctree │ │ ├── authors.doctree │ │ ├── cf-conventions.doctree │ │ ├── changelog.doctree │ │ ├── contributions.doctree │ │ ├── environment.pickle │ │ ├── external-links.doctree │ │ ├── faq.doctree │ │ └── index.doctree │ │ ├── Description.html │ │ ├── Installation.html │ │ ├── Usage.html │ │ ├── _images │ │ ├── fig1.png │ │ └── fig2.jpg │ │ ├── _sources │ │ ├── Description.rst.txt │ │ ├── Installation.rst.txt │ │ ├── Usage.rst.txt │ │ ├── api.rst.txt │ │ ├── api │ │ │ ├── imdlib.core.IMD.rst.txt │ │ │ ├── imdlib.core.get_data.rst.txt │ │ │ ├── imdlib.core.open_data.rst.txt │ │ │ ├── imdlib.util.LeapYear.rst.txt │ │ │ ├── imdlib.util.get_filename.rst.txt │ │ │ ├── imdlib.util.get_lat_lon.rst.txt │ │ │ └── imdlib.util.total_days.rst.txt │ │ ├── authors.rst.txt │ │ ├── cf-conventions.rst.txt │ │ ├── changelog.rst.txt │ │ ├── contributions.rst.txt │ │ ├── external-links.rst.txt │ │ ├── faq.rst.txt │ │ └── index.rst.txt │ │ ├── _static │ │ ├── alabaster.css │ │ ├── basic.css │ │ ├── css │ │ │ ├── badge_only.css │ │ │ ├── fonts │ │ │ │ ├── Roboto-Slab-Bold.woff │ │ │ │ ├── Roboto-Slab-Bold.woff2 │ │ │ │ ├── Roboto-Slab-Regular.woff │ │ │ │ ├── Roboto-Slab-Regular.woff2 │ │ │ │ ├── fontawesome-webfont.eot │ │ │ │ ├── fontawesome-webfont.svg │ │ │ │ ├── fontawesome-webfont.ttf │ │ │ │ ├── fontawesome-webfont.woff │ │ │ │ ├── fontawesome-webfont.woff2 │ │ │ │ ├── lato-bold-italic.woff │ │ │ │ ├── lato-bold-italic.woff2 │ │ │ │ ├── lato-bold.woff │ │ │ │ ├── lato-bold.woff2 │ │ │ │ ├── lato-normal-italic.woff │ │ │ │ ├── lato-normal-italic.woff2 │ │ │ │ ├── lato-normal.woff │ │ │ │ └── lato-normal.woff2 │ │ │ └── theme.css │ │ ├── custom.css │ │ ├── doctools.js │ │ ├── documentation_options.js │ │ ├── file.png │ │ ├── fonts │ │ │ ├── FontAwesome.otf │ │ │ ├── Lato │ │ │ │ ├── lato-bold.eot │ │ │ │ ├── lato-bold.ttf │ │ │ │ ├── lato-bold.woff │ │ │ │ ├── lato-bold.woff2 │ │ │ │ ├── lato-bolditalic.eot │ │ │ │ ├── lato-bolditalic.ttf │ │ │ │ ├── lato-bolditalic.woff │ │ │ │ ├── lato-bolditalic.woff2 │ │ │ │ ├── lato-italic.eot │ │ │ │ ├── lato-italic.ttf │ │ │ │ ├── lato-italic.woff │ │ │ │ ├── lato-italic.woff2 │ │ │ │ ├── lato-regular.eot │ │ │ │ ├── lato-regular.ttf │ │ │ │ ├── lato-regular.woff │ │ │ │ └── lato-regular.woff2 │ │ │ ├── Roboto-Slab-Bold.woff │ │ │ ├── Roboto-Slab-Bold.woff2 │ │ │ ├── Roboto-Slab-Light.woff │ │ │ ├── Roboto-Slab-Light.woff2 │ │ │ ├── Roboto-Slab-Regular.woff │ │ │ ├── Roboto-Slab-Regular.woff2 │ │ │ ├── Roboto-Slab-Thin.woff │ │ │ ├── Roboto-Slab-Thin.woff2 │ │ │ ├── RobotoSlab │ │ │ │ ├── roboto-slab-v7-bold.eot │ │ │ │ ├── roboto-slab-v7-bold.ttf │ │ │ │ ├── roboto-slab-v7-bold.woff │ │ │ │ ├── roboto-slab-v7-bold.woff2 │ │ │ │ ├── roboto-slab-v7-regular.eot │ │ │ │ ├── roboto-slab-v7-regular.ttf │ │ │ │ ├── roboto-slab-v7-regular.woff │ │ │ │ └── roboto-slab-v7-regular.woff2 │ │ │ ├── fontawesome-webfont.eot │ │ │ ├── fontawesome-webfont.svg │ │ │ ├── fontawesome-webfont.ttf │ │ │ ├── fontawesome-webfont.woff │ │ │ ├── fontawesome-webfont.woff2 │ │ │ ├── lato-bold-italic.woff │ │ │ ├── lato-bold-italic.woff2 │ │ │ ├── lato-bold.woff │ │ │ ├── lato-bold.woff2 │ │ │ ├── lato-normal-italic.woff │ │ │ ├── lato-normal-italic.woff2 │ │ │ ├── lato-normal.woff │ │ │ └── lato-normal.woff2 │ │ ├── graphviz.css │ │ ├── jquery-3.5.1.js │ │ ├── jquery.js │ │ ├── js │ │ │ ├── badge_only.js │ │ │ ├── html5shiv-printshiv.min.js │ │ │ ├── html5shiv.min.js │ │ │ ├── modernizr.min.js │ │ │ └── theme.js │ │ ├── language_data.js │ │ ├── minus.png │ │ ├── plus.png │ │ ├── pygments.css │ │ ├── searchtools.js │ │ ├── underscore-1.12.0.js │ │ ├── underscore-1.3.1.js │ │ └── underscore.js │ │ ├── api.html │ │ ├── api │ │ ├── imdlib.core.IMD.html │ │ ├── imdlib.core.get_data.html │ │ ├── imdlib.core.open_data.html │ │ ├── imdlib.util.LeapYear.html │ │ ├── imdlib.util.get_filename.html │ │ ├── imdlib.util.get_lat_lon.html │ │ └── imdlib.util.total_days.html │ │ ├── authors.html │ │ ├── cf-conventions.html │ │ ├── changelog.html │ │ ├── contributions.html │ │ ├── external-links.html │ │ ├── faq.html │ │ ├── genindex.html │ │ ├── googleac2a728cd80ab282.html │ │ ├── index.html │ │ ├── objects.inv │ │ ├── py-modindex.html │ │ ├── robots.txt │ │ ├── search.html │ │ ├── searchindex.js │ │ └── sitemap-index.xml ├── _html │ ├── googleac2a728cd80ab282.html │ ├── robots.txt │ └── sitemap-index.xml ├── api.rst ├── api │ ├── imdlib.core.IMD.rst │ ├── imdlib.core.get_data.rst │ ├── imdlib.core.open_data.rst │ ├── imdlib.util.LeapYear.rst │ ├── imdlib.util.get_filename.rst │ ├── imdlib.util.get_lat_lon.rst │ └── imdlib.util.total_days.rst ├── cf-conventions.rst ├── changelog.rst ├── climate-indices.rst ├── conf.py ├── faq.rst ├── index.rst ├── make.bat ├── publication.rst ├── requirements.txt ├── savefig │ ├── fig1.png │ └── fig2.jpg └── tbl │ └── climate-indices.csv ├── imdlib ├── __init__.py ├── compute.py ├── core.py ├── naming.py ├── real.py ├── util.py └── version.py ├── make.bat ├── meta.yaml ├── requirements.txt ├── setup.py └── test ├── changes.log └── test.py /.github/workflows/conda.yml: -------------------------------------------------------------------------------- 1 | # This workflows will upload a Python Package using Twine when a release is created 2 | # For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries 3 | 4 | name: conda 5 | 6 | # Controls when the action will run. 7 | on: 8 | workflow_dispatch: 9 | # # Triggers the workflow on push or pull request events but only for the master branch 10 | # push: 11 | # branches: [ master ] 12 | # pull_request: 13 | # branches: [ master ] 14 | 15 | # # Allows you to run this workflow manually from the Actions tab 16 | # workflow_dispatch: 17 | 18 | jobs: 19 | deploy: 20 | 21 | runs-on: ubuntu-latest 22 | 23 | steps: 24 | - uses: actions/checkout@v2 25 | - name: Run conda bash script 26 | env: 27 | ANACONDA_TOKEN: ${{ secrets.ANACONDA_TOKEN }} 28 | run: bash deploy_conda.sh 29 | -------------------------------------------------------------------------------- /.github/workflows/pypi.yml: -------------------------------------------------------------------------------- 1 | # This workflows will upload a Python Package using Twine 2 | # For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries 3 | 4 | name: pypi 5 | 6 | # Controls when the action will run. 7 | on: 8 | workflow_dispatch: 9 | # # Triggers the workflow on push or pull request events but only for the master branch 10 | # push: 11 | # branches: [ master ] 12 | # pull_request: 13 | # branches: [ master ] 14 | 15 | # # Allows you to run this workflow manually from the Actions tab 16 | # workflow_dispatch: 17 | 18 | jobs: 19 | deploy: 20 | 21 | runs-on: ubuntu-latest 22 | 23 | steps: 24 | - uses: actions/checkout@v2 25 | - name: Set up Python 26 | uses: actions/setup-python@v2 27 | with: 28 | python-version: '3.x' 29 | - name: Install dependencies 30 | run: | 31 | python -m pip install --upgrade pip 32 | pip install setuptools wheel twine 33 | - name: Build and publish 34 | env: 35 | TWINE_USERNAME: ${{ secrets.PYPI_USERS }} 36 | TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} 37 | run: | 38 | python setup.py sdist bdist_wheel 39 | twine upload dist/* 40 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # conda/ 2 | # test/2018.grd 3 | # conda* 4 | # deploy* 5 | 6 | # .* 7 | # !/.gitignore 8 | 9 | # CI/CD Source # 10 | ################### 11 | #*.yml 12 | 13 | # Bash Script # 14 | ################### 15 | # *.sh 16 | miniconda.sh 17 | 18 | # Compiled source # 19 | ################### 20 | *.com 21 | *.class 22 | *.dll 23 | *.exe 24 | *.o 25 | *.so 26 | *.pyc 27 | *.pyo 28 | *.so 29 | 30 | # Packages # 31 | ############ 32 | # it's better to unpack these files and commit the raw source 33 | # git has its own built in compression methods 34 | *.7z 35 | *.dmg 36 | *.gz 37 | *.iso 38 | *.jar 39 | *.rar 40 | *.tar 41 | *.zip 42 | 43 | # python build 44 | *.egg-info/ -------------------------------------------------------------------------------- /.no_travis.yml: -------------------------------------------------------------------------------- 1 | language: python 2 | python: 3 | - "3.6" 4 | # env: 5 | # global: 6 | # secure: QfXgoTOoSf7jj/sIo0Fk/5VsXV4da9Eb4kap9V9fKVjjp0MwRkXX/dh0RQzhP5dKFrzL0u8GXnCU12sX2Hwr8AR/Xqy1XVvFHP2kgpT7qxxczZIyyc2c2AdjBSOylVJC/WUwitdht/aWYIZeW5jBLpFWJ4FvY57RQ+ktQDTuTKPQq5eZ2i3fQMOtynAPVuaQWezxyf+zSuI4zwDzPenBer1DeXE/ZwdnPaczE691KlkxjdnjLn+fAmOUDuiWj85gjzEMbriguVH8z/uCbkt78pgiF5XU6D3tjD+DFRUvNiRKJ7rqTJwVCKCoJyggG2gWWA+ijl6TCO6fUJff63UG+Bxp76Jfj5sLdkKQYcMVNLuQEv0ZlL+rpsm19GdsXHO5hhZVaOkp1bIZXcgusiUr6HB6evex8r40cCq22WUV/hE+RzdkLM63Igubti5FvBTqFQrgt8dk48y8OuQokdmuGpbhtyeDT4zXz9+FoBl8BxyqXGy4JqdEOnlgJlXtNM3cAvpqR0wnK9sxM6/LWOdlTVBCBFqE5zPOm8SihHazugWd6zb8ryQEuESCi9bzCpba4DVhRjopzodc06bBNISuBQjZ5Y/Dv6oi6QKZf63JQYfQ/now6Ct32qVWGNA050Gc2/3elj+G2tGsTg2+kEhCygKenN4hUWFx3E8Vrgp1H2s= 7 | # before_install: 8 | # - echo $HOME 9 | # - wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh 10 | # - chmod +x miniconda.sh 11 | # - bash miniconda.sh -b -p $HOME/miniconda 12 | # - export PATH="$HOME/miniconda/bin:$PATH" 13 | # - conda install -y -c anaconda python=3.6 14 | # - conda config --set always_yes true --set changeps1 no 15 | # - conda update -q conda 16 | # - conda install -y conda-build 17 | # - conda install -y anaconda-client 18 | # install: 19 | # - pip install . 20 | # - pip install tqdm 21 | # - pip install -r requirements.txt 22 | # - pip install pytest pytest-cov 23 | # script: 24 | # - chmod +x deploy_conda.sh 25 | # after_success: 26 | # - echo "Tests completed successfully!" 27 | # after_failure: 28 | # - echo "Some test cases failed!" 29 | # jobs: 30 | # include: 31 | # - stage: "Uplaoding to PyPI" 32 | # name: "Uploadig tested imdlib to pypi" 33 | # script: 34 | # - python -c "print('Hi from Python!')" 35 | # deploy: 36 | # - provider: pypi 37 | # github-token: $GITHUB_TOKEN 38 | # user: __token__ 39 | # password: 40 | # secure: OBc3A5ev15krWGKKApUjjE8pYNmEI3h3A/OXcc/KlnlW7MBksvrgzNPXbEhaUJ1/cYyzCAxJhOozFP8HO0Np80KkXZt26MCohhBTpDTcnzOm0JpE+wZBg+FQCRXNuELkwNj7B3mlrgZcXys3/qyjQ8CyqIg/4MAejIS/M7yPFgocJ+wdYlLPR4Q3GdnVoIv2X2GScPUFybpQ9PKxgZaB83amhXDKlphzFmxPoHIsak2fKZ7wbzFfWGRHL1pqk897fV+WSm+Oc4086NSYg+1pq5v45hCo3c5EGhdXf94Om554YDZd/YEq+EVzvHJ3noijjFFR1F51R9s5CBlObpV+WIF2xJRGm58oI3YkwSrNpLYKiNSUjqLgcLguMhwk+1VUCyCIrK2tOY2kAeXiBJgORl+MOigr66nJhGmNjdOVZ0ALputHHtz+4FqayFNR6fWvtnrS9O9NQtq9q5NZ4rQD90+ZOPcFrD87HujWL1aZGPfZt0IXlZQKTl5owV5JKKcMDIi7e8s9WwYX/IuG27yNLmbcb1I3K/nAS3B4Zg4ZCXqkbXBJekpPSVuYszFUlywzZmV8KqB5aYkBsur+n9FYkUuSGO7RlgwYPRnie6qSK1hXTWrZo0QsiDfhzwlw0rXiJxI2qF3/JDj39CJ1PeLvH5G9UnOJdINXKCBz7vgxoy4= 41 | # on: 42 | # tags: false 43 | # python: 3.6 44 | # - stage: "Upload to Ananconda" 45 | # name: "upload latest pypi to Anacoonda" 46 | # script: 47 | # - bash deploy_conda.sh -------------------------------------------------------------------------------- /.pre-commit-config.yaml: -------------------------------------------------------------------------------- 1 | # See: https://pre-commit.com/hooks.html 2 | # Must put flake8 in separate group so 'black' is executed first 3 | # WARNING: Make sure to keep flags in sync with ci/run-linter.sh 4 | repos: 5 | - repo: https://github.com/pre-commit/pre-commit-hooks 6 | rev: v3.1.0 7 | hooks: 8 | - id: no-commit-to-branch 9 | - id: double-quote-string-fixer 10 | - id: check-docstring-first 11 | - id: check-merge-conflict 12 | - id: end-of-file-fixer 13 | - id: trailing-whitespace 14 | 15 | # apply after format() kwargs broken up into setters 16 | # - repo: https://github.com/ambv/black 17 | # rev: 19.10 18 | # hooks: 19 | # - id: black 20 | # args: ['--line-length', '88', '--skip-string-normalization'] 21 | 22 | - repo: https://github.com/pre-commit/mirrors-isort 23 | rev: v4.3.21 24 | hooks: 25 | - id: isort 26 | args: ['--line-width=88', '--multi-line=3', '--force-grid-wrap=0', '--trailing-comma'] 27 | exclude: '^docs/' 28 | 29 | - repo: https://github.com/PyCQA/flake8 30 | rev: 3.8.3 31 | hooks: 32 | - id: flake8 33 | args: ['--max-line-length=88', '--ignore=W503,E402,E741'] 34 | 35 | # apply once this handles long tables better 36 | # - repo: https://github.com/PyCQA/doc8 37 | # rev: 0.8.1 38 | # hooks: 39 | # - id: doc8 40 | # args: ['--max-line-length', '88', '--allow-long-titles'] 41 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) [2019-2020] [Saswata Nandi] 4 | 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in all 14 | copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 22 | SOFTWARE. -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | # Minimal makefile for Sphinx documentation 2 | # 3 | 4 | # You can set these variables from the command line, and also 5 | # from the environment for the first two. 6 | SPHINXOPTS ?= 7 | SPHINXBUILD ?= sphinx-build 8 | SOURCEDIR = source 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) 21 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # imdlib 2 | [![Build Status](https://github.com/iamsaswata/imdlib/actions/workflows/pypi.yml/badge.svg)](https://github.com/iamsaswata/imdlib/actions/workflows/pypi.yml) 3 | ![GitHub](https://img.shields.io/github/license/iamsaswata/imdlib) 4 | ![PyPI](https://img.shields.io/pypi/v/imdlib) 5 | ![Conda](https://img.shields.io/conda/v/iamsaswata/imdlib) 6 | [![Downloads](https://pepy.tech/badge/imdlib)](https://pepy.tech/project/imdlib) 7 | 8 | 9 | This is a python package to download and handle binary grided data from Indian Meterological department (IMD). 10 | 11 | ## Installation 12 | 13 | > pip install imdlib 14 | 15 | or 16 | 17 | > conda install -c iamsaswata imdlib 18 | 19 | or 20 | 21 | > pip install git+https://github.com/iamsaswata/imdlib.git 22 | 23 | 24 | ## Documentation 25 | 26 | [Tutorial](https://saswatanandi.github.io/softwares/imdlib) 27 | [Tutorial](https://pratiman-91.github.io/blog.html) 28 | 29 | ## Video Tutorial 30 | 31 | [![IMDLIB - Albedo Foundation](https://img.youtube.com/vi/uSIPPY5WRaM/0.jpg)](https://www.youtube.com/watch?v=uSIPPY5WRaM) 32 | 33 | ## License 34 | 35 | imdlib is available under the [MIT](https://opensource.org/licenses/MIT) license. 36 | 37 | ## Citation 38 | 39 | If you are using imdlib and would like to cite it in academic publication, we would certainly appreciate it. We recommend to use one of these two DOIs for this purpose: 40 | 41 | Nandi, S., Patel, P., and Swain, S. (2024). IMDLIB: An open-source library for retrieval, processing and spatiotemporal exploratory assessments of gridded meteorological observation datasets over India. *Environmental Modelling and Software*, 71 (105869), [[DOI]](https://doi.org/10.1016/j.envsoft.2023.105869) 42 | 43 | Nandi, S., Patel, P., and Swain, S. (2022). IMDLIB: A python library for IMD gridded data. Zenodo. [[DOI]](https://doi.org/10.5281/zenodo.7205414) 44 | 45 | [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.7205414.svg)](https://doi.org/10.5281/zenodo.7205414) 46 | 47 | ## Publications using IMDLIB 48 | 49 | Swain, S., Mishra, P.K., Nandi, S., Pradhan, B., Sahoo, S., Al-Ansari, A. (2024). A simplistic approach for monitoring meteorological drought over arid regions: a case study of Rajasthan, India. *Applied Water Science*, 14, 36. [[DOI]](https://doi.org/10.1007/s13201-023-02085-z) 50 | 51 | Jaiswal, S., Balietti, A., & Schäffer, D. (2023). Environmental Protection and Labor Market Composition. *University of Heidelberg, Department of Economics* [[DOI]](https://doi.org/10.11588/heidok.00033831) 52 | 53 | Pandey, H.K., Singh, V.K., Singh, R.P. et al. (2023). Soil Loss Estimation Using RUSLE in Hard Rock Terrain: a Case Study of Bundelkhand, India. *Water Conserv Sci Eng 8*, 55. [[DOI]](https://doi.org/10.1007/s41101-023-00229-5) 54 | 55 | Vage, S., Gupta, T., Roy, S. (2023). Impact Analysis of Climate Change on Floods in an Indian Region Using Machine Learning. *In: ICANN 2023*, 14261. [[DOI]](https://doi.org/10.1007/978-3-031-44198-1_31) 56 | 57 | Garg, N., Negi, S., Nagar, R., Rao, S., & KR, S. (2023). Multivariate multi-step LSTM model for flood runoff prediction: a case study on the Godavari River Basin in India. *Journal of Water and Climate Change*, [[DOI]](https://doi.org/10.2166/wcc.2023.374) 58 | 59 | Bora, S., & Hazarika, A. (2023). Rainfall time series forecasting using ARIMA model. In 2023 ATCON-1, (pp. 1-5). *IEEE*, [[DOI]](https://doi.org/10.1109/ICAIA57370.2023.10169493) 60 | 61 | Panja, A., Garai, S., Zade, S., Veldandi, A., Sahani, S., & Maiti, S. (2023). Climate Data Extraction for Social Science Research: A Step by Step Process. *Social Science Dimensions of Climate Resilient Agriculture*, [[ISBN]](https://www.researchgate.net/profile/Sanjit-Maiti/publication/372909405_Social_Science_Dimensions_of_Climate_Resilient_Agriculture/links/64cd3c4191fb036ba6c6d311/Social-Science-Dimensions-of-Climate-Resilient-Agriculture.pdf#page=57) (ISBN: 978-81-964762-1-2) 62 | 63 | Chakra, S., Ganguly, A., Oza, H., Padhya, V., Pandey, A., & Deshpande, R. D. (2023). Multidecadal summer monsoon rainfall trend reversals in South Peninsular India: a new approach to examining long-term rainfall dataset. *Journal of Hydrology*, [[DOI]](https://doi.org/10.1016/j.jhydrol.2023.129975). 64 | 65 | Sardar, P., and Samadder, S. R. (2023).  Long-term ecological vulnerability assessment of indian sundarban region under present and future climatic conditions under CMIP6 model. *Ecological Informatics*. [[DOI]](https://doi.org/10.1016/j.ecoinf.2023.102140) 66 | 67 | Roy, P. K., Ghosh, A., Basak, S. K., Mohinuddin, S., & Roy M. B. (2023).  Analysing the Role of AHP Model to Identify Flood Hazard Zonation in a Coastal Island, India. *Journal of the Indian Society of Remote Sensing Article*, 1-15. [[DOI]](https://doi.org/10.1007/s12524-023-01697-x) 68 | 69 | Kundu, M., Zafor, A., & Maiti, R. (2023). Assessing the nature of potential groundwater zones through machine learning (ML) algorithm in tropical plateau region, West Bengal, India. *Acta Geophysica*, 1-16. [[DOI]](https://doi.org/10.1007/s11600-023-01042-3) 70 | 71 | Venkatesh, S., Kirubakaran, T., Ayaz, R. M., Umar, S. M., & Parimalarenganayaki, S. (2023). Non-parametric Approaches to Identify Rainfall Pattern in Semi-Arid Regions: Ranipet, Vellore, and Tirupathur Districts, Tamil Nadu, India. *In River Dynamics and Flood Hazards* (pp. 507-525). Springer, Singapore. [[DOI]](https://doi.org/10.1007/978-981-19-7100-6_28) 72 | 73 | Swain, S., Mishra, S. K., Pandey, A., & Dayal, D. (2022). Assessment of drought trends and variabilities over the agriculture-dominated Marathwada Region, India. *Environmental Monitoring and Assessment, 194(12)*, 1-18. 74 | [[DOI]](https://doi.org/10.1007/s10661-022-10532-8) 75 | 76 | Swain, S., Mishra, S. K., Pandey, A., Dayal, D., & Srivastava, P. K. (2022). Appraisal of historical trends in maximum and minimum temperature using multiple non-parametric techniques over the agriculture-dominated Narmada Basin, India. *Environmental Monitoring and Assessment*, 194(12), 1-23. [[DOI]](https://doi.org/10.1007/s10661-022-10534-6) 77 | -------------------------------------------------------------------------------- /conda/meta.yaml: -------------------------------------------------------------------------------- 1 | package: 2 | version: {{ environ['VERSION'] }} 3 | build: 4 | script_env: 5 | - VERSION 6 | - CONDA_BLD_PATH -------------------------------------------------------------------------------- /conda/requirements.yml: -------------------------------------------------------------------------------- 1 | name: test_env 2 | channels: 3 | - conda-forge 4 | dependencies: 5 | - python=3.6 6 | - conda-build 7 | - anaconda-client 8 | - numpy 9 | - pandas 10 | - matplotlib 11 | - scipy 12 | - xarray 13 | - six 14 | - pytz 15 | - pip 16 | - pip: 17 | - tqdm 18 | - pytest 19 | - pytest-cov 20 | - motionless 21 | - python-dateutil 22 | - certifi 23 | -------------------------------------------------------------------------------- /deploy_conda.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | echo "========================" 3 | echo "========================" 4 | echo "Showing home directory" 5 | echo $HOME 6 | ls 7 | echo "========================" 8 | 9 | echo "========================" 10 | echo "Downaloading miniconda" 11 | wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh 12 | ls 13 | echo "========================" 14 | 15 | echo "========================" 16 | echo "========================" 17 | echo "Setting up miniconda" 18 | chmod +x miniconda.sh 19 | bash miniconda.sh -b -p $HOME/miniconda 20 | export PATH="$HOME/miniconda/bin:$PATH" 21 | echo "========================" 22 | 23 | 24 | echo "========================" 25 | echo "========================" 26 | echo "Update miniconda" 27 | conda install -y -c conda-forge python=3.10 28 | conda config --set always_yes true --set changeps1 no 29 | # conda update -q conda 30 | conda install -y conda-build 31 | conda install -y anaconda-client 32 | echo "========================" 33 | 34 | echo "========================" 35 | echo "========================" 36 | echo "install requirements.tt" 37 | pip install -r requirements.txt 38 | echo "========================" 39 | 40 | 41 | echo "========================" 42 | echo "======================" 43 | # change the package name to the existing PyPi package you would like to build 44 | pkg='imdlib' 45 | echo $PWD 46 | array=( 3.10 ) 47 | echo "Building conda package ..." 48 | cd ~ 49 | echo $PWD 50 | # conda skeleton pypi $pkg 51 | # KeyError: 'extras_require' 52 | # https://github.com/conda/conda-build/issues/4354 53 | conda skeleton pypi $pkg --python-version 3.6 54 | cd $pkg 55 | echo $PWD 56 | cd ~ 57 | echo "======================" 58 | 59 | 60 | echo "========================" 61 | echo "======================" 62 | echo "Building conda packages" 63 | 64 | echo $PWD 65 | for i in "${array[@]}" 66 | do 67 | conda-build --python $i $pkg 68 | done 69 | echo "========================" 70 | 71 | 72 | 73 | # convert package to other platforms 74 | echo "=========================" 75 | echo "Converting conda packages" 76 | echo "=========================" 77 | cd ~ 78 | echo $PWD 79 | platforms=( linux-64 win-64 ) 80 | find $HOME/miniconda/conda-bld/linux-64/ -name *.tar.bz2 | while read file 81 | do 82 | echo $file 83 | #conda convert --platform all $file -o $HOME/conda-bld/ 84 | for platform in "${platforms[@]}" 85 | do 86 | conda convert --platform $platform $file -o $HOME/miniconda/conda-bld/ 87 | done 88 | done 89 | echo "=========================" 90 | echo "Converting finished" 91 | echo "=========================" 92 | 93 | 94 | echo "=========================" 95 | echo "Uploading conda packages" 96 | echo "=========================" 97 | find $HOME/miniconda/conda-bld/ -name *.tar.bz2 | while read file 98 | do 99 | echo $file 100 | anaconda -t $ANACONDA_TOKEN upload $file 101 | done 102 | echo "Building conda package done!" 103 | echo "===================================" 104 | echo "Succeessful submission to anaconda" 105 | echo "===================================" 106 | -------------------------------------------------------------------------------- /docs/Description.rst: -------------------------------------------------------------------------------- 1 | Description 2 | =========== 3 | 4 | IMDLIB is a python package to download and handle binary gridded data from the India Meteorological Department (IMD). For more information about the IMD datasets, check the following link: `IMD Pune`_. 5 | 6 | .. _IMD Pune: https://imdpune.gov.in/Clim_Pred_LRF_New/Grided_Data_Download.html 7 | 8 | Installation 9 | ============ 10 | 11 | IMDLIB is tested for both Windows and Linux platforms with 64-bit architecture. 12 | 13 | We recommend ‘Conda’ to install IMDLIB. 14 | 15 | .. code-block:: bash 16 | 17 | conda install -c iamsaswata imdlib 18 | 19 | Installation using pip: 20 | 21 | .. code-block:: bash 22 | 23 | pip install imdlib 24 | 25 | Installation from source/development version: 26 | 27 | .. code-block:: bash 28 | 29 | pip install git+https://github.com/iamsaswata/imdlib.git 30 | 31 | Dependency 32 | ------------ 33 | You need to have a python version 3.5 or higher for using IMDLIB. If you install IMDLIB from the source, the following plugins should be pre-installed. 34 | 35 | .. list-table:: 36 | :widths: 20 20 37 | :header-rows: 1 38 | 39 | * - Packages 40 | - version 41 | * - certifi 42 | - [2019.11.28] 43 | * - matplotlib 44 | - [3.1.3] 45 | * - numpy 46 | - [1.18.1] 47 | * - pandas 48 | - [0.25.3] 49 | * - python-dateutil 50 | - [ 2.8.1 ] 51 | * - pytest 52 | - [5.3.4] 53 | * - pytz 54 | - [ 2019.3] 55 | * - urllib3 56 | - [1.25.0] 57 | * - scipy 58 | - [1.4.1] 59 | * - six 60 | - [1.14.0] 61 | * - xarray 62 | - [0.14.1] 63 | * - rioxarray (optional) 64 | - [0.1.1] 65 | -------------------------------------------------------------------------------- /docs/Makefile: -------------------------------------------------------------------------------- 1 | # Minimal makefile for Sphinx documentation 2 | # 3 | 4 | # You can set these variables from the command line, and also 5 | # from the environment for the first two. 6 | SPHINXOPTS ?= 7 | SPHINXBUILD ?= sphinx-build 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) 21 | -------------------------------------------------------------------------------- /docs/Usage.rst: -------------------------------------------------------------------------------- 1 | Downloading 2 | =========== 3 | 4 | IMDLIB is capable of downloading gridded rainfall and temperature (minimum and maximum) data. Here is an example of downloading rainfall data from 2010 to 2018: 5 | 6 | .. code-block:: python 7 | 8 | import imdlib as imd 9 | 10 | start_yr = 2010 11 | end_yr = 2018 12 | variable = 'rain' # other options are ('tmin'/ 'tmax') 13 | data = imd.get_data(variable, start_yr, end_yr, fn_format='yearwise') 14 | 15 | Output 16 | ------ 17 | 18 | .. code-block:: text 19 | 20 | Downloading: rain for year 2010 21 | Downloading: rain for year 2011 22 | Downloading: rain for year 2012 23 | Downloading: rain for year 2013 24 | Downloading: rain for year 2014 25 | Downloading: rain for year 2015 26 | Downloading: rain for year 2016 27 | Downloading: rain for year 2017 28 | Downloading: rain for year 2018 29 | Download Successful !!! 30 | 31 | The output is saved in the current working directory. If you want to save the files to a different directory, then you can use the following code: 32 | 33 | .. code-block:: python 34 | 35 | import imdlib as imd 36 | 37 | start_yr = 2010 38 | end_yr = 2018 39 | variable = 'rain' # other options are ('tmin'/ 'tmax') 40 | file_dir = (r'C:\Users\imdlib\Desktop\\') #Path to save the files 41 | imd.get_data(variable, start_yr, end_yr, fn_format='yearwise', file_dir=file_dir) 42 | 43 | Reading IMD datasets 44 | ==================== 45 | 46 | One of the major purposes of IMDLIB is to process IMD’s gridded datasets. The original data is available in ``grd`` file format. IMDLIB can read ``grd`` file in ``xarray`` and will create an ``IMD class object``. 47 | 48 | .. code-block:: python 49 | 50 | import imdlib as imd 51 | 52 | start_yr = 2010 53 | end_yr = 2018 54 | variable = 'rain' # other options are ('tmin'/ 'tmax') 55 | file_dir = (r'C:\Users\imdlib\Desktop\\') #Path to save the files 56 | data = imd.open_data(variable, start_yr, end_yr,'yearwise', file_dir) 57 | data 58 | 59 | .. [*] This step is for reading IMD datasets after they are downloaded. If you have the data already downloaded and stored locally, you can directly use this step to read the datasets. 60 | 61 | Output 62 | ------ 63 | 64 | ```` 65 | 66 | - ``file_dir`` should refer to top-level directory. It should contain 3 sub-directories ``rain``, ``tmin``, and ``tmax``. 67 | 68 | - If ``file_dir`` exists without any subdirectory, IMDLIB will look for the files in ``file_dir``. But be careful if you are using ``file_format = ‘yearwise’``, as it will not differentiate between the datasets, ``2018.grd`` for rainfall and ``2018.grd`` for tmin. 69 | 70 | - If ``file_dir`` is not given, it will look for the adatasets from the current directory and its subdirectories. 71 | 72 | Processing 73 | ========== 74 | 75 | Getting the xarray object for further processing: 76 | 77 | .. code-block:: python 78 | 79 | ds = data.get_xarray() 80 | print(ds) 81 | 82 | .. code-block:: python 83 | 84 | 85 | Dimensions: (lat: 129, lon: 135, time: 3287) 86 | Coordinates: 87 | * lat (lat) float64 6.5 6.75 7.0 7.25 7.5 ... 37.5 37.75 38.0 38.25 38.5 88 | * lon (lon) float64 66.5 66.75 67.0 67.25 67.5 ... 99.25 99.5 99.75 100.0 89 | * time (time) datetime64[ns] 2010-01-01 2010-01-02 ... 2018-12-31 90 | Data variables: 91 | rain (time, lat, lon) float64 -999.0 -999.0 -999.0 ... -999.0 -999.0 92 | Attributes: 93 | Conventions: CF-1.7 94 | title: IMD gridded data 95 | source: https://imdpune.gov.in/ 96 | history: 2021-02-27 08:10:43.519783 Python 97 | references: 98 | comment: 99 | crs: epsg:4326 100 | 101 | 102 | Plotting 103 | ======== 104 | 105 | Plotting can be done by: 106 | 107 | .. code-block:: python 108 | 109 | ds = ds.where(ds['rain'] != -999.) #Remove NaN values 110 | ds['rain'].mean('time').plot() 111 | 112 | .. image:: savefig/fig1.png 113 | :width: 400 114 | 115 | 116 | Saving 117 | ====== 118 | 119 | Get data for a given location, convert, and save into csv file: 120 | 121 | .. code-block:: python 122 | 123 | lat = 20.03 124 | lon = 77.23 125 | data.to_csv('test.csv', lat, lon, file_dir) 126 | 127 | Save data in netCDF format: 128 | 129 | .. code-block:: python 130 | 131 | data.to_netcdf('test.nc', file_dir) 132 | 133 | Save data in GeoTIFF format (if you have rioxarray library): 134 | 135 | .. code-block:: python 136 | 137 | data.to_geotiff('test.tif', file_dir) 138 | 139 | 140 | Gridded Data Real Time 141 | ====================== 142 | 143 | Now IMDLIB can process Gridded (daily) Real Time data (Rainfall at 0.25\ :sup:`o`\ & Temperature at 0.5\ :sup:`o`\ spatial resolution) 144 | 145 | Downloading 146 | ----------- 147 | 148 | The steps are similar to the data downloading and opening of IMD gridded archive data 149 | 150 | An example is presented below. 151 | 152 | .. code-block:: python 153 | 154 | import imdlib as imd 155 | start_dy = '2020-01-31' 156 | end_dy = '2020-03-05' 157 | var_type = 'rain' 158 | file_dir='../data' 159 | data = imd.get_real_data(var_type, start_dy, end_dy, file_dir) 160 | 161 | Output 162 | ------ 163 | 164 | .. code-block:: text 165 | 166 | Downloading: rain for date 2020-01-31 167 | Downloading: rain for date 2020-02-01 168 | Downloading: rain for date 2020-02-02 169 | Downloading: rain for date 2020-02-03 170 | Downloading: rain for date 2020-02-04 171 | Downloading: rain for date 2020-02-05 172 | Downloading: rain for date 2020-02-06 173 | Downloading: rain for date 2020-02-07 174 | Downloading: rain for date 2020-02-08 175 | Downloading: rain for date 2020-02-09 176 | Downloading: rain for date 2020-02-10 177 | Downloading: rain for date 2020-02-11 178 | Downloading: rain for date 2020-02-12 179 | Downloading: rain for date 2020-02-13 180 | Downloading: rain for date 2020-02-14 181 | Downloading: rain for date 2020-02-15 182 | Downloading: rain for date 2020-02-16 183 | Downloading: rain for date 2020-02-17 184 | Downloading: rain for date 2020-02-18 185 | Downloading: rain for date 2020-02-19 186 | Downloading: rain for date 2020-02-20 187 | Downloading: rain for date 2020-02-21 188 | Downloading: rain for date 2020-02-22 189 | Downloading: rain for date 2020-02-23 190 | Downloading: rain for date 2020-02-24 191 | Downloading: rain for date 2020-02-25 192 | Downloading: rain for date 2020-02-26 193 | Downloading: rain for date 2020-02-27 194 | Downloading: rain for date 2020-02-28 195 | Downloading: rain for date 2020-02-29 196 | Downloading: rain for date 2020-03-01 197 | Downloading: rain for date 2020-03-02 198 | Downloading: rain for date 2020-03-03 199 | Downloading: rain for date 2020-03-04 200 | Downloading: rain for date 2020-03-05 201 | Download Successful !!! 202 | 203 | Reading 204 | ------- 205 | 206 | If the data is already downloaded. Read the real time gridded data. 207 | 208 | .. code-block:: python 209 | 210 | import imdlib as imd 211 | start_dy = '2020-01-31' 212 | end_dy = '2020-03-05' 213 | var_type = 'rain' 214 | file_dir='../data' 215 | data = imd.open_real_data(var_type, start_dy, end_dy, file_dir) 216 | 217 | 218 | Climate Indices 219 | =============== 220 | 221 | Available cliimate indices are listed in a Table at the reference section of this documentation. 222 | 223 | An example of computing heavy precipitation days between year 2015 and 2019 is as follows: 224 | 225 | .. code-block:: python 226 | 227 | import imdlib as imd 228 | start_yr, end_yr = 2015, 2019 229 | variable = 'rain' 230 | rain = imd.get_data(variable, start_yr, end_yr,'yearwise', '../data') 231 | d64 = rain.compute('d64', 'A', threshold=64.5) 232 | -------------------------------------------------------------------------------- /docs/_build/doctrees/Description.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/Description.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/Installation.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/Installation.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/Usage.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/Usage.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/api.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/api.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/api/imdlib.core.IMD.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/api/imdlib.core.IMD.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/api/imdlib.core.get_data.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/api/imdlib.core.get_data.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/api/imdlib.core.open_data.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/api/imdlib.core.open_data.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/api/imdlib.util.LeapYear.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/api/imdlib.util.LeapYear.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/api/imdlib.util.get_filename.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/api/imdlib.util.get_filename.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/api/imdlib.util.get_lat_lon.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/api/imdlib.util.get_lat_lon.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/api/imdlib.util.total_days.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/api/imdlib.util.total_days.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/authors.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/authors.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/cf-conventions.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/cf-conventions.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/changelog.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/changelog.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/contributions.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/contributions.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/environment.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/environment.pickle -------------------------------------------------------------------------------- /docs/_build/doctrees/external-links.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/external-links.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/faq.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/faq.doctree -------------------------------------------------------------------------------- /docs/_build/doctrees/index.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/doctrees/index.doctree -------------------------------------------------------------------------------- /docs/_build/html/.buildinfo: -------------------------------------------------------------------------------- 1 | # Sphinx build info version 1 2 | # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. 3 | config: 949b6136828ea04532ad6efff9d36a78 4 | tags: 645f666f9bcd5a90fca523b33c5a78b7 5 | -------------------------------------------------------------------------------- /docs/_build/html/.doctrees/Description.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/.doctrees/Description.doctree -------------------------------------------------------------------------------- /docs/_build/html/.doctrees/Installation.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/.doctrees/Installation.doctree -------------------------------------------------------------------------------- /docs/_build/html/.doctrees/Usage.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/.doctrees/Usage.doctree -------------------------------------------------------------------------------- /docs/_build/html/.doctrees/authors.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/.doctrees/authors.doctree -------------------------------------------------------------------------------- /docs/_build/html/.doctrees/cf-conventions.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/.doctrees/cf-conventions.doctree -------------------------------------------------------------------------------- /docs/_build/html/.doctrees/changelog.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/.doctrees/changelog.doctree -------------------------------------------------------------------------------- /docs/_build/html/.doctrees/contributions.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/.doctrees/contributions.doctree -------------------------------------------------------------------------------- /docs/_build/html/.doctrees/environment.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/.doctrees/environment.pickle -------------------------------------------------------------------------------- /docs/_build/html/.doctrees/external-links.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/.doctrees/external-links.doctree -------------------------------------------------------------------------------- /docs/_build/html/.doctrees/faq.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/.doctrees/faq.doctree -------------------------------------------------------------------------------- /docs/_build/html/.doctrees/index.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/.doctrees/index.doctree -------------------------------------------------------------------------------- /docs/_build/html/Installation.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | <no title> — imdlib documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 | 47 | 95 | 96 |
97 | 98 | 99 | 105 | 106 | 107 |
108 | 109 |
110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 127 |
128 | 129 |
    130 | 131 |
  • »
  • 132 | 133 |
  • <no title>
  • 134 | 135 | 136 |
  • 137 | 138 | 139 | View page source 140 | 141 | 142 |
  • 143 | 144 |
145 | 146 | 147 |
148 |
149 |
150 |
151 | 152 | 153 | 154 |
155 | 156 |
157 |
158 | 159 | 165 | 166 | 167 |
168 | 169 |
170 |

171 | 172 | © Copyright 2020, Saswata Nandi and Pratiman Patel 173 | 174 |

175 |
176 | 177 | 178 | 179 | Built with Sphinx using a 180 | 181 | theme 182 | 183 | provided by Read the Docs. 184 | 185 |
186 | 187 |
188 |
189 | 190 |
191 | 192 |
193 | 194 | 195 | 200 | 201 | 202 | 203 | 204 | 205 | 206 | 207 | -------------------------------------------------------------------------------- /docs/_build/html/_images/fig1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_images/fig1.png -------------------------------------------------------------------------------- /docs/_build/html/_images/fig2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_images/fig2.jpg -------------------------------------------------------------------------------- /docs/_build/html/_sources/Description.rst.txt: -------------------------------------------------------------------------------- 1 | Description 2 | =========== 3 | 4 | IMDLIB is a python package to download and handle binary gridded data from the India Meteorological Department (IMD). For more information about the IMD datasets, check the following link: `IMD Pune`_. 5 | 6 | .. _IMD Pune: https://imdpune.gov.in/Clim_Pred_LRF_New/Grided_Data_Download.html 7 | 8 | Installation 9 | ============ 10 | 11 | IMDLIB is tested for both Windows and Linux platforms with 64-bit architecture. 12 | 13 | We recommend ‘Conda’ to install IMDLIB. 14 | 15 | .. code-block:: bash 16 | 17 | conda install -c iamsaswata imdlib 18 | 19 | Installation using pip: 20 | 21 | .. code-block:: bash 22 | 23 | pip install imdlib 24 | 25 | Installation from source/development version: 26 | 27 | .. code-block:: bash 28 | 29 | pip install git+https://github.com/iamsaswata/imdlib.git 30 | 31 | Dependency 32 | ------------ 33 | You need to have a python version 3.5 or higher for using IMDLIB. If you install IMDLIB from the source, the following plugins should be pre-installed. 34 | 35 | .. list-table:: 36 | :widths: 20 20 37 | :header-rows: 1 38 | 39 | * - Packages 40 | - version 41 | * - certifi 42 | - [2019.11.28] 43 | * - matplotlib 44 | - [3.1.3] 45 | * - numpy 46 | - [1.18.1] 47 | * - pandas 48 | - [0.25.3] 49 | * - python-dateutil 50 | - [ 2.8.1 ] 51 | * - pytest 52 | - [5.3.4] 53 | * - pytz 54 | - [ 2019.3] 55 | * - urllib3 56 | - [1.25.0] 57 | * - scipy 58 | - [1.4.1] 59 | * - six 60 | - [1.14.0] 61 | * - xarray 62 | - [0.14.1] 63 | * - rioxarray (optional) 64 | - [0.1.1] 65 | -------------------------------------------------------------------------------- /docs/_build/html/_sources/Installation.rst.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_sources/Installation.rst.txt -------------------------------------------------------------------------------- /docs/_build/html/_sources/Usage.rst.txt: -------------------------------------------------------------------------------- 1 | Downloading 2 | =========== 3 | 4 | IMDLIB is capable of downloading gridded rainfall and temperature (minimum and maximum) data. Here is an example of downloading rainfall data from 2010 to 2018: 5 | 6 | .. code-block:: python 7 | 8 | import imdlib as imd 9 | 10 | start_yr = 2010 11 | end_yr = 2018 12 | variable = 'rain' # other options are ('tmin'/ 'tmax') 13 | data = imd.get_data(variable, start_yr, end_yr, fn_format='yearwise') 14 | 15 | Output 16 | ------ 17 | 18 | .. code-block:: text 19 | 20 | Downloading: rain for year 2010 21 | Downloading: rain for year 2011 22 | Downloading: rain for year 2012 23 | Downloading: rain for year 2013 24 | Downloading: rain for year 2014 25 | Downloading: rain for year 2015 26 | Downloading: rain for year 2016 27 | Downloading: rain for year 2017 28 | Downloading: rain for year 2018 29 | Download Successful !!! 30 | 31 | The output is saved in the current working directory. If you want to save the files to a different directory, then you can use the following code: 32 | 33 | .. code-block:: python 34 | 35 | import imdlib as imd 36 | 37 | start_yr = 2010 38 | end_yr = 2018 39 | variable = 'rain' # other options are ('tmin'/ 'tmax') 40 | file_dir = (r'C:\Users\imdlib\Desktop\\') #Path to save the files 41 | imd.get_data(variable, start_yr, end_yr, fn_format='yearwise', file_dir=file_dir) 42 | 43 | Reading IMD datasets 44 | ==================== 45 | 46 | One of the major purposes of IMDLIB is to process IMD’s gridded datasets. The original data is available in ``grd`` file format. IMDLIB can read ``grd`` file in ``xarray`` and will create an ``IMD class object``. 47 | 48 | .. code-block:: python 49 | 50 | import imdlib as imd 51 | 52 | start_yr = 2010 53 | end_yr = 2018 54 | variable = 'rain' # other options are ('tmin'/ 'tmax') 55 | file_dir = (r'C:\Users\imdlib\Desktop\\') #Path to save the files 56 | data = imd.open_data(variable, start_yr, end_yr,'yearwise', file_dir) 57 | data 58 | 59 | .. [*] This step is for reading IMD datasets after they are downloaded. If you have the data already downloaded and stored locally, you can directly use this step to read the datasets. 60 | 61 | Output 62 | ------ 63 | 64 | ```` 65 | 66 | - ``file_dir`` should refer to top-level directory. It should contain 3 sub-directories ``rain``, ``tmin``, and ``tmax``. 67 | 68 | - If ``file_dir`` exists without any subdirectory, IMDLIB will look for the files in ``file_dir``. But be careful if you are using ``file_format = ‘yearwise’``, as it will not differentiate between the datasets, ``2018.grd`` for rainfall and ``2018.grd`` for tmin. 69 | 70 | - If ``file_dir`` is not given, it will look for the adatasets from the current directory and its subdirectories. 71 | 72 | Processing 73 | ========== 74 | 75 | Getting the xarray object for further processing: 76 | 77 | .. code-block:: python 78 | 79 | ds = data.get_xarray() 80 | print(ds) 81 | 82 | .. code-block:: python 83 | 84 | 85 | Dimensions: (lat: 129, lon: 135, time: 3287) 86 | Coordinates: 87 | * lat (lat) float64 6.5 6.75 7.0 7.25 7.5 ... 37.5 37.75 38.0 38.25 38.5 88 | * lon (lon) float64 66.5 66.75 67.0 67.25 67.5 ... 99.25 99.5 99.75 100.0 89 | * time (time) datetime64[ns] 2010-01-01 2010-01-02 ... 2018-12-31 90 | Data variables: 91 | rain (time, lat, lon) float64 -999.0 -999.0 -999.0 ... -999.0 -999.0 92 | Attributes: 93 | Conventions: CF-1.7 94 | title: IMD gridded data 95 | source: https://imdpune.gov.in/ 96 | history: 2021-02-27 08:10:43.519783 Python 97 | references: 98 | comment: 99 | crs: epsg:4326 100 | 101 | 102 | Plotting 103 | ======== 104 | 105 | Plotting can be done by: 106 | 107 | .. code-block:: python 108 | 109 | ds = ds.where(ds['rain'] != -999.) #Remove NaN values 110 | ds['rain'].mean('time').plot() 111 | 112 | .. image:: savefig/fig1.png 113 | :width: 400 114 | 115 | 116 | Saving 117 | ====== 118 | 119 | Get data for a given location, convert, and save into csv file: 120 | 121 | .. code-block:: python 122 | 123 | lat = 20.03 124 | lon = 77.23 125 | data.to_csv('test.csv', lat, lon, file_dir) 126 | 127 | Save data in netCDF format: 128 | 129 | .. code-block:: python 130 | 131 | data.to_netcdf('test.nc', file_dir) 132 | 133 | Save data in GeoTIFF format (if you have rioxarray library): 134 | 135 | .. code-block:: python 136 | 137 | data.to_geotiff('test.tif', file_dir) -------------------------------------------------------------------------------- /docs/_build/html/_sources/api.rst.txt: -------------------------------------------------------------------------------- 1 | ============= 2 | API reference 3 | ============= 4 | 5 | Top-level functions 6 | =================== 7 | 8 | .. automodapi:: imdlib.core 9 | :no-inheritance-diagram: 10 | 11 | .. automodapi:: imdlib.util 12 | :no-inheritance-diagram: -------------------------------------------------------------------------------- /docs/_build/html/_sources/api/imdlib.core.IMD.rst.txt: -------------------------------------------------------------------------------- 1 | IMD 2 | === 3 | 4 | .. currentmodule:: imdlib.core 5 | 6 | .. autoclass:: IMD 7 | :show-inheritance: 8 | 9 | .. rubric:: Attributes Summary 10 | 11 | .. autosummary:: 12 | 13 | ~IMD.shape 14 | 15 | .. rubric:: Methods Summary 16 | 17 | .. autosummary:: 18 | 19 | ~IMD.get_xarray 20 | ~IMD.to_csv 21 | ~IMD.to_geotiff 22 | ~IMD.to_netcdf 23 | 24 | .. rubric:: Attributes Documentation 25 | 26 | .. autoattribute:: shape 27 | 28 | .. rubric:: Methods Documentation 29 | 30 | .. automethod:: get_xarray 31 | .. automethod:: to_csv 32 | .. automethod:: to_geotiff 33 | .. automethod:: to_netcdf 34 | -------------------------------------------------------------------------------- /docs/_build/html/_sources/api/imdlib.core.get_data.rst.txt: -------------------------------------------------------------------------------- 1 | get_data 2 | ======== 3 | 4 | .. currentmodule:: imdlib.core 5 | 6 | .. autofunction:: get_data 7 | -------------------------------------------------------------------------------- /docs/_build/html/_sources/api/imdlib.core.open_data.rst.txt: -------------------------------------------------------------------------------- 1 | open_data 2 | ========= 3 | 4 | .. currentmodule:: imdlib.core 5 | 6 | .. autofunction:: open_data 7 | -------------------------------------------------------------------------------- /docs/_build/html/_sources/api/imdlib.util.LeapYear.rst.txt: -------------------------------------------------------------------------------- 1 | LeapYear 2 | ======== 3 | 4 | .. currentmodule:: imdlib.util 5 | 6 | .. autofunction:: LeapYear 7 | -------------------------------------------------------------------------------- /docs/_build/html/_sources/api/imdlib.util.get_filename.rst.txt: -------------------------------------------------------------------------------- 1 | get_filename 2 | ============ 3 | 4 | .. currentmodule:: imdlib.util 5 | 6 | .. autofunction:: get_filename 7 | -------------------------------------------------------------------------------- /docs/_build/html/_sources/api/imdlib.util.get_lat_lon.rst.txt: -------------------------------------------------------------------------------- 1 | get_lat_lon 2 | =========== 3 | 4 | .. currentmodule:: imdlib.util 5 | 6 | .. autofunction:: get_lat_lon 7 | -------------------------------------------------------------------------------- /docs/_build/html/_sources/api/imdlib.util.total_days.rst.txt: -------------------------------------------------------------------------------- 1 | total_days 2 | ========== 3 | 4 | .. currentmodule:: imdlib.util 5 | 6 | .. autofunction:: total_days 7 | -------------------------------------------------------------------------------- /docs/_build/html/_sources/authors.rst.txt: -------------------------------------------------------------------------------- 1 | About Authors 2 | ============= -------------------------------------------------------------------------------- /docs/_build/html/_sources/cf-conventions.rst.txt: -------------------------------------------------------------------------------- 1 | .. _cf-conventions: 2 | 3 | CF conventions 4 | ========================== 5 | 6 | NetCDF File Convention 7 | ----------------------- 8 | 9 | The IMDLIB produces netCDF (network Common Data Form) based final output. It is the most common data format in hydroclimatic studies. The netCDF Climate and Forecast (CF) Metadata Conventions, Version 1.7, has been adopted by IMDLIB for the efficient and consistent use with other standard netCDF tools/applications. The EPSG:4326 coordinate reference systems (CRS) are considered in the CF naming convention. They are vital for the function to_geotiff to work correctly. Users may visit the `CF Conventions homepage`_ for more information. 10 | 11 | .. _CF Conventions homepage: https://cfconventions.org/ 12 | 13 | .. image:: savefig/fig2.jpg 14 | :width: 700 15 | -------------------------------------------------------------------------------- /docs/_build/html/_sources/changelog.rst.txt: -------------------------------------------------------------------------------- 1 | Changelog History 2 | ================= 3 | 4 | v0.1.11 (12 March 2021) 5 | -------------------------- 6 | 7 | * Updated docs 8 | 9 | * Fixed missing libraries for conda upload 10 | 11 | 12 | v0.1.10 (27 Feburary 2021) 13 | -------------------------- 14 | 15 | * Removed requests as dependency. 16 | 17 | * Added API references. 18 | 19 | * Improvement in the docs. 20 | 21 | * Updated `to_csv` to save file with time information and header. 22 | 23 | 24 | v0.1.9 (30 December 2020) 25 | ------------------------- 26 | 27 | * Added CF-1.7 conventions for the NetCDF output. 28 | 29 | * Added support for converting data into GeoTIFF format. 30 | 31 | * Improvement in the return process the imd.get_data() functionality 32 | 33 | * Updated link for the new https based IMD data portal 34 | -------------------------------------------------------------------------------- /docs/_build/html/_sources/contributions.rst.txt: -------------------------------------------------------------------------------- 1 | Contributions 2 | ============= -------------------------------------------------------------------------------- /docs/_build/html/_sources/external-links.rst.txt: -------------------------------------------------------------------------------- 1 | External Links 2 | ============== -------------------------------------------------------------------------------- /docs/_build/html/_sources/faq.rst.txt: -------------------------------------------------------------------------------- 1 | .. _faq: 2 | 3 | Frequently Asked Questions 4 | ========================== 5 | 6 | Why IMDLIB? 7 | ----------- 8 | 9 | The contemporary hydroclimatic studies require a huge data handling. Recently, the high-resolution gridded meteorological datasets, i.e., Rainfall (0.25° x 0.25°), Maximum and Minimum Temperature (1° x 1°) at daily timescale are made open-access. This gridded dataset for India was prepared considering measurements from well-spread gauge stations over the Indian land region after expanded quality controls. However, extraction of data for our area of interest often consumes substantial time and effort. IMDLIB resolves this problem by providing an easy and user-friendly way to extract continuous gridded data. 10 | 11 | Can IMDLIB process any GRD file? 12 | -------------------------------- 13 | No. For handling any binary dataset, one needs to know the exact dimension (both spatial and 14 | temporal) of the given data. IMDLIB takes this information from `imdpune`_. So, if the data 15 | dimension doesn't match with that of IMDLIB, it won't be able to read or further 16 | process them. 17 | 18 | .. _imdpune: http://imdpune.gov.in/Clim_Pred_LRF_New/Grided_Data_Download.html 19 | 20 | What is the development status of the IMDLIB library? 21 | ----------------------------------------------------- 22 | 23 | As of today (March 2021), IMDLIB is used by a large mass of people, specifically the M.Tech, Ph.D. and postdoctoral scholars across India. We would continue and maintain IMDLIB in the future as well. IMDLIB is a useful library that we enjoyed building during our Ph.D. journey. 24 | 25 | What other tools should I know? 26 | -------------------------------------- 27 | 28 | For handling the gridded data, the netCDF file system is universally adopted. The `xarray`_ 29 | is an excellent library for handling netCDF data in python. If one needs parallel support, 30 | `Dask`_ provides advanced parallelism for analytics. But, both of them use `numpy`_ / `pandas`_ 31 | as the core for building their final product. Hopefully, `pangeo`_ will emerge as one of the most powerful tools for data analytics in the cloud-native future. 32 | 33 | .. _xarray: http://xarray.pydata.org/en/stable/ 34 | .. _dask: https://dask.org/ 35 | .. _numpy: https://numpy.org/ 36 | .. _pandas: http://pandas.pydata.org/ 37 | .. _pangeo: https://pangeo-data.github.io/ 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /docs/_build/html/_sources/index.rst.txt: -------------------------------------------------------------------------------- 1 | .. imdlib documentation master file, created by 2 | sphinx-quickstart on Wed Dec 30 16:00:48 2021. 3 | You can adapt this file completely to your liking, but it should at least 4 | contain the root `toctree` directive. 5 | 6 | IMDLIB - a Python library for IMD gridded data 7 | ============================================== 8 | 9 | IMDLIB is a python package to download and handle binary gridded data from the India Meteorological 10 | Department (IMD). For more information about the IMD datasets, the link of 11 | `IMD Pune`_ may be referred. It heavily employs the `xarray`_ for processing the datasets. 12 | 13 | .. _IMD Pune: https://imdpune.gov.in/Clim_Pred_LRF_New/Grided_Data_Download.html 14 | .. _xarray: http://xarray.pydata.org/en/stable/ 15 | 16 | .. toctree:: 17 | :maxdepth: 1 18 | :caption: Getting Started 19 | 20 | Description 21 | 22 | .. toctree:: 23 | :maxdepth: 1 24 | :caption: Usage 25 | 26 | Usage 27 | 28 | .. toctree:: 29 | :maxdepth: 1 30 | :caption: Reference 31 | 32 | faq 33 | changelog 34 | cf-conventions 35 | api 36 | 37 | Citation 38 | -------- 39 | 40 | If you are using imdlib and would like to cite it in academic publication, we recommend to use the zenodo DOI: 41 | 42 | .. image:: https://zenodo.org/badge/235463327.svg 43 | :target: https://doi.org/10.5281/zenodo.4405233 44 | 45 | About 46 | ----- 47 | 48 | :License: 49 | MIT License 50 | 51 | :Status: 52 | .. image:: https://badge.fury.io/py/imdlib.svg 53 | :target: https://badge.fury.io/py/imdlib 54 | .. image:: https://anaconda.org/iamsaswata/imdlib/badges/version.svg 55 | :target: https://anaconda.org/iamsaswata/imdlib 56 | .. image:: https://zenodo.org/badge/235463327.svg 57 | :target: https://doi.org/10.5281/zenodo.4405233 58 | 59 | :Documentation: 60 | .. image:: https://readthedocs.org/projects/imdlib/badge/?version=stable 61 | :target: http://imdlib.readthedocs.io/?badge=stable 62 | 63 | :Contact: 64 | * `Saswata Nandi `__ 65 | * `Pratiman Patel `__ 66 | * `Sabyasachi Swain `__ 67 | 68 | .. meta:: 69 | :description: IMDLIB is a python package library to download IMD gridded data 70 | :keywords: imdlib, IMDLIB, imd, IMD, python, India, gridded rainfall, gridded temperature 71 | -------------------------------------------------------------------------------- /docs/_build/html/_static/css/badge_only.css: -------------------------------------------------------------------------------- 1 | .fa:before{-webkit-font-smoothing:antialiased}.clearfix{*zoom:1}.clearfix:after,.clearfix:before{display:table;content:""}.clearfix:after{clear:both}@font-face{font-family:FontAwesome;font-style:normal;font-weight:400;src:url(fonts/fontawesome-webfont.eot?674f50d287a8c48dc19ba404d20fe713?#iefix) format("embedded-opentype"),url(fonts/fontawesome-webfont.woff2?af7ae505a9eed503f8b8e6982036873e) format("woff2"),url(fonts/fontawesome-webfont.woff?fee66e712a8a08eef5805a46892932ad) format("woff"),url(fonts/fontawesome-webfont.ttf?b06871f281fee6b241d60582ae9369b9) format("truetype"),url(fonts/fontawesome-webfont.svg?912ec66d7572ff821749319396470bde#FontAwesome) format("svg")}.fa:before{font-family:FontAwesome;font-style:normal;font-weight:400;line-height:1}.fa:before,a .fa{text-decoration:inherit}.fa:before,a .fa,li .fa{display:inline-block}li .fa-large:before{width:1.875em}ul.fas{list-style-type:none;margin-left:2em;text-indent:-.8em}ul.fas li .fa{width:.8em}ul.fas li .fa-large:before{vertical-align:baseline}.fa-book:before,.icon-book:before{content:"\f02d"}.fa-caret-down:before,.icon-caret-down:before{content:"\f0d7"}.fa-caret-up:before,.icon-caret-up:before{content:"\f0d8"}.fa-caret-left:before,.icon-caret-left:before{content:"\f0d9"}.fa-caret-right:before,.icon-caret-right:before{content:"\f0da"}.rst-versions{position:fixed;bottom:0;left:0;width:300px;color:#fcfcfc;background:#1f1d1d;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;z-index:400}.rst-versions a{color:#2980b9;text-decoration:none}.rst-versions .rst-badge-small{display:none}.rst-versions .rst-current-version{padding:12px;background-color:#272525;display:block;text-align:right;font-size:90%;cursor:pointer;color:#27ae60}.rst-versions .rst-current-version:after{clear:both;content:"";display:block}.rst-versions .rst-current-version .fa{color:#fcfcfc}.rst-versions .rst-current-version .fa-book,.rst-versions .rst-current-version .icon-book{float:left}.rst-versions .rst-current-version.rst-out-of-date{background-color:#e74c3c;color:#fff}.rst-versions .rst-current-version.rst-active-old-version{background-color:#f1c40f;color:#000}.rst-versions.shift-up{height:auto;max-height:100%;overflow-y:scroll}.rst-versions.shift-up .rst-other-versions{display:block}.rst-versions .rst-other-versions{font-size:90%;padding:12px;color:grey;display:none}.rst-versions .rst-other-versions hr{display:block;height:1px;border:0;margin:20px 0;padding:0;border-top:1px solid #413d3d}.rst-versions .rst-other-versions dd{display:inline-block;margin:0}.rst-versions .rst-other-versions dd a{display:inline-block;padding:6px;color:#fcfcfc}.rst-versions.rst-badge{width:auto;bottom:20px;right:20px;left:auto;border:none;max-width:300px;max-height:90%}.rst-versions.rst-badge .fa-book,.rst-versions.rst-badge .icon-book{float:none;line-height:30px}.rst-versions.rst-badge.shift-up .rst-current-version{text-align:right}.rst-versions.rst-badge.shift-up .rst-current-version .fa-book,.rst-versions.rst-badge.shift-up .rst-current-version .icon-book{float:left}.rst-versions.rst-badge>.rst-current-version{width:auto;height:30px;line-height:30px;padding:0 6px;display:block;text-align:center}@media screen and (max-width:768px){.rst-versions{width:85%;display:none}.rst-versions.shift{display:block}} -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/Roboto-Slab-Bold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/Roboto-Slab-Bold.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/Roboto-Slab-Bold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/Roboto-Slab-Bold.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/Roboto-Slab-Regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/Roboto-Slab-Regular.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/Roboto-Slab-Regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/Roboto-Slab-Regular.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/fontawesome-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/fontawesome-webfont.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/lato-bold-italic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/lato-bold-italic.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/lato-bold-italic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/lato-bold-italic.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/lato-bold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/lato-bold.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/lato-bold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/lato-bold.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/lato-normal-italic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/lato-normal-italic.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/lato-normal-italic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/lato-normal-italic.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/lato-normal.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/lato-normal.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/css/fonts/lato-normal.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/css/fonts/lato-normal.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/custom.css: -------------------------------------------------------------------------------- 1 | /* This file intentionally left blank. */ 2 | -------------------------------------------------------------------------------- /docs/_build/html/_static/documentation_options.js: -------------------------------------------------------------------------------- 1 | var DOCUMENTATION_OPTIONS = { 2 | URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'), 3 | VERSION: '', 4 | LANGUAGE: 'None', 5 | COLLAPSE_INDEX: false, 6 | BUILDER: 'html', 7 | FILE_SUFFIX: '.html', 8 | LINK_SUFFIX: '.html', 9 | HAS_SOURCE: true, 10 | SOURCELINK_SUFFIX: '.txt', 11 | NAVIGATION_WITH_KEYS: false 12 | }; -------------------------------------------------------------------------------- /docs/_build/html/_static/file.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/file.png -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/FontAwesome.otf -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-bold.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-bold.eot -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-bold.ttf -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-bold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-bold.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-bold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-bold.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-bolditalic.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-bolditalic.eot -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-bolditalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-bolditalic.ttf -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-bolditalic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-bolditalic.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-bolditalic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-bolditalic.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-italic.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-italic.eot -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-italic.ttf -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-italic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-italic.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-italic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-italic.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-regular.eot -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-regular.ttf -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-regular.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Lato/lato-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Lato/lato-regular.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Roboto-Slab-Bold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Roboto-Slab-Bold.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Roboto-Slab-Bold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Roboto-Slab-Bold.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Roboto-Slab-Light.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Roboto-Slab-Light.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Roboto-Slab-Light.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Roboto-Slab-Light.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Roboto-Slab-Regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Roboto-Slab-Regular.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Roboto-Slab-Regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Roboto-Slab-Regular.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Roboto-Slab-Thin.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Roboto-Slab-Thin.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/Roboto-Slab-Thin.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/Roboto-Slab-Thin.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.eot -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.ttf -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.eot -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.ttf -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/fontawesome-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/fontawesome-webfont.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/lato-bold-italic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/lato-bold-italic.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/lato-bold-italic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/lato-bold-italic.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/lato-bold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/lato-bold.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/lato-bold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/lato-bold.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/lato-normal-italic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/lato-normal-italic.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/lato-normal-italic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/lato-normal-italic.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/lato-normal.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/lato-normal.woff -------------------------------------------------------------------------------- /docs/_build/html/_static/fonts/lato-normal.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/_static/fonts/lato-normal.woff2 -------------------------------------------------------------------------------- /docs/_build/html/_static/graphviz.css: -------------------------------------------------------------------------------- 1 | /* 2 | * graphviz.css 3 | * ~~~~~~~~~~~~ 4 | * 5 | * Sphinx stylesheet -- graphviz extension. 6 | * 7 | * :copyright: Copyright 2007-2020 by the Sphinx team, see AUTHORS. 8 | * :license: BSD, see LICENSE for details. 9 | * 10 | */ 11 | 12 | img.graphviz { 13 | border: 0; 14 | max-width: 100%; 15 | } 16 | 17 | object.graphviz { 18 | max-width: 100%; 19 | } 20 | -------------------------------------------------------------------------------- /docs/_build/html/_static/js/badge_only.js: -------------------------------------------------------------------------------- 1 | !function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=4)}({4:function(e,t,r){}}); -------------------------------------------------------------------------------- /docs/_build/html/_static/js/html5shiv-printshiv.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | * @preserve HTML5 Shiv 3.7.3-pre | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed 3 | */ 4 | !function(a,b){function c(a,b){var c=a.createElement("p"),d=a.getElementsByTagName("head")[0]||a.documentElement;return c.innerHTML="x",d.insertBefore(c.lastChild,d.firstChild)}function d(){var a=y.elements;return"string"==typeof a?a.split(" "):a}function e(a,b){var c=y.elements;"string"!=typeof c&&(c=c.join(" ")),"string"!=typeof a&&(a=a.join(" ")),y.elements=c+" "+a,j(b)}function f(a){var b=x[a[v]];return b||(b={},w++,a[v]=w,x[w]=b),b}function g(a,c,d){if(c||(c=b),q)return c.createElement(a);d||(d=f(c));var e;return e=d.cache[a]?d.cache[a].cloneNode():u.test(a)?(d.cache[a]=d.createElem(a)).cloneNode():d.createElem(a),!e.canHaveChildren||t.test(a)||e.tagUrn?e:d.frag.appendChild(e)}function h(a,c){if(a||(a=b),q)return a.createDocumentFragment();c=c||f(a);for(var e=c.frag.cloneNode(),g=0,h=d(),i=h.length;i>g;g++)e.createElement(h[g]);return e}function i(a,b){b.cache||(b.cache={},b.createElem=a.createElement,b.createFrag=a.createDocumentFragment,b.frag=b.createFrag()),a.createElement=function(c){return y.shivMethods?g(c,a,b):b.createElem(c)},a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+d().join().replace(/[\w\-:]+/g,function(a){return b.createElem(a),b.frag.createElement(a),'c("'+a+'")'})+");return n}")(y,b.frag)}function j(a){a||(a=b);var d=f(a);return!y.shivCSS||p||d.hasCSS||(d.hasCSS=!!c(a,"article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}mark{background:#FF0;color:#000}template{display:none}")),q||i(a,d),a}function k(a){for(var b,c=a.getElementsByTagName("*"),e=c.length,f=RegExp("^(?:"+d().join("|")+")$","i"),g=[];e--;)b=c[e],f.test(b.nodeName)&&g.push(b.applyElement(l(b)));return g}function l(a){for(var b,c=a.attributes,d=c.length,e=a.ownerDocument.createElement(A+":"+a.nodeName);d--;)b=c[d],b.specified&&e.setAttribute(b.nodeName,b.nodeValue);return e.style.cssText=a.style.cssText,e}function m(a){for(var b,c=a.split("{"),e=c.length,f=RegExp("(^|[\\s,>+~])("+d().join("|")+")(?=[[\\s,>+~#.:]|$)","gi"),g="$1"+A+"\\:$2";e--;)b=c[e]=c[e].split("}"),b[b.length-1]=b[b.length-1].replace(f,g),c[e]=b.join("}");return c.join("{")}function n(a){for(var b=a.length;b--;)a[b].removeNode()}function o(a){function b(){clearTimeout(g._removeSheetTimer),d&&d.removeNode(!0),d=null}var d,e,g=f(a),h=a.namespaces,i=a.parentWindow;return!B||a.printShived?a:("undefined"==typeof h[A]&&h.add(A),i.attachEvent("onbeforeprint",function(){b();for(var f,g,h,i=a.styleSheets,j=[],l=i.length,n=Array(l);l--;)n[l]=i[l];for(;h=n.pop();)if(!h.disabled&&z.test(h.media)){try{f=h.imports,g=f.length}catch(o){g=0}for(l=0;g>l;l++)n.push(f[l]);try{j.push(h.cssText)}catch(o){}}j=m(j.reverse().join("")),e=k(a),d=c(a,j)}),i.attachEvent("onafterprint",function(){n(e),clearTimeout(g._removeSheetTimer),g._removeSheetTimer=setTimeout(b,500)}),a.printShived=!0,a)}var p,q,r="3.7.3",s=a.html5||{},t=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,u=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,v="_html5shiv",w=0,x={};!function(){try{var a=b.createElement("a");a.innerHTML="",p="hidden"in a,q=1==a.childNodes.length||function(){b.createElement("a");var a=b.createDocumentFragment();return"undefined"==typeof a.cloneNode||"undefined"==typeof a.createDocumentFragment||"undefined"==typeof a.createElement}()}catch(c){p=!0,q=!0}}();var y={elements:s.elements||"abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output picture progress section summary template time video",version:r,shivCSS:s.shivCSS!==!1,supportsUnknownElements:q,shivMethods:s.shivMethods!==!1,type:"default",shivDocument:j,createElement:g,createDocumentFragment:h,addElements:e};a.html5=y,j(b);var z=/^$|\b(?:all|print)\b/,A="html5shiv",B=!q&&function(){var c=b.documentElement;return!("undefined"==typeof b.namespaces||"undefined"==typeof b.parentWindow||"undefined"==typeof c.applyElement||"undefined"==typeof c.removeNode||"undefined"==typeof a.attachEvent)}();y.type+=" print",y.shivPrint=o,o(b),"object"==typeof module&&module.exports&&(module.exports=y)}("undefined"!=typeof window?window:this,document); -------------------------------------------------------------------------------- /docs/_build/html/_static/js/html5shiv.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | * @preserve HTML5 Shiv 3.7.3 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed 3 | */ 4 | !function(a,b){function c(a,b){var c=a.createElement("p"),d=a.getElementsByTagName("head")[0]||a.documentElement;return c.innerHTML="x",d.insertBefore(c.lastChild,d.firstChild)}function d(){var a=t.elements;return"string"==typeof a?a.split(" "):a}function e(a,b){var c=t.elements;"string"!=typeof c&&(c=c.join(" ")),"string"!=typeof a&&(a=a.join(" ")),t.elements=c+" "+a,j(b)}function f(a){var b=s[a[q]];return b||(b={},r++,a[q]=r,s[r]=b),b}function g(a,c,d){if(c||(c=b),l)return c.createElement(a);d||(d=f(c));var e;return e=d.cache[a]?d.cache[a].cloneNode():p.test(a)?(d.cache[a]=d.createElem(a)).cloneNode():d.createElem(a),!e.canHaveChildren||o.test(a)||e.tagUrn?e:d.frag.appendChild(e)}function h(a,c){if(a||(a=b),l)return a.createDocumentFragment();c=c||f(a);for(var e=c.frag.cloneNode(),g=0,h=d(),i=h.length;i>g;g++)e.createElement(h[g]);return e}function i(a,b){b.cache||(b.cache={},b.createElem=a.createElement,b.createFrag=a.createDocumentFragment,b.frag=b.createFrag()),a.createElement=function(c){return t.shivMethods?g(c,a,b):b.createElem(c)},a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+d().join().replace(/[\w\-:]+/g,function(a){return b.createElem(a),b.frag.createElement(a),'c("'+a+'")'})+");return n}")(t,b.frag)}function j(a){a||(a=b);var d=f(a);return!t.shivCSS||k||d.hasCSS||(d.hasCSS=!!c(a,"article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}mark{background:#FF0;color:#000}template{display:none}")),l||i(a,d),a}var k,l,m="3.7.3-pre",n=a.html5||{},o=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,p=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,q="_html5shiv",r=0,s={};!function(){try{var a=b.createElement("a");a.innerHTML="",k="hidden"in a,l=1==a.childNodes.length||function(){b.createElement("a");var a=b.createDocumentFragment();return"undefined"==typeof a.cloneNode||"undefined"==typeof a.createDocumentFragment||"undefined"==typeof a.createElement}()}catch(c){k=!0,l=!0}}();var t={elements:n.elements||"abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output picture progress section summary template time video",version:m,shivCSS:n.shivCSS!==!1,supportsUnknownElements:l,shivMethods:n.shivMethods!==!1,type:"default",shivDocument:j,createElement:g,createDocumentFragment:h,addElements:e};a.html5=t,j(b),"object"==typeof module&&module.exports&&(module.exports=t)}("undefined"!=typeof window?window:this,document); -------------------------------------------------------------------------------- /docs/_build/html/_static/js/theme.js: -------------------------------------------------------------------------------- 1 | !function(n){var e={};function t(i){if(e[i])return e[i].exports;var o=e[i]={i:i,l:!1,exports:{}};return n[i].call(o.exports,o,o.exports,t),o.l=!0,o.exports}t.m=n,t.c=e,t.d=function(n,e,i){t.o(n,e)||Object.defineProperty(n,e,{enumerable:!0,get:i})},t.r=function(n){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(n,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(n,"__esModule",{value:!0})},t.t=function(n,e){if(1&e&&(n=t(n)),8&e)return n;if(4&e&&"object"==typeof n&&n&&n.__esModule)return n;var i=Object.create(null);if(t.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:n}),2&e&&"string"!=typeof n)for(var o in n)t.d(i,o,function(e){return n[e]}.bind(null,o));return i},t.n=function(n){var e=n&&n.__esModule?function(){return n.default}:function(){return n};return t.d(e,"a",e),e},t.o=function(n,e){return Object.prototype.hasOwnProperty.call(n,e)},t.p="",t(t.s=0)}([function(n,e,t){t(1),n.exports=t(3)},function(n,e,t){(function(){var e="undefined"!=typeof window?window.jQuery:t(2);n.exports.ThemeNav={navBar:null,win:null,winScroll:!1,winResize:!1,linkScroll:!1,winPosition:0,winHeight:null,docHeight:null,isRunning:!1,enable:function(n){var t=this;void 0===n&&(n=!0),t.isRunning||(t.isRunning=!0,e((function(e){t.init(e),t.reset(),t.win.on("hashchange",t.reset),n&&t.win.on("scroll",(function(){t.linkScroll||t.winScroll||(t.winScroll=!0,requestAnimationFrame((function(){t.onScroll()})))})),t.win.on("resize",(function(){t.winResize||(t.winResize=!0,requestAnimationFrame((function(){t.onResize()})))})),t.onResize()})))},enableSticky:function(){this.enable(!0)},init:function(n){n(document);var e=this;this.navBar=n("div.wy-side-scroll:first"),this.win=n(window),n(document).on("click","[data-toggle='wy-nav-top']",(function(){n("[data-toggle='wy-nav-shift']").toggleClass("shift"),n("[data-toggle='rst-versions']").toggleClass("shift")})).on("click",".wy-menu-vertical .current ul li a",(function(){var t=n(this);n("[data-toggle='wy-nav-shift']").removeClass("shift"),n("[data-toggle='rst-versions']").toggleClass("shift"),e.toggleCurrent(t),e.hashChange()})).on("click","[data-toggle='rst-current-version']",(function(){n("[data-toggle='rst-versions']").toggleClass("shift-up")})),n("table.docutils:not(.field-list,.footnote,.citation)").wrap("
"),n("table.docutils.footnote").wrap("
"),n("table.docutils.citation").wrap("
"),n(".wy-menu-vertical ul").not(".simple").siblings("a").each((function(){var t=n(this);expand=n(''),expand.on("click",(function(n){return e.toggleCurrent(t),n.stopPropagation(),!1})),t.prepend(expand)}))},reset:function(){var n=encodeURI(window.location.hash)||"#";try{var e=$(".wy-menu-vertical"),t=e.find('[href="'+n+'"]');if(0===t.length){var i=$('.document [id="'+n.substring(1)+'"]').closest("div.section");0===(t=e.find('[href="#'+i.attr("id")+'"]')).length&&(t=e.find('[href="#"]'))}t.length>0&&($(".wy-menu-vertical .current").removeClass("current"),t.addClass("current"),t.closest("li.toctree-l1").addClass("current"),t.closest("li.toctree-l1").parent().addClass("current"),t.closest("li.toctree-l1").addClass("current"),t.closest("li.toctree-l2").addClass("current"),t.closest("li.toctree-l3").addClass("current"),t.closest("li.toctree-l4").addClass("current"),t.closest("li.toctree-l5").addClass("current"),t[0].scrollIntoView())}catch(n){console.log("Error expanding nav for anchor",n)}},onScroll:function(){this.winScroll=!1;var n=this.win.scrollTop(),e=n+this.winHeight,t=this.navBar.scrollTop()+(n-this.winPosition);n<0||e>this.docHeight||(this.navBar.scrollTop(t),this.winPosition=n)},onResize:function(){this.winResize=!1,this.winHeight=this.win.height(),this.docHeight=$(document).height()},hashChange:function(){this.linkScroll=!0,this.win.one("hashchange",(function(){this.linkScroll=!1}))},toggleCurrent:function(n){var e=n.closest("li");e.siblings("li.current").removeClass("current"),e.siblings().find("li.current").removeClass("current"),e.find("> ul li.current").removeClass("current"),e.toggleClass("current")}},"undefined"!=typeof window&&(window.SphinxRtdTheme={Navigation:n.exports.ThemeNav,StickyNav:n.exports.ThemeNav}),function(){for(var n=0,e=["ms","moz","webkit","o"],t=0;t 4 | 5 | 6 | 7 | 8 | 9 | 10 | LeapYear — IMDLIB documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 |
47 | 48 | 122 | 123 |
124 | 125 | 126 | 132 | 133 | 134 |
135 | 136 |
137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 |
155 | 156 | 174 | 175 | 176 |
177 |
178 |
179 |
180 | 181 |
182 |

LeapYear

183 |
184 |
185 | imdlib.util.LeapYear(year)
186 |

Check leap year or not

187 |
188 | 189 |
190 | 191 | 192 |
193 | 194 |
195 |
196 | 197 | 205 | 206 | 207 |
208 | 209 |
210 |

211 | 212 | © Copyright 2021, Saswata Nandi, Pratiman Patel and Sabyasachi Swain 213 | 214 |

215 |
216 | 217 | 218 | 219 | Built with Sphinx using a 220 | 221 | theme 222 | 223 | provided by Read the Docs. 224 | 225 |
226 | 227 |
228 |
229 | 230 |
231 | 232 |
233 | 234 | 235 | 240 | 241 | 242 | 243 | 244 | 245 | 246 | 247 | -------------------------------------------------------------------------------- /docs/_build/html/api/imdlib.util.get_filename.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | get_filename — IMDLIB documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 |
47 | 48 | 122 | 123 |
124 | 125 | 126 | 132 | 133 | 134 |
135 | 136 |
137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 |
155 | 156 |
    157 | 158 |
  • »
  • 159 | 160 |
  • API reference »
  • 161 | 162 |
  • get_filename
  • 163 | 164 | 165 |
  • 166 | 167 | 168 | View page source 169 | 170 | 171 |
  • 172 | 173 |
174 | 175 | 176 |
177 |
178 |
179 |
180 | 181 |
182 |

get_filename

183 |
184 |
185 | imdlib.util.get_filename(year, var_type, fn_format, file_dir)
186 |

Get filename for reading the file content in future

187 |
188 | 189 |
190 | 191 | 192 |
193 | 194 |
195 |
196 | 197 | 205 | 206 | 207 |
208 | 209 |
210 |

211 | 212 | © Copyright 2021, Saswata Nandi, Pratiman Patel and Sabyasachi Swain 213 | 214 |

215 |
216 | 217 | 218 | 219 | Built with Sphinx using a 220 | 221 | theme 222 | 223 | provided by Read the Docs. 224 | 225 |
226 | 227 |
228 |
229 | 230 |
231 | 232 |
233 | 234 | 235 | 240 | 241 | 242 | 243 | 244 | 245 | 246 | 247 | -------------------------------------------------------------------------------- /docs/_build/html/api/imdlib.util.get_lat_lon.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | get_lat_lon — IMDLIB documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 |
47 | 48 | 122 | 123 |
124 | 125 | 126 | 132 | 133 | 134 |
135 | 136 |
137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 |
155 | 156 |
    157 | 158 |
  • »
  • 159 | 160 |
  • API reference »
  • 161 | 162 |
  • get_lat_lon
  • 163 | 164 | 165 |
  • 166 | 167 | 168 | View page source 169 | 170 | 171 |
  • 172 | 173 |
174 | 175 | 176 |
177 |
178 |
179 |
180 | 181 |
182 |

get_lat_lon

183 |
184 |
185 | imdlib.util.get_lat_lon(lat, lon, lat_rage, lon_range)
186 |

Check INDEX of closest lat lon for a given co-ordinate

187 |
188 | 189 |
190 | 191 | 192 |
193 | 194 |
195 |
196 | 197 | 205 | 206 | 207 |
208 | 209 |
210 |

211 | 212 | © Copyright 2021, Saswata Nandi, Pratiman Patel and Sabyasachi Swain 213 | 214 |

215 |
216 | 217 | 218 | 219 | Built with Sphinx using a 220 | 221 | theme 222 | 223 | provided by Read the Docs. 224 | 225 |
226 | 227 |
228 |
229 | 230 |
231 | 232 |
233 | 234 | 235 | 240 | 241 | 242 | 243 | 244 | 245 | 246 | 247 | -------------------------------------------------------------------------------- /docs/_build/html/api/imdlib.util.total_days.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | total_days — IMDLIB documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 | 47 | 121 | 122 |
123 | 124 | 125 | 131 | 132 | 133 |
134 | 135 |
136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 |
154 | 155 |
    156 | 157 |
  • »
  • 158 | 159 |
  • API reference »
  • 160 | 161 |
  • total_days
  • 162 | 163 | 164 |
  • 165 | 166 | 167 | View page source 168 | 169 | 170 |
  • 171 | 172 |
173 | 174 | 175 |
176 |
177 |
178 |
179 | 180 |
181 |

total_days

182 |
183 |
184 | imdlib.util.total_days(starting_day, ending_day)
185 |

Calculate to no of days for a given starting and ending day

186 |
187 | 188 |
189 | 190 | 191 |
192 | 193 |
194 |
195 | 196 | 202 | 203 | 204 |
205 | 206 |
207 |

208 | 209 | © Copyright 2021, Saswata Nandi, Pratiman Patel and Sabyasachi Swain 210 | 211 |

212 |
213 | 214 | 215 | 216 | Built with Sphinx using a 217 | 218 | theme 219 | 220 | provided by Read the Docs. 221 | 222 |
223 | 224 |
225 |
226 | 227 |
228 | 229 |
230 | 231 | 232 | 237 | 238 | 239 | 240 | 241 | 242 | 243 | 244 | -------------------------------------------------------------------------------- /docs/_build/html/authors.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | About Authors — IMDLIB documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 | 47 | 112 | 113 |
114 | 115 | 116 | 122 | 123 | 124 |
125 | 126 |
127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 |
145 | 146 |
    147 | 148 |
  • »
  • 149 | 150 |
  • About Authors
  • 151 | 152 | 153 |
  • 154 | 155 | 156 | View page source 157 | 158 | 159 |
  • 160 | 161 |
162 | 163 | 164 |
165 |
166 |
167 |
168 | 169 |
170 |

About Authors

171 |
172 | 173 | 174 |
175 | 176 |
177 |
178 | 179 | 185 | 186 | 187 |
188 | 189 |
190 |

191 | 192 | © Copyright 2020, Saswata Nandi and Pratiman Patel 193 | 194 |

195 |
196 | 197 | 198 | 199 | Built with Sphinx using a 200 | 201 | theme 202 | 203 | provided by Read the Docs. 204 | 205 |
206 | 207 |
208 |
209 | 210 |
211 | 212 |
213 | 214 | 215 | 220 | 221 | 222 | 223 | 224 | 225 | 226 | 227 | -------------------------------------------------------------------------------- /docs/_build/html/cf-conventions.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | CF conventions — IMDLIB documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 |
47 | 48 | 115 | 116 |
117 | 118 | 119 | 125 | 126 | 127 |
128 | 129 |
130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 |
148 | 149 |
    150 | 151 |
  • »
  • 152 | 153 |
  • CF conventions
  • 154 | 155 | 156 |
  • 157 | 158 | 159 | View page source 160 | 161 | 162 |
  • 163 | 164 |
165 | 166 | 167 |
168 |
169 |
170 |
171 | 172 |
173 |

CF conventions

174 |
175 |

NetCDF File Convention

176 |

The IMDLIB produces netCDF (network Common Data Form) based final output. It is the most common data format in hydroclimatic studies. The netCDF Climate and Forecast (CF) Metadata Conventions, Version 1.7, has been adopted by IMDLIB for the efficient and consistent use with other standard netCDF tools/applications. The EPSG:4326 coordinate reference systems (CRS) are considered in the CF naming convention. They are vital for the function to_geotiff to work correctly. Users may visit the CF Conventions homepage for more information.

177 | _images/fig2.jpg 178 |
179 |
180 | 181 | 182 |
183 | 184 |
185 |
186 | 187 | 195 | 196 | 197 |
198 | 199 |
200 |

201 | 202 | © Copyright 2021, Saswata Nandi, Pratiman Patel and Sabyasachi Swain 203 | 204 |

205 |
206 | 207 | 208 | 209 | Built with Sphinx using a 210 | 211 | theme 212 | 213 | provided by Read the Docs. 214 | 215 |
216 | 217 |
218 |
219 | 220 |
221 | 222 |
223 | 224 | 225 | 230 | 231 | 232 | 233 | 234 | 235 | 236 | 237 | -------------------------------------------------------------------------------- /docs/_build/html/contributions.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | Contributions — IMDLIB documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 |
47 | 48 | 113 | 114 |
115 | 116 | 117 | 123 | 124 | 125 |
126 | 127 |
128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 |
146 | 147 |
    148 | 149 |
  • »
  • 150 | 151 |
  • Contributions
  • 152 | 153 | 154 |
  • 155 | 156 | 157 | View page source 158 | 159 | 160 |
  • 161 | 162 |
163 | 164 | 165 |
166 |
167 |
168 |
169 | 170 |
171 |

Contributions

172 |
173 | 174 | 175 |
176 | 177 |
178 |
179 | 180 | 188 | 189 | 190 |
191 | 192 |
193 |

194 | 195 | © Copyright 2020, Saswata Nandi and Pratiman Patel 196 | 197 |

198 |
199 | 200 | 201 | 202 | Built with Sphinx using a 203 | 204 | theme 205 | 206 | provided by Read the Docs. 207 | 208 |
209 | 210 |
211 |
212 | 213 |
214 | 215 |
216 | 217 | 218 | 223 | 224 | 225 | 226 | 227 | 228 | 229 | 230 | -------------------------------------------------------------------------------- /docs/_build/html/external-links.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | External Links — IMDLIB documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 |
47 | 48 | 113 | 114 |
115 | 116 | 117 | 123 | 124 | 125 |
126 | 127 |
128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 |
146 | 147 |
    148 | 149 |
  • »
  • 150 | 151 |
  • External Links
  • 152 | 153 | 154 |
  • 155 | 156 | 157 | View page source 158 | 159 | 160 |
  • 161 | 162 |
163 | 164 | 165 |
166 |
167 |
168 |
169 | 170 | 173 | 174 | 175 |
176 | 177 |
178 |
179 | 180 | 188 | 189 | 190 |
191 | 192 |
193 |

194 | 195 | © Copyright 2020, Saswata Nandi and Pratiman Patel 196 | 197 |

198 |
199 | 200 | 201 | 202 | Built with Sphinx using a 203 | 204 | theme 205 | 206 | provided by Read the Docs. 207 | 208 |
209 | 210 |
211 |
212 | 213 |
214 | 215 |
216 | 217 | 218 | 223 | 224 | 225 | 226 | 227 | 228 | 229 | 230 | -------------------------------------------------------------------------------- /docs/_build/html/googleac2a728cd80ab282.html: -------------------------------------------------------------------------------- 1 | google-site-verification: googleac2a728cd80ab282.html -------------------------------------------------------------------------------- /docs/_build/html/objects.inv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/_build/html/objects.inv -------------------------------------------------------------------------------- /docs/_build/html/py-modindex.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | Python Module Index — IMDLIB documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 |
48 | 49 | 113 | 114 |
115 | 116 | 117 | 123 | 124 | 125 |
126 | 127 |
128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 |
146 | 147 |
    148 | 149 |
  • »
  • 150 | 151 |
  • Python Module Index
  • 152 | 153 | 154 |
  • 155 | 156 |
  • 157 | 158 |
159 | 160 | 161 |
162 |
163 |
164 |
165 | 166 | 167 |

Python Module Index

168 | 169 |
170 | i 171 |
172 | 173 | 174 | 175 | 177 | 178 | 180 | 183 | 184 | 185 | 188 | 189 | 190 | 193 |
 
176 | i
181 | imdlib 182 |
    186 | imdlib.core 187 |
    191 | imdlib.util 192 |
194 | 195 | 196 |
197 | 198 |
199 |
200 | 201 | 202 |
203 | 204 |
205 |

206 | 207 | © Copyright 2021, Saswata Nandi, Pratiman Patel and Sabyasachi Swain 208 | 209 |

210 |
211 | 212 | 213 | 214 | Built with Sphinx using a 215 | 216 | theme 217 | 218 | provided by Read the Docs. 219 | 220 |
221 | 222 |
223 |
224 | 225 |
226 | 227 |
228 | 229 | 230 | 235 | 236 | 237 | 238 | 239 | 240 | 241 | 242 | -------------------------------------------------------------------------------- /docs/_build/html/robots.txt: -------------------------------------------------------------------------------- 1 | User-agent: * 2 | 3 | Disallow: / 4 | 5 | Allow: /en/stable 6 | 7 | Allow: /en/latest 8 | 9 | Allow: /en/develop 10 | 11 | Sitemap: https://imdlib.readthedocs.io/en/latest/sitemap-index.xml -------------------------------------------------------------------------------- /docs/_build/html/search.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | Search — IMDLIB documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 |
47 | 48 | 112 | 113 |
114 | 115 | 116 | 122 | 123 | 124 |
125 | 126 |
127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 |
145 | 146 |
    147 | 148 |
  • »
  • 149 | 150 |
  • Search
  • 151 | 152 | 153 |
  • 154 | 155 | 156 | 157 |
  • 158 | 159 |
160 | 161 | 162 |
163 |
164 |
165 |
166 | 167 | 174 | 175 | 176 |
177 | 178 |
179 | 180 |
181 | 182 |
183 |
184 | 185 | 186 |
187 | 188 |
189 |

190 | 191 | © Copyright 2021, Saswata Nandi, Pratiman Patel and Sabyasachi Swain 192 | 193 |

194 |
195 | 196 | 197 | 198 | Built with Sphinx using a 199 | 200 | theme 201 | 202 | provided by Read the Docs. 203 | 204 |
205 | 206 |
207 |
208 | 209 |
210 | 211 |
212 | 213 | 214 | 219 | 220 | 221 | 222 | 223 | 224 | 227 | 228 | 229 | 230 | 231 | 232 | 233 | -------------------------------------------------------------------------------- /docs/_build/html/searchindex.js: -------------------------------------------------------------------------------- 1 | Search.setIndex({docnames:["Description","Usage","api","api/imdlib.core.IMD","api/imdlib.core.get_data","api/imdlib.core.open_data","api/imdlib.util.LeapYear","api/imdlib.util.get_filename","api/imdlib.util.get_lat_lon","api/imdlib.util.total_days","cf-conventions","changelog","faq","index"],envversion:{"sphinx.domains.c":2,"sphinx.domains.changeset":1,"sphinx.domains.citation":1,"sphinx.domains.cpp":3,"sphinx.domains.index":1,"sphinx.domains.javascript":2,"sphinx.domains.math":2,"sphinx.domains.python":2,"sphinx.domains.rst":2,"sphinx.domains.std":1,sphinx:56},filenames:["Description.rst","Usage.rst","api.rst","api/imdlib.core.IMD.rst","api/imdlib.core.get_data.rst","api/imdlib.core.open_data.rst","api/imdlib.util.LeapYear.rst","api/imdlib.util.get_filename.rst","api/imdlib.util.get_lat_lon.rst","api/imdlib.util.total_days.rst","cf-conventions.rst","changelog.rst","faq.rst","index.rst"],objects:{"imdlib.core":{IMD:[3,1,1,""],get_data:[4,4,1,""],open_data:[5,4,1,""]},"imdlib.core.IMD":{get_xarray:[3,2,1,""],shape:[3,3,1,""],to_csv:[3,2,1,""],to_geotiff:[3,2,1,""],to_netcdf:[3,2,1,""]},"imdlib.util":{LeapYear:[6,4,1,""],get_filename:[7,4,1,""],get_lat_lon:[8,4,1,""],total_days:[9,4,1,""]},imdlib:{core:[2,0,0,"-"],util:[2,0,0,"-"]}},objnames:{"0":["py","module","Python module"],"1":["py","class","Python class"],"2":["py","method","Python method"],"3":["py","attribute","Python attribute"],"4":["py","function","Python function"]},objtypes:{"0":"py:module","1":"py:class","2":"py:method","3":"py:attribute","4":"py:function"},terms:{"0x13e5b3753c8":1,"100":1,"129":1,"135":1,"2010":1,"2011":1,"2012":1,"2013":1,"2014":1,"2015":1,"2016":1,"2017":1,"2018":[1,3,4,5],"2019":0,"2021":[1,12],"3287":1,"4326":[1,10],"519783":1,"999":1,"class":[1,3,4,5],"default":[4,5],"final":[10,12],"function":[4,5,10,11],"gridded rainfal":13,"gridded temperatur":13,"import":1,"int":[4,5],"new":11,"public":13,"return":[3,4,5,11],"true":4,"try":[],Added:11,But:[1,12],CRS:10,For:[0,12,13],One:1,The:[1,10,12],abl:12,about:0,academ:13,access:12,accod:[4,5],across:12,adataset:1,address:[4,5],adopt:[10,12],advanc:12,after:[1,4,5,12],alreadi:1,analyt:12,ani:1,api:[11,13],applic:10,architectur:0,area:12,arrai:[3,4,5],ascii:3,ask:13,associ:[],attribut:[1,3],avail:1,awar:[],base:[3,10,11],been:10,below:4,between:1,binari:[0,3,4,5,12,13],bit:0,bool:4,both:[0,12],bracket:4,build:12,cach:[4,5],calcul:9,can:1,capabl:1,care:1,cat:3,center:[],certifi:0,chang:[4,5],changelog:13,check:[0,6,8],cite:13,climat:10,closest:8,cloud:12,code:1,com:0,come:[],comment:1,common:10,conda:[0,11],consid:[10,12],consist:10,consum:12,contact:13,contain:[1,4,5],contemporari:12,content:7,continu:12,control:12,convent:[1,11,13],conventionm:[4,5],convert:[1,11],coordin:[1,10],core:[1,3,4,5,12],correctli:10,creat:1,crs:1,csv:[1,3],curli:4,current:[1,3,4,5],dai:[3,9],daili:[3,4,5,12],dask:12,data:[0,1,3,4,5,10,11,12],dataset:[0,12,13],date:3,datetime64:1,dateutil:0,decid:[],depart:[0,13],depend:11,descript:13,desktop:1,detail:4,develop:0,dict:4,differ:1,differenti:1,digit:3,dimens:[1,3,12],directli:[1,4],directori:[1,4,5],doc:11,document:[3,13],doesn:12,doi:13,done:1,download:[0,4,5,13],draft:4,dure:12,each:4,easi:12,effici:10,effort:12,emerg:12,emploi:13,employ:[],encourag:[],end:[3,4,5,9],end_dai:3,end_yr:[1,4,5],ending_dai:9,enjoi:12,epsg:[1,10],exact:12,exampl:[1,4],excel:12,exist:1,expand:12,experi:[],extract:12,fals:[4,5],fellow:[],file:[1,3,4,5,7,11],file_dir:[1,4,5,7],file_format:1,file_nam:3,filenam:[4,5,7],filesnam:[4,5],find:[],fix:11,float64:1,fn_format:[1,4,5,7],follow:[0,1],forc:[],forecast:10,form:10,format:[1,3,4,5,10,11],frequent:13,friend:[],friendli:12,from:[0,1,3,4,5,12,13],further:[1,12],futur:[4,5,7,12],gaug:12,geotiff:[1,11],get:[1,7,13],get_data:[1,5,11],get_xarrai:[1,3],git:0,github:0,give:4,given:[1,8,9,12],gov:1,grd:[1,3,4,5],grid:[0,1,3,12],had:[],hadl:[],handl:[0,3,12,13],has:10,have:[0,1],header:11,heavili:13,here:1,high:12,higher:0,histori:[1,13],home:[],homepag:10,hopefulli:12,how:[],howev:12,http:[0,1,4,11],huge:12,hydroclimat:[10,12],hydrolog:[],hydrologist:[],iamsaswata:0,idea:4,imd:[0,4,5,11],imdlib:[0,1,3,4,5,6,7,8,9,10],imdpun:[1,12],implement:4,improv:11,index:8,india:[0,12,13],indian:12,inform:[0,3,10,11,12,13],initi:[],input:[3,4,5],instal:13,integr:[],interest:12,its:1,januari:[],journei:12,land:12,larg:12,lat:[1,3,8],lat_rag:8,lat_siz:3,leap:6,lev:[],level:1,librari:[1,11],licens:13,like:[4,5,13],limit:[],link:[0,11,13],linux:0,list:[4,5],local:1,locat:1,lon:[1,3,8],lon_rang:8,lon_siz:3,look:1,made:12,mai:[10,13],main:[4,5],maintain:12,major:1,march:12,mass:12,match:12,matplotlib:0,maximum:[1,3,4,5,12],mean:[1,4,5],measur:12,metadata:10,meteorolog:[0,3,12,13],method:3,minimum:[1,3,4,5,12],miss:11,mit:13,month:3,more:[0,10,13],most:[10,12],must:[],name:10,nan:1,nandi:[2,4,13],nativ:12,need:[0,4,12],netcdf:[1,3,11,12],network:10,no_dai:3,no_of_dai:3,none:[3,4,5],note:[],number:[4,5],numpi:[0,3,4,5,12],object:[1,3,4,5],often:12,one:12,onli:[],open:[5,12],open_data:1,option:[0,1],ordin:8,origin:1,other:[1,10],our:12,out_dir:3,output:[10,11],over:12,own:[],packag:[0,13],page:[],pain:[],panda:[0,12],pangeo:12,parallel:12,password:4,past:[],patel:[2,4,13],path:1,peopl:12,phd:[],pip:0,plan:[],platform:0,plot:13,plugin:0,port:4,portal:11,possibl:[3,4,5],postdoctor:12,power:12,pratiman:[2,4,13],pre:0,prepar:12,print:1,problem:12,process:[3,4,5,11,13],produc:10,product:12,proper:[],provid:12,proxi:[4,5],publicli:[],publish:[],pune:[0,13],purpos:1,pytest:0,python:[0,1,12],pytz:0,qualiti:12,question:13,quit:[],rain:[1,3,4,5],rainfal:[1,3,4,5,12],rang:[4,5],read:[5,7,12,13],recent:12,recommend:[0,13],refer:[1,10,11,13],region:12,remov:[1,11],renam:[4,5],repres:[4,5],request:11,requir:12,research:[],resolut:12,resolv:12,resourc:[],rioxarrai:[0,1],sabyasachi:13,saswata:[2,4,13],save:[4,11,13],scholar:12,scienc:[],scientist:[],scipi:0,server:[4,5],sever:[],shape:3,should:[0,1,4,5],show:3,shown:4,six:0,small:[],sourc:[0,1],spatial:12,specif:12,specifi:[4,5],spread:12,standard:10,start:[3,4,5,9,13],start_dai:3,start_yr:[1,4,5],starting_dai:9,station:12,statu:13,step:1,store:[1,3],str:[3,4,5],studi:[10,12],sub:1,sub_dir:[4,5],subdirectori:[1,4,5],substanti:12,success:1,summari:3,support:[3,11,12],swain:13,system:[10,12],take:12,tech:12,tediou:[],temperatur:[1,3,4,5,12],tempereatur:[3,4,5],tempor:12,test:[0,1],thei:[1,4,5,10],them:12,thi:[1,12],three:[3,4,5],tif:1,time:[1,4,5,11,12],time_rang:5,timescal:12,titl:1,tmax:[1,3,4,5],tmin:[1,3,4,5],to_ascii:3,to_csv:[1,3,11],to_geotiff:[1,3,10],to_netcdf:[1,3],todai:12,tool:10,top:1,tupl:[4,5],txt:3,type:4,unam:4,under:4,univers:12,unknown:[],updat:11,upload:11,urllib3:0,usag:13,use:[1,10,12,13],used:[4,5,12],useful:12,user:[1,10,12],using:[0,1,13],util:[6,7,8,9],vale:[4,5],valu:[1,3,4,5],var_typ:[4,5,7],variabl:[1,3,4],variou:[],version:[0,10],visit:10,vital:10,wai:12,want:1,well:12,were:[],where:1,which:[4,5],window:0,without:1,won:12,work:[1,4,5,10],would:[12,13],write:3,xarrai:[0,1,3,12,13],year:[1,3,4,5,6,7],yearwis:[1,4,5],you:[0,1,4,13],zenodo:13},titles:["Description","Downloading","API reference","IMD","get_data","open_data","LeapYear","get_filename","get_lat_lon","total_days","CF conventions","Changelog History","Frequently Asked Questions","IMDLIB - a Python library for IMD gridded data"],titleterms:{"2020":11,"2021":11,"class":2,"function":2,about:13,ani:12,api:2,ask:12,can:12,changelog:11,citat:13,convent:10,core:2,data:13,dataset:1,decemb:11,depend:0,descript:0,develop:12,download:1,feburari:11,file:[10,12],frequent:12,get_data:4,get_filenam:7,get_lat_lon:8,grd:12,grid:13,histori:11,imd:[1,3,13],imdlib:[2,12,13],instal:0,know:12,leapyear:6,level:2,librari:[12,13],march:11,modul:2,netcdf:10,open_data:5,other:12,output:1,plot:1,process:[1,12],python:13,question:12,read:1,refer:2,save:1,should:12,statu:12,tool:12,top:2,total_dai:9,util:2,what:12,why:12}}) -------------------------------------------------------------------------------- /docs/_build/html/sitemap-index.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | https://imdlib.readthedocs.io/en/latest/ 6 | daily 7 | 1 8 | 9 | -------------------------------------------------------------------------------- /docs/_html/googleac2a728cd80ab282.html: -------------------------------------------------------------------------------- 1 | google-site-verification: googleac2a728cd80ab282.html -------------------------------------------------------------------------------- /docs/_html/robots.txt: -------------------------------------------------------------------------------- 1 | User-agent: * 2 | 3 | Disallow: / 4 | 5 | Allow: /en/stable 6 | 7 | Allow: /en/latest 8 | 9 | Allow: /en/develop 10 | 11 | Sitemap: https://imdlib.readthedocs.io/en/latest/sitemap-index.xml -------------------------------------------------------------------------------- /docs/_html/sitemap-index.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | https://imdlib.readthedocs.io/en/latest/ 6 | daily 7 | 1 8 | 9 | -------------------------------------------------------------------------------- /docs/api.rst: -------------------------------------------------------------------------------- 1 | ============= 2 | API reference 3 | ============= 4 | 5 | Top-level functions 6 | =================== 7 | 8 | .. automodapi:: imdlib.core 9 | :no-inheritance-diagram: 10 | 11 | .. automodapi:: imdlib.util 12 | :no-inheritance-diagram: 13 | 14 | .. automodapi:: imdlib.compute 15 | :no-inheritance-diagram: 16 | -------------------------------------------------------------------------------- /docs/api/imdlib.core.IMD.rst: -------------------------------------------------------------------------------- 1 | IMD 2 | === 3 | 4 | .. currentmodule:: imdlib.core 5 | 6 | .. autoclass:: IMD 7 | :show-inheritance: 8 | 9 | .. rubric:: Attributes Summary 10 | 11 | .. autosummary:: 12 | 13 | ~IMD.shape 14 | 15 | .. rubric:: Methods Summary 16 | 17 | .. autosummary:: 18 | 19 | ~IMD.get_xarray 20 | ~IMD.to_csv 21 | ~IMD.to_geotiff 22 | ~IMD.to_netcdf 23 | 24 | .. rubric:: Attributes Documentation 25 | 26 | .. autoattribute:: shape 27 | 28 | .. rubric:: Methods Documentation 29 | 30 | .. automethod:: get_xarray 31 | .. automethod:: to_csv 32 | .. automethod:: to_geotiff 33 | .. automethod:: to_netcdf 34 | -------------------------------------------------------------------------------- /docs/api/imdlib.core.get_data.rst: -------------------------------------------------------------------------------- 1 | get_data 2 | ======== 3 | 4 | .. currentmodule:: imdlib.core 5 | 6 | .. autofunction:: get_data 7 | -------------------------------------------------------------------------------- /docs/api/imdlib.core.open_data.rst: -------------------------------------------------------------------------------- 1 | open_data 2 | ========= 3 | 4 | .. currentmodule:: imdlib.core 5 | 6 | .. autofunction:: open_data 7 | -------------------------------------------------------------------------------- /docs/api/imdlib.util.LeapYear.rst: -------------------------------------------------------------------------------- 1 | LeapYear 2 | ======== 3 | 4 | .. currentmodule:: imdlib.util 5 | 6 | .. autofunction:: LeapYear 7 | -------------------------------------------------------------------------------- /docs/api/imdlib.util.get_filename.rst: -------------------------------------------------------------------------------- 1 | get_filename 2 | ============ 3 | 4 | .. currentmodule:: imdlib.util 5 | 6 | .. autofunction:: get_filename 7 | -------------------------------------------------------------------------------- /docs/api/imdlib.util.get_lat_lon.rst: -------------------------------------------------------------------------------- 1 | get_lat_lon 2 | =========== 3 | 4 | .. currentmodule:: imdlib.util 5 | 6 | .. autofunction:: get_lat_lon 7 | -------------------------------------------------------------------------------- /docs/api/imdlib.util.total_days.rst: -------------------------------------------------------------------------------- 1 | total_days 2 | ========== 3 | 4 | .. currentmodule:: imdlib.util 5 | 6 | .. autofunction:: total_days 7 | -------------------------------------------------------------------------------- /docs/cf-conventions.rst: -------------------------------------------------------------------------------- 1 | .. _cf-conventions: 2 | 3 | CF conventions 4 | ========================== 5 | 6 | NetCDF File Convention 7 | ----------------------- 8 | 9 | The IMDLIB produces netCDF (network Common Data Form) based final output. It is the most common data format in hydroclimatic studies. The netCDF Climate and Forecast (CF) Metadata Conventions, Version 1.7, has been adopted by IMDLIB for the efficient and consistent use with other standard netCDF tools/applications. The EPSG:4326 coordinate reference systems (CRS) are considered in the CF naming convention. They are vital for the function to_geotiff to work correctly. Users may visit the `CF Conventions homepage`_ for more information. 10 | 11 | .. _CF Conventions homepage: https://cfconventions.org/ 12 | 13 | .. image:: savefig/fig2.jpg 14 | :width: 700 15 | -------------------------------------------------------------------------------- /docs/changelog.rst: -------------------------------------------------------------------------------- 1 | Changelog History 2 | ================= 3 | 4 | 5 | v0.1.15 (06 January 2023) 6 | -------------------------- 7 | 8 | * Added support for real-time daily IMD rainfall (0.25\ :sup:`o`\) and temperature data (0.5\ :sup:`o`\) 9 | 10 | v0.1.14 (11 October 2022) 11 | -------------------------- 12 | 13 | * Updated download url (https://imdpune.gov.in/Clim_Pred_LRF_New >> https://imdpune.gov.in/cmpg/Griddata) 14 | 15 | * added module for standard version check (e.g. imdlib.__version__) 16 | 17 | v0.1.11 (12 March 2021) 18 | -------------------------- 19 | 20 | * Updated docs 21 | 22 | * Fixed missing libraries for conda upload 23 | 24 | 25 | v0.1.10 (27 Feburary 2021) 26 | -------------------------- 27 | 28 | * Removed requests as dependency. 29 | 30 | * Added API references. 31 | 32 | * Improvement in the docs. 33 | 34 | * Updated `to_csv` to save file with time information and header. 35 | 36 | 37 | v0.1.9 (30 December 2020) 38 | ------------------------- 39 | 40 | * Added CF-1.7 conventions for the NetCDF output. 41 | 42 | * Added support for converting data into GeoTIFF format. 43 | 44 | * Improvement in the return process the imd.get_data() functionality 45 | 46 | * Updated link for the new https based IMD data portal 47 | -------------------------------------------------------------------------------- /docs/climate-indices.rst: -------------------------------------------------------------------------------- 1 | .. _climate-indices: 2 | 3 | Available Climate-Indices 4 | ========================= 5 | 6 | 7 | .. tabularcolumns:: |p{1cm}|p{7cm}| 8 | 9 | .. csv-table:: 10 | :file: tbl/climate-indices.csv 11 | :header-rows: 1 12 | :class: longtable 13 | :widths: 1 1 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /docs/conf.py: -------------------------------------------------------------------------------- 1 | # Configuration file for the Sphinx documentation builder. 2 | # 3 | # This file only contains a selection of the most common options. For a full 4 | # list see the documentation: 5 | # https://www.sphinx-doc.org/en/master/usage/configuration.html 6 | 7 | # -- Path setup -------------------------------------------------------------- 8 | 9 | # If extensions (or modules to document with autodoc) are in another directory, 10 | # add these directories to sys.path here. If the directory is relative to the 11 | # documentation root, use os.path.abspath to make it absolute, like shown here. 12 | # 13 | # import os 14 | # import sys 15 | # sys.path.insert(0, os.path.abspath('.')) 16 | 17 | 18 | # -- Project information ----------------------------------------------------- 19 | 20 | project = 'IMDLIB' 21 | copyright = '2022, Saswata Nandi, Pratiman Patel and Sabyasachi Swain' 22 | author = 'Saswata Nandi, Pratiman Patel and Sabyasachi Swain' 23 | 24 | 25 | # -- General configuration --------------------------------------------------- 26 | 27 | # Add any Sphinx extension module names here, as strings. They can be 28 | # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom 29 | # ones. 30 | extensions = ['sphinx_rtd_theme', 31 | 'sphinx_automodapi.automodapi', 32 | 'sphinx_automodapi.smart_resolver' 33 | ] 34 | 35 | # Add any paths that contain templates here, relative to this directory. 36 | templates_path = ['_templates'] 37 | 38 | # List of patterns, relative to source directory, that match files and 39 | # directories to ignore when looking for source files. 40 | # This pattern also affects html_static_path and html_extra_path. 41 | exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] 42 | 43 | 44 | # -- Options for HTML output ------------------------------------------------- 45 | 46 | # The theme to use for HTML and HTML Help pages. See the documentation for 47 | # a list of builtin themes. 48 | # 49 | html_theme = 'sphinx_rtd_theme' 50 | 51 | # Add any paths that contain custom static files (such as style sheets) here, 52 | # relative to this directory. They are copied after the builtin static files, 53 | # so a file named "default.css" will overwrite the builtin "default.css". 54 | html_static_path = ['_static'] 55 | html_extra_path = ["_html"] 56 | -------------------------------------------------------------------------------- /docs/faq.rst: -------------------------------------------------------------------------------- 1 | .. _faq: 2 | 3 | Frequently Asked Questions 4 | ========================== 5 | 6 | Why IMDLIB? 7 | ----------- 8 | 9 | The contemporary hydroclimatic studies require a huge data handling. Recently, the high-resolution gridded meteorological datasets, i.e., Rainfall (0.25° x 0.25°), Maximum and Minimum Temperature (1° x 1°) at daily timescale are made open-access. This gridded dataset for India was prepared considering measurements from well-spread gauge stations over the Indian land region after expanded quality controls. However, extraction of data for our area of interest often consumes substantial time and effort. IMDLIB resolves this problem by providing an easy and user-friendly way to extract continuous gridded data. 10 | 11 | Can IMDLIB process any GRD file? 12 | -------------------------------- 13 | No. For handling any binary dataset, one needs to know the exact dimension (both spatial and 14 | temporal) of the given data. IMDLIB takes this information from `imdpune`_. So, if the data 15 | dimension doesn't match with that of IMDLIB, it won't be able to read or further 16 | process them. 17 | 18 | .. _imdpune: http://imdpune.gov.in/Clim_Pred_LRF_New/Grided_Data_Download.html 19 | 20 | What is the development status of the IMDLIB library? 21 | ----------------------------------------------------- 22 | 23 | As of today (March 2021), IMDLIB is used by a large mass of people, specifically the M.Tech, Ph.D. and postdoctoral scholars across India. We would continue and maintain IMDLIB in the future as well. IMDLIB is a useful library that we enjoyed building during our Ph.D. journey. 24 | 25 | What other tools should I know? 26 | -------------------------------------- 27 | 28 | For handling the gridded data, the netCDF file system is universally adopted. The `xarray`_ 29 | is an excellent library for handling netCDF data in python. If one needs parallel support, 30 | `Dask`_ provides advanced parallelism for analytics. But, both of them use `numpy`_ / `pandas`_ 31 | as the core for building their final product. Hopefully, `pangeo`_ will emerge as one of the most powerful tools for data analytics in the cloud-native future. 32 | 33 | .. _xarray: http://xarray.pydata.org/en/stable/ 34 | .. _dask: https://dask.org/ 35 | .. _numpy: https://numpy.org/ 36 | .. _pandas: http://pandas.pydata.org/ 37 | .. _pangeo: https://pangeo-data.github.io/ 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /docs/index.rst: -------------------------------------------------------------------------------- 1 | .. imdlib documentation master file, created by 2 | sphinx-quickstart on Wed Dec 30 16:00:48 2021. 3 | You can adapt this file completely to your liking, but it should at least 4 | contain the root `toctree` directive. 5 | 6 | IMDLIB - a Python library for IMD gridded data 7 | ============================================== 8 | 9 | IMDLIB is a python package to download and handle binary gridded data from the India Meteorological 10 | Department (IMD). For more information about the IMD datasets, the link of 11 | `IMD Pune`_ may be referred. It heavily employs the `xarray`_ for processing the datasets. 12 | 13 | .. _IMD Pune: https://imdpune.gov.in/lrfindex.php 14 | .. _xarray: http://xarray.pydata.org/en/stable/ 15 | 16 | .. toctree:: 17 | :maxdepth: 1 18 | :caption: Getting Started 19 | 20 | Description 21 | 22 | .. toctree:: 23 | :maxdepth: 1 24 | :caption: Usage 25 | 26 | Usage 27 | 28 | .. toctree:: 29 | :maxdepth: 1 30 | :caption: Reference 31 | 32 | faq 33 | climate-indices 34 | changelog 35 | cf-conventions 36 | publication 37 | api 38 | 39 | Citation 40 | -------- 41 | 42 | If you are using imdlib and would like to cite it in academic publication, we recommend to use the zenodo DOI: 43 | 44 | .. image:: https://zenodo.org/badge/235463327.svg 45 | :target: https://doi.org/10.5281/zenodo.4405233 46 | 47 | About 48 | ----- 49 | 50 | :License: 51 | MIT License 52 | 53 | :Status: 54 | .. image:: https://badge.fury.io/py/imdlib.svg 55 | :target: https://badge.fury.io/py/imdlib 56 | .. image:: https://anaconda.org/iamsaswata/imdlib/badges/version.svg 57 | :target: https://anaconda.org/iamsaswata/imdlib 58 | .. image:: https://zenodo.org/badge/235463327.svg 59 | :target: https://doi.org/10.5281/zenodo.4405233 60 | 61 | :Documentation: 62 | .. image:: https://readthedocs.org/projects/imdlib/badge/?version=stable 63 | :target: http://imdlib.readthedocs.io/?badge=stable 64 | 65 | :Contact: 66 | * `Saswata Nandi `__ 67 | * `Pratiman Patel `__ 68 | * `Sabyasachi Swain `__ 69 | 70 | .. meta:: 71 | :description: IMDLIB is a python package library to download IMD gridded data 72 | :keywords: imdlib, IMDLIB, imd, IMD, python, India, gridded rainfall, gridded temperature 73 | -------------------------------------------------------------------------------- /docs/make.bat: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | pushd %~dp0 4 | 5 | REM Command file for Sphinx documentation 6 | 7 | if "%SPHINXBUILD%" == "" ( 8 | set SPHINXBUILD=sphinx-build 9 | ) 10 | set SOURCEDIR=. 11 | set BUILDDIR=_build 12 | 13 | if "%1" == "" goto help 14 | 15 | %SPHINXBUILD% >NUL 2>NUL 16 | if errorlevel 9009 ( 17 | echo. 18 | echo.The 'sphinx-build' command was not found. Make sure you have Sphinx 19 | echo.installed, then set the SPHINXBUILD environment variable to point 20 | echo.to the full path of the 'sphinx-build' executable. Alternatively you 21 | echo.may add the Sphinx directory to PATH. 22 | echo. 23 | echo.If you don't have Sphinx installed, grab it from 24 | echo.http://sphinx-doc.org/ 25 | exit /b 1 26 | ) 27 | 28 | %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% 29 | goto end 30 | 31 | :help 32 | %SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% 33 | 34 | :end 35 | popd 36 | -------------------------------------------------------------------------------- /docs/publication.rst: -------------------------------------------------------------------------------- 1 | ============= 2 | Publications 3 | ============= 4 | 5 | Publications using IMDLIB 6 | ========================= 7 | 8 | 9 | Bora, S., & Hazarika, A. (2023, April). Rainfall time series forecasting using ARIMA model. In 2023 ATCON-1, (pp. 1-5). *IEEE*, https://doi.org/10.1109/ICAIA57370.2023.10169493 10 | 11 | Panja, A., Garai, S., Zade, S., Veldandi, A., Sahani, S., & Maiti, S. (2023). Climate Data Extraction for Social Science Research: A Step by Step Process. *Social Science Dimensions of Climate Resilient Agriculture*, ISBN: 978-81-964762-1-2. 12 | 13 | Chakra, S., Ganguly, A., Oza, H., Padhya, V., Pandey, A., & Deshpande, R. D. (2023). Multidecadal summer monsoon rainfall trend reversals in South Peninsular India: a new approach to examining long-term rainfall dataset. *Journal of Hydrology*. https://doi.org/10.1016/j.jhydrol.2023.129975. 14 | 15 | Sardar, P., and Samadder, S. R. (2023).  Long-term ecological vulnerability assessment of indian sundarban region under present and future climatic conditions under CMIP6 model. *Ecological Informatics*. https://doi.org/10.1016/j.ecoinf.2023.102140 16 | 17 | Roy, P. K., Ghosh, A., Basak, S. K., Mohinuddin, S., & Roy M. B. (2023).  Analysing the Role of AHP Model to Identify Flood Hazard Zonation in a Coastal Island, India. *Journal of the Indian Society of Remote Sensing Article*, 1-15. https://doi.org/10.1007/s12524-023-01697-x 18 | 19 | Kundu, M., Zafor, A., & Maiti, R. (2023). Assessing the nature of potential groundwater zones through machine learning (ML) algorithm in tropical plateau region, West Bengal, India. *Acta Geophysica*, 1-16. https://doi.org/10.1007/s11600-023-01042-3 20 | 21 | Venkatesh, S., Kirubakaran, T., Ayaz, R. M., Umar, S. M., & Parimalarenganayaki, S. (2023). Non-parametric Approaches to Identify Rainfall Pattern in Semi-Arid Regions: Ranipet, Vellore, and Tirupathur Districts, Tamil Nadu, India. *In River Dynamics and Flood Hazards* (pp. 507-525). Springer, Singapore. https://doi.org/10.1007/978-981-19-7100-6_28 22 | 23 | Swain, S., Mishra, S. K., Pandey, A., & Dayal, D. (2022). Assessment of drought trends and variabilities over the agriculture-dominated Marathwada Region, India. *Environmental Monitoring and Assessment, 194(12)*, 1-18. 24 | https://doi.org/10.1007/s10661-022-10532-8 25 | 26 | Swain, S., Mishra, S. K., Pandey, A., Dayal, D., & Srivastava, P. K. (2022). Appraisal of historical trends in maximum and minimum temperature using multiple non-parametric techniques over the agriculture-dominated Narmada Basin, India. *Environmental Monitoring and Assessment*, 194(12), 1-23. https://doi.org/10.1007/s10661-022-10534-6 27 | 28 | -------------------------------------------------------------------------------- /docs/requirements.txt: -------------------------------------------------------------------------------- 1 | sphinx-automodapi 2 | imdlib 3 | -------------------------------------------------------------------------------- /docs/savefig/fig1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/savefig/fig1.png -------------------------------------------------------------------------------- /docs/savefig/fig2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/iamsaswata/imdlib/0dad3bffc84219d08e1559d4117bf5bda6452118/docs/savefig/fig2.jpg -------------------------------------------------------------------------------- /docs/tbl/climate-indices.csv: -------------------------------------------------------------------------------- 1 | Index ,Description 2 | Rainy days (dr) ,Total number of days in a year with rainfall over a threshold (default: 2.5 mm) 3 | Consecutive wet days (cwd),The maximum length of wet spell (maximum consecutive days in a year with precipitation ≥ a threshold (default: 2.5 mm)) 4 | Heavy precipitation days (d64),The number of days in a year with precipitation ≥ a threshold (default: 64 mm) 5 | Total precipitation in wet days (rtwd),The sum of precipitation in all the rainy days of a year 6 | Maximum daily rainfall (rxa),The maximum daily rainfall in a year 7 | Maximum 5-days rainfall (rx5d),The highest magnitude of rainfall accumulations for consecutive 5 days in a year 8 | Simple daily intensity index (sdii),It represents the average intensity of a rainy day over a year (computed as the ratio of rtwd and dr) 9 | Precipitation concentration index (pci),An indicator for temporal precipitation distribution (represents how uniformly annual precipitation is istributed in the months) 10 | Coolest night (mnadt),Minimum value of temperature over a year (the least daily TMIN value of a year) 11 | Hottest day (mxadt),Maximum value of temperature over a year (the highest daily TMAX value of a year) 12 | Diurnal Temperature Range (dtr),"The difference between the maximum and minimum temperature of a year (i.e., the difference between mxadt and mnadt)" 13 | Modified Mann-Kendall test statistic (mmk_hr),The trend detecting statistic of the non-parametric MMK test advocated by Hamed and Rao (1998) 14 | Spearman’s Rho statistics (spr),The trend detecting statistic of the non-parametric Spearman’s Rho test 15 | Sen’s slope estimate (sse),"The trend detecting statistic (i.e., slope) of Sen’s slope" 16 | Magnitude of trend (sstr),The ratio of product of Sen’s slope (sse) with number of data points to the mean value (expressed in terms of percentage) 17 | -------------------------------------------------------------------------------- /imdlib/__init__.py: -------------------------------------------------------------------------------- 1 | from imdlib.core import IMD, open_data, get_data 2 | from imdlib.util import LeapYear, get_lat_lon, total_days, get_filename, get_filename_realtime 3 | from imdlib.real import open_real_data, get_real_data 4 | from .version import __version__ 5 | -------------------------------------------------------------------------------- /imdlib/naming.py: -------------------------------------------------------------------------------- 1 | # Dictionary of functions 2 | # Representing long name in netcdf data 3 | 4 | long_name_dict_anu = { 5 | "cwd": "Consecutive wet days", 6 | "dr": "Rainy days", 7 | "dtr": "Diurnal Temperature Range", 8 | "d64": "Heavy precipitation days", 9 | "mmk_hr": "Modified Mann-Kendall[Hamed and Rao, 1998] statistics (Z)", 10 | "mnadt": "Min. Annual Daily Tmin (Coolest Night)", 11 | "mxadt": "Max. Annual Daily Tmax (Hottest Day)", 12 | "pci": "Precipitation concentration index", 13 | "rtwd": "Total precipitation in wet days", 14 | "rx5d": "Maximum 5 days rainfall", 15 | "rxa": "Maximum annual rainfall", 16 | "sdii": "Simple precipitation intensity index", 17 | "spr": "Spearman’s Rho statistics (Zsr)", 18 | "sse": "Sen’s slope estimates", 19 | "sstr": "Magnitude of trend" 20 | } 21 | 22 | # Dictionary of functions 23 | # Representing short name in netcdf data 24 | 25 | short_name_dict = { 26 | "cwd": "cwd", 27 | "dr": "dr", 28 | "dtr": "dtr", 29 | "d64": "d64", 30 | "mmk_hr": "mmk_hr", 31 | "mnadt": "mnadt", 32 | "mxadt": "mxadt", 33 | "pci": "pci", 34 | "rtwd": "rtwd", 35 | "rx5d": "rx5d", 36 | "rxa": "rxa", 37 | "sdii": "sdii", 38 | "spr": "spr", 39 | "sse": "sse", 40 | "sstr": "sstr" 41 | } 42 | 43 | # Dictionary of functions 44 | # Representing untits in netcdf data 45 | 46 | units_dic_anu = { 47 | "cwd": "Days", 48 | "dr": "Days", 49 | "dtr": "C", 50 | "d64": "Days", 51 | "mmk_hr": "Z", 52 | "mnadt": "C", 53 | "mxadt": "C", 54 | "pci": "", 55 | "rtwd": "mm/year", 56 | "rx5d": "mm/year", 57 | "rxa": "mm", 58 | "sdii": "", 59 | "spr": "Zsr", 60 | "sse": "Slope", 61 | "sstr": "%" 62 | } 63 | -------------------------------------------------------------------------------- /imdlib/util.py: -------------------------------------------------------------------------------- 1 | import numpy as np 2 | from datetime import date 3 | from pathlib import Path 4 | 5 | 6 | def LeapYear(year): 7 | """ 8 | Check leap year or not 9 | """ 10 | if (year % 4) == 0: 11 | if (year % 100) == 0: 12 | if (year % 400) == 0: 13 | return True 14 | else: 15 | return False 16 | else: 17 | return True 18 | else: 19 | return False 20 | 21 | 22 | def get_lat_lon(lat, lon, lat_rage, lon_range): 23 | """ 24 | Check INDEX of closest lat lon for a given co-ordinate 25 | """ 26 | lat_index = np.abs(lat_rage - lat).argmin() 27 | lon_index = np.abs(lon_range - lon).argmin() 28 | return lat_index, lon_index 29 | 30 | 31 | def total_days(starting_day, ending_day): 32 | """ 33 | Calculate to no of days for a given starting and ending day 34 | """ 35 | start_year = int(starting_day[0:4]) 36 | start_month = int(starting_day[5:7]) 37 | start_day = int(starting_day[8:10]) 38 | end_year = int(ending_day[0:4]) 39 | end_month = int(ending_day[5:7]) 40 | end_day = int(ending_day[8:10]) 41 | days = date(end_year, end_month, end_day) - date( 42 | start_year, start_month, start_day) 43 | return days.days + 1 44 | 45 | 46 | def get_filename(year, var_type, fn_format, file_dir): 47 | """ 48 | Get filename for reading the file content in future 49 | """ 50 | if var_type == 'rain': 51 | if file_dir is not None: 52 | if fn_format == 'yearwise': 53 | if Path('{}{}{}'.format(file_dir, '/', var_type)).exists(): 54 | fname = file_dir + '/' + var_type + '/' + \ 55 | str(year) + '.grd' 56 | else: 57 | fname = file_dir + '/' + str(year) + '.grd' 58 | else: 59 | if Path('{}{}{}'.format(file_dir, '/', var_type)).exists(): 60 | fname = file_dir + '/' + var_type + '/' + \ 61 | 'Rainfall_ind' + str(year) + '_rfp25.grd' 62 | else: 63 | fname = file_dir + '/' + 'Rainfall_ind' + str(year) + '_rfp25.grd' 64 | else: 65 | if fn_format == 'yearwise': 66 | if Path(var_type).exists(): 67 | fname = var_type + '/' + str(year) + '.grd' 68 | else: 69 | fname = str(year) + '.grd' 70 | else: 71 | if Path(var_type).exists(): 72 | fname = var_type + '/' + 'Rainfall_ind' + str(year) + '_rfp25.grd' 73 | else: 74 | fname = 'Rainfall_ind' + str(year) + '_rfp25.grd' 75 | 76 | elif var_type == 'tmax': 77 | 78 | if file_dir is not None: 79 | if fn_format == 'yearwise': 80 | if Path('{}{}{}'.format(file_dir, '/', var_type)).exists(): 81 | fname = file_dir + '/' + var_type + '/' + \ 82 | str(year) + '.GRD' 83 | else: 84 | fname = file_dir + '/' + str(year) + '.GRD' 85 | else: 86 | if Path('{}{}{}'.format(file_dir, '/', var_type)).exists(): 87 | fname = file_dir + '/' + var_type + '/' + 'Maxtemp_MaxT_' + \ 88 | str(year) + '.GRD' 89 | else: 90 | fname = file_dir + '/' + 'Maxtemp_MaxT_' + str(year) + '.GRD' 91 | 92 | else: 93 | if fn_format == 'yearwise': 94 | if Path(var_type).exists(): 95 | fname = var_type + '/' + str(year) + '.GRD' 96 | else: 97 | fname = str(year) + '.GRD' 98 | 99 | else: 100 | if Path(var_type).exists(): 101 | fname = var_type + '/' + 'Maxtemp_MaxT_' + str(year) + '.GRD' 102 | else: 103 | fname = 'Maxtemp_MaxT_' + str(year) + '.GRD' 104 | 105 | elif var_type == 'tmin': 106 | 107 | if file_dir is not None: 108 | if fn_format == 'yearwise': 109 | if Path('{}{}{}'.format(file_dir, '/', var_type)).exists(): 110 | fname = file_dir + '/' + var_type + '/' + str(year) + \ 111 | '.GRD' 112 | else: 113 | fname = file_dir + '/' + str(year) + '.GRD' 114 | else: 115 | if Path('{}{}{}'.format(file_dir, '/', var_type)).exists(): 116 | fname = file_dir + '/' + var_type + '/' + 'Mintemp_MinT_' + \ 117 | str(year) + '.GRD' 118 | else: 119 | fname = file_dir + '/' + 'Mintemp_MinT_' + str(year) + '.GRD' 120 | 121 | else: 122 | if fn_format == 'yearwise': 123 | if Path(var_type).exists(): 124 | fname = var_type + '/' + str(year) + '.GRD' 125 | else: 126 | fname = str(year) + '.GRD' 127 | 128 | else: 129 | if Path(var_type).exists(): 130 | fname = var_type + '/' + 'Mintemp_MinT_' + str(year) + '.GRD' 131 | else: 132 | fname = 'Mintemp_MinT_' + str(year) + '.GRD' 133 | 134 | else: 135 | raise Exception("Error in variable type declaration." 136 | " It must be 'rain'/'temp'/'tmax'.") 137 | 138 | return fname 139 | 140 | 141 | def get_filename_realtime(day, var_type, file_dir): 142 | """ 143 | Get filename for reading the real-time file content in future 144 | """ 145 | if var_type == 'rain': 146 | if file_dir is not None: 147 | fname = file_dir + '/' + 'rain_ind0.25_' + day.strftime("%y_%m_%d") + '.grd' 148 | else: 149 | fname = 'rain_ind0.25_' + day.strftime("%y_%m_%d") + '.grd' 150 | 151 | elif var_type == 'tmax': 152 | 153 | if file_dir is not None: 154 | fname = file_dir + '/' + 'max' + day.strftime("%d%m%Y") + '.grd' 155 | else: 156 | fname = 'max' + day.strftime("%d%m%Y") + '.grd' 157 | 158 | elif var_type == 'tmin': 159 | 160 | if file_dir is not None: 161 | fname = file_dir + '/' + 'min' + day.strftime("%d%m%Y") + '.grd' 162 | else: 163 | fname = 'min' + day.strftime("%d%m%Y") + '.grd' 164 | 165 | else: 166 | raise Exception("Error in variable type declaration." 167 | " It must be 'rain'/'temp'/'tmax'.") 168 | 169 | return fname 170 | -------------------------------------------------------------------------------- /imdlib/version.py: -------------------------------------------------------------------------------- 1 | __version__ = '0.1.20' 2 | -------------------------------------------------------------------------------- /make.bat: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | pushd %~dp0 4 | 5 | REM Command file for Sphinx documentation 6 | 7 | if "%SPHINXBUILD%" == "" ( 8 | set SPHINXBUILD=sphinx-build 9 | ) 10 | set SOURCEDIR=source 11 | set BUILDDIR=build 12 | 13 | if "%1" == "" goto help 14 | 15 | %SPHINXBUILD% >NUL 2>NUL 16 | if errorlevel 9009 ( 17 | echo. 18 | echo.The 'sphinx-build' command was not found. Make sure you have Sphinx 19 | echo.installed, then set the SPHINXBUILD environment variable to point 20 | echo.to the full path of the 'sphinx-build' executable. Alternatively you 21 | echo.may add the Sphinx directory to PATH. 22 | echo. 23 | echo.If you don't have Sphinx installed, grab it from 24 | echo.http://sphinx-doc.org/ 25 | exit /b 1 26 | ) 27 | 28 | %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% 29 | goto end 30 | 31 | :help 32 | %SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% 33 | 34 | :end 35 | popd 36 | -------------------------------------------------------------------------------- /meta.yaml: -------------------------------------------------------------------------------- 1 | package: 2 | name: imdlib 3 | version: 0.1.20 4 | build: 5 | script_env: 6 | - VERSION 7 | - CONDA_BLD_PATH 8 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | certifi 2 | matplotlib 3 | numpy 4 | pandas 5 | python-dateutil 6 | pytz 7 | scipy 8 | six 9 | xarray 10 | pytest 11 | urllib3 12 | requests 13 | -------------------------------------------------------------------------------- /setup.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # -*- coding: utf-8 -*- 3 | """ 4 | :copyright: (c) 2023 by Saswata Nandi 5 | :license: MIT, see LICENSE for more details. 6 | """ 7 | import os 8 | import sys 9 | 10 | from setuptools import setup, find_packages 11 | from setuptools.command.install import install 12 | 13 | # imdlib version 14 | VERSION = "0.1.20" 15 | 16 | 17 | def readme(): 18 | """print long description""" 19 | with open('README.md') as f: 20 | return f.read() 21 | 22 | 23 | setup( 24 | name="imdlib", 25 | version="0.1.20", 26 | author="Saswata Nandi", 27 | author_email="iamsaswata@yahoo.com", 28 | description="A tool for handling and downloading IMD gridded data", 29 | long_description=readme(), 30 | long_description_content_type="text/markdown", 31 | url="https://github.com/iamsaswata/", 32 | license="MIT", 33 | packages=find_packages(), 34 | classifiers=[ 35 | "Programming Language :: Python :: 3", 36 | "License :: OSI Approved :: MIT License", 37 | "Operating System :: OS Independent", 38 | "Development Status :: 4 - Beta", 39 | "Intended Audience :: Developers", 40 | "Intended Audience :: Science/Research", 41 | "License :: OSI Approved :: MIT License", 42 | "Operating System :: OS Independent", 43 | "Topic :: Scientific/Engineering :: Hydrology", 44 | ], 45 | python_requires='>=3.0', 46 | 47 | keywords='imd, India, rainfall, data, hydrology, IMD, grid, grided, gridded', 48 | # packages=['':'cct_nn'], 49 | install_requires=['matplotlib', 50 | 'numpy', 51 | 'pandas', 52 | 'six', 53 | 'pandas', 54 | 'python-dateutil', 55 | 'pytz', 56 | 'urllib3', 57 | 'scipy', 58 | 'xarray', 59 | 'requests', ] 60 | ) 61 | -------------------------------------------------------------------------------- /test/changes.log: -------------------------------------------------------------------------------- 1 | 1. Remove requests as dependency [Done] 2 | 2. Adding api references [Done] 3 | 3. Improve the typos 4 | 4. to_csv added better csv file with dates [Done] 5 | -------------------------------------------------------------------------------- /test/test.py: -------------------------------------------------------------------------------- 1 | import imdlib as imd 2 | import os 3 | 4 | 5 | def test_read(): 6 | cwd = os.path.dirname(os.path.abspath(__file__)) 7 | #/home/travis/build/iamsaswata/imdlib 8 | a = imd.open_data((2018, 2018), 'rain','yearwise', cwd) 9 | assert a.data.shape == (365,135,129) 10 | 11 | 12 | #a.shape 13 | #b = a.get_xarray() 14 | # plt.show(b.mean('time').plot()) 15 | --------------------------------------------------------------------------------