utilities-awetzel 1.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- utilities_awetzel-1.0.0/LICENSE.md +23 -0
- utilities_awetzel-1.0.0/PKG-INFO +138 -0
- utilities_awetzel-1.0.0/README.md +91 -0
- utilities_awetzel-1.0.0/pyproject.toml +43 -0
- utilities_awetzel-1.0.0/setup.cfg +4 -0
- utilities_awetzel-1.0.0/utilities/__init__.py +2 -0
- utilities_awetzel-1.0.0/utilities/array.py +821 -0
- utilities_awetzel-1.0.0/utilities/binning.py +1154 -0
- utilities_awetzel-1.0.0/utilities/catalog.py +1634 -0
- utilities_awetzel-1.0.0/utilities/constant.py +451 -0
- utilities_awetzel-1.0.0/utilities/coordinate.py +1294 -0
- utilities_awetzel-1.0.0/utilities/cosmology.py +832 -0
- utilities_awetzel-1.0.0/utilities/halo_property.py +846 -0
- utilities_awetzel-1.0.0/utilities/io.py +1055 -0
- utilities_awetzel-1.0.0/utilities/math.py +1227 -0
- utilities_awetzel-1.0.0/utilities/orbit.py +715 -0
- utilities_awetzel-1.0.0/utilities/particle.py +2786 -0
- utilities_awetzel-1.0.0/utilities/plot.py +1506 -0
- utilities_awetzel-1.0.0/utilities/simulation.py +843 -0
- utilities_awetzel-1.0.0/utilities_awetzel.egg-info/PKG-INFO +138 -0
- utilities_awetzel-1.0.0/utilities_awetzel.egg-info/SOURCES.txt +22 -0
- utilities_awetzel-1.0.0/utilities_awetzel.egg-info/dependency_links.txt +1 -0
- utilities_awetzel-1.0.0/utilities_awetzel.egg-info/requires.txt +4 -0
- utilities_awetzel-1.0.0/utilities_awetzel.egg-info/top_level.txt +1 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
Copyright 2014-2024 by Andrew Wetzel <arwetzel@gmail.com>, Shea Garrison-Kimmel, Jenna Samuel, Nico Garavito-Camargo.
|
|
2
|
+
|
|
3
|
+
In summary, you are free to use, edit, share, and do whatever you want. But
|
|
4
|
+
please cite us and report bugs!
|
|
5
|
+
|
|
6
|
+
Less succinctly, this software is governed by the MIT License:
|
|
7
|
+
|
|
8
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
9
|
+
this software and associated documentation files (the "Software"), to deal in
|
|
10
|
+
the Software without restriction, including without limitation the rights to
|
|
11
|
+
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
|
12
|
+
the Software, and to permit persons to whom the Software is furnished to do so,
|
|
13
|
+
subject to the following conditions:
|
|
14
|
+
|
|
15
|
+
The above copyright notice and this permission notice shall be included in all
|
|
16
|
+
copies or substantial portions of the Software.
|
|
17
|
+
|
|
18
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
19
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
|
20
|
+
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
|
21
|
+
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
|
22
|
+
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
|
23
|
+
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: utilities_awetzel
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: utilities for Andrew Wetzel's packages
|
|
5
|
+
Author: Shea Garrison-Kimmel, Jenna Samuel, Nico Garavito-Camargo
|
|
6
|
+
Author-email: Andrew Wetzel <arwetzel@gmail.com>
|
|
7
|
+
Maintainer-email: Andrew Wetzel <arwetzel@gmail.com>
|
|
8
|
+
License: Copyright 2014-2024 by Andrew Wetzel <arwetzel@gmail.com>, Shea Garrison-Kimmel, Jenna Samuel, Nico Garavito-Camargo.
|
|
9
|
+
|
|
10
|
+
In summary, you are free to use, edit, share, and do whatever you want. But
|
|
11
|
+
please cite us and report bugs!
|
|
12
|
+
|
|
13
|
+
Less succinctly, this software is governed by the MIT License:
|
|
14
|
+
|
|
15
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
16
|
+
this software and associated documentation files (the "Software"), to deal in
|
|
17
|
+
the Software without restriction, including without limitation the rights to
|
|
18
|
+
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
|
19
|
+
the Software, and to permit persons to whom the Software is furnished to do so,
|
|
20
|
+
subject to the following conditions:
|
|
21
|
+
|
|
22
|
+
The above copyright notice and this permission notice shall be included in all
|
|
23
|
+
copies or substantial portions of the Software.
|
|
24
|
+
|
|
25
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
26
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
|
27
|
+
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
|
28
|
+
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
|
29
|
+
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
|
30
|
+
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
31
|
+
|
|
32
|
+
Project-URL: Repository, https://bitbucket.org/awetzel/utilities/src/master/
|
|
33
|
+
Project-URL: Issues, https://bitbucket.org/awetzel/utilities/issues?status=new&status=open&status=submitted
|
|
34
|
+
Keywords: utilities,astronomy,astrophysics,cosmology,galaxies,stars,dark matter
|
|
35
|
+
Classifier: Programming Language :: Python :: 3
|
|
36
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
37
|
+
Classifier: Topic :: Scientific/Engineering :: Astronomy
|
|
38
|
+
Classifier: Development Status :: 4 - Beta
|
|
39
|
+
Classifier: Operating System :: OS Independent
|
|
40
|
+
Requires-Python: >=3.8
|
|
41
|
+
Description-Content-Type: text/markdown
|
|
42
|
+
License-File: LICENSE.md
|
|
43
|
+
Requires-Dist: numpy>=1.22.2
|
|
44
|
+
Requires-Dist: scipy>=1.13.1
|
|
45
|
+
Requires-Dist: h5py>=3.9.0
|
|
46
|
+
Requires-Dist: matplotlib>=3.8
|
|
47
|
+
|
|
48
|
+
# Description
|
|
49
|
+
|
|
50
|
+
Python package of utility functions that are useful in analyzing various datasets, in particular, catalogs of particles or galaxies/halos from cosmological simulations.
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
# Requirements
|
|
55
|
+
|
|
56
|
+
python 3, numpy, scipy, h5py, matplotlib.
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
---
|
|
60
|
+
# Content
|
|
61
|
+
|
|
62
|
+
## lower-level utilities
|
|
63
|
+
|
|
64
|
+
### array.py
|
|
65
|
+
* create, manipulate, analyze arrays
|
|
66
|
+
|
|
67
|
+
### binning.py
|
|
68
|
+
* binning of array data
|
|
69
|
+
|
|
70
|
+
### constant.py
|
|
71
|
+
* physical constants and unit conversions
|
|
72
|
+
|
|
73
|
+
### coordinate.py
|
|
74
|
+
* manipulate positions and velocities
|
|
75
|
+
|
|
76
|
+
### io.py
|
|
77
|
+
* read, write, print during run time
|
|
78
|
+
|
|
79
|
+
### math.py
|
|
80
|
+
* math, statistics, and fitting
|
|
81
|
+
|
|
82
|
+
### plot.py
|
|
83
|
+
* supplementary functions for plotting with matplotlib
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
## higher-level utilities
|
|
87
|
+
|
|
88
|
+
### catalog.py
|
|
89
|
+
* analyze catalogs of halos/galaxies
|
|
90
|
+
|
|
91
|
+
### cosmology.py
|
|
92
|
+
* calculate cosmological values, including cosmic density, distance, age, volume
|
|
93
|
+
|
|
94
|
+
### halo_property.py
|
|
95
|
+
* calculate halo properties at different radii, convert between virial definitions
|
|
96
|
+
|
|
97
|
+
### orbit.py
|
|
98
|
+
* compute orbital quantities such as peri/apo-centric distance, orbital time, in a given gravitational potential
|
|
99
|
+
|
|
100
|
+
### particle.py
|
|
101
|
+
* high-level analysis of N-body particle data
|
|
102
|
+
|
|
103
|
+
### simulation.py
|
|
104
|
+
* tools to help set up and run a simulation
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
---
|
|
108
|
+
# Units
|
|
109
|
+
|
|
110
|
+
Unless otherwise noted, this package stores all quantities in (combinations of) these base units
|
|
111
|
+
* mass [M_sun]
|
|
112
|
+
* position [kpc comoving]
|
|
113
|
+
* distance, radius [kpc physical]
|
|
114
|
+
* time [Gyr]
|
|
115
|
+
* temperature [K]
|
|
116
|
+
* magnetic field [Gauss]
|
|
117
|
+
* elemental abundance [linear mass fraction]
|
|
118
|
+
|
|
119
|
+
These are the common exceptions to those standards
|
|
120
|
+
* velocity [km/s]
|
|
121
|
+
* acceleration [km/s / Gyr]
|
|
122
|
+
* gravitational potential [km^2 / s^2]
|
|
123
|
+
* rates (star formation, cooling, accretion) [M_sun / yr]
|
|
124
|
+
* metallicity (if converted from stored massfraction) [log10(mass_fraction / mass_fraction_solar)], using Asplund et al 2009 for Solar
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
---
|
|
128
|
+
# Installing
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
The easiest way to install `utilities` is with `pip`
|
|
132
|
+
|
|
133
|
+
```
|
|
134
|
+
python -m pip install git+ssh://git@bitbucket.org/awetzel/utilities.git
|
|
135
|
+
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
We recommend working on a virtual environment with `venv` or `conda` within which to install the package.
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
# Description
|
|
2
|
+
|
|
3
|
+
Python package of utility functions that are useful in analyzing various datasets, in particular, catalogs of particles or galaxies/halos from cosmological simulations.
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
---
|
|
7
|
+
# Requirements
|
|
8
|
+
|
|
9
|
+
python 3, numpy, scipy, h5py, matplotlib.
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
# Content
|
|
14
|
+
|
|
15
|
+
## lower-level utilities
|
|
16
|
+
|
|
17
|
+
### array.py
|
|
18
|
+
* create, manipulate, analyze arrays
|
|
19
|
+
|
|
20
|
+
### binning.py
|
|
21
|
+
* binning of array data
|
|
22
|
+
|
|
23
|
+
### constant.py
|
|
24
|
+
* physical constants and unit conversions
|
|
25
|
+
|
|
26
|
+
### coordinate.py
|
|
27
|
+
* manipulate positions and velocities
|
|
28
|
+
|
|
29
|
+
### io.py
|
|
30
|
+
* read, write, print during run time
|
|
31
|
+
|
|
32
|
+
### math.py
|
|
33
|
+
* math, statistics, and fitting
|
|
34
|
+
|
|
35
|
+
### plot.py
|
|
36
|
+
* supplementary functions for plotting with matplotlib
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
## higher-level utilities
|
|
40
|
+
|
|
41
|
+
### catalog.py
|
|
42
|
+
* analyze catalogs of halos/galaxies
|
|
43
|
+
|
|
44
|
+
### cosmology.py
|
|
45
|
+
* calculate cosmological values, including cosmic density, distance, age, volume
|
|
46
|
+
|
|
47
|
+
### halo_property.py
|
|
48
|
+
* calculate halo properties at different radii, convert between virial definitions
|
|
49
|
+
|
|
50
|
+
### orbit.py
|
|
51
|
+
* compute orbital quantities such as peri/apo-centric distance, orbital time, in a given gravitational potential
|
|
52
|
+
|
|
53
|
+
### particle.py
|
|
54
|
+
* high-level analysis of N-body particle data
|
|
55
|
+
|
|
56
|
+
### simulation.py
|
|
57
|
+
* tools to help set up and run a simulation
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
---
|
|
61
|
+
# Units
|
|
62
|
+
|
|
63
|
+
Unless otherwise noted, this package stores all quantities in (combinations of) these base units
|
|
64
|
+
* mass [M_sun]
|
|
65
|
+
* position [kpc comoving]
|
|
66
|
+
* distance, radius [kpc physical]
|
|
67
|
+
* time [Gyr]
|
|
68
|
+
* temperature [K]
|
|
69
|
+
* magnetic field [Gauss]
|
|
70
|
+
* elemental abundance [linear mass fraction]
|
|
71
|
+
|
|
72
|
+
These are the common exceptions to those standards
|
|
73
|
+
* velocity [km/s]
|
|
74
|
+
* acceleration [km/s / Gyr]
|
|
75
|
+
* gravitational potential [km^2 / s^2]
|
|
76
|
+
* rates (star formation, cooling, accretion) [M_sun / yr]
|
|
77
|
+
* metallicity (if converted from stored massfraction) [log10(mass_fraction / mass_fraction_solar)], using Asplund et al 2009 for Solar
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
---
|
|
81
|
+
# Installing
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
The easiest way to install `utilities` is with `pip`
|
|
85
|
+
|
|
86
|
+
```
|
|
87
|
+
python -m pip install git+ssh://git@bitbucket.org/awetzel/utilities.git
|
|
88
|
+
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
We recommend working on a virtual environment with `venv` or `conda` within which to install the package.
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools>=61.0", "wheel"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "utilities_awetzel"
|
|
7
|
+
version = "1.0.0"
|
|
8
|
+
dependencies = [
|
|
9
|
+
"numpy>=1.22.2",
|
|
10
|
+
"scipy>=1.13.1",
|
|
11
|
+
"h5py>=3.9.0",
|
|
12
|
+
"matplotlib>=3.8"
|
|
13
|
+
]
|
|
14
|
+
requires-python = ">=3.8"
|
|
15
|
+
authors = [
|
|
16
|
+
{name = "Andrew Wetzel", email = "arwetzel@gmail.com"},
|
|
17
|
+
{name = "Shea Garrison-Kimmel"},
|
|
18
|
+
{name = "Jenna Samuel"},
|
|
19
|
+
{name = "Nico Garavito-Camargo"},
|
|
20
|
+
]
|
|
21
|
+
maintainers = [
|
|
22
|
+
{name = "Andrew Wetzel", email = "arwetzel@gmail.com"},
|
|
23
|
+
]
|
|
24
|
+
description = "utilities for Andrew Wetzel's packages"
|
|
25
|
+
readme = "README.md"
|
|
26
|
+
license = {file = "LICENSE.md"}
|
|
27
|
+
keywords = ["utilities", "astronomy", "astrophysics", "cosmology", "galaxies", "stars", "dark matter"]
|
|
28
|
+
classifiers = [
|
|
29
|
+
"Programming Language :: Python :: 3",
|
|
30
|
+
"License :: OSI Approved :: MIT License",
|
|
31
|
+
"Topic :: Scientific/Engineering :: Astronomy",
|
|
32
|
+
"Development Status :: 4 - Beta",
|
|
33
|
+
"Operating System :: OS Independent",
|
|
34
|
+
]
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
[tool.setuptools.packages.find]
|
|
38
|
+
where = ["."]
|
|
39
|
+
include = ["utilities", "utilities.*"]
|
|
40
|
+
|
|
41
|
+
[project.urls]
|
|
42
|
+
Repository = "https://bitbucket.org/awetzel/utilities/src/master/"
|
|
43
|
+
Issues = "https://bitbucket.org/awetzel/utilities/issues?status=new&status=open&status=submitted"
|