{
"info": {
"author": "Marco Tazzari",
"author_email": "mtazzari@gmail.com",
"bugtrack_url": null,
"classifiers": [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: GNU Lesser General Public License v3 (LGPLv3)",
"Operating System :: OS Independent",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3"
],
"description": "======\nuvplot\n======\nA simple package to make nice plots of deprojected interferometric visibilities, often called **uvplots**.\nIt can be installed inside the `NRAO CASA package `_ (see instructions below) and has functionalities to export visibilities from the MS Table format to ASCII. Available on the `Python Package Index `_.\n\n\n.. image:: https://travis-ci.org/mtazzari/uvplot.svg?branch=master\n :target: https://travis-ci.org/mtazzari/uvplot\n\n.. image:: https://img.shields.io/pypi/v/uvplot.svg\n :target: https://pypi.python.org/pypi/uvplot\n\n.. image:: https://img.shields.io/github/release/mtazzari/uvplot/all.svg\n :target: https://github.com/mtazzari/uvplot/releases\n \n.. image:: https://img.shields.io/badge/License-LGPL%20v3-blue.svg\n :target: https://www.gnu.org/licenses/lgpl-3.0\n\n.. image:: https://zenodo.org/badge/105298533.svg\n :target: https://zenodo.org/badge/latestdoi/105298533\n \n|\n\nThe current version implements the basic plotting functionality.\n\nFeatures on the road map:\n - handle MS tables with spectral windows with different number of channels;\n - choose specific channels to export;\n - import visibilities from ASCII to MS Table.\n\nIf you are interested, have feature requests, or encounter issues, consider creating an `Issue `_ or writing me an `email `_. I am happy to have your feedback!\n\nInstallation\n------------\n\n**uvplot** works on `Python` >=2.7 and >=3.6 and can be installed with:\n\n.. code-block :: bash\n\n pip install uvplot\n\nTo make **uvplot** available in CASA, run from the shell:\n\n.. code-block :: bash\n\n casa-pip install uvplot\n\nwhere `casa-pip` is a tool that can be downloaded at `https://github.com/radio-astro-tools/casa-python `_.\n\nTo upgrade **uvplot** to a newer version on your system, just run:\n\n.. code-block :: bash\n\n pip install --upgrade uvplot\n \nTo upgrade **uvplot** inside CASA use the `--no-deps` option to prevent `casa-pip` from automatically upgrading `numpy` and `matplotlib` (which is not allowed inside CASA and will lead to errors):\n\n.. code-block :: bash\n\n casa-pip install --upgrade --no-deps uvplot\n \n**uvplot** has been tested on CASA versions >= 4.7.0.\n\nFeatures\n--------\n\n**1) Plotting visibilities**\n============================\nThis is an example plot:\n\n.. image:: docs/images/uvplot.png\n :width: 60 %\n :alt: example uv plot\n :align: center\n\ncreated with uvplot:\n\n.. code-block:: py\n\n import numpy as np\n from uvplot import UVTable, arcsec\n from uvplot import COLUMNS_V0 # use uvplot >= 0.2.6\n\n wle = 0.88e-3 # Observing wavelength [m]\n\n dRA = 0.3 * arcsec # Delta Right Ascension offset [rad]\n dDec = 0.07 * arcsec # Delta Declination offset [rad]\n inc = np.radians(73.) # Inclination [rad]\n PA = np.radians(59) # Position Angle [rad]\n\n uvbin_size = 30e3 # uv-distance bin [wle]\n\n uv = UVTable(filename='uvtable.txt', wle=wle, columns=COLUMNS_V0)\n uv.apply_phase(dRA, dDec)\n uv.deproject(inc, PA)\n\n uv_mod = UVTable(filename='uvtable_mod.txt', wle=wle, COLUMNS_V0)\n uv_mod.apply_phase(dRA=dRA, dDec=dDec)\n uv_mod.deproject(inc=inc, PA=PA)\n\n axes = uv.plot(label='Data', uvbin_size=uvbin_size)\n uv_mod.plot(label='Model', uvbin_size=uvbin_size, axes=axes, yerr=False, linestyle='-', color='r')\n\n axes[0].figure.savefig(\"uvplot.png\")\n\nFrom version v0.2.6 it is necessary to provide the `columns` parameter\nwhen reading an ASCII uvtable. The `columns` parameter can be specified\neither as a parameter to the `UVTable()` command, or as the **2nd** line\nin the ASCII file. The available `columns` formats are:\n\n.. code-block:: bash\n\n FORMAT COLUMNS COLUMNS_LINE (copy-paste as 2nd line in the ASCII file)\n COLUMNS_V0 ['u', 'v', 'Re', 'Im', 'weights'] '# Columns u v Re Im weights'\n COLUMNS_V1 ['u', 'v', 'Re', 'Im', 'weights', 'freqs', 'spws'] '# Columns u v Re Im weights freqs spws'\n COLUMNS_V2 ['u', 'v', 'V', 'weights', 'freqs', 'spws'] '# Columns u v V weights freqs spws'\n\nTo import an ASCII uvtable with 5 columns with uvplot < 0.2.6:\n\n.. code-block:: py\n\n from uvplot import UVTable\n uvt = UVTable(filename='uvtable.txt', format='ascii', columns=COLUMNS_V0)\n\n\nand with uvplot >= 0.2.6:\n\n.. code-block:: py\n\n from uvplot import UVTable\n from uvplot import COLUMNS_V0 # ['u', 'v', 'Re', 'Im', 'weights']\n uvt = UVTable(filename='uvtable.txt', format='ascii', columns=COLUMNS_V0)\n\n\n**2) Exporting visibilities** from MS table to uvtable (ASCII)\n==============================================================\nOnce installed **uvplot** inside CASA (see instructions above),\nit is possible to export the visibilities in `mstable.ms` to an ASCII table by executing these lines **from a CASA shell**:\n\n.. code-block:: py\n\n CASA <1>: from uvplot import export_uvtable\n CASA <2>: export_uvtable(\"uvtable.txt\", tb, vis='mstable.ms')\n\n**Note**: it is strongly recommended to perform a CASA `split` command with `keepflags=False` before exporting the uvtable. This ensures that only valid visibilities are exported.\n\nThe resulting `uvtable.txt` will contain `u, v` coordinates (in meters), `Re(V), Im(V)` visibility measurements (in Jansky),\nand `weights`. The table will also report the average wavelength (averaged among all selected spectral windows):\n\n.. code-block:: bash\n\n # Extracted from mstable.ms.\n # wavelength[m] = 0.00132940778422\n # Columns:\tu[m]\tv[m]\tRe(V)[Jy]\tIm(V)[Jy]\tweight\n -2.063619e+02\t2.927104e+02\t-1.453431e-02\t-1.590934e-02\t2.326950e+04\n 3.607948e+02\t6.620900e+01\t-1.680727e-02\t1.124862e-02\t3.624442e+04\n 5.752178e+02\t-6.299933e+02\t5.710317e-03\t6.592049e-03\t4.719500e+04\n -9.198434e+02\t-1.374651e+03\t1.313417e-03\t4.299262e-03\t4.259890e+04\n 9.623210e+01\t-4.631573e+02\t7.731462e-03\t-8.803369e-03\t4.801395e+04\n 9.348914e+01\t-5.191096e+02\t3.759772e-03\t4.754967e-04\t4.748304e+04\n 1.108410e+03\t-1.396906e+03\t3.222965e-03\t-5.164917e-03\t4.690977e+04\n [...]\n\nBy default `export_uvtable` exports all channels in all spectral windows. However, it is also possible to specify which\nspectral windows and channels to export. More details are given in the documentation of the `export_uvtable() `_ function.\n\n**Note**: currently, `export_uvtable` only works for MS tables where all the spectral windows have **the same** number of channels (which, individually, can be larger than 1).\n\nLicense and Attribution\n-----------------------\nIf you use **uvplot** for your publication, please cite the `Zenodo reference `_ ::\n\n @misc{uvplot_mtazzari,\n author = {Marco Tazzari},\n title = {mtazzari/uvplot: v0.1.1},\n month = oct,\n year = 2017,\n doi = {10.5281/zenodo.1003113},\n url = {https://doi.org/10.5281/zenodo.1003113}\n }\n\n**uvplot** is free software licensed under the LGPLv3 License. For more details see the LICENSE.\n\n\u00a9 Copyright 2018-2019 Marco Tazzari and contributors.\n\nContributors\n------------\nAuthor:\n - `Marco Tazzari (University of Cambridge) `_\n\nContributions to the code base:\n - `Patrick Cronin-Coltsmann `_\n - `Grant Kennedy `_\n\nDocumentation\n-------------\nCheck out the `documentation `_.\n\nChangelog\n---------\nSee the list of changes in all releases `here `_.\n",
"description_content_type": "",
"docs_url": null,
"download_url": "https://github.com/mtazzari/uvplot/archive/0.2.10.tar.gz",
"downloads": {
"last_day": -1,
"last_month": -1,
"last_week": -1
},
"home_page": "https://github.com/mtazzari/uvplot",
"keywords": "science",
"license": "LGPLv3",
"maintainer": "",
"maintainer_email": "",
"name": "uvplot",
"package_url": "https://pypi.org/project/uvplot/",
"platform": "",
"project_url": "https://pypi.org/project/uvplot/",
"project_urls": {
"Download": "https://github.com/mtazzari/uvplot/archive/0.2.10.tar.gz",
"Homepage": "https://github.com/mtazzari/uvplot"
},
"release_url": "https://pypi.org/project/uvplot/0.2.10/",
"requires_dist": null,
"requires_python": "",
"summary": "Utilities for handling and plotting interferometric visibilities.",
"version": "0.2.10"
},
"last_serial": 5782090,
"releases": {
"0.2.10": [
{
"comment_text": "",
"digests": {
"md5": "c16b89e47b39f1b6c631f1878b12d64c",
"sha256": "1f5620f96019adcad2883aa01bf67dcb6ddd7e5861e2b3f5ba83e03be905b3fd"
},
"downloads": -1,
"filename": "uvplot-0.2.10.tar.gz",
"has_sig": false,
"md5_digest": "c16b89e47b39f1b6c631f1878b12d64c",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 20694,
"upload_time": "2019-09-04T15:42:28",
"url": "https://files.pythonhosted.org/packages/d1/95/c7dcafcf0eb8aedaf531282de0e4808b3ceb81d32307ccde56355a62ffd3/uvplot-0.2.10.tar.gz"
}
],
"0.2.2": [
{
"comment_text": "",
"digests": {
"md5": "d56ba511339ce7675e38f3fa4f7040cd",
"sha256": "148b72caae05b041c6a4a8eb7f5a88e00c47a59888129931e8270ddb6d6796e3"
},
"downloads": -1,
"filename": "uvplot-0.2.2.tar.gz",
"has_sig": false,
"md5_digest": "d56ba511339ce7675e38f3fa4f7040cd",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 13804,
"upload_time": "2018-02-05T18:02:23",
"url": "https://files.pythonhosted.org/packages/80/1d/8b3a6d39a885150100ab0f8b45bc05b84447f6ab3d42ff8220f93746977e/uvplot-0.2.2.tar.gz"
}
],
"0.2.3": [
{
"comment_text": "",
"digests": {
"md5": "078308d494e530b13441002cc1707bff",
"sha256": "2d757c634d312ac5c73be4e38eb6299c0f13546ce4dcbd0811d3e43ed9f68d5a"
},
"downloads": -1,
"filename": "uvplot-0.2.3.tar.gz",
"has_sig": false,
"md5_digest": "078308d494e530b13441002cc1707bff",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 14038,
"upload_time": "2018-02-06T09:06:46",
"url": "https://files.pythonhosted.org/packages/6d/b1/4fcbec6676a0d46a5bb00f1d192ab31a74845c1c67bd20adb4683c0b7f49/uvplot-0.2.3.tar.gz"
}
],
"0.2.4": [
{
"comment_text": "",
"digests": {
"md5": "74147dd9183b91ff34cb710de0dde914",
"sha256": "48f5e166e58507eecfb6a41bb562f401d26eb6c9ad8e279f56a13ef4c5b4d4a9"
},
"downloads": -1,
"filename": "uvplot-0.2.4.tar.gz",
"has_sig": false,
"md5_digest": "74147dd9183b91ff34cb710de0dde914",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 14910,
"upload_time": "2018-10-05T21:02:05",
"url": "https://files.pythonhosted.org/packages/66/f7/19a3ea8f036643951b199ddc1fc018066cfa2763ba812cd613c9b1f9a8bf/uvplot-0.2.4.tar.gz"
}
],
"0.2.5": [
{
"comment_text": "",
"digests": {
"md5": "431dbe54b67be6bb2f494315dab33cf4",
"sha256": "fa6721b278455dae37ec141c62ffb9aa8342b28f31ec2c3af2886ad99de9cf33"
},
"downloads": -1,
"filename": "uvplot-0.2.5.tar.gz",
"has_sig": false,
"md5_digest": "431dbe54b67be6bb2f494315dab33cf4",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 17132,
"upload_time": "2018-11-21T09:37:08",
"url": "https://files.pythonhosted.org/packages/39/0b/d9faa753ea82261b47e403a629bff8897ded49b183a6fc4bc91418c17a78/uvplot-0.2.5.tar.gz"
}
],
"0.2.6": [
{
"comment_text": "",
"digests": {
"md5": "35d658d014bb0a3bc6629d544baf8586",
"sha256": "fad6fc51085a0bd142d794c78cf657f3a328fb2c83cd1f711844e15a2cfbaa35"
},
"downloads": -1,
"filename": "uvplot-0.2.6.tar.gz",
"has_sig": false,
"md5_digest": "35d658d014bb0a3bc6629d544baf8586",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 19893,
"upload_time": "2019-01-11T19:18:02",
"url": "https://files.pythonhosted.org/packages/07/17/2b782059b63b32521b12d7ef639760fc21fb1d7bc007cd08725dd90fa4de/uvplot-0.2.6.tar.gz"
}
],
"0.2.7": [
{
"comment_text": "",
"digests": {
"md5": "24a2c308cfdaccfbf8bae4b4b24dca0d",
"sha256": "563c2843b50443455e9ea7d55bac66b8ce7e50b0371e482dea623addebad3c92"
},
"downloads": -1,
"filename": "uvplot-0.2.7.tar.gz",
"has_sig": false,
"md5_digest": "24a2c308cfdaccfbf8bae4b4b24dca0d",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 19895,
"upload_time": "2019-01-13T01:41:41",
"url": "https://files.pythonhosted.org/packages/d0/04/d07024be72ac0ae14feddb7267b8053569fa796496f843d8da28f904696e/uvplot-0.2.7.tar.gz"
}
],
"0.2.8": [
{
"comment_text": "",
"digests": {
"md5": "7cea541a724fbf9e840cd8ebbe79b881",
"sha256": "b92ca0b946888a910101b7c629526020cce5818d93bc8ae68e79318e9669c26d"
},
"downloads": -1,
"filename": "uvplot-0.2.8.tar.gz",
"has_sig": false,
"md5_digest": "7cea541a724fbf9e840cd8ebbe79b881",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 20191,
"upload_time": "2019-02-27T22:56:50",
"url": "https://files.pythonhosted.org/packages/b1/1c/c159084ddaee7774a7e124805e0c7acbfce360539cb73e99245a9e4f8c10/uvplot-0.2.8.tar.gz"
}
],
"0.2.9": [
{
"comment_text": "",
"digests": {
"md5": "4c374be5e6e817a48a9255337a6db069",
"sha256": "c3525bd73260a2c937bba3f852368a4a8d3843c567458d58b8f8600bfdb3d8b4"
},
"downloads": -1,
"filename": "uvplot-0.2.9.tar.gz",
"has_sig": false,
"md5_digest": "4c374be5e6e817a48a9255337a6db069",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 20217,
"upload_time": "2019-06-11T15:01:24",
"url": "https://files.pythonhosted.org/packages/48/a7/8e53d2863df3d23e9aefa0bc324b53ae4028a07106bd5d9708129935fb0d/uvplot-0.2.9.tar.gz"
}
]
},
"urls": [
{
"comment_text": "",
"digests": {
"md5": "c16b89e47b39f1b6c631f1878b12d64c",
"sha256": "1f5620f96019adcad2883aa01bf67dcb6ddd7e5861e2b3f5ba83e03be905b3fd"
},
"downloads": -1,
"filename": "uvplot-0.2.10.tar.gz",
"has_sig": false,
"md5_digest": "c16b89e47b39f1b6c631f1878b12d64c",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 20694,
"upload_time": "2019-09-04T15:42:28",
"url": "https://files.pythonhosted.org/packages/d1/95/c7dcafcf0eb8aedaf531282de0e4808b3ceb81d32307ccde56355a62ffd3/uvplot-0.2.10.tar.gz"
}
]
}