Merge branch 'master_14.3.1' into asm_14.3.1

Former-commit-id: 8245370186 [formerly 6ed90023551e25216c10d05f2568593992326900]
Former-commit-id: a4f68caac6
This commit is contained in:
Brian.Dyke 2014-09-26 13:02:49 -04:00
commit 34a073a848
17 changed files with 198 additions and 91 deletions

View file

@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!--
This_software_was_developed_and_/_or_modified_by_Raytheon_Company,
pursuant_to_Contract_DG133W-05-CQ-1067_with_the_US_Government.
U.S._EXPORT_CONTROLLED_TECHNICAL_DATA
This_software_product_contains_export-restricted_data_whose
export/transfer/disclosure_is_restricted_by_U.S._law._Dissemination
to_non-U.S._persons_whether_in_the_United_States_or_abroad_requires
an_export_license_or_other_authorization.
Contractor_Name:________Raytheon_Company
Contractor_Address:_____6825_Pine_Street,_Suite_340
________________________Mail_Stop_B8
________________________Omaha,_NE_68106
________________________402.291.0100
See_the_AWIPS_II_Master_Rights_File_("Master_Rights_File.pdf")_for
further_licensing_information.
-->
<DerivedParameter abbreviation="GVV1hr" name="Mean 1hr Geometric Vertical Velocity" unit="m/s" />

View file

@ -18,5 +18,8 @@
See_the_AWIPS_II_Master_Rights_File_("Master_Rights_File.pdf")_for
further_licensing_information.
-->
<DerivedParameter unit="" name="Max Lightning Threat (flashes/km^2)" abbreviation="LTNG">
<DerivedParameter unit="" name="Max 1hr Lightning Threat (flashes/km^2)" abbreviation="LTNG">
<Method name="Alias">
<Field abbreviation="LTNG1hr"/>
</Method>
</DerivedParameter>

View file

@ -0,0 +1,26 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!--
This_software_was_developed_and_/_or_modified_by_Raytheon_Company,
pursuant_to_Contract_DG133W-05-CQ-1067_with_the_US_Government.
U.S._EXPORT_CONTROLLED_TECHNICAL_DATA
This_software_product_contains_export-restricted_data_whose
export/transfer/disclosure_is_restricted_by_U.S._law._Dissemination
to_non-U.S._persons_whether_in_the_United_States_or_abroad_requires
an_export_license_or_other_authorization.
Contractor_Name:________Raytheon_Company
Contractor_Address:_____6825_Pine_Street,_Suite_340
________________________Mail_Stop_B8
________________________Omaha,_NE_68106
________________________402.291.0100
See_the_AWIPS_II_Master_Rights_File_("Master_Rights_File.pdf")_for
further_licensing_information.
-->
<DerivedParameter abbreviation="MAXUPHL" name="Max 1hr Updraft Helicity" unit="m^2/s^2" >
<Method name="Alias" >
<Field abbreviation="MXUPHL1hr" />
</Method>
</DerivedParameter>

View file

@ -18,7 +18,7 @@
See_the_AWIPS_II_Master_Rights_File_("Master_Rights_File.pdf")_for
further_licensing_information.
-->
<DerivedParameter abbreviation="MAXDVV" name="Max Downdraft Vertical Velocity" unit="m/s" >
<DerivedParameter abbreviation="MXDVV" name="Max 1hr Downdraft Vertical Velocity" unit="m/s" >
<Method name="Alias">
<Field abbreviation="MAXDVV1hr"/>
</Method>

View file

@ -18,7 +18,7 @@
See_the_AWIPS_II_Master_Rights_File_("Master_Rights_File.pdf")_for
further_licensing_information.
-->
<DerivedParameter abbreviation="MAXUVV" name="Max Updraft Vertical Velocity" unit="m/s" >
<DerivedParameter abbreviation="MXUVV" name="Max 1hr Updraft Vertical Velocity" unit="m/s" >
<Method name="Alias">
<Field abbreviation="MAXUVV1hr"/>
</Method>

View file

@ -106,6 +106,8 @@
indentText="false" />
<contribute xsi:type="menuItem" menuText="Geometric Vert Velocity"
key="GVV" indentText="true" />
<contribute xsi:type="menuItem" menuText="Mean 1hr Geometric Vert Velocity"
key="GVV1hr" indentText="true" />
<contribute xsi:type="menuItem" menuText="Vert Velocity"
key="VV" indentText="true" />
<contribute xsi:type="menuItem" menuText="Wind Gust" key="Gust"
@ -304,9 +306,9 @@
<contribute xsi:type="menuItem" menuText="MSLP Grad Vec"
key="PGrd1" indentText="false" />
<contribute xsi:type="menuItem" menuText="Max Updraft VV"
key="MAXUVV" indentText="true" />
key="MXUVV" indentText="true" />
<contribute xsi:type="menuItem" menuText="Max Downdraft VV"
key="MAXDVV" indentText="true" />
key="MXDVV" indentText="true" />
<contribute xsi:type="menuItem" menuText="Max Updraft Helicity"
key="MAXUPHL" indentText="true" />
<contribute xsi:type="menuItem" menuText="Most Unstable BL Parcel Level"
@ -1392,14 +1394,6 @@
key="VILIQ" indentText="true" />
<contribute xsi:type="menuItem" menuText="Derived Echo Top"
key="RETOP" indentText="true" />
<contribute xsi:type="menuItem" menuText="CAPPI"
key="REFD" indentText="true" />
<contribute xsi:type="menuItem" menuText="MAX 1hr CAPPI"
key="MXREF" indentText="true" />
<contribute xsi:type="menuItem" menuText="Derived VIL"
key="VILIQ" indentText="true" />
<contribute xsi:type="menuItem" menuText="Derived Echo Top"
key="RETOP" indentText="true" />
</contribute>
<!--

View file

@ -1225,6 +1225,8 @@
levelTwoValue="0" />
<DatabaseLevel levelName="BL" levelOneValue="180"
levelTwoValue="0" />
<DatabaseLevel levelName="BL" levelOneValue="255"
levelTwoValue="0" />
<DatabaseLevel levelName="FHAG" levelOneValue="0"
levelTwoValue="30" />
</Level>

View file

@ -78,6 +78,8 @@ import com.vividsolutions.jts.geom.Polygon;
* Aug 28, 2014 ASM #15658 D. Friedman Add marine zones.
* Aug 29, 2014 ASM #15551 Qinglu Lin Sort watches by ETN and filter out ActiveTableRecord
* with act of CAN and EXP in processRecords().
* Sep 12, 2014 ASM #15551 Qinglu Lin Prevent a county's WOU from being used while its
* corresponding WCN is canceled or expired.
*
* </pre>
*
@ -307,6 +309,8 @@ public class WatchUtil {
InstantiationException {
List<ActiveTableRecord> records = new ArrayList<ActiveTableRecord>(
response.getNumResults());
Map<Pair<String, String>, Set<String>> removedUgczones = new HashMap<Pair<String, String>, Set<String>>();
Set<String> ugczones = null;
for (Map<String, Object> result : response.getResults()) {
WarningAction action = WarningAction.valueOf(String.valueOf(result
.get(ACTION)));
@ -316,7 +320,7 @@ public class WatchUtil {
* fixed the underlying system. request.addConstraint("act", new
* RequestConstraint("CAN", ConstraintType.NOT_EQUALS));
*/
if (action != WarningAction.CAN || action != WarningAction.EXP) {
if (action != WarningAction.CAN && action != WarningAction.EXP) {
ActiveTableRecord record = entityClass.newInstance();
record.setIssueTime((Calendar) result.get(ISSUE_TIME_FIELD));
record.setStartTime((Calendar) result.get(START_TIME_FIELD));
@ -327,6 +331,37 @@ public class WatchUtil {
record.setEtn(String.valueOf(result.get(ETN)));
record.setAct(String.valueOf(result.get(ACTION)));
records.add(record);
} else {
Pair<String, String> key = new Pair<String, String>(null, null);
key.setFirst(String.valueOf(result.get(ETN)));
key.setSecond(String.valueOf(result.get(PHEN_SIG_FIELD)));
ugczones = removedUgczones.get(key);
if (ugczones == null) {
ugczones = new HashSet<String>();
}
ugczones.add(String.valueOf(result.get(UGC_ZONE_FIELD)));
removedUgczones.put(key, ugczones);
}
}
// remove ActiveTableRecord from records whose etn, ugcZone, and phensig is same as
// canceled or expired.
String etn, ugczone, phensig;
for (Pair<String, String> etnPhensig: removedUgczones.keySet()) {
ugczones = removedUgczones.get(etnPhensig);
etn = etnPhensig.getFirst();
phensig = etnPhensig.getSecond();
Iterator<String> iter = ugczones.iterator();
while (iter.hasNext()) {
ugczone = iter.next();
Iterator<ActiveTableRecord> iterator = records.iterator();
while (iterator.hasNext()) {
ActiveTableRecord atr = iterator.next();
if (atr.getEtn().equals(etn) && atr.getUgcZone().equals(ugczone) &&
atr.getPhensig().equals(phensig)) {
iterator.remove();
}
}
}
}
@ -361,9 +396,6 @@ public class WatchUtil {
Map<Watch, List<String>> map = new HashMap<Watch, List<String>>();
// For each watch event, get the end time and list of active zones
for (ActiveTableRecord ar : activeTableRecords) {
if (ar.getAct().equals("CAN") || ar.getAct().equals("EXP")) {
continue;
}
/*
* Currently reports all zones in the watch even if a given zone is
* not in the warning polygon. If the logic is changed to only show

View file

@ -217,6 +217,7 @@ import com.vividsolutions.jts.io.WKTReader;
* 07/28/2014 DR 17475 Qinglu Lin Updated populateStrings() and findLargestQuadrant(), removed findLargestGeometry(),
* added createAreaAndCentroidMaps() and movePopulatePt(), updated paintText() to center W.
* 08/20/2014 ASM #16703 D. Friedman Make geo feature types for watches explicit
* 09/10/2014 ASM #16730 D. Friedman Fix NPE.
* 09/14/2014 ASM #641 dhuffman To facilitate Area.java need to filter the differences between Areas and Zones,
* refactored filterCheck and added a new siginature version of filterArea.
* 09/17/2014 ASM #15465 Qinglu Lin get backupOfficeShort and backupOfficeLoc from backup WFO config.xml, and pop up AlertViz if
@ -351,9 +352,11 @@ public class WarngenLayer extends AbstractStormTrackResource {
private Set<String> getAllFipsInArea(Geometry warningArea) {
Set<String> fipsIds = new HashSet<String>();
for (int n = 0; n < warningArea.getNumGeometries(); ++n) {
Geometry area = warningArea.getGeometryN(n);
fipsIds.add(getFips(area));
if (warningArea != null) {
for (int n = 0; n < warningArea.getNumGeometries(); ++n) {
Geometry area = warningArea.getGeometryN(n);
fipsIds.add(getFips(area));
}
}
return fipsIds;
}

View file

@ -878,37 +878,7 @@ public class TemplateRunner {
System.out.println("velocity time: "
+ (System.currentTimeMillis() - tz0));
String watches[] = {"TORNADO WATCH", "SEVERE THUNDERSTORM WATCH"};
int index1 = -1, index2 = -1, index1ToUse = -1;
String doubleDollar = "$$";
boolean firstTime = true;
for (String s: watches) {
index1 = script.indexOf(s, 0);
if (index1 > 0) {
index2 = script.indexOf(doubleDollar, index1);
}
if (firstTime && index1 > -1) {
index1ToUse = index1;
firstTime = false;
}
}
String days[] = {"SUNDAY", "MONDAY", "TUESDAY", "WEDNESDAY", "THURSDAY", "FRIDAY", "SATURDAY"};
String substring = "", text;
if (index1ToUse > -1 && index2 > -1) {
substring = script.substring(index1ToUse, index2).toUpperCase();
// remove day
for (String day: days) {
substring = substring.replaceAll(day + " ", "");
}
// replace 1200 PM/1200 AM with NOON/MIDNIGHT
substring = substring.replaceAll("1200 PM", "NOON");
substring = substring.replaceAll("1200 AM", "MIDNIGHT");
// concatenate strings
text = script.substring(0, index1ToUse - 1);
text = text + " " + substring + script.substring(index2, script.length());
} else {
text = script.toString();
}
String text = script.toString();
WarningTextHandler handler = WarningTextHandlerFactory.getHandler(
selectedAction, text, config.getAutoLockText());
String handledText = handler.handle(text, areas, cancelareas,

View file

@ -37,6 +37,7 @@ import com.raytheon.viz.texteditor.TextWarningConstants;
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* 06182008 bwoodle additional format method overloads, javadocs.
* Sep 12, 2014 ASM RM#15551 Qinglu Lin Added formatUseNoonMidnight().
*
* </pre>
*
@ -45,6 +46,8 @@ import com.raytheon.viz.texteditor.TextWarningConstants;
*/
public class DateUtil {
Pattern timePtrn = Pattern.compile("(1200\\s(AM|PM))");
/**
* Format a date for the severe weather warnings templates
*
@ -107,6 +110,28 @@ public class DateUtil {
return str;
}
public String formatUseNoonMidnight(Date date, DateFormat format, int interval, String tz) {
return formatUseNoonMidnight(date, format, interval, getTimeZoneFromString(tz));
}
public String formatUseNoonMidnight(Date date, DateFormat format, int interval, TimeZone tz) {
String str;
Date workingDate = date;
if (interval > 0) {
workingDate = roundDate(date, interval);
}
synchronized (format) {
format.setTimeZone(tz);
str = format.format(workingDate);
}
Matcher m = timePtrn.matcher(str);
if(m.find()) {
str = str.replace("1200 AM", "MIDNIGHT");
str = str.replace("1200 PM", "NOON");
}
return str;
}
/**
* Format a date for the severe weather warnings templates
*

View file

@ -13,7 +13,7 @@
##### Qinglu Lin 03-17-2014 DR 16309. Updated inserttorwatches and insertsvrwatches.
##### Qinglu Lin 05-21-2014 DR 16309. Updated inserttorwatches and insertsvrwatches by changing 'FOR##' to 'FOR ##'.
##### D. Friedman 08-28-2014 ASM #15658. Add marine watch wording.
##### Qinglu Lin 08-29-2014 ASM #15551. Overhauled inserttorwatches and insertsvrwatches.
##### Qinglu Lin 09-15-2014 ASM #15551. Overhauled inserttorwatches and insertsvrwatches, added until.
####################################################################################################
#*
Mile Marker Test Code
@ -200,25 +200,35 @@ ${drainage.name}##
#end
#end
#set($etns = [])
#set($lastTime = "")
#set($currTime = "")
#set($lastEtn = "")
#set($lastEndTime = "")
#set($count = 0)
#foreach(${watch} in ${tornadoWatches})
#if($lastEtn != "" && ${watch.etn} != ${lastEtn})
#set($success = $etns.add(${watch.etn}))
#end
#foreach(${watch} in ${tornadoWatches})
#set($count = $count + 1)
#if(${lastEtn} != "" && ${watch.etn} != ${lastEtn})
. ##
#end
#set($endTime = ${watch.endTime})
#if(${watch.etn} == ${lastEtn})
#if(${endTime} == ${lastEndTime})
...##
#else
...UNTIL ${dateUtil.format(${endTime}, ${timeFormat.plain}, 15, ${localtimezone})} FOR ##
#end
#else
A TORNADO WATCH${ALSO} REMAINS IN EFFECT UNTIL ${dateUtil.format(${endTime}, ${timeFormat.plain}, 15, ${localtimezone})} FOR ##
#if(${watch.etn} != ${lastEtn})
#set($lastTime = "#until(${endTime}, ${timeFormat}, ${secondtimezone}, ${watch})")
A TORNADO WATCH${ALSO} REMAINS IN EFFECT ${lastTime}##
#set($ALSO = " ALSO")
#else
#if(!$foreach.hasNext() || ${watch.etn} != $etns.get(${count}))
AND ##
#else
...##
#end
#set($currTime = "#until(${endTime}, ${timeFormat}, ${secondtimezone}, ${watch})")
#if(${currTime} != ${lastTime})
${currTime}##
#set($lastTime = ${currTime})
#end
#if(${secondtimezone})
/${dateUtil.format(${watch.getEndTime()}, ${timeFormat.plain}, 15, ${secondtimezone})}/##
#end
#if(!${watch.marineAreas})
#areaFormat(${watch.partOfState} true false true)${watch.state}##
@ -226,7 +236,6 @@ A TORNADO WATCH${ALSO} REMAINS IN EFFECT UNTIL ${dateUtil.format(${endTime}, ${t
#formatMarineAreas(${watch.marineAreas})
#end
#set($lastEtn = ${watch.etn})
#set($lastEndTime = ${watch.endTime})
#end
#if(${lastEtn} != "")
.
@ -234,6 +243,14 @@ A TORNADO WATCH${ALSO} REMAINS IN EFFECT UNTIL ${dateUtil.format(${endTime}, ${t
#end
########END MACRO
#macro(until $endTime $timeFormat $secondtimezone $watch)
UNTIL ${dateUtil.formatUseNoonMidnight(${endTime}, ${timeFormat.clock}, 15, ${localtimezone})}##
#if(${secondtimezone})
/${dateUtil.formatUseNoonMidnight(${watch.getEndTime()}, ${timeFormat.clock}, 15, ${secondtimezone})}/##
#end
FOR ##
#end
#macro(insertsvrwatches $watches $list $secondtimezone $dateUtil $timeFormat)
#set($svrWatches = [])
#set($ALSO = "")
@ -244,25 +261,35 @@ A TORNADO WATCH${ALSO} REMAINS IN EFFECT UNTIL ${dateUtil.format(${endTime}, ${t
#end
#end
#set($etns = [])
#set($lastTime = "")
#set($currTime = "")
#set($lastEtn = "")
#set($lastEndTime = "")
#set($count = 0)
#foreach(${watch} in ${svrWatches})
#if($lastEtn != "" && ${watch.etn} != ${lastEtn})
#set($success = $etns.add(${watch.etn}))
#end
#foreach(${watch} in ${svrWatches})
#set($count = $count + 1)
#if(${lastEtn} != "" && ${watch.etn} != ${lastEtn})
. ##
#end
#set($endTime = ${watch.endTime})
#if(${watch.etn} == ${lastEtn})
#if(${endTime} == ${lastEndTime})
...##
#else
...UNTIL ${dateUtil.format(${endTime}, ${timeFormat.plain}, 15, ${localtimezone})} FOR ##
#end
#else
A SEVERE THUNDERSTORM WATCH${ALSO} REMAINS IN EFFECT UNTIL ${dateUtil.format(${endTime}, ${timeFormat.plain}, 15, ${localtimezone})} FOR ##
#if(${watch.etn} != ${lastEtn})
#set($lastTime = "#until(${endTime}, ${timeFormat}, ${secondtimezone}, ${watch})")
A SEVERE THUNDERSTORM WATCH${ALSO} REMAINS IN EFFECT ${lastTime}##
#set($ALSO = " ALSO")
#else
#if(!$foreach.hasNext() || ${watch.etn} != $etns.get(${count}))
AND ##
#else
...##
#end
#set($currTime = "#until(${endTime}, ${timeFormat}, ${secondtimezone}, ${watch})")
#if(${currTime} != ${lastTime})
${currTime}##
#set($lastTime = ${currTime})
#end
#if(${secondtimezone})
/${dateUtil.format(${watch.getEndTime()}, ${timeFormat.plain}, 15, ${secondtimezone})}/##
#end
#if(!${watch.marineAreas})
#areaFormat(${watch.partOfState} true false true)${watch.state}##
@ -270,7 +297,6 @@ A SEVERE THUNDERSTORM WATCH${ALSO} REMAINS IN EFFECT UNTIL ${dateUtil.format(${e
#formatMarineAreas(${watch.marineAreas})
#end
#set($lastEtn = ${watch.etn})
#set($lastEndTime = ${watch.endTime})
#end
#if(${lastEtn} != "")
.

View file

@ -49,9 +49,6 @@
<ConstantField value="-1e35"/>
<ConstantField value="-1"/>
</Method>
<Method models="HRRR" name="Alias" levels="Skin" >
<Field level="Surface" abbreviation="T"/>
</Method>
<Method models="SREF212" name="Alias">
<Field abbreviation="Tmean"/>
</Method>

View file

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<AttributeSetGroup xmlns:ns2="http://www.example.org/productType">
<resource>HRRR</resource>
<attrSetGroupName>standard</attrSetGroupName>
<attrSetNames>1000-500_thkn,1000-850_thkn,1000mb_hght_tmp_wind,500mb_hght_wind,500mb_hght_tmp_wind,700mb_hght_tmp_wind,850mb_hght_tmp_wind</attrSetNames>
</AttributeSetGroup>

View file

@ -1455,4 +1455,7 @@
<ResourceDefinitionFilter isEnabled="true" rscDefnName="GEOMAG">
<filters>Forecast,SWPC</filters>
</ResourceDefinitionFilter>
<ResourceDefinitionFilter isEnabled="true" rscDefnName="HRRR">
<filters>Forecast,SBN</filters>
</ResourceDefinitionFilter>
</ResourceDefinitionFilters>

View file

@ -1,4 +1,4 @@
%define _ldm_version 6.11.5
%define _ldm_version 6.12.6
%define _ldm_src_tar ldm-%{_ldm_version}.tar.gz
# ldm-%{_ldm_version}.tar.gz is tarred up ldm-%{_ldm_version}/src dir after
# ISG makes retrans changes
@ -162,10 +162,12 @@ _myHost=`hostname`
_myHost=`echo ${_myHost} | cut -f1 -d'-'`
pushd . > /dev/null 2>&1
cd ${_ldm_dir}/SOURCES
cp ${_ldm_dir}/SOURCES/%{_ldm_src_tar} ${_ldm_dir}
# unpack the ldm source
/bin/tar -xf %{_ldm_src_tar} \
-C ${_ldm_dir}
#/bin/tar -xf %{_ldm_src_tar} \
# -C ${_ldm_dir}
cd ${_ldm_dir}
gunzip -c %{_ldm_src_tar} | pax -r '-s:/:/src/:'
if [ $? -ne 0 ]; then
exit 1
fi
@ -174,6 +176,7 @@ if [ $? -ne 0 ]; then
exit 1
fi
chown -R ldm:fxalpha ${_ldm_dir}
popd . > /dev/null 2>&1
# create .bash_profile
if [ ! -f /usr/local/ldm/.bash_profile ]; then
@ -194,7 +197,7 @@ if [ $? -ne 0 ]; then
exit 1
fi
export _current_dir=`pwd`
su ldm -lc "cd ${_current_dir}; ./configure --disable-max-size --with-noaaport --disable-root-actions --prefix=${_ldm_root_dir} CFLAGS='-g -O0'" \
su ldm -lc "cd ${_current_dir}; ./configure --disable-max-size --with-noaaport --with-retrans --disable-root-actions --prefix=${_ldm_root_dir} CFLAGS='-g -O0'" \
> configure.log 2>&1
if [ $? -ne 0 ]; then
echo "FATAL: ldm configure has failed!"
@ -209,11 +212,6 @@ if [ $? -ne 0 ]; then
exit 1
fi
su ldm -lc "cd ${_current_dir}; /bin/bash my-install" > my-install.log 2>&1
if [ $? -ne 0 ]; then
echo "FATAL: my-install has failed!"
exit 1
fi
popd > /dev/null 2>&1
pushd . > /dev/null 2>&1
cd ${_ldm_root_dir}/src

Binary file not shown.