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

Certain fov fail to image #149

Open
epaell opened this issue Nov 20, 2020 · 0 comments
Open

Certain fov fail to image #149

epaell opened this issue Nov 20, 2020 · 0 comments

Comments

@epaell
Copy link

epaell commented Nov 20, 2020

I've been trying to use hipspy to generate a series of frames for an animation (where I pan and zoom across a HiPS image) but have been running into an issue where certain fields-of-view result in the following error:

./test1.py Fetching tiles: 100%|██████████████████████████████████████████████████████████████████████████████████████████| 142/142 [00:07<00:00, 17.83it/s] Traceback (most recent call last): File "./test1.py", line 15, in <module> result = make_sky_image(geometry, hips_survey, 'png', precise=True) File "/Users/len067/miniconda3/lib/python3.8/site-packages/hips/draw/ui.py", line 46, in make_sky_image painter.run() File "/Users/len067/miniconda3/lib/python3.8/site-packages/hips/draw/paint.py", line 148, in run self.make_tile_list() File "/Users/len067/miniconda3/lib/python3.8/site-packages/hips/draw/paint.py", line 178, in make_tile_list self.draw_tiles = [tile for children in tiles for tile in children] File "/Users/len067/miniconda3/lib/python3.8/site-packages/hips/draw/paint.py", line 178, in <listcomp> self.draw_tiles = [tile for children in tiles for tile in children] TypeError: 'HipsTile' object is not iterable

An minimal version of this script is:
`
#!/usr/bin/env python
from astropy.coordinates import SkyCoord
from astropy.coordinates import Angle
from astropy import units as au
from hips import WCSGeometry
from hips import HipsSurveyProperties
from hips import make_sky_image

coord = SkyCoord(Angle(303.74380308, unit=au.deg), Angle(-56.25561379, unit=au.deg), frame='fk5')
hips_survey = HipsSurveyProperties.fetch('https://www.atnf.csiro.au/research/RACS/RACS_I1/properties')
geometry = WCSGeometry.create(skydir=coord, width=3840, height=2160, fov="3.2666666666666666 deg", coordsys='icrs', projection='SIN')
result = make_sky_image(geometry, hips_survey, 'png', precise=True)
`

It almost appears as something happens when shifting from one HiPS level to another because I can image a sequence of fovs fine (e.g. fov="3.2 deg" works fine) and then a number will fail, then it'll start working again, then as the fov gets large the same thing will happen again (I ran these in parallel so now I have various gaps in my animation which I just can't seem to generate).

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