Skip to content

Commit aae72a8

Browse files
authored
Merge pull request #5 from javicarron/development-so3
Merging
2 parents 34f3b08 + 40e360f commit aae72a8

31 files changed

+6852
-1193
lines changed

README.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
<img src="logo.png" width="100">
2+
13
# Pynkowski
24

35
A Python package to compute Minkowski Functionals and other higher order statistics of input fields, as well as their expected values for different kinds of fields.
@@ -10,17 +12,17 @@ The statistics currently supported by this package are:
1012
The formats currently supported for **input data** are the following:
1113

1214
- Scalar HEALPix maps, as the ones used by [healpy](https://healpy.readthedocs.io/), such as $T, \kappa, P^2$ (see [paper 1](https://arxiv.org/abs/2211.07562)).
13-
- Polarisation HEALPix maps in the $SO(3)$ formalism (coming soon, see [paper 2](https://arxiv.org/abs/2301.13191)).
15+
- Polarisation HEALPix maps in the $SO(3)$ formalism (see [paper 2](https://arxiv.org/abs/2301.13191)).
1416
- 2D and 3D numpy arrays (coming soon).
1517

1618
The theoretical expectation of some statistics is currently supported for the following **theoretical fields**:
1719

1820
- Gaussian fields (such as CMB $T$ or the initial density field, see [paper 1](https://arxiv.org/abs/2211.07562)).
1921
- $\chi^2$ fields (such as CMB $P^2$, see [paper 1](https://arxiv.org/abs/2211.07562)).
20-
- Spin 2 maps in the $SO(3)$ formalism (coming soon, see [paper 2](https://arxiv.org/abs/2301.13191)).
22+
- Spin 2 maps in the $SO(3)$ formalism (see [paper 2](https://arxiv.org/abs/2301.13191)).
2123

2224
We are actively working on the implementation of more statistics, data formats, and theoretical fields. If you want to contribute, we welcome and appreciate pull requests.
23-
If you have any comments or suggestions, please feel free to contact us by email ([1](mailto:javier.carron@roma2.infn.it) and [2](mailto:[email protected] )) or by opening a discussion thread or issue.
25+
If you have any comments or suggestions, please feel free to contact us by email ([1](mailto:javier.carron@csic.es) and [2](mailto:[email protected] )) or by opening a discussion thread or issue.
2426

2527
The repository can be found on [https://github.com/javicarron/pynkowski](https://github.com/javicarron/pynkowski).
2628

@@ -51,12 +53,14 @@ This package is divided into three modules: `stats`, `data`, and `theory`. Each
5153

5254
- [`data`](https://javicarron.github.io/pynkowski/pynkowski/data.html)
5355
- [`base_da`](https://javicarron.github.io/pynkowski/pynkowski/data/base_da.html)
56+
- [`array`](https://javicarron.github.io/pynkowski/pynkowski/data/array.html)
5457
- [`healpix`](https://javicarron.github.io/pynkowski/pynkowski/data/healpix.html)
5558
- [`utils_da`](https://javicarron.github.io/pynkowski/pynkowski/data/utils_da.html)
5659

5760
- [`theory`](https://javicarron.github.io/pynkowski/pynkowski/theory.html)
5861
- [`base_th`](https://javicarron.github.io/pynkowski/pynkowski/theory/base_th.html)
5962
- [`gaussian`](https://javicarron.github.io/pynkowski/pynkowski/theory/gaussian.html)
63+
- [`spingaussian`](https://javicarron.github.io/pynkowski/pynkowski/theory/spingaussian.html)
6064
- [`chi2`](https://javicarron.github.io/pynkowski/pynkowski/theory/chi2.html)
6165
- [`utils_th`](https://javicarron.github.io/pynkowski/pynkowski/theory/utils_th.html)
6266

docs/pynkowski.html

Lines changed: 106 additions & 95 deletions
Large diffs are not rendered by default.

docs/pynkowski/__version.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
<path fill-rule="evenodd" d="M4.146 8.354a.5.5 0 0 1 0-.708l3-3a.5.5 0 1 1 .708.708L5.707 7.5H14.5a.5.5 0 0 1 0 1H5.707l2.147 2.146a.5.5 0 0 1-.708.708l-3-3z"/>
4545
</svg> &nbsp;pynkowski</a>
4646

47-
<img src="https://raw.githubusercontent.com/javicarron/pynkowski/main/logo.png" class="logo" alt="project logo"/>
47+
<img src="https://raw.githubusercontent.com/javicarron/pynkowski/development-so3/logo.png" class="logo" alt="project logo"/>
4848

4949
<input type="search" placeholder="Search..." role="searchbox" aria-label="search"
5050
pattern=".+" required>
@@ -74,7 +74,7 @@ <h1 class="modulename">
7474

7575
<label class="view-source-button" for="mod-__version-view-source"><span>View Source</span></label>
7676

77-
<div class="pdoc-code codehilite"><pre><span></span><span id="L-1"><a href="#L-1"><span class="linenos">1</span></a><span class="n">__version__</span><span class="o">=</span><span class="s1">&#39;1.0.0&#39;</span>
77+
<div class="pdoc-code codehilite"><pre><span></span><span id="L-1"><a href="#L-1"><span class="linenos">1</span></a><span class="n">__version__</span><span class="o">=</span><span class="s1">&#39;1.1.0&#39;</span>
7878
</span><span id="L-2"><a href="#L-2"><span class="linenos">2</span></a>
7979
</span></pre></div>
8080

docs/pynkowski/data.html

Lines changed: 25 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -44,16 +44,18 @@
4444
<path fill-rule="evenodd" d="M4.146 8.354a.5.5 0 0 1 0-.708l3-3a.5.5 0 1 1 .708.708L5.707 7.5H14.5a.5.5 0 0 1 0 1H5.707l2.147 2.146a.5.5 0 0 1-.708.708l-3-3z"/>
4545
</svg> &nbsp;pynkowski</a>
4646

47-
<img src="https://raw.githubusercontent.com/javicarron/pynkowski/main/logo.png" class="logo" alt="project logo"/>
47+
<img src="https://raw.githubusercontent.com/javicarron/pynkowski/development-so3/logo.png" class="logo" alt="project logo"/>
4848

4949
<input type="search" placeholder="Search..." role="searchbox" aria-label="search"
5050
pattern=".+" required>
5151

5252

5353
<h2>Submodules</h2>
5454
<ul>
55+
<li><a href="data/array.html">array</a></li>
5556
<li><a href="data/base_da.html">base_da</a></li>
5657
<li><a href="data/healpix.html">healpix</a></li>
58+
<li><a href="data/so3data.html">so3data</a></li>
5759
<li><a href="data/utils_da.html">utils_da</a></li>
5860
</ul>
5961

@@ -78,7 +80,8 @@ <h1 class="modulename">
7880
<div class="docstring"><p>This module contains all the classes to work with data in several conventions. Currently, the implemented formats are the following:</p>
7981

8082
<ul>
81-
<li><a href="data/base_da.html"><code>base_da</code></a>: the abstract class for general data fields, to be used as the base for the other fields.</li>
83+
<li><a href="data/base_da.html"><code>base_da</code></a>: the base class for data fields, to be used as the base for the other fields.</li>
84+
<li><a href="data/array.html"><code>array</code></a>: fields in the form of numpy arrays of arbitrary dimension, typically used for 2D or 3D maps.</li>
8285
<li><p><a href="data/healpix.html"><code>healpix</code></a>: scalar maps on the sphere in the healpix convention. An optional interface for $P^2$ is included.</p></li>
8386
<li><p>There is also a general utilities submodule called <a href="data/utils_da.html"><code>utils_da</code></a>.</p></li>
8487
</ul>
@@ -90,23 +93,26 @@ <h1 class="modulename">
9093

9194
<div class="pdoc-code codehilite"><pre><span></span><span id="L-1"><a href="#L-1"><span class="linenos"> 1</span></a><span class="sd">&#39;&#39;&#39;This module contains all the classes to work with data in several conventions. Currently, the implemented formats are the following:</span>
9295
</span><span id="L-2"><a href="#L-2"><span class="linenos"> 2</span></a>
93-
</span><span id="L-3"><a href="#L-3"><span class="linenos"> 3</span></a><span class="sd">- [`base_da`](data/base_da.html): the abstract class for general data fields, to be used as the base for the other fields.</span>
94-
</span><span id="L-4"><a href="#L-4"><span class="linenos"> 4</span></a><span class="sd">- [`healpix`](data/healpix.html): scalar maps on the sphere in the healpix convention. An optional interface for $P^2$ is included.</span>
95-
</span><span id="L-5"><a href="#L-5"><span class="linenos"> 5</span></a>
96-
</span><span id="L-6"><a href="#L-6"><span class="linenos"> 6</span></a><span class="sd">- There is also a general utilities submodule called [`utils_da`](data/utils_da.html).</span>
97-
</span><span id="L-7"><a href="#L-7"><span class="linenos"> 7</span></a><span class="sd">&#39;&#39;&#39;</span>
98-
</span><span id="L-8"><a href="#L-8"><span class="linenos"> 8</span></a>
99-
</span><span id="L-9"><a href="#L-9"><span class="linenos"> 9</span></a><span class="kn">from</span> <span class="nn">.base_da</span> <span class="kn">import</span> <span class="n">DataField</span>
100-
</span><span id="L-10"><a href="#L-10"><span class="linenos">10</span></a>
101-
</span><span id="L-11"><a href="#L-11"><span class="linenos">11</span></a><span class="k">try</span><span class="p">:</span>
102-
</span><span id="L-12"><a href="#L-12"><span class="linenos">12</span></a> <span class="kn">import</span> <span class="nn">healpy</span> <span class="k">as</span> <span class="nn">hp</span>
103-
</span><span id="L-13"><a href="#L-13"><span class="linenos">13</span></a> <span class="kn">from</span> <span class="nn">.healpix</span> <span class="kn">import</span> <span class="n">Healpix</span><span class="p">,</span> <span class="n">HealpixP2</span>
104-
</span><span id="L-14"><a href="#L-14"><span class="linenos">14</span></a><span class="k">except</span> <span class="ne">ImportError</span><span class="p">:</span>
105-
</span><span id="L-15"><a href="#L-15"><span class="linenos">15</span></a> <span class="n">hp</span> <span class="o">=</span> <span class="kc">None</span>
106-
</span><span id="L-16"><a href="#L-16"><span class="linenos">16</span></a> <span class="nb">print</span><span class="p">(</span><span class="s2">&quot;healpy was not loaded, some functionality will be unavailable&quot;</span><span class="p">)</span>
107-
</span><span id="L-17"><a href="#L-17"><span class="linenos">17</span></a>
108-
</span><span id="L-18"><a href="#L-18"><span class="linenos">18</span></a><span class="c1"># __all__ = [&quot;Healpix&quot;, &quot;HealpixP2&quot;]</span>
109-
</span><span id="L-19"><a href="#L-19"><span class="linenos">19</span></a><span class="n">__docformat__</span> <span class="o">=</span> <span class="s2">&quot;numpy&quot;</span>
96+
</span><span id="L-3"><a href="#L-3"><span class="linenos"> 3</span></a><span class="sd">- [`base_da`](data/base_da.html): the base class for data fields, to be used as the base for the other fields.</span>
97+
</span><span id="L-4"><a href="#L-4"><span class="linenos"> 4</span></a><span class="sd">- [`array`](data/array.html): fields in the form of numpy arrays of arbitrary dimension, typically used for 2D or 3D maps.</span>
98+
</span><span id="L-5"><a href="#L-5"><span class="linenos"> 5</span></a><span class="sd">- [`healpix`](data/healpix.html): scalar maps on the sphere in the healpix convention. An optional interface for $P^2$ is included.</span>
99+
</span><span id="L-6"><a href="#L-6"><span class="linenos"> 6</span></a>
100+
</span><span id="L-7"><a href="#L-7"><span class="linenos"> 7</span></a><span class="sd">- There is also a general utilities submodule called [`utils_da`](data/utils_da.html).</span>
101+
</span><span id="L-8"><a href="#L-8"><span class="linenos"> 8</span></a><span class="sd">&#39;&#39;&#39;</span>
102+
</span><span id="L-9"><a href="#L-9"><span class="linenos"> 9</span></a>
103+
</span><span id="L-10"><a href="#L-10"><span class="linenos">10</span></a><span class="kn">from</span> <span class="nn">.base_da</span> <span class="kn">import</span> <span class="n">DataField</span>
104+
</span><span id="L-11"><a href="#L-11"><span class="linenos">11</span></a><span class="kn">from</span> <span class="nn">.array</span> <span class="kn">import</span> <span class="n">DataArray</span>
105+
</span><span id="L-12"><a href="#L-12"><span class="linenos">12</span></a>
106+
</span><span id="L-13"><a href="#L-13"><span class="linenos">13</span></a><span class="k">try</span><span class="p">:</span>
107+
</span><span id="L-14"><a href="#L-14"><span class="linenos">14</span></a> <span class="kn">import</span> <span class="nn">healpy</span> <span class="k">as</span> <span class="nn">hp</span>
108+
</span><span id="L-15"><a href="#L-15"><span class="linenos">15</span></a> <span class="kn">from</span> <span class="nn">.healpix</span> <span class="kn">import</span> <span class="n">Healpix</span><span class="p">,</span> <span class="n">HealpixP2</span>
109+
</span><span id="L-16"><a href="#L-16"><span class="linenos">16</span></a> <span class="kn">from</span> <span class="nn">.so3data</span> <span class="kn">import</span> <span class="n">SO3Healpix</span><span class="p">,</span> <span class="n">SO3Patch</span>
110+
</span><span id="L-17"><a href="#L-17"><span class="linenos">17</span></a><span class="k">except</span> <span class="ne">ImportError</span><span class="p">:</span>
111+
</span><span id="L-18"><a href="#L-18"><span class="linenos">18</span></a> <span class="n">hp</span> <span class="o">=</span> <span class="kc">None</span>
112+
</span><span id="L-19"><a href="#L-19"><span class="linenos">19</span></a> <span class="nb">print</span><span class="p">(</span><span class="s2">&quot;healpy was not loaded, some functionality will be unavailable&quot;</span><span class="p">)</span>
113+
</span><span id="L-20"><a href="#L-20"><span class="linenos">20</span></a>
114+
</span><span id="L-21"><a href="#L-21"><span class="linenos">21</span></a><span class="c1"># __all__ = [&quot;Healpix&quot;, &quot;HealpixP2&quot;]</span>
115+
</span><span id="L-22"><a href="#L-22"><span class="linenos">22</span></a><span class="n">__docformat__</span> <span class="o">=</span> <span class="s2">&quot;numpy&quot;</span>
110116
</span></pre></div>
111117

112118

0 commit comments

Comments
 (0)