Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ValueError: Semi-minor axis must be in ]0, a[ #3

Open
Kincaidr opened this issue Aug 6, 2023 · 0 comments
Open

ValueError: Semi-minor axis must be in ]0, a[ #3

Kincaidr opened this issue Aug 6, 2023 · 0 comments

Comments

@Kincaidr
Copy link

Kincaidr commented Aug 6, 2023

Hi,

I am trying to create a MOC as shown in your example here docs/astropy/examples.ipynb.

If i follow these steps exactly:

region_center = SkyCoord(ra=35.30109, dec=-4.45962, unit='deg')
search_radius = 1*u.deg
from mocpy import MOC

moc_xxl = MOC.from_elliptical_cone(
    lon=region_center.ra,
    lat=region_center.dec,
    a=search_radius,
    b=search_radius,
    pa=0*u.deg,
    max_depth=14
)

I get:

ValueError: Semi-minor axis must be in ]0, a[

If i make a slight modification of a < b :

a_deg=1*u.deg
b_deg = 0.999*u.deg

moc_xxl = MOC.from_elliptical_cone(
    lon=region_center.ra,
    lat=region_center.dec,
    a=a_deg,
    b=b_deg,
    pa=0*u.deg,
    max_depth=14
)
Then it works
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant