Description
The DS9 class that is bundled with VIP https://github.com/vortex-exoplanet/VIP/blob/master/vip_hci/vip_ds9.py has some features that I use frequently and would like to see here. Perhaps they already do and I just don't realize how to use them.
Start
First, the PyDS9 package includes a method that will start the DS9 process looking in the PATH or for some pre-configured names https://github.com/ericmandel/pyds9/blob/678ebf359ccd550150eadbe2f5c59d58b8145274/pyds9/pyds9.py#L70-L91
I actually have a version of this specifically for Mac that works fine-
const APP_NAMES = ("SAOImageDS9.app", "SAOImage DS9.app")
function start(target="ds9")
user_dir = homedir()
local ds9_cmd
for p in ("/Applications", user_dir, joinpath(user_dir, "Applications "), joinpath(user_dir, "Desktop")), app in APP_NAMES
ds9_app_dir = joinpath(p, app)
if ispath(ds9_app_dir)
ds9_cmd = `open -a $ds9_app_dir --args -title $target`
end
end
run(ds9_cmd)
end
so all that needs to be added is a version that works for other platforms
display
In general, the VIP DS9 class has a lot of nice helpers. Things like clear_frames
cmap
, etc. which call simple commands internally but give a very nice functional interface. I don't think all of these are necessary, but I think it would be nice to get a list of functions we want to provide convenience methods for.
In particular, the display
method of the VIP DS9 class is really nice. It automatically tiles out vararg
frames for display. I'd really like to see something like this!