Python software suite for various ionospheric analyses
Project description
cthulhu
Ionospheric diagnostics and tools. Mostly designed to work with the information provided by RTS calibration logs for EoR analysis, but will work with any other positional data.
Usage
cthulhu is designed to interface with the Murchison Widefield Array (MWA) Real-Time System (RTS) calibration software. But, cthulhu is also modular enough to accept generic ionospheric data; it needs only the expected and apparent positions of sources (provided as “offsets” or “shifts”).
cthulhu_wrapper.py acts as the primary interface for RTS data, and this application is directly responsible for populating the MWA quality-assurance database (QA DB). cthulhu_wrapper.py also acts as a demonstration of using the cthulhu library, but it may be easier to follow library usage with examples in the notebooks directory.
A simple usage of cthulhu is given in “cthulhu_wrapper.py”. Alternatively, for integration with another script or somesuch:
from cthulhu.reconstruct import Obsid from cthulhu.plot_tools import generate_diagnostic_figure, raw_and_tec obj = Obsid([ra, dec, ra_shifts, dec_shifts]) generate_diagnostic_figure(obj) raw_and_tec(obj)
where ra, dec, ra_shifts and dec_shifts are lists or numpy arrays containing expected and apparent positions of sources due to ionospheric activity. This will generate plots in the present working directory under plots and raw_and_tec.
If interfacing with RTS logs, cthulhu includes scripts to convert RTS logs to pickles, JSONs and YAMLs. These intermediate files are useful because interfacing directly with an RTS log is much slower, and occupy much smaller volumes. Pickles will be approximately one-third the size of a JSON or YAML, but need to be unpacked before being inspected, and are not compatible across all versions of python and computer architectures. In addition, pickles can execute arbitrary code upon opening, so avoid using them whenever possible. YAML is also a lot more readable than JSON, as well as contained in a smaller file size, so use YAML if you can!
Limitations
Currently, cthulhu expects coordinates to be in a celestial reference frame ($alpha$, $delta$). However, no coordinate transformations (or etc.) are performed with common operations, so your resulting plots will simply use the values of your input data’s coordinate system with default RA/Dec. labels. Other coordinates could be incorporated in the future, but is beyond the scope of this work.
Modelling and correcting the “ionosphere” from the data is not implemented correctly yet, although this will not involve much work.
Bugs? Inconsistencies?
Absolutely! If you find something odd, let me know and I’ll attempt to fix it ASAP.
Contact
christopherjordan87 -at- gmail.com
Dependencies
python 2.7.x or 3.x
numpy
scipy
astropy
matplotlib
future
pyGrad2Surf (available on my GitHub)
Optional dependencies
PyYAML (human-readable intermediate format, really nice!)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distribution
File details
Details for the file cthulhu-0.2.0-py2.py3-none-any.whl
.
File metadata
- Download URL: cthulhu-0.2.0-py2.py3-none-any.whl
- Upload date:
- Size: 33.3 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/43.0.0 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.8.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0226c9fdcb0eabd9ab36756e996270920577773ce8bfc192e8d17554188d0f9a |
|
MD5 | 0e9a95a865e0eb8c1982f35f718100e2 |
|
BLAKE2b-256 | 816e63eb0dc8cc2ff6a27cfdf41811d774876bf14473cb38c75939192fa98990 |