Skip to main content

MILKYWAY@HOME PYTHON PACKAGE (MWAHPY)

NOTE: MWAHPY HAS ENTERED LONG-TERM LEGACY SUPPORT (V2.0.0+). PULL REQUESTS WILL BE REVIEWED AND MERGED IF POSSIBLE, BUT I AM NO LONGER PLANNING ON IMPLEMENTING NEW FEATURES FOR THE CODE BASE.

Copyright Tom Donlon, 2020 RPI

Significant work also done by Kevin Roux (Kevnroux)

github user: thomasdonlon

Requires Python v.>3.6.0


MilkyWay@home is a computational astrophysics project located at RPI and run by Dr. Heidi Newberg. The project contains two main components, (i) the Separation Application and (ii) the N-body Application. I have worked with both, and over a few years have developed several useful bits of python code to supplement analysis and usage of MilkyWay@home. This code has been cleaned and organized here, so that others can avoid having to constantly reinvent the wheel.

The purpose of the mwahpy package is to provide a collection of useful tools for people working with/on the MilkyWay@home N-body project at RPI.

In practice it would be good for this package to be updated along with the MilkyWay@home project and/or python updates after I'm gone. No clue if that's going to happen, but I plan on maintaining support at least through the spring of 2023 (while I'm in grad school).

Issues with the package can be directed to my github profile or on the MilkyWay@home forums at milkyway.cs.rpi.edu. Improvements or additions are welcome, just send a pull request to the mwahpy github repository.

CONTENTS

A non-exhaustive list of contents of the package is given below:

  • easy importing of data from N-body output
  • easy manipulation of data after reading in
  • A variety of coordinate transformations for typical coordinate systems used in Galactic astronomy
  • easy visualization of the imported data through plotting functionality
  • a wide variety of useful scripts and routines for working with N-body simulations, especially those with dwarf galaxies
  • a tutorial .pdf document along with documentation for each function in the package

INSTALLATION

FOR USERS:

  1. Open your terminal, and run

python3 -m pip install mwahpy

  1. Insert import statements for the subpackages that you want to use in your .py files:

import mwahpy.{mwahpy subpackage}

import mwahpy.{other mwahpy subpackage}

...

  1. Do science

FOR DEVELOPERS:

  1. Clone the mwahpy github repository

  2. Make the desired changes in the source code

  3. Navigate to the directory where you cloned the repo, and then run

python3 setup.py develop --user

(note, you will probably need to uninstall any previous versions of mwahpy you had on your machine before running this)

  1. To test your changes, insert import statements for the subpackages that you want to use in your .py files as you normally would:

import mwahpy.{mwahpy subpackage}

import mwahpy.{other mwahpy subpackage}

...

  1. Once you are done making changes to the source code, put in a pull request to master

  2. Navigate to the directory where you cloned the repo, and then run

python3 setup.py develop --uninstall

pip3 install mwahpy

Your changes will not be available in the main mwahpy build until a new release comes out.

TODO

MAJOR:

  • Expand plot capabilities
  • Finish refactoring coords.py
  • Finish unit testing of coordinate transformations
  • add animate() for the Nbody struct for nice animations
  • update documentation so it is current (probably last thing I'll do during summer 2023)

MINOR:

  • Let subset_circ() and subset_rect() handle None as bounds
  • Implement better linear algebra to reduce the computation time of coords.get_rvpm()
  • Play around with turning off mwahpy_glob.verbose flag for some things to quiet unnecessary output
  • Add levels of verbosity, and make this changeable by running a command

ISSUES

  • No known issues.

Metadata

Release files for mwahpy 2.1.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mwahpy 2.1.6
File Size Uploaded
mwahpy-2.1.6.tar.gz 949.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for mwahpy 2.1.6
File Interpreter ABI Platform
mwahpy-2.1.6-py3-none-any.whl Python 3 none any Details

Total release size: 1.1 MB

Release files / mwahpy-2.1.6.tar.gz

Download URL mwahpy-2.1.6.tar.gz
Size 949.4 kB
Tags Source
SHA-256 checksum
How to use checksums
92b8cee7d1abffc5d37575f0bcf214b254d3a2e4ad7bbda7f4ccde359967bf8f
BLAKE2b-256 checksum
How to use checksums
1a00149b8757e357de472ad5950307e811fd0274d62159e60708affc687baea3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.12.3

Release files / mwahpy-2.1.6-py3-none-any.whl

Download URL mwahpy-2.1.6-py3-none-any.whl
Size 182.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5b0f23485de3df8d1a6c92f6baa4432eae65131fe2aedc47250b8a717d59d245
BLAKE2b-256 checksum
How to use checksums
6fcb6bc587f78c5a4c592c4de077b87e16f04723c4e2307374c7b4e5f754355e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.12.3

Release history Release notifications | RSS feed

This release

2.1.6 This release

2 release files

2.1.5

2 release files

2.1.4

2 release files

2.1.3

2 release files

2.1.2

2 release files

2.1.1

2 release files

2.1.0

2 release files

2.0.0

2 release files

1.4.8

2 release files

1.4.7

2 release files

1.4.6

2 release files

1.4.5

2 release files

1.4.4

2 release files

1.4.3

2 release files

1.4.2

2 release files

1.4.1

2 release files

1.4.0

2 release files

1.3.8

2 release files

1.3.7

2 release files

1.3.6

2 release files

1.3.5

2 release files

1.3.4

2 release files

1.3.3

2 release files

1.2.3

2 release files

1.2.2

2 release files

1.2.1

2 release files

1.2.0

2 release files

1.1.0

2 release files

1.0.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page