Overview 5 – Post-Processing

The Choices

  1. Flow phenomenon: Water boiling? Faucet dripping? Why does it look like that?
  2. Visualization technique: Add dye? See light distorted by air/water  surface?
  3. Lighting: Continuous? Strobe? Sheet?
  4. Photography
    A: Framing and Composition
    B: Cameras
    C: Lenses
    D: Exposure
    E: Resolution
  5. Post processing: Creating the final output. Editing: at least cropping the image and setting contrast.

We come to the last set of choices: post-processing. While it is possible that you can take the perfect image or video sequence, it is unlikely. All visualizations are going to benefit from editing in terms of cropping, and most will benefit from adjusting contrast and brightness. Some will want to go farther in pursuit of aesthetic goals. However, there is an important line drawn between manipulations that enhance visualization of the flow physics, and those that distort or obscure the physics. In flow vis, our goal is to reveal the awesomeness of the physics while keeping it truthful. The art is in applying the aesthetic you want without losing important information. Your work will be accompanied by a written document as well, so stay focused on the essential visuals of flow physics, keep track of and report the manipulations you perform, and let the text convey your details.

There are a bewildering variety of programs available for editing still images and videos, and you should be familiar with at least one of each. There are industry-standard programs that usually have an annual subscription fee such as Photoshop, but there are also free open-source programs that are just as powerful. I’ll touch on the ones I’m familiar with, but as with the rest of imaging technology, this area is changing rapidly. You should plan on learning new programs every few years. After you switch a couple of times, you’ll see the commonalities and the learning curves will shorten.

When learning to use these powerful programs, it’s easy to get overwhelmed with all the different methods for achieving a goal, even within a single program. I suggest starting with a tutorial for newbies. I read pretty fast, and much prefer written documentation, but others love instructional videos. Some programs provide well-written online documents that are easy to read, with lots of screenshots, and some programs only have bare-bones, cryptic lists of functions.  Videos tend to be focused on a particular workflow and will miss many features, but they may provide quick answers to specific questions. Some instructional videos are direct, clear, and reasonably paced, and others run at hyperspeed, or are loaded with jokes or promotions and ads. Each of us has to find what works for us.

After listing some program options to choose between, I’ll go over some basic manipulations that you’ll need, and briefly show how to achieve them in Darktable for still images. I’ll also provide at least a recommendation of programs for video editing.

Image Processing

Software Options

Photoshop is still the standard for fine-art still photography. It’s an Adobe product, and comes bundled in the Adobe Creative Cloud. Student subscriptions are available. Forever licenses are available, used or new; you can get the 2022 stand alone version for Windows for $40 although I can’t swear to the authenticity of the license. There are two other flavors of Photoshop: Photoshop Elements is an inexpensive ($30) lightweight version that will be fine for this course, and Lightroom, which is designed for professional (wedding) photography where the same edits are made on many images simultaneously.

There are several free open-source image processing programs: Gimp, Darktable and Rawtherapee.  Gimp is a good competitor for Photoshop, and is a raster-based editor, meaning you make edits changing pixel values, and to undo you have to go back through the history.  Rawtherapee probably has an easier graphic user interface and shorter learning curve, but is comparable in functions to both Gimp and Darktable. Critics say that it is slow to render, but I haven’t used it enough to comment. I like Darktable because it is nondestructive; all the manipulations are saved in a sidecar xmp file without changing the original image. Also, the functions are housed individually, so you can turn a function on and off and change its settings at any point in the workflow. It can read my raw Canon files, but it took a while for somebody to write the module for the most recent camera. I also like its written documentation, plus many users have posted video tutorials for various levels of expertise. As an open-source project, you can find out exactly what each function does to the image, enhancing the scientific validity of the edited result.  In contrast, Photoshop functions are proprietary.

Basic Image Manipulations

There are only four things you really need to be able to do to a still image: crop (trim off a side); adjust contrast and brightness or use RGB curves; clone stamp or retouch spots; and save in the format you need. There is much more you can do, of course, but this is the minimum.

Figure 1: Initial darktable screen. Hertzberg 2022

Let’s go through how to do these things in Darktable. When you start Darktable you get the input/output screen, called the ‘lighttable’ screen. There are other approaches, but to just get going with an image, drag the file into the central window and click to select it, then click on ‘darktable’ in the upper right corner.

Figure 2: Crop function in darktable. Hertzberg 2022

To crop the image, find the crop function menu by typing into the search window in the upper right, beneath the histogram. All functions in darktable are activated with their on/off button, and the menu is expanded or collapsed by clicking on the function name. The function can be reset to default parameters with the reset button, the middle of the three buttons to the right of the function name.

Once the crop function is active, you can drag the edges of the image to make the crop. You can come back and change the crop at any point while editing. When you go to the next function, you’ll see the cropped version unless the crop function is turned off.

Figure 3. Setting the RGB curve to an S shape increases contrast in the middle pixel values. Hertzberg 2022.

Setting brightness, contrast, and color balance are almost always needed, and there are dozens of functions to achieve these with varying levels of automatic settings. I advise learning to use the ‘RGB curve’ function. It is likely available in all image processing programs, and is an explicit representation of what you are doing to the image. The RGB curve is a transfer function. The starting pixel values are on the horizontal axis (abcissa), with the resulting output pixel values on the vertical axis (ordinate). If the curve is a straight line, all the inputs are mapped linearly to the output. If the curve is a slight S shape as shown in Figure 3, then most of the dark (shadow) pixels at the left end of the x axis) become even darker, being mapped to very low values of output pixels. You can see this change in real time in the image, and in the histogram in the upper right corner of darktable. The upper right end of the RGB curve does something similar to the bright pixels, making them brighter. The middle pixels will become either darker or brighter, depending on the local curve in relation to the original linear map. The resulting effect is stronger overall contrast. By sliding the whole curve to the right the image is brightened overall; to the left, it’s darkened.

You can operate on the red, green or blue color channels independently to shift colors. Change the mode from ‘RGB, linked channels’ which controls all three color channels simultaneously, to ‘RGB, independent channels’, which lets you edit transfer curves for each of the channels separately. For example, you can make the image more yellow by depressing just the blue curve and/or lifting the red and green curves.

Figure 4: Retouch function in darktable. Hertzberg 2022.

The last basic manipulation is retouching, a.k.a., clone stamping. This means to copy a small area from one region into another place. You can replace a dead or hot pixel easily this way, or edit out a light pole from a cloud image. Darktable has a very sophisticated wavelet transform technique to do this, but it’s tricky to use, so let’s start with a basic copy-and-paste version. Open the ‘retouch’ function, shown in Figure 4, and choose the circular retouch tool. Click on the problem area in the image, then drag to where you want to copy from. You can change the diameter of the copied area using the scroll wheel on the mouse, if you need to.

Figure 4: Export menu in darktable. Hertzberg 2022.

The trickiest part of darktable is generating a final output file, oddly enough. All of the manipulations are stored immediately and automatically as you make them in a separate file, with the same name and location as your image file, plus an .xmp extension. But to get all of your changes applied to your image in a new image file, you have to go back to the lightroom screen.

Make sure your current image is selected, and expand the ‘export’ function on the right. Set the ‘storage option’ to ‘$(FILE_FOLDER)/$(FILE_NAME)’. This will create your output file with the same location and filename as your original. It won’t overwrite anything if you have ‘on conflict’ set to ‘create unique filename’. It will make a yourname_01 file, with whatever filetype extension you chose next, under ‘format options’. For posting to the flowvis.org website, I recommend the .png file type. This is loss-free and compact. You can set the pixel size for one dimension (1200 recommended for flowvis.org), leave the other as ‘0’ and it will maintain the aspect ratio automatically. After choosing these settings, hit the ‘export’ button at the bottom of the menu.

Video editing

Software Options

Video editing is a bit more complex than still image editing. You’ll want to do the same basic manipulations as in a still, plus add titles and audio. The files are much larger, making every aspect more resource intensive. Video editing requires a better computer than photo editing; you’ll also need a video streaming service like YouTube or Vimeo, and uploading will take much longer. Cropping is harder because it’s wiser to stick with a standard format and aspect ratio, but you can usually pan and zoom within your original framing.  There are a variety of free consumer-level programs, but there are certain things to watch out for: you may not be able to adjust the brightness or contrast, and you may be stuck with dumb-looking titles, or a watermark (the program name in light text across your video).

If you are new to video editing you should start with iMovie if you are on a Mac or other iOS device. If you are using a PC, I like Minitool Moviemaker as a starter editor for beginners. It does the basic manipulations well and does not mar your video with a watermark. The free version has a length limit of 2 minutes, which is likely sufficient for Flow Vis classwork. It has reasonable written documentation, and there are lots of tutorials on YouTube to get you started.

If you are ready for a more advanced editing program, then Final Cut Pro is what film students use on Macs. There are a couple of very powerful free programs for PCs that I’m familiar with: Davinci Resolve and Blender. Resolve is free to the individual, but you’ll need a license to do larger projects with multiple contributors. Resolve has good written and video documentation. Blender is an open-source program, free to all, and includes a LOT of animation tools in addition to pretty good video editing capability. Unfortunately, written documentation for Blender is scarce, although there are tons of video tutorials of varying quality from the user community. I’m currently learning Blender because I want to do some animated illustrations for this book; otherwise I’d have stuck with Davinci Resolve. The editing workflow is very similar in the two programs, although the terminology is different.

Basic Video Manipulations

The basic things you’ll need to do to your video before uploading it are similar to still image editing, with a couple of additions. I’ll list the things you’ll need to be able to do, but it will be easier to learn how from a YouTube tutorial.

First you’ll need to import your video clips into the program. Then you’ll composite them, which involves placing items like video clips, still images, and titles on a timeline. Adjusting brightness, contrast, and color is called ‘color grading’ when you do it for video. Cropping  — meaning changing the xy pixel dimensions — isn’t a great idea for the new user, but zooming in and panning around is do-able, allowing you to exclude extraneous equipment from view, for example. For posting to the Flowvis.org website your video must have at least a title at the beginning, with your name, your collaborators, and the date, so you’ll want to learn how to add text to your video. You can really waste a lot of time playing with titles and text (I know I do) so I recommend sticking to a very simple style at first.

I strongly recommend you add some music; it can really lend weight to your visual message. However, you must only use music that you have a right to use. You can find royalty-free music to use in YouTube and Vimeo, or your video editor may offer some. For a Flowvis.org post I require that you include in your titles a credit for any music used, at the beginning or end of your video.

The programs for beginners, like iMovie and Minitool Moviemaker offer ‘templates’. These will make your video look unprofessional, with distracting titles, transitions, chopped sequences and cheesy music. They are appropriate for weddings, family vacation videos, and party invitations. You may find them hilarious, but I don’t recommend you use them in your professional portfolio.

You’ll want to post your videos to a streaming service: YouTube, Vimeo or both. Unfortunately the Flowvis.org website does not have space to host student videos. Instead, you may want to build a professional portfolio on one or the other streaming service. I prefer Vimeo; it seems more oriented towards professionals and does not add advertisements,  but YouTube will probably get you more views.

Next up: clouds

This concludes the overview of the choices required to create a flow visualization. Next we’ll examine the physics of atmospheric clouds. After that we’ll go over a range of flow vis techniques in more detail.

 

References

Overview 4 – Photography E – Resolution
Clouds 1: Names