Remote astrophotography is all about using remote telescopes to acquire observations and there’s current;y no more remote telescope than the James Webb Space Telescope. Launched December 25, 2022 and started producing images on July 12, 2022; the JWST has produced amazing images. The nice thing about the JWST mission is that NASA makes all of the public observations available for download. This means that you can process the same FITS data that’s used to produce the incredible pictures featured in the media whenever the JWST team releases an image. You can also download other observations that the JWST has made.

I created the following image of NGC 3324 by downloading and processing the JWST images:

This image is completely different from the one featured in the media and is my interpretation of the data.

Here’s another interpretation of the same region:

The image is dark but the colors are as close as I could get them to the original color palette.

If you use PixInsight, you can use it to create JWST images. One of the difficulties you’ll encounter is combining the 4-6 grayscale images from all of the filters. If you search for articles and videos about processing JWST images using PixInsight, you’ll come across some people that suggest that you use PixelMath expressions along with various masks to combine and process images: this is far too involved and fails to yield results suitable for experimentation. I found a much easier way that lets your computer do most of the work, freeing you to experiment with what your final image might look like.

This article explains the following:

  • Downloading the JWST images
  • Extracting the FITS files from the JWST images
  • Aligning and quality-checking your images
  • Combining the greyscale images from each of the filters to produce a color image

Working with JWST images requires a fair amount of patience because you end up waiting a long time for downloads, then waiting for your computer to process, and then taking time to produce your final image. It can be an enjoyable project to work on an image over the span of several hours or a few days by following the steps in this guide.

Downloading JWST Images

  1. Point your browser to www.stsci.edu
  2. Click the Advanced Search link.
  3. In the MIssion box, type JWST and press enter to narrow down the search.
  4. In the Instrument box, type NIRCAM/IMAGE and press enter to narrow down the search.

    We’ll select the object to observe next. You can get a listing of objects available for download by exporting the list of observations to a CSV file which you can open in Excel or Google Sheets:

    Once the search completes, click the Export Table button near the top of the page to download a CSV file that you can open with Excel. Once you have opened the file, filter public observations by filtering on column AB for PUBLIC and then look at column E (you can sort and filter on this column), which contains the object name.
  5. In the Object Name field, enter the object’s name and press enter to search.
  6. When the Search button at the top becomes active, click Search – this will open a new tab on the search screen.
  7. The List View will contain the listing of observations for the object you selected – download each file by clicking the floppy disk icon at the left side of the listing (warning – some files are enormous and will take a long time to download).
  8. You can save your search by clicking the Copy Link for this Search button.

Note the tabs across the top of the search result page – one is Home Page, and the others are your search results. Next, extract the FITS file from the ZIP files you downloaded.

Extracting the FITS Image from your Downloaded Observation

Each of the ZIP files you download contains some files in various folders within the archive. Do the following:

  1. Double-click the name of one of the ZIP files you downloaded to open the file in Windows Explorer.
  2. Within the archive, find a folder that contains the words “nircam_clear”, followed by an F and some numbers – double-click the folder to open it.
  3. You’ll see four files in this folder, two of which are FITS files; the FITS file for the observation is usually the largest file and contains the characters, “i2d” at the end. Extract the file somewhere convenient on your system and note the location.

The FITS file contains seven images and we only want one of them, so you’ll have to extract the image you want from the FITS file next.

Extracting the Observation from the JWST FITS

Do the following to extract the JWST observation from the FITS file:

  1. Open one of the FITS files using PixInsight

    This might take some time to complete; PixInsight will open seven images once it finishes processing the file.
  2. In the listing of open windows, locate the one ending in the the characters “_SCI” in the name; this is usually the first file PixInsight opens and will be at the bottom of the stack of open windows.
  3. Save the file in XISF format and then close all of the open windows.

    Here is an example of the filename you’re looking for in the list of open windows:

    jw02729_o001_t001_nircam_clear_f444w_i2d_SCI

You need to extract the observation from each FITS file and save it in XISF format.

Next, we’ll have to align the images.

Running StarAlignment on the JWST Images

The images need to be aligned with one another and for that you use the StarAlignment process. The process generally works at its default settings and the only option I unchecked was Generate drizzle data option since drizzle files are not needed for our purposes. If you experience problems with StarAlignment, experiment with the settings in the Star Detection options. Carefully review the images for quality to pick a good reference image; you could use the Blink process for this purpose.

Evaluate the Image Quality

This step is optional but I prefer to do this before committing a lot of time to colorize my image. I use the ImageIntegration process (at its default settings) to combine all of the aligned images to produce a grayscale working image; the process runs on its own and I just leave it running and do something else.

I then inspect the image for quality issues by zooming in on various parts of the image; I look for duplicate stars and other artifacts that StarAlignment might have introduced and go back to StarAlignment if I see any problems.

Next, we’ll use the CombineImages script to combine all of the filters into a single color image.

Downloading and Installing the CombineImages Script

  1. Point your browser to the PixInsight forum, specifically this post about the CombineImages script, version 0.61.

    Alternatively, download it from my website but be aware that this might not be the latest version.
  2. Download DC_CombineImages_v0.61.zip from the forum post.
  3. Extract the folder that’s in the ZIP to, preferably, your Documents folder.

    Do not install the script in the PixInsight Program Files folder; the script needs access to create files and, by default, won’t have permission to do so. You would have to run PixInsight as an Administrator to grant the script access, and this is not recommended. You won’t encounter permissions problems if you install the script in our Documents folder.

  4. Install the script as a Featured Script in PixInsight

    From the menu, select Script Feature Scripts; click the Add button; select the folder where you installed the DC_CombineImages_V061 folder and PixInsight will add the script to your Script menu

Once you have the script installed, you can just use the Script menu to access it. Next, you’ll use the script to create your combined color image.

Using the CombineImages Script

The easiest way to use CombnieImages is to let it do whatever it needs using its automated features. In the DC_CombineImages_v061 folder is a folder called “Input Images” – copy your star-aligned images to this folder (don’t forget your reference image).

Start the CombineImages script by selecting Script DC_Scripts CombineImages. The script will detect the input files, so answer Yes to the prompt, “Do you wish to open them?”.

CombineImages will detect that this is a JWST observation and will apply the default JWST color palette to the image; this might take a few minutes to complete.

Once complete, you can start experimenting with the colors for each filter. You can reduce processing time by selecting one of the RESAMPLE options where the dropdown says “FULL SIZE” by default. Click the Combine button when you are ready to apply the changes you made. Once satisfied with the result, reset the shrink mode to “FULL SIZE”, click Combine, and then click Save to save your final image.

The CombineImages script makes it easy to experiment with color to produce a nice final image. Review the user guide that’s on the script window for helpful tips and suggestions.

Further Processing

Once you have your final image, you must stretch it before you can share it or publish it. I generally use the STF and GeneralizedHyperbolicStretch process to stretch my image. I might also use SCNR and other processes to highlight different aspects of the image. Noise reduction and deconvolution are not necessary because the data is of very high quality – as it should be, it is, after all, a $10 billion space telescope located in orbit a million miles from the earth!

Conclusion

In this article, you learned about how to download and process JWST images using PixInsight. My workflow automates and simplifies a lot of steps making it easy to experiment to produce good results in a reasonable time.

JWST Animation

Check out the JWST on its way to the Lagrange two point – amazing that it has arrived and we can process its images!

Update

If you don’t have PixInsight, I wrote an article that uses freely available tools to create JWST images.