Tuesday, January 27, 2015

A freeware script generator for Nebulosity

After visiting a friend I decided to look into other image processing software packages. Some are more affordable than others, at least from my viewpoint.  I found that Nebulosity has a large number of fans. It comes from the same house that gives us PHD (for free!) and I downloaded the trial version.

I like how it works for the most part, but its image acquisition ability seems to me to be only average. I should clarify--it's not so much its capabilities as the interface. If you use a DSLR or a one-shot-color CCD, or your nightly imaging sessions tend to involve only one filter, the interface is perfectly fine.

If you use a monochrome CCD and multiple filters during a session it gets a little more complicated. You have the choice to use the GUI for each filter or a built-in script editor to program your filter sequence.
The script editor is helpful and easy to use. Some understanding of the commands will take you a long way.

What the Nebulosity script system lacks is a way to temporarily interrupt running scripts to perform other tasks such as refocusing when a filter is changed. The focusing tools provided by Nebulosity can only be accessed when a script is not being run. A running script can be aborted but you can't resume executing the script from the command at which it was aborted.

I've done some programming in the past, so I thought I'd try to build something that could make refocusing possible from within a script. The solution I adopted is to make use of Nebulosity's ability to listen to the Windows clipboard for commands--it's not an elegant solution, but it seems to work. I may or may not use this depending on what else I find available for image capture, but it was fun throwing it together!

The program is called (at the moment) NFeeder.

Here are some screen captures:

Script Editor tab of main screen (click to enlarge to actual size) 
The Script Editor is fairly simple. The usual stuff is defined: destination folder, object name prefix, the sequence of filters (including exposure time, binning, and number of frames to capture). Dark and Bias frames are considered as types of filters and can be chosen in the same way.

Filter wheel contents are defined using an editor:
Filterset editor
Repetitions of the filter sequence can be specified. If you want to refocus at appropriate times, that can be indicated. (Dark and Bias frames don't move the filter wheel or pause for refocusing.)

The generator parses the inputs and constructs a Nebulosity script, shown at right. You can edit this by hand if you want. The script can be saved and previously saved scripts can be loaded.

If you're not refocusing, you can save the script and run it from within Nebulosity just as it is. If you want the ability to refocus when the filter changes you need to move on to the Feeder tab:

Feeder tab of the main screen
The Feeder tab shows the same script that was created/edited on the Script Editor tab. NFeeder works like this:

  1. Start Nebulosity, connect to the camera and do whatever is best done within the Nebulosity interface: I prefer to set cooling and configure dithering from outside a script.
  2. Launch a stub script that puts Nebulosity into listening mode. The stub script can be created from this tab
  3. Start feeding a script to Nebulosity with the click of  a Start button. As it works NFeeder shows you which commands have been sent to Nebulosity. 
  4. When NFeeder reaches a point where refocusing should be done, it passes a command to Nebulosity to show a prompt dialog. Clicking cancel in the prompt dialog aborts the stub script and you're free to access Nebulosity's focusing tools.
  5. When you're done focusing, launch the stub again and click NFeeder's Resume button
  6. Repeat steps 3 and 4 until the session ends.
  7. Click Nebulosity's Abort button to end the stub.
This may sound complicated, but it's not. I've tried the program with a Canon DSLR and SBIG ST-8300M + 8-cell filter wheel, and it worked correctly.

Want to give it a try? Here's the download. The application files and installer were scanned by Avast antivirus. Your comments would be appreciated. Still on my to-complete list are the night vision mode and better help information.

Please keep in mind that I made this for fun for a very small group of people (i.e., mainly myself) so it's probably lacking in features that may make it useful to you. It's free for your use because I enjoyed making it.

And yes, I'm aware of some other programs that serve similar purposes. Commercial products include Sequence Generator Pro ($99) which does far more than I need and Astro Photography Tool (APT) which is an amazing value (and one I'll probably purchase). Both are standalone programs worth considering.

Friday, December 12, 2014

The Importance of Bias Frames

The rule I came to understand for using bias frames was this: Temperature-regulated cameras don't need them when the dark frame exposure time and temperature match those of the light frames. In other words, bias frames are useful only when you're trying to match dark and light frames that differ in exposure time or temperature.

Is this really true? Some people say it's not, and that bias frames should always be used. My experience seems to agree. But is there a way to verify this? That's what I tried to do with some simple analysis using my SBIG ST-8300M CCD camera.

I started by shooting twenty three-minuted dark frames at a temperature of -25C. Ten of these I set aside for later testing. The remaining ten were combined using three different methods (average, median, min/max exclude average). The result was three master dark frames, one for each common method of combining dark frames.

I then shot twenty bias frames at -25C. The ST-8300M's shortest exposure time is 0.04 seconds, so that's what was used. These were averaged to create a master bias frame.

Next, the ten dark frames that were set aside (it's helpful at  this point to think of them as light frames) were calibrated with each of the master dark frames, both with and without the master bias frame. This created six sets of calibrated frames. 

Each set of calibrated frames was then stacked using average, median, min/max excluded average, weighted median and sigma clipping (at 2.55 standard deviations). These are some of the standard stacking methods offered by ImagesPlus. The result is thirty images. ImagesPlus was then used to calculate the noise in each image (represented by the standard deviation of each image's pixels, in this case), and the results are given in the tables below:
Noise in processed images. Top table: noise present when the master bias frame is used. Each column is for a different dark frame combining method (AVG = average, MED= median, MME = min/max exclude). Each row corresponds to a different "light" frame stacking method (WMED = weighted median,  S255 = sigma clipping at 2.55 standard deviations. The row of numbers below each column is the column average. Bottom Table: as in the top table, but the calibration was performed without the master bias frame.
The results show that the exclusion of the master bias frame roughly doubled the standard deviation of the pixel values!

The images below show a comparison between the lowest noise (using min/max for dark combine and light stacking and bias for calibration) and the greatest noise (using median for combine and stacking, with no bias information). ImagesPlus digital development was applied equally to both stacked images.

Best case: Min/max combine and stack, bias included in calibration

Worst case: Median combine and stack, bias not included in calibration.

The lowest noise levels corresponded to combining dark frames using either an average or a min/max exclusion method and then stacking light frames with the min/max exclude method. Because both dark and light frames can be contaminated by cosmic rays, it makes sense to use some sort of rejection combine method in their processing. Both median and min/max perform about the same when the bias information is included. When the bias frame information is not included the min/max method clearly outperforms the median method.

I think that from now on I'll always use bias frames!

Sunday, November 30, 2014

Finishing the Astronomical League Bright Nebula list anytime soon? Not very likely.

The ALBN requires 100 objects to be imaged, and I'm in need of 26 more to finish. There are 62 listed objects that I can choose from according to the published list. Let's see how that shakes out.

First eliminate the bogus object on the list, IC 425, although I'm tempted to image its supposed location and count that as one. This leaves 61 Objects.

Next, eliminate all the objects that are too low to image from the locations I plan to use. The southernmost locations are the Iowa and Nebraska star parties at 41.8 and 42.6 degrees north, respectively. As a guess, these allow imaging to about 40 degrees south declination. This eliminates five objects: IC 4628, Gum 12, NGC 2736, NGC 6164, and NGC 6188. There are now 56 objects.

Now let's assume I want to avoid imaging objects that require very dark sites, namely those with Lynd's brightness 6. This includes eleven objects (Sh 2-218, LBN 619, 1064, 683, 8, 10, 1091, 19, 70, 140, and 434). There are now 45 objects available. (Tossing out the brightness 5 objects eliminates another 12 objects, leaving 33.)

Let's see how far I could get just doing the brightest objects. Brightness 1 has 4 objects, 2 has 4, 3 has 5, and 4 has 7. The total without dipping into the 5s is 20. There are some objects without assigned brightness that could add some to this: NGC 2174, Sh 2-264, LBN 962, NGC 2149, NGC 2296, NGC 6357, NGC 6729, and IC 4812. These lift the total to 28! Only two objects to spare!!

Actually, LBN 20 and 22 (brightness 5) share a field, so there are three to spare.

A first pass at the optimum months for imaging these can be found using SkyTools3.

January: IC 2169, LBN 943, Sh 2-280, NGC 2296, IC 468, NGC 2359
February:
March:
April:
May: LBN 1122
June: LBN 20, LBN 22, NGC 6357, Sh 2-12, Sh 2-13
July: IC 4812, NGC 6729, LBN 52, IC 4701
August:
September:
October:
November: IC 360, NGC 1555, NGC 1579
December: LBN 945, NGC 1931, Sh 2-264, NGC 1999, Sh 2-240, LBN 962, NGC 2149, NGC 2174, IC 2162

This is where the bad news rears its ugly head. Sixteen (nineteen minus the three spare) objects must be imaged during the winter months. Given the terribly cloudy (not to mention cold) winters we've had lately, this becomes problematic. It's probably going to be necessary to dip into the dimmer objects that are available in spring and summer. These include LBN 683, 1088, 10, 1091, 19, 11, 8, 70, and 490. That's only 9, though, which means that at least seven of those winter objects will need to be imaged.

Conclusion: I might be at this for a couple of years yet!

Wednesday, November 12, 2014

Lens Happy

A visit to National Camera Exchange's used lenses page turned up a manual focus 200mm f/4 Olympus Zuiko OM lens. This should work with my ST-8300M, and old reviews suggest that it's got a chance of providing acceptable corner stars even when close to wide open. At a price of $40 it's worth a try. My impression is that the lens sells for $50-60 on the used market, which probably explains why it sat on NatCam's shelf for a long time at $90.

If you get the impression I've got a fixation with lenses, you're right. There have been too many objects that are a bit too large for my 422mm AT65EDQ, and I'm too impatient to make a mosaic for each of them. My telescopes currently give me a nice range of focal lengths:
  • 2350mm (C925 @ f/10)
  • 1480mm (C925 @ f/6.3)
  • 700mm (TV 102 @ f/6.9)
  • 422mm (AT65EDQ @ f/6.5)
These very roughly represent steps of two in scale. Extending these to shorter focal lengths with SLR lenses adds:
  • 135mm (Tamron OM @ f/5.6)
  • 70mm (Canon 17-70mm zoom @ f/5.6)
  • 50mm (Zuiko OM lens @ f/1.8)
  • 28mm (Tokina @ f/1.8)
The 200 mm lens fills the gap between scopes and lenses, taking the place of an old Tele-Astranar that won't reach focus with my CCD. Granted that these are a bunch of consumer-grade lenses I don't expect miracles from them.

The field of view of a 200mm lens used with an ST-8300 is huge: 5.1 x 3.9 degrees. Here are some objects that fit nicely into that field with a little room around the edges:
IC 1396, which is more extensive than Sky Tools depicts

Lagoon and Trifid Nebulae and vicinity.

Rho Ophiuchi Nebula and vicinity

Orion Nebula and vicinity


M 31 et al.

IC 1318 et al.

Rosette nebula
North America and Pelican Nebulae
The pictures represent the full field of a 200mm lens combined with an ST-8300 CCD camera as illustrated by SkyTools3.

There are more objects than these suitable for the 200mm lens, but this will make a good start!




Wednesday, November 5, 2014

A New Imaging Telescope, sort of.

Recently I've tried making a couple of mosaic images, but the process is slow. Given my circumstances it's typically a full night's work to make one piece of a mosaic. Wouldn't it be nice to use something that's fast with a much wider field of view?

One way to shoot wide fields is with a camera lens. Consumer-grade lenses tend to be mediocre imaging tools, though; their fields are not very flat and stars at the edges will show a lot of distortion unless the lens is closed down quite a bit. A good reference is Jerry Lodriguss' "Catching the Light" page about lenses. He recommends a number of lenses for imaging, some of which are within the reach of budget-minded imagers.

I'd like to add another lens, a fixed focal length Tamron 135mm Adaptall. It opens up to f/2.5, but it's actually quite decent at f/4. Here's what I mean:

400x400 Corners of a Tamron image
These are the four corners, each 400x400 pixels, from a stretched stack of 10-minute H-alpha exposures. The full frame is 3352x2532. The uneven brightness result from not applying a flat frame. Obviously it needs one!

For reference, here is the frame center:
Center 400x400 area
Center focus is sharp, and the corners are very good.

I originally purchased this lens back in the late 70's or early 80's for my OM-1 and it's been gathering dust since I went digital. Getting this mated with my SBIG ST-8300 was a minor adventure.

The Tamron was sold as a lens that can be used with a number of cameras. It was usually sold along with an adapter for the indended camera, in my case Olympus. SBIG sells a Canon lens adapter for the ST-8300 (A little pricey at $300, but it works). There are a whole bunch of adapter rings available to let OM-1 users put their lenses on their Canons, so the whole thing fits together: Adaptall lens | Adaptall to OM-1 adapter | OM-1 to Canon adapter | Canon adapter | ST-8300. Simple, right?

So now I can go wide. Instead of my AT65EDQ (422mm @ f/6.5) I can image with 135mm @ f/4. That's almost ten times the angular area with exposures that are a factor of 2.5 shorter. Nice.

Targets for this winter will be Barnard's Loop, Sh 2-240 (the Spaghetti Nebula), and whatever else the weather permits.

I'll also be testing an old 200mm lens I used with my OM-1. It only opens to f/6.3 and I suspect the optics are relatively poor. We'll see.

Thursday, October 23, 2014

New Images, Projects Done and to Do

Projects Done:

I completed the light shield extension for my AT65, but immediately changed over to imaging with my TV 102 so it's gotten no use.

The electroluminescent flat illuminator is also done, and if the results indicate anything it works great. Just rotate the telescope to looking at the zenith, place the device over the objective, turn off the mount and transfer the 12V power cord to the panel, and start shooting flats.

Images since last time? There's been a few, and you can find them in my gallery on Astrobin. I'll show two of them here in reduced size to save you a trip:

This is IC 348; I really wanted to do a good job with this because I think lately my image quality has suffered as I gather images for the AL Bright Nebula list.
IC 348 and friends
IC 348 is the cluster with nebulosity just below the bright star (Omicron Persei). Note that there are a couple of dark clouds present, one under 348 and the other at image right. 

The evening this was taken was a bit of a marathon, in that it started at dusk and extended until 5:30 A.M. when the Moon rose and I started getting sleep-deprivation punchy. The last image of the night was of the Moon:


I like this image because clouds caused the sunlit side of the Moon to look like it's in a glow... the effect in my mind is of the moon rising like a rocket (complete with exhaust plume) in the morning sky. Well, maybe you had to be there. Given that it's an LRGB image with only one frame per channel it came out well in a goofy sort of way.

Also imaged was M 78, which I think came out a little dark--I'll probably reprocess it.

Next up is fiddling with my DSLR lenses to see how they work with my ST-8300. That's in preparation for some of the big objects coming up: The Witch's Head, Barnard's Loop, Simeis 147, and others. I've got a couple of humble-quality Canon and Olympus lenses that should work (thanks to an adapter) with the Canon adapter sold by SBIG, and I want to see how much they'll need to be stopped down to make decent star shapes.

Monday, September 29, 2014

Imaging at the 4M

The 4M is the MAS (Minnesota Astronomical Society) Mini Messier Marathon. It takes place annually during the fall when it's the second time of the year one can see a large number of Messier objects in one night. In Minnesota the fall marathon usually has much nicer weather; in spring, the observing field can be under a foot or more of snow, or it can be a soggy mess thanks to snow melt. The wind chill can be -25F.

This year the 4M was very nice. Temperatures were in the 60s, the ground was soft but not too wet, and a gentle breeze kept the dew from forming. Mosquitoes were at a minimum--I noticed only a few, and that was only during the early evening. Clouds spread overhead at sunset and persisted until a little before 10 P.M., at which time it was a scramble to get my imaging gear going before I lost too much more time on the southern objects I was going for.
Because the transparency was poor and time was limited I opted to go for only one of my southern targets, Sh 2-46, a fairly bright (LBN brightness 3) emission nebula in Serpens Cauda. With almost no time for it I opted to image it only in luminance. I had to end imaging after 39 minutes because it was sinking into the low-altitude murk and starting to lose brightness.

I stayed west of the meridian to get LBN 113, another emission nebula that almost three hours of Ha could not catch in my back yard. This time I went with a different plan, L binned 2x2 and RGB binned 3x3. I used equal total exposure times for L and RGB, 15x180s. The results were better than I expected:
Top: Sh 2-46. Bottom: LBN 113.
2-46 is the unimpressive light patch just below the center of the image. 113 straddles the yellow star near the image's center. The bright blue star to its right is theta Aql.

These took me to almost midnight, so the evening was still young. By that time M45 was well up, and a difficult object  I wanted, IC 353, was right beside it. It didn't take long to acquire the object and begin shooting. 

However, I made a bad mistake at this time. The scope and camera had to move quite a bit to swing from west to east of the meridian, and in that flip the camera's sensor plane went out of orthogonality with the optical axis. Focus was no longer anything like crisp across the field, and there was some astigmatism introduced. I should have checked everything over, but in my haste I didn't.

After I was done with IC 353, I was getting tired and decided to image something bright. IC 405 in Auriga was up now, and that became my target:

Top: IC 353. Bottom: IC 405 (Flaming Star Nebula)

IC 405 deserves more exposure time, but that will have to wait until another night. By the time I was done with 405 it was 2:44 A.M., and I was ready to call it a night. all but a handful of marathoners had packed it in for the night by this time, so I decided to join them.

Three of these are new AL Bright nebula list images for me, and the image of LBN 113 replaces my earlier attempt. I'm left with only one shaky image, in my opinion, that of Barnard's Loop. It's plainly in the image, but it could look so much nicer!

What's next? The seasonal dry spell in AL Bright Nebular list objects will last for another month or so. Things really start to pick up in November. If there are some clear nights another trip to Cherry Grove may allow me to pick up some fading summer objects. Cherry Grove is only modestly dark, but it's dark enough to allow LRGB imaging.