pdrtpy


Namepdrtpy JSON
Version 2.3.1 PyPI version JSON
download
home_pagehttp://dustem.astro.umd.edu
SummaryPhotoDissociation Region Toolbox (PDRT), astrophysics analysis tools
upload_time2023-02-06 18:20:09
maintainer
docs_urlNone
authorMarc W. Pound, Mark G. Wolfire
requires_python>=3.8
licenseGPLv3
keywords pdr photodissociation astronomy astrophysics
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            *******************************************
PhotoDissociation Region Toolbox --- Python
*******************************************

*Reliable astrophysics at everyday low, low prices!* |reg| 

------------------------------------------------------------

.. image:: https://img.shields.io/badge/ascl-1102.022-blue.svg?colorB=262255&style=plastic
   :target: http://ascl.net/1102.022
   :alt: Astrophysics Source Code Library 1102.022

.. image:: http://www.repostatus.org/badges/latest/active.svg?style=plastic
 :target: http://www.repostatus.org/#active
 :alt: Project Status: Active - The project has reached a stable, usable state and is being actively developed.

.. image:: https://img.shields.io/pypi/pyversions/pdrtpy.svg?style=plastic
 :target: https://img.shields.io/pypi/pyversions/pdrtpy.svg?style=plastic
 :alt: Python version

.. image:: https://img.shields.io/badge/License-GPLv3-blue.svg?style=plastic
 :target: https://www.gnu.org/licenses/gpl-3.0
 :alt: GNU GPL v3 License
 
.. image:: https://readthedocs.org/projects/pdrtpy/badge/?version=latest&style=plastic
 :target: https://pdrtpy.readthedocs.io/en/latest/?badge=latest
 :alt: Documentation status
 
.. image:: https://img.shields.io/badge/Contributor%20Covenant-2.1-4baaaa.svg?style=plastic
 :target: https://github.com/mpound/pdrtpy/blob/master/CODE_OF_CONDUCT.md
 :alt: Contributor Covenant Code of Conduct  

.. image:: https://github.com/mpound/pdrtpy/actions/workflows/run-integration-tests.yml/badge.svg
 :alt: Integration test status

.. image:: https://github.com/mpound/pdrtpy/blob/master/coverage.svg
 :alt: Code coverage

.. image:: https://app.codacy.com/project/badge/Grade/dfa0433c8679423ca57cc75a84dc9083
 :alt: Codacy quality grade

``pdrtpy`` is the new and improved version of the formerly web-based `PhotoDissociation Region Toolbox <http://dustem.astro.umd.edu/>`_, rewritten in Python with new capabilities and giving more flexibility to end users.  (The web-based /CGI version of PDRT is deprecated and no longer supported). 

The PDR Toolbox is a science-enabling tool for the community, designed to
help astronomers determine the physical parameters of photodissociation
regions from observations. Typical observations of both Galactic
and extragalactic PDRs come from ground- and space-based millimeter,
submillimeter, and far-infrared telescopes such as ALMA, SOFIA, JWST,
Spitzer, and Herschel. Given a set of observations of spectral line or
continuum intensities, PDR Toolbox can compute best-fit FUV incident
intensity and cloud density based on our models of PDR emission.

The PDR Toolbox will cover a wide range of spectral lines and metallicities
and allows map-based analysis so users can quickly compute spatial
images of density and radiation field from map data.  We provide Jupyter
`Example Notebooks`_ for data analysis.  It also can support models from
other PDR codes enabling comparison of derived properties between codes.

The underlying PDR model code has improved physics and chemistry. Critical updates include those discussed in 
`Neufeld & Wolfire 2016 <https://ui.adsabs.harvard.edu/abs/2016ApJ...826..183N/abstract>`_, plus photo rates from 
`Heays et al. 2017 <https://ui.adsabs.harvard.edu/abs/2017A%26A...602A.105H/abstract>`_, oxygen chemistry rates from 
`Kovalenko et al. 2018 <https://ui.adsabs.harvard.edu/abs/2018ApJ...856..100K/abstract>`_ and 
`Tran et al. 2018 <https://ui.adsabs.harvard.edu/abs/2018ApJ...854...25T/abstract>`_, 
and carbon chemistry rates from 
`Dagdigian 2019 <https://ui.adsabs.harvard.edu/abs/2019MNRAS.487.3427D/abstract>`_. We have also implemented new collisional
excitation rates for |OI| from
`Lique et al. 2018 <https://ui.adsabs.harvard.edu/abs/2018MNRAS.474.2313L/abstract>`_ (and Lique private
communication) and have included |13C| chemistry along with the
emitted line intensities for  |13CII| and |13CO|.

We also support fitting of temperatures and column densities to |H2| excitation diagrams.

Up to date documentation can be found at `pdrtpy.readthedocs.io <http://pdrtpy.readthedocs.io/>`_.

What is a PDR? 
==============
Photodissociation regions (PDRs) include all of the neutral gas in the
ISM where far-ultraviolet (FUV) photons dominate the chemistry and/or
heating.  In regions of massive star formation, PDRS are created at
the boundaries between the HII regions and neutral molecular cloud,
as photons with energies 6 eV < h \nu < 13.6 eV.
photodissociate molecules and photoionize other elements.  The gas is
heated from photo-electrons and cools mostly through far-infrared fine
structure lines like   |OI| and  |CII|.

For a full review of PDR physics and chemistry, see `Hollenbach & Tielens 1997 <https://ui.adsabs.harvard.edu/abs/1997ARA&A..35..179H>`_.

Getting Started
===============

Installation
------------

Requirements
^^^^^^^^^^^^

``pdrtpy`` requires Python 3 and recent versions of  `astropy <https://astropy.org>`_, `numpy <https://numpy.org>`_, `scipy <https://scipy.org>`_, `lmfit <https://lmfit.github.io/lmfit-py/>`_, and `matplotlib <https://matplotlib.org/>`_. If you want to run the `Example Notebooks`_, you also need `jupyter <https://jupyter.org>`_.

First make sure you are using Python 3:

.. code-block:: sh

   python --version

should show e.g., *3.7.6*. 


.. Also, make sure *setuptools* is up to date:

.. .. code-block:: sh

..   pip install -U setuptools

Install the package
^^^^^^^^^^^^^^^^^^^

With pip
--------
Python has numerous ways to install packages; the easiest is with *pip*. 
The code is hosted at the `Python Packaging Index <https://pypi.org/project/pdrtpy/>`_, so you can type:

.. code-block:: sh

   pip install pdrtpy

If you do not have permission to install into your Python system package area, you will need to do a `user-install <https://pip.pypa.io/en/latest/user_guide/#user-installs>`_, which will install the package locally.

.. code-block:: sh

   pip install --user pdrtpy

* For installation from github, see `For Developers`_ below.

Then go ahead and install the `Example Notebooks`_.

.. _notebooks:

Example Notebooks
-----------------

We have prepared Jupyter iPython notebooks with examples of how to use ``pdrtpy``.  You can download these as follows.

.. code-block:: sh

    git clone https://github.com/mpound/pdrtpy-nb.git

If you don't have git, you can 
`download a zip file of the repository <https://github.com/mpound/pdrtpy-nb/archive/master.zip>`_.

To familiarize yourself with the capabilities of ``pdrtpy``, we suggest you do the notebooks in this order:

- `Working with Measurements <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_Measurements.ipynb>`_
- `Introduction to ModelSets <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_ModelSets.ipynb>`_
- `Exploring Models <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_Model_Plotting.ipynb>`_
- `Determining Radiation Field and Intensity <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_Find_n_G0_Single_Pixel.ipynb>`_
- `Image Radiation Field and Intensity for Maps <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_Make_n_G0_maps.ipynb>`_
- `Fitting |H2| Excitation Diagrams <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_H2_Excitation.ipynb>`_
- `Adding Custom Models <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_Adding_Models.ipynb>`_

Getting Help & Giving Feedback
==============================
If you have a question or wish to give feedback about using PDR Toolbox or about the example notebooks, head on over to our `PDR Toolbox online forum <https://groups.google.com/g/pdrt>`_.  There you can post your question and engage in discussion with the developers and other users.  Feature requests from the community are welcome.

Reporting Issues
================
If you find a bug or something you think is in error, please report it on
the `github issue tracker <https://github.com/mpound/pdrtpy/issues>`_. 
(You must have a `Github account <https://github.com/>`_ to submit an issue).
If you aren't sure if something is a bug or not, or if you don't wish to
create a Github account, you can post to the `PDR Toolbox forum
<https://groups.google.com/g/pdrt>`_.

Contribute Code or Documentation
=================================
We welcome contributions and ideas to improve the PDR Toolbox!  **All contributors agree to follow our** `Code of Conduct <https://github.com/mpound/pdrtpy/blob/master/CODE_OF_CONDUCT.md>`_ .  Please look at our 
`Roadmap of Functionality <https://github.com/mpound/pdrtpy/blob/master/roadmap.md>`_ 
to see the main new features we want to build.  You can help out with those or suggest new features. 

For Developers
--------------
If you plan to tinker with the code, you should fork the repo and work on your own fork.  Point your browser to 
`https://github.com/mpound/pdrtpy <https://github.com/mpound/pdrtpy>`_
and click on *fork* in the upper right corner.   After you have made your changes, create a pull request to merge them into the master branch.

You may want to use a virtual environment to protect from polluting your daily working environment (especially if you have a stable version of `pdrtpy` installed).

.. code-block:: sh
  
   sudo apt-get install python3-venv
   python -m venv ~/pdrtpy_venv
   source ~/pdrtpy_venv/bin/activate[.csh] 
   cd pdrtpy
   pip install -r requirements.txt
   pip install -e .


.. |reg|    unicode:: U+000AE .. REGISTERED SIGN
.. |13C|    replace:: :sup:`13`\ C
.. |13CO|   replace:: :sup:`13`\ CO
.. |13CII|  replace:: [\ :sup:`13`\ C II]
.. |OI|  replace:: [O I]
.. |CII|  replace:: [C II]
.. |H2|  replace:: H\ :sub:`2`
.. |nu|     unicode:: 0x3bd .. greek nu



            

Raw data

            {
    "_id": null,
    "home_page": "http://dustem.astro.umd.edu",
    "name": "pdrtpy",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": "",
    "keywords": "PDR photodissociation astronomy astrophysics",
    "author": "Marc W. Pound, Mark G. Wolfire",
    "author_email": "mpound@umd.edu",
    "download_url": "https://files.pythonhosted.org/packages/bc/c6/69978188df5b0c4f965822c3687fbbbde391363f3fcc26eeba32f8233155/pdrtpy-2.3.1.tar.gz",
    "platform": null,
    "description": "*******************************************\nPhotoDissociation Region Toolbox --- Python\n*******************************************\n\n*Reliable astrophysics at everyday low, low prices!* |reg| \n\n------------------------------------------------------------\n\n.. image:: https://img.shields.io/badge/ascl-1102.022-blue.svg?colorB=262255&style=plastic\n   :target: http://ascl.net/1102.022\n   :alt: Astrophysics Source Code Library 1102.022\n\n.. image:: http://www.repostatus.org/badges/latest/active.svg?style=plastic\n :target: http://www.repostatus.org/#active\n :alt: Project Status: Active - The project has reached a stable, usable state and is being actively developed.\n\n.. image:: https://img.shields.io/pypi/pyversions/pdrtpy.svg?style=plastic\n :target: https://img.shields.io/pypi/pyversions/pdrtpy.svg?style=plastic\n :alt: Python version\n\n.. image:: https://img.shields.io/badge/License-GPLv3-blue.svg?style=plastic\n :target: https://www.gnu.org/licenses/gpl-3.0\n :alt: GNU GPL v3 License\n \n.. image:: https://readthedocs.org/projects/pdrtpy/badge/?version=latest&style=plastic\n :target: https://pdrtpy.readthedocs.io/en/latest/?badge=latest\n :alt: Documentation status\n \n.. image:: https://img.shields.io/badge/Contributor%20Covenant-2.1-4baaaa.svg?style=plastic\n :target: https://github.com/mpound/pdrtpy/blob/master/CODE_OF_CONDUCT.md\n :alt: Contributor Covenant Code of Conduct  \n\n.. image:: https://github.com/mpound/pdrtpy/actions/workflows/run-integration-tests.yml/badge.svg\n :alt: Integration test status\n\n.. image:: https://github.com/mpound/pdrtpy/blob/master/coverage.svg\n :alt: Code coverage\n\n.. image:: https://app.codacy.com/project/badge/Grade/dfa0433c8679423ca57cc75a84dc9083\n :alt: Codacy quality grade\n\n``pdrtpy`` is the new and improved version of the formerly web-based `PhotoDissociation Region Toolbox <http://dustem.astro.umd.edu/>`_, rewritten in Python with new capabilities and giving more flexibility to end users.  (The web-based /CGI version of PDRT is deprecated and no longer supported). \n\nThe PDR Toolbox is a science-enabling tool for the community, designed to\nhelp astronomers determine the physical parameters of photodissociation\nregions from observations. Typical observations of both Galactic\nand extragalactic PDRs come from ground- and space-based millimeter,\nsubmillimeter, and far-infrared telescopes such as ALMA, SOFIA, JWST,\nSpitzer, and Herschel. Given a set of observations of spectral line or\ncontinuum intensities, PDR Toolbox can compute best-fit FUV incident\nintensity and cloud density based on our models of PDR emission.\n\nThe PDR Toolbox will cover a wide range of spectral lines and metallicities\nand allows map-based analysis so users can quickly compute spatial\nimages of density and radiation field from map data.  We provide Jupyter\n`Example Notebooks`_ for data analysis.  It also can support models from\nother PDR codes enabling comparison of derived properties between codes.\n\nThe underlying PDR model code has improved physics and chemistry. Critical updates include those discussed in \n`Neufeld & Wolfire 2016 <https://ui.adsabs.harvard.edu/abs/2016ApJ...826..183N/abstract>`_, plus photo rates from \n`Heays et al. 2017 <https://ui.adsabs.harvard.edu/abs/2017A%26A...602A.105H/abstract>`_, oxygen chemistry rates from \n`Kovalenko et al. 2018 <https://ui.adsabs.harvard.edu/abs/2018ApJ...856..100K/abstract>`_ and \n`Tran et al. 2018 <https://ui.adsabs.harvard.edu/abs/2018ApJ...854...25T/abstract>`_, \nand carbon chemistry rates from \n`Dagdigian 2019 <https://ui.adsabs.harvard.edu/abs/2019MNRAS.487.3427D/abstract>`_. We have also implemented new collisional\nexcitation rates for |OI| from\n`Lique et al. 2018 <https://ui.adsabs.harvard.edu/abs/2018MNRAS.474.2313L/abstract>`_ (and Lique private\ncommunication) and have included |13C| chemistry along with the\nemitted line intensities for  |13CII| and |13CO|.\n\nWe also support fitting of temperatures and column densities to |H2| excitation diagrams.\n\nUp to date documentation can be found at `pdrtpy.readthedocs.io <http://pdrtpy.readthedocs.io/>`_.\n\nWhat is a PDR? \n==============\nPhotodissociation regions (PDRs) include all of the neutral gas in the\nISM where far-ultraviolet (FUV) photons dominate the chemistry and/or\nheating.  In regions of massive star formation, PDRS are created at\nthe boundaries between the HII regions and neutral molecular cloud,\nas photons with energies 6 eV < h \\nu < 13.6 eV.\nphotodissociate molecules and photoionize other elements.  The gas is\nheated from photo-electrons and cools mostly through far-infrared fine\nstructure lines like   |OI| and  |CII|.\n\nFor a full review of PDR physics and chemistry, see `Hollenbach & Tielens 1997 <https://ui.adsabs.harvard.edu/abs/1997ARA&A..35..179H>`_.\n\nGetting Started\n===============\n\nInstallation\n------------\n\nRequirements\n^^^^^^^^^^^^\n\n``pdrtpy`` requires Python 3 and recent versions of  `astropy <https://astropy.org>`_, `numpy <https://numpy.org>`_, `scipy <https://scipy.org>`_, `lmfit <https://lmfit.github.io/lmfit-py/>`_, and `matplotlib <https://matplotlib.org/>`_. If you want to run the `Example Notebooks`_, you also need `jupyter <https://jupyter.org>`_.\n\nFirst make sure you are using Python 3:\n\n.. code-block:: sh\n\n   python --version\n\nshould show e.g., *3.7.6*. \n\n\n.. Also, make sure *setuptools* is up to date:\n\n.. .. code-block:: sh\n\n..   pip install -U setuptools\n\nInstall the package\n^^^^^^^^^^^^^^^^^^^\n\nWith pip\n--------\nPython has numerous ways to install packages; the easiest is with *pip*. \nThe code is hosted at the `Python Packaging Index <https://pypi.org/project/pdrtpy/>`_, so you can type:\n\n.. code-block:: sh\n\n   pip install pdrtpy\n\nIf you do not have permission to install into your Python system package area, you will need to do a `user-install <https://pip.pypa.io/en/latest/user_guide/#user-installs>`_, which will install the package locally.\n\n.. code-block:: sh\n\n   pip install --user pdrtpy\n\n* For installation from github, see `For Developers`_ below.\n\nThen go ahead and install the `Example Notebooks`_.\n\n.. _notebooks:\n\nExample Notebooks\n-----------------\n\nWe have prepared Jupyter iPython notebooks with examples of how to use ``pdrtpy``.  You can download these as follows.\n\n.. code-block:: sh\n\n    git clone https://github.com/mpound/pdrtpy-nb.git\n\nIf you don't have git, you can \n`download a zip file of the repository <https://github.com/mpound/pdrtpy-nb/archive/master.zip>`_.\n\nTo familiarize yourself with the capabilities of ``pdrtpy``, we suggest you do the notebooks in this order:\n\n- `Working with Measurements <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_Measurements.ipynb>`_\n- `Introduction to ModelSets <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_ModelSets.ipynb>`_\n- `Exploring Models <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_Model_Plotting.ipynb>`_\n- `Determining Radiation Field and Intensity <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_Find_n_G0_Single_Pixel.ipynb>`_\n- `Image Radiation Field and Intensity for Maps <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_Make_n_G0_maps.ipynb>`_\n- `Fitting |H2| Excitation Diagrams <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_H2_Excitation.ipynb>`_\n- `Adding Custom Models <https://github.com/mpound/pdrtpy-nb/blob/master/notebooks/PDRT_Example_Adding_Models.ipynb>`_\n\nGetting Help & Giving Feedback\n==============================\nIf you have a question or wish to give feedback about using PDR Toolbox or about the example notebooks, head on over to our `PDR Toolbox online forum <https://groups.google.com/g/pdrt>`_.  There you can post your question and engage in discussion with the developers and other users.  Feature requests from the community are welcome.\n\nReporting Issues\n================\nIf you find a bug or something you think is in error, please report it on\nthe `github issue tracker <https://github.com/mpound/pdrtpy/issues>`_. \n(You must have a `Github account <https://github.com/>`_ to submit an issue).\nIf you aren't sure if something is a bug or not, or if you don't wish to\ncreate a Github account, you can post to the `PDR Toolbox forum\n<https://groups.google.com/g/pdrt>`_.\n\nContribute Code or Documentation\n=================================\nWe welcome contributions and ideas to improve the PDR Toolbox!  **All contributors agree to follow our** `Code of Conduct <https://github.com/mpound/pdrtpy/blob/master/CODE_OF_CONDUCT.md>`_ .  Please look at our \n`Roadmap of Functionality <https://github.com/mpound/pdrtpy/blob/master/roadmap.md>`_ \nto see the main new features we want to build.  You can help out with those or suggest new features. \n\nFor Developers\n--------------\nIf you plan to tinker with the code, you should fork the repo and work on your own fork.  Point your browser to \n`https://github.com/mpound/pdrtpy <https://github.com/mpound/pdrtpy>`_\nand click on *fork* in the upper right corner.   After you have made your changes, create a pull request to merge them into the master branch.\n\nYou may want to use a virtual environment to protect from polluting your daily working environment (especially if you have a stable version of `pdrtpy` installed).\n\n.. code-block:: sh\n  \n   sudo apt-get install python3-venv\n   python -m venv ~/pdrtpy_venv\n   source ~/pdrtpy_venv/bin/activate[.csh] \n   cd pdrtpy\n   pip install -r requirements.txt\n   pip install -e .\n\n\n.. |reg|    unicode:: U+000AE .. REGISTERED SIGN\n.. |13C|    replace:: :sup:`13`\\ C\n.. |13CO|   replace:: :sup:`13`\\ CO\n.. |13CII|  replace:: [\\ :sup:`13`\\ C II]\n.. |OI|  replace:: [O I]\n.. |CII|  replace:: [C II]\n.. |H2|  replace:: H\\ :sub:`2`\n.. |nu|     unicode:: 0x3bd .. greek nu\n\n\n",
    "bugtrack_url": null,
    "license": "GPLv3",
    "summary": "PhotoDissociation Region Toolbox (PDRT), astrophysics analysis tools",
    "version": "2.3.1",
    "split_keywords": [
        "pdr",
        "photodissociation",
        "astronomy",
        "astrophysics"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "54515611b4e8db510ef4a0d5f71b70fd18207f414b4858b1a86660cd8f3e69d4",
                "md5": "a1ed99e547e2e6bb22ad6f324967c081",
                "sha256": "f9914f23625c603a34eb5c5bc0227dc252a9934b6bd2fd5f865bbac371b6895e"
            },
            "downloads": -1,
            "filename": "pdrtpy-2.3.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "a1ed99e547e2e6bb22ad6f324967c081",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 57303032,
            "upload_time": "2023-02-06T18:20:01",
            "upload_time_iso_8601": "2023-02-06T18:20:01.117338Z",
            "url": "https://files.pythonhosted.org/packages/54/51/5611b4e8db510ef4a0d5f71b70fd18207f414b4858b1a86660cd8f3e69d4/pdrtpy-2.3.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "bcc669978188df5b0c4f965822c3687fbbbde391363f3fcc26eeba32f8233155",
                "md5": "a43d93591185b89f0984b15bb1eb2f3d",
                "sha256": "c2edc20588b03be6eb3220f9db9f6224cce6068b666fde7a0367f557ff00ec7d"
            },
            "downloads": -1,
            "filename": "pdrtpy-2.3.1.tar.gz",
            "has_sig": false,
            "md5_digest": "a43d93591185b89f0984b15bb1eb2f3d",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 54245627,
            "upload_time": "2023-02-06T18:20:09",
            "upload_time_iso_8601": "2023-02-06T18:20:09.813258Z",
            "url": "https://files.pythonhosted.org/packages/bc/c6/69978188df5b0c4f965822c3687fbbbde391363f3fcc26eeba32f8233155/pdrtpy-2.3.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-02-06 18:20:09",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "lcname": "pdrtpy"
}
        
Elapsed time: 0.03591s