Focal Point Basics Jobsheets

Completely Removing an Existing Hazard Type

Purpose:

This jobsheet will show you how to use "_override_remove_" to completely remove FF.W.BurnScar from the drop down menu in the HID.

Tasks:

 

  1. Create a hazard and view the options in the "type" menu in the HID. Notice that FF.W.BurnScar is an option. 
  2. Open the localization and find the HazardCategories.py file, in the Hazard Categories folder of Hazard Services. Create a user override of this file.
  3. We need to remove FF.W.BurnScar from the hydrology category. Copy and paste the following lines into your user override file: 
    from collections import OrderedDict
     
    HazardCategories = OrderedDict(
        {
        "Hydrology": ["_override_remove_", ("FF", "W", "BurnScar")]    
         }
         
        )
    
    1. Note: Be sure to include the import line in your override file!
  4. Save the file and return back to your Hydro or D2D perspective to view the HID again. You will need to close the HID if still open, and open it again. 
  5. Notice now that the drop down menu for Type no longer includes FF.W.BurnScar
    1. There is a caveat with removing hazard types that you must also be aware of. The override above just removed the option from the HID, but you must override the HazardTypes.py file to remove FF.W.BurnScar in any place it appears as a "replace by" option. This is what allows one hazard type to transition to the next. Without changing this, if you try to select another hazard when transitioning an existing hazard, it will fail to populate the "Type" pull down menu and give an error. 
  6. In the localization, find the file called HazardTypes.py in the Hazard Types folder of Hazard Services. Create a user override for this file. 
  7. In the Base version of this file, use the find feature ("ctrl+f") to search for any place where "FF.W.BurnScar" appears. You should find it as a "replacedBy" option for four other hazard types. 
  8. For each of the hazard types where FF.W.BurnScar exists, you will need a line in the override file. Below are the lines you should copy and paste into the user override of HazardTypes.py: 
    HazardTypes = {
        'FF.W.Convective' : {'replacedBy': ["_override_remove_list_", 'FF.W.BurnScar']},
        'FF.W.NonConvective' : {'replacedBy': ["_override_remove_list_", 'FF.W.BurnScar']},
        'FA.W' : {'replacedBy': ["_override_remove_list_", 'FF.W.BurnScar']},
        'FA.Y' : {'replacedBy': ["_override_remove_list_", 'FF.W.BurnScar']},
        }
    
    1. Note: You can also use "_override_remove_" instead of "_override_remove_list_" here since we are only removing a single item. "_override_remove_list_" allows you to include multiple items to remove, if desired or necessary. 

 

As a final note, you may want to remove the option for "Burn Scar Flood" from the recommenders list in the console. To do this: 

  1. Click on the "Setup" icon on the Hazard Services Console. 
  2. Click Manage Settings --> Edit/Filter
  3. On the Edit Setting GUI, choose the Recommenders tab. 
  4. Click on the BurnScarFlood option in the Visible Recommenders list, then click the left-pointing arrow to move it to the Available Recommenders list.
  5. Save your changes. 
  6. Repeat for any other settings types (e.g. Hydrology All, Hydrology NonRiver, etc.) 

 

 

That's it! 

 

 

For more information on removing hazard types, see section 3.0.3.2 of the Focal Point Guide