spacetelescope / imexam

imexam is a python tool for simple image examination, and plotting, with similar functionality to IRAF's imexamine
http://imexam.readthedocs.io
BSD 3-Clause "New" or "Revised" License
74 stars 45 forks source link

Some plots appear to be broken on Windows #189

Open robertoabraham opened 5 years ago

robertoabraham commented 5 years ago

Hi - I'm experimenting with imexam on my Windows 10 laptop. I'm running in native Win32 mode (i.e. I'm not using the Windows Subsystem for Linux). Most things appear to work well (I'm using a Jupyter notebook and ginga's html5 widget to display things). However, a couple of plot types don't appear to be working. For example, radial plots and curve-of-growth plots. Others appear to working well (such as line and column plots, surface plots, and histograms). For example, when I try to make a radial plot I get the following. Firstly, I get some useful information printed in the notebook

read: r at 1910.0, 1258.666664123536
xc=1908.215353  yc=1258.139816

Then I get the following error:

2019-08-23 21:38:45,752 | E | ginga_viewer.py:550 (_key_press_imexam) | Failed examine function: TypeError("'float' object is not callable")
2019-08-23 21:38:45,756 | E | ginga_viewer.py:555 (_key_press_imexam) | Traceback:
   File "C:\Users\abrah\Anaconda3\lib\site-packages\imexam\ginga_viewer.py", line 548, in _key_press_imexam
    method(data_x, data_y, data)
  File "C:\Users\abrah\Anaconda3\lib\site-packages\imexam\imexamine.py", line 1058, in radial_profile
    annulus_area = annulus_apertures.area()

I'm using the development version of imexam, which I installed as follows:

pip install git+https://github.com/spacetelescope/imexam.git

I'm using Anaconda Python 3.7 and it's fairly vanilla (i.e. I'm not attempting to use the Astroconda channel as I don't think that supports Windows).

I suspect I'm doing something stupid... however the set of stupid things I could be doing is very large, and some insight into the specific stupid thing I'm doing would be appreciated. And please don't say "running Windows" 😄. In the last couple of years Windows usage in my department has been spiking, and I'm trying to figure out what works using some common setups.

Thanks,

Bob

robertoabraham commented 5 years ago

Hi - just a gentle nudge regarding this issue. Any help with getting imexam to work on Windows would be greatly appreciated.

sosey commented 5 years ago

sorry @robertoabraham I've been a little swamped. I think I have a windows 10 laptop at home I can test with but will need some time. My basic tests on win64 through appveyor seem to be working, but I'll try and load master to my home laptop and run through all the plots live with ginga, it looks like the issue might be with the ginga interface. What version of ginga are you running?

robertoabraham commented 5 years ago

Hi Megan, I'm running ginga 2.7.2. And thanks so much for your help with this!

sosey commented 4 years ago

so I think this is due to a change in the API for photutils, I've fixed it on the master branch and will make a new release. If you're still around, give it a test. Sorry for the long response time!

robertoabraham commented 4 years ago

Thanks Megan, I'll give it a whirl in the next few days. Thanks. Bob