Skip to content

Bug: realize_geom raises ValueError if a region is smaller than a pixel #140

@erykoff

Description

@erykoff

The following code raises a ValueError:

import numpy as np
import healsparse as hsp

m = healsparse.HealSparseMap.make_empty(32, 4096, dtype=np.uint8)
reg = hsp.Circle(ra=100.0, dec=50.4, radius=1./3600., value=1)
hsp.realize_geom([reg], m)

ValueError: Shape mismatch: cannot set an array of values to a zero-length list of pixels.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions