These tutorials will cover the use of four of the common perspectives in DAWN:

As time goes by, we'll also add more tutorials to cover some of the more specialised perpectives. This tutoral covers the Data Browsing perspective.


1) Browsing Data

The data browsing capabilities of DAWN are provided by two modules which take slightly different approaches to the same problem: Data Browsing (the default perspective) and DExplore. Both are capable of opening a range of different data types (traces, images, surface...) from many different types of files (dat, tif, img, Nexus/hdf5....). In the First Steps section you already plotted a trace, but now we'll look at how you can re-format that plot. Re-draw the plot of Energy vs ln(I0/It from the MoKedge_1_15.dat file:

1) Open DAWN and start the Data Browsing perspective

2) Expand the data folder in the left-most pane of the DAWN window (see the screenshot above)

3) Double click on the file MoKedge_1_15.dat

4) Select the checkboxes in the Data tab on the right next to Energy and ln(I0/It) (select them in that order!)

You should now have a plot displayed in a dat-file editor, similar to the screenshot below:

As mentioned in the description of Editors, the tool bar of the plot tab contains a range of useful tools for formatting or analysing the data.

 

 

 

 

4. The Plot -  Basics

When DAWN opens and image it automatically displays a default plot and automatically adjusts the contrast/brightness of the image. The plot can be customized by using the settings action.

Navigating the plot

The above toolbar actions can be used to zoom and pan around the image.

Image tool bar actions

The view menu - Colormaps

There are more options for adjusting the image in the view menu

Trace tool bar actions

 

 

 

 

 

 

 

 

 

 

 

a. Dat File Editor

Has three tabs for accessing data

 

 

You should see a single trace plotted, as shown above.

 

 

 

 

 

 

 

 

 

You will be greeted with a largely blank screen with lots of empty tabs, don't worry about that for now.

Opening A File

Find the Project Explorer tab on the left hand side of the screen (it should be the only one that isn't blank).

This opens the powder diffraction image for display.

The Project Explorer is like a favorites page for your data, you can link to folders of data on your local computer to this tab without making duplicates of the data.

Make a new data project

MyData should now be displayed in the Project Explorer

Data can also be opened directly from the file system using the File Navigator tab, or by dragging and dropping directly from a file explorer

Exercise 2. Use the File Navigator to open some data.

Exercise 3. Open some data by directly dragging it into the DAWN plot

Exercise 4. Add a folder to the Data Project by dragging the folder and dropping it in with the example data (choose to link rather than copy)

Editors and views - Plot/Text/Data/Tree

Now lets return to the diffraction image we have displayed.

On double-clicking the file some new tabs appeared and many of the previously blank views now show information. Before we dive in to opening and viewing different types of data lets take a minute to discuss some nomenclature that should make the rest of the tutorial more understandable.

Perspectives

The Data Browsing tool you are currently looking at (and all the other tools mentioned, like DExplore, Workflows....) are technically called Perspectives. In DAWN, a perspective is simply a collection of different tab views designed to help perform a certain task, be it to view and image, or write a python script. Many of these views appear in multiple perspectives and if you see a view in one perspective that looks the same as in another, there is a good chance they will work the same way.

The Editor

Most perspectives show an editor tab, one for each file open. The editor is the tab view that appears when you open a file (it has the name of the file at the top of the tab).  DAWN has different editors for images, nexus files, dat files, python scripts... many different things.  You don't need to worry about which editor you are looking at, DAWN automatically chooses the best editor for the type of file you want to open. (The name "Editor" is a bit odd considering the data files you open cannot be edited. When python source code or a workflow moml file is opened, on the other hand, these also appear in an editor and can be edited).

Views

Pretty much everything that is not an editor is a view. You can identify a view by the name it shows at the top of its tab.

Exercise 5. Locate the Editor and the Meta data, Value, Progress, and Console views in the Data Browsing perspectives, click on the tab to see what each view contains (most will be empty at this stage)

See how a new editor has appeared containing a blank plot and the Meta data view has changed to the Data view. The Data view contains a list of every data set found in the .dat file.

Take another look at the editor.  You should notices some tab pages at the bottom which say Plot, Text, Data and Info. Switch between these tabs to see what they show.

 

Nexus File Editor

Nexus files (and HDF5 files) can contain many different data sets of different types, shapes and sizes.  The files are often shown as a tree, with different nodes containing different data or metadata information.

 
The Rapid2D/data data set has 4 dimensions [1,1,512,512]. Since two of these dimensions are 1 the data set is shown as a 2D image, which in this case is what we expect to see. Just because a data set is 2D (or greater) does not mean it is an image, what if we wanted to view this data as a trace?

 

Exercise 6. Change the plotting method using the actions in the Data view , then return to showing the 2D image.

Exercise 7. In the example data, go to the saxs folder and open more .nxs files and view the data inside. This folder contains nxs and h5 files, what do they each contain? Look at the size of the files, where does the data live? Where does the metadata live?

Customizing Perspectives

After using Dawn for a while, the screen can get quite busy. Its very easy to have lots of views open making it difficult to see the wood for the trees.

The user interface in DAWN is highly customizable. Any views you are not using can be closed or hidden. Important views can be maximized. Views you need can be opened, even if they are not part of the perspective. If you want a view to be part of a perspective you can make your own custom perspective with the view added.

Hopefully by now you should have made a horrible mess of the perspective. If not, try harder.



Exercise 8. Close the Console view. Bring it back using the Window menu instead of reseting the perspective.


If you find you are using a particular set of views in a perspective you can save that arrangement as your own bespoke perspective so it always resets to have your most used views where you expect them.

4. The Plot -  Basics

When DAWN opens and image it automatically displays a default plot and automatically adjusts the contrast/brightness of the image. The plot can be customized by using the settings action.

Navigating the plot

The above toolbar actions can be used to zoom and pan around the image.

Image tool bar actions

The view menu - Colormaps

There are more options for adjusting the image in the view menu

Trace tool bar actions

5. DExplore

On a basic level DExplore does most of the things the Data Browsing perspective does. Differences include:

 

Exercise 8. Open some of the data files used previously in this tutorial in DExplore. Plot different data sets, in different ways, and do some slicing.


There are some fundamental differences between the way the Data Browsing perspective and DExplore work. As time goes by and you learn to do more advanced things in DAWN the differences become more obvious. For basic data viewing either perspective should work fine.

6. Help and Cheatsheets

Exercise 9. Close DAWN and start it again, do you see the Welcome screen?

Congratulations you have made it to the end of the first tutorial, if you would like to learn more (without jumping ahead to the next tutorial), feel free to browse the help menu contents or look at the cheat sheet sections(Help-> Cheatsheets...) for more training on how to use DAWN.

Also don't miss the DAWN science YouTube Channel for video guides on using DAWN: http://www.youtube.com/user/DAWNScience

7. Feedback (optional)

The help menu in DAWN has a feedback form so you can alert us if DAWN crashes or behaves in an unexpected way.

If you like, send us a feedback (Title the summary DAWN TRAINING), telling us how you found the training worksheets (were they clear? Too much/Too little information?).  Feel free to tell us what kind of data you are interested in (images/traces/both) and what visualization and analysis tool you like/dislike and what you feel is missing.

Test Yourself

  1. Where do you get dawn on (a) A Diamond Linux workstation, (b) A windows PC
  2. What is the icon for the "Show Welcome Screen" toolbar action?
  3. Describe one way of adding a folder to the project explorer.
  4. What is a perspective?
  5. What is the difference between an editor and a view?
  6. What tabs would you find in a nexus editor that you wouldn't find in a dat file editor?
  7. What happens when you make a view a Fast View?
  8. How do you reset a perspective and what does it do?
  9. Name one colormap.
  10. What is the Icon for panning in a plot?
  11. Where can you change the color of a trace?

Appendix I - Refreshing Example Data

If you have no extra data or links to folders in your current example data, delete the folder (and remove project content from disk).