Focal Point Winter Weather Jobsheets

Set Grids to Use

Purpose:

This jobsheet demonstrates how to enable or disable special weather element grids (using sleetAmt as the example) which are used for your WSW product generation.

Tasks:

AT-A-GLANCE:

  • What? Change the true or false value returned by the useSleetAmtGrid method (or similar use-grid methods), in an override of LocalVariables.py
  • Simple and Immediate. Logic which reads the state of these booleans is already incorporated into code for triggering the associated behavior (e.g. sampling of alternate grids), and requires no additional configuration.

Follow the steps below for more detailed guidance.

*** OTHER CONFIGURATIONS WITH IDENTICAL WORKFLOW *** The methodology in this jobsheet can be applied to any setting in LocalVariables.py which has a true or false value (e.g. toggles for other weather element grids, etc.).

 

  1. [OPTIONAL] Create a hazard for your area to check the grids used for sampling (real or test grid data will be necessary)
    1. Launch Hazard Services in your desired perspective (e.g. GFE) with the Winter Setting file
    2. Draw a hazard in your area, overlapping an area with non-zero SleetAmt grid (or other element related to the options you're configuring)
    3. Select a category (e.g. Winter) and hazard (e.g. WS.W) depending on the weather element you're sampling
    4. Leave the checkbox for "Automatically Generated Impacts" selected, then click "Preview" to generate a product
    5. Review the "What" bullet for information about accumulations (and possibly the impacts bullet as well)
      1. For this SleetAmt exercise, the baseline behavior should show sleet accumulations in the "What" bullet, as well as a "Travel could be very difficult" impact statement (if the amount is >2 inches)
  2. Switch to the Localization Perspective by clicking on the "Open Perspective" icon at the top-right of your CAVE window, and choosing "Localization"
  3. In the Localization Perspective, navigate to the Utilities sub-directory under the Hazard Services folder.
  4. Double click on LocalVariables.py to show the available versions
  5. Create a user override version if none exists (user override is best practice for testing changes):
    1. If there is only a BASE version: right click on BASE and select Create Override File, then select User
    2. If there is another version (e.g. SITE) you wish to use: right click on that file and select Copy To, then select User (this lets you work on an updated SITE version to replace the original when you're finished)
  6. Double click on the USER version of LocalVariables.py to open it for editing
  7. Open a reference copy of the existing LocalVariables.py file, which will be used for comparing to and copying existing code for overrides.
    1. It's typically best to open the BASE version because most methods have not already been overridden in a higher-level override
  8. In the reference file you opened, scroll or search to find the "useSleetAmtGrid" method (whose first line appears as "def useSleetAmtGrid(self):" in LocalVariables.py)
  9. Once found, select the entire useSleetAmtGrid method by clicking and dragging from (and including) the "def useSleetAmtGrid(self):" line which begins the function, all the way to (and including) the last line of the function which has the "return False" statement.​​​​​​​
    1. These methods are very small so you will only be copying a few lines
  10. Copy the selected contents by right-clicking and selecting "Copy" from the pop-up menu, or by hitting CTRL-C on your keyboard
  11. Switch back to the USER override you were working on
  12. Paste the useSleetAmtGrid method into your USER override on a blank line after the "class..." and "pass" lines (or after any pre-existing override methods in the file), by right-clicking and selecting "Paste" from the pop-up menu, or by hitting CTRL-V on your keyboard
  13. In the USER copy of the useSleetAmtGrid method you just pasted in, change the return value to True enable the use of the SleetAmt grid when generating product text, as seen below (changes in bold):
    def useSleetAmtGrid(self):
        # Read the SleetAmt grid when generating the product text
        return True # <--CHANGE
    
  14. Make sure you've maintained proper indentation... the "def sleetAmtGrid" line should be indented one level more than the "class LocalVariables" line. If you need to fix your indentation, you can select the whole method, then press TAB to indent everything further, or SHIFT-TAB to remove one level of indentation for the entire selection
  15. When finished, save the file by hitting Ctrl+S, or selecting Save from the File menu
    1. If a "File Version Conflict" is encountered, click OK to accept merge
    2. In the two-panel "Merge" tab that opens, make no changes, once again save the file by hitting Ctrl+s, then close the "Merge" tab
    3. When a "File Changed" message appears,  click Yes.
    4. This behavior will only be encountered each time a new override file that did not exist before is created and saved​​​​​​​
  16. [OPTIONAL, RECOMMENDED] Verify the change of your grid configurations​​​​​​​ by generating a product and reviewing
    1. Switch back to GFE and refresh the preview on your initial test hazard, or generate a new one overlapping a non-zero SleetAmt grid (or suitable element for the grid you've just configured)
    2. ​​​​​​​Verify that the "What" bullet does NOT contain sleet accumulations (if you've switched usSleetAmtGrid to return false as this jobsheet demonstrates). ​​​​​​​​​​​​
  17. Task Complete!