From 53f00b40e3a51ed4b5694feec7c3bc15e4bbb971 Mon Sep 17 00:00:00 2001 From: Tito Dal Canton Date: Wed, 18 Dec 2024 11:57:02 +0100 Subject: [PATCH] Remove FIXME and fix imports --- pycbc/distributions/sky_location.py | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/pycbc/distributions/sky_location.py b/pycbc/distributions/sky_location.py index 3e3f4df5348..3baadcaa910 100644 --- a/pycbc/distributions/sky_location.py +++ b/pycbc/distributions/sky_location.py @@ -20,8 +20,6 @@ import logging import warnings import numpy - - from scipy.spatial.transform import Rotation from pycbc.distributions import angular @@ -30,8 +28,6 @@ from pycbc.types import angle_as_radians from pycbc.libutils import import_optional -mhealpy = import_optional('mhealpy') - logger = logging.getLogger('pycbc.distributions.sky_location') @@ -186,6 +182,7 @@ class HealpixSky: def __init__(self, **params): # Read the map file. file_name = params['healpix_file'] + mhealpy = import_optional('mhealpy') self.healpix_map = mhealpy.HealpixMap.read_map(file_name) # Get the probabilities at each pixel. @@ -234,9 +231,6 @@ def pixel_corners(self, indices): more HEALPix pixels. Dimension 0 is the pixel index, 1 is the Cartesian coordinate, 2 is the corner index. """ - # FIXME boundaries() works for an input array and is fast, but only for - # single-resolution maps. It raises an exception with MOC maps. Another - # bugfix for mhealpy? return numpy.array( [self.healpix_map.boundaries(pi, step=1) for pi in indices] )