Mocpy

Latest version: v0.17.0

Safety actively analyzes 681812 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 5

0.17.0

Added

* Add support of `regions.Regions` [163]
* Add option to turn off optimization in `fill`. The optimization degrades MOCs that are
way more precise than the given WCS [166]
* Creation of a MOC from a zone (defined by min/max ra and dec)`MOC.from_zone`
* Creation of a single MOC from a lot of cones/boxes is faster with the new option in
`MOC.from_cones`/`MOC.from_boxes`: the keyword 'union_strategy' can now take the value
'small_cones'/'small_boxes' or 'large_cones'/'large_boxes'.
Small cones/boxes is faster for non-overlapping cones/boxes.
* `MOC.from_fits_images` can now loop through the HDUList to only keep images with the
parameter `hdu_index` set to -1 [110]
* `MOC.from_fits_image` now has an 'approximate' option that returns a rough approximation
of the footprint of the image data from the corners of a square deduced from its WCS and
does not apply any mask.

Fixed

* fix healpix order corresponding to 1 pixel on the image calculation in `MOC.from_fits_image` [169]
* `MOC.from_fits_images` will return an empty MOC and emit a warning if there are no images in the
FITS file instead of returning an error.

0.16.2

Fixed

* `MOC.from_astropy_regions` now accepts `EllipseSkyRegion` and `RectangleSkyRegion` where
width > height.

0.16.1

Fixed

* `from_healpix_cells` and `from_valued_healpix_cells` accept order zero cells again

0.16.0

Added

* `MOC.mask_uniq` allows to mas an array of uniq cells with a MOC
* `MOC.values_and_weights_in_multiorder_map` allows to filter a multiordermap by a MOC with
weights corresponding to the area of the cells intersecting the MOC and the multiordermap
* the `mocpy.WCS` class can now accept a sequence of angles as its fov argument rather than always
representing square areas of the sky.
* `MOC.from_polygons` and `MOC.from_polygons` now accept a boolean `complement` that allows to chose
between the small MOC described by the polygon or the bigger one (its complement)
* implement multi-moc operations on STMOCs (ex: stmoc1.union(stmoc2, stmoc3, ...)) for `union`,
`intersection`, and `difference`

Changed

* `MOC.from_healpix_cells` also accepts an int as depth if all the cells are at the same level
* `MOC.from_vizier_table()` does not call the MOCServer anymore. It now raises an error if the
catalog of table name is invalid (see 143). It also accepts `max_depth` as an argument. This
should replace `nside` in a future version.
* `MOC.from_ivorn()` now accepts `max_depth` as an argument. This should reb=place `nside` later.

Fixed

* `ranges` in `from_depth29_ranges` is now optional, to be consistent with the existing docstring
* `from_healpix_cells` and `from_valued_healpix_cells` now filter out invalid cells and raise a
warning when they do so
* fix multimoc operations (were all failing with a TypeError) [153]

0.15.0

Added

* a new method `MOC.from_cones` allows to create a list of MOCs from a list of centers
and radii. This is multi-threaded.
* new method `MOC.from_boxes` allows to create lists of MOCs from boxes. This is multi-threaded.

Changed

* `MOC.from_polygons` now accepts list of coordinates (that it assumes to be in degrees and
ICRS frame) rather than only lists of SkyCoord objects [137]

0.14.0

Fixed

* `MOC.border` no does not attempt on plotting the border when the MOc is out of the
view anymore.
* fix an issue where the number of references to the rust side was not
incremented when a moc was created from a pickle file. This also solves a lot of issues
with the multiprocessing module that calls pickle behind the scenes.

Added

* `MOC.sum_in_multiordermap` takes an astropy table with a `UNIQ` column and
a column name to sum. It returns the sum of the column in the intersection between the
MOC and the Multi-order-map. `MOC.probability_in_multiordermap` has a similar
behavior but also converts a probability-density into a probability.
* added `MOC.probabilities_in_multiordermap`, which is a multithreaded (on the Rust side) version of
`MOC.probability_in_multiordermap`.
* `MOC.from_polygons` now allows to create more efficiently some SpaceMOCs from a list a
of polygons.
* `STMOC.new_empty()` allows to create a new empty Space-Time MOC.
* `MOC.from_box` to create rectangular MOCs
* `MOC.from_astropy_regions` to create MOCs from astropy regions.

Page 1 of 5

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.