diff --git a/cave/com.raytheon.uf.viz.collaboration.pointdata/com.raytheon.uf.viz.collaboration.pointdata.ecl b/cave/com.raytheon.uf.viz.collaboration.pointdata/com.raytheon.uf.viz.collaboration.pointdata.ecl new file mode 100644 index 0000000000..e69de29bb2 diff --git a/cave/com.raytheon.uf.viz.collaboration.product.feature/com.raytheon.uf.viz.collaboration.product.feature.ecl b/cave/com.raytheon.uf.viz.collaboration.product.feature/com.raytheon.uf.viz.collaboration.product.feature.ecl new file mode 100644 index 0000000000..e69de29bb2 diff --git a/cave/com.raytheon.uf.viz.monitor.fog/src/com/raytheon/uf/viz/monitor/fog/ui/dialogs/FogZoneTableDlg.java b/cave/com.raytheon.uf.viz.monitor.fog/src/com/raytheon/uf/viz/monitor/fog/ui/dialogs/FogZoneTableDlg.java index f42616efab..492e9319a9 100644 --- a/cave/com.raytheon.uf.viz.monitor.fog/src/com/raytheon/uf/viz/monitor/fog/ui/dialogs/FogZoneTableDlg.java +++ b/cave/com.raytheon.uf.viz.monitor.fog/src/com/raytheon/uf/viz/monitor/fog/ui/dialogs/FogZoneTableDlg.java @@ -46,7 +46,6 @@ import com.raytheon.uf.viz.monitor.ui.dialogs.ZoneTableDlg; * * Jan 25, 2010 #4281 zhao Modified the notify method * Jun 16, 2012 14386 zhao Modified the notify method - * Dec 03, 2012 15216/15639 zhao fixed a bug related to Link-to-Frame * * @author * @@ -79,6 +78,7 @@ public class FogZoneTableDlg extends ZoneTableDlg { if (zoneTable.isDisposed()) { return; } + // TODO: Silver Springs Guys. We now have competing ways of adding the // data to the table. // You need to merge the two. The way we had setup originally was to use @@ -86,6 +86,7 @@ public class FogZoneTableDlg extends ZoneTableDlg { // You guys have this ObMultiHrsReports. Find a way that will // incorporate both for the obs and // The algorithm output. + if (me.getSource() instanceof FogMonitor) { FogMonitor fog = (FogMonitor) me.getSource(); @@ -93,11 +94,12 @@ public class FogZoneTableDlg extends ZoneTableDlg { if (date != null) { Date nominalTime = date; ObMultiHrsReports obData = fog.getObData(); - if (!isLinkedToFrame()) { - nominalTime = obData.getLatestNominalTime(); - } +// if (!isLinkedToFrame()) { +// nominalTime = obData.getLatestNominalTime(); +// } FogDataGenerator fdg = new FogDataGenerator(); - HashMap fogAlgCellType = fdg.getAlgCellTypes(fog.getAlgorithmData(nominalTime)); + HashMap fogAlgCellType = fdg + .getAlgCellTypes(fog.getAlgorithmData(nominalTime)); obData.setFogAlgCellType(fogAlgCellType); this.updateTableDlg(obData.getObHourReports(nominalTime)); } diff --git a/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/dialogs/ProductScriptsDialog.java b/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/dialogs/ProductScriptsDialog.java index 92ac6936e9..1470da1644 100644 --- a/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/dialogs/ProductScriptsDialog.java +++ b/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/dialogs/ProductScriptsDialog.java @@ -1,19 +1,19 @@ /** * 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. **/ @@ -45,7 +45,6 @@ import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.SimulatedTime; -import com.raytheon.uf.common.time.TimeRange; import com.raytheon.uf.viz.core.VizApp; import com.raytheon.viz.gfe.Activator; import com.raytheon.viz.gfe.core.DataManager; @@ -58,7 +57,7 @@ import com.raytheon.viz.ui.widgets.ToggleSelectList; /** * The product generation scripts dialog. - * + * *
  * SOFTWARE HISTORY
  * Date         Ticket#    Engineer    Description
@@ -66,11 +65,9 @@ import com.raytheon.viz.ui.widgets.ToggleSelectList;
  * 	Mar 7, 2008			   Eric Babin   Initial Creation
  * Oct 27, 2012 1287       rferrel     Code cleanup for non-blocking dialog.
  * Oct 25, 2012 1287       rferrel     Code changes for non-blocking PublishDialog.
- * Nov 30, 2012 15575      ryu         Added variable replacement for SelectedStart, 
- *                                     SelectedEnd, and home
- *
+ * 
  * 
- * + * * @author ebabin * @version 1.0 */ @@ -87,8 +84,6 @@ public class ProductScriptsDialog extends CaveJFACEDialog { private Map scriptDict; - private String gfeHome; - private String prddir; private ToggleSelectList scriptsList; @@ -108,8 +103,6 @@ public class ProductScriptsDialog extends CaveJFACEDialog { this.setShellStyle(SWT.DIALOG_TRIM | SWT.MODELESS); this.dataManager = dataManager; - gfeHome = Activator.getDefault().getPreferenceStore() - .getString("GFESUITE_HOME"); prddir = Activator.getDefault().getPreferenceStore() .getString("GFESUITE_PRDDIR"); scripts = Activator.getDefault().getPreferenceStore() @@ -145,7 +138,7 @@ public class ProductScriptsDialog extends CaveJFACEDialog { } /** - * + * */ private void runScripts() { int[] idxs = scriptsList.getSelectionIndices(); @@ -177,15 +170,6 @@ public class ProductScriptsDialog extends CaveJFACEDialog { .getSpatialEditorTime(); Date seEnd = new Date(seStart.getTime() + 60 * 1000); - Date selStart = new Date(0); - Date selEnd = new Date(0); - TimeRange selectedTR = dataManager.getParmOp() - .getSelectionTimeRange(); - if (selectedTR != null) { - selStart = selectedTR.getStart(); - selEnd = selectedTR.getEnd(); - } - // The following variables are replaced by known values: cmd = cmd.replace("{host}", hostParts[0]); cmd = cmd.replace("{port}", hostParts[1]); @@ -193,13 +177,8 @@ public class ProductScriptsDialog extends CaveJFACEDialog { cmd = cmd.replace("{productDB}", productDB.toString()); cmd = cmd.replace("{SEstart}", gmtTime.format(seStart)); cmd = cmd.replace("{SEend}", gmtTime.format(seEnd)); - cmd = cmd.replace("{SelectedStart}", - gmtTime.format(selStart)); - cmd = cmd.replace("{SelectedEnd}", - gmtTime.format(selEnd)); cmd = cmd.replace("{time}", curLocalTime); cmd = cmd.replace("{ztime}", curGMTTime); - cmd = cmd.replace("{home}", gfeHome); cmd = cmd.replace("{prddir}", prddir); // The user is prompted to enter the value with which to replace @@ -418,7 +397,7 @@ public class ProductScriptsDialog extends CaveJFACEDialog { /* * (non-Javadoc) - * + * * @see * org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets * .Shell) diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/spatial/GribSpatialCache.java b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/spatial/GribSpatialCache.java index 6323061aa9..2b7bb6d8e0 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/spatial/GribSpatialCache.java +++ b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/spatial/GribSpatialCache.java @@ -76,7 +76,6 @@ import com.vividsolutions.jts.geom.Coordinate; * ------------ ---------- ----------- -------------------------- * 4/7/09 1994 bphillip Initial Creation * Jul 25, 2012 977 rjpeter Add ability for sub grids to have a defined center point. - * 12/04/2012 DR 15382 D. Friedman Restrict subgrid coordinates to reference grid bounds. * * * @author bphillip @@ -543,10 +542,6 @@ public class GribSpatialCache { Coordinate upperRightPosition = new Coordinate( xCenterPoint + xDistance, yCenterPoint - yDistance); - lowerLeftPosition.x = Math.min(Math.max(0, lowerLeftPosition.x), gridCoverage.getNx() - 1); - lowerLeftPosition.y = Math.min(Math.max(0, lowerLeftPosition.y), gridCoverage.getNy() - 1); - upperRightPosition.x = Math.min(Math.max(0, upperRightPosition.x), gridCoverage.getNx() - 1); - upperRightPosition.y = Math.min(Math.max(0, upperRightPosition.y), gridCoverage.getNy() - 1); lowerLeftPosition = MapUtil.gridCoordinateToLatLon( lowerLeftPosition, PixelOrientation.CENTER, diff --git a/edexOsgi/com.raytheon.uf.common.parameter/build.properties b/edexOsgi/com.raytheon.uf.common.parameter/build.properties new file mode 100644 index 0000000000..34d2e4d2da --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.parameter/build.properties @@ -0,0 +1,4 @@ +source.. = src/ +output.. = bin/ +bin.includes = META-INF/,\ + . diff --git a/edexOsgi/com.raytheon.uf.common.spatial/build.properties b/edexOsgi/com.raytheon.uf.common.spatial/build.properties new file mode 100644 index 0000000000..34d2e4d2da --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.spatial/build.properties @@ -0,0 +1,4 @@ +source.. = src/ +output.. = bin/ +bin.includes = META-INF/,\ + . diff --git a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java index cd5cc61fa4..734e89484c 100644 --- a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java +++ b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java @@ -24,22 +24,10 @@ import java.util.ArrayList; import java.util.Calendar; import java.util.Date; import java.util.HashMap; -import java.util.Iterator; import java.util.LinkedHashMap; import java.util.Map.Entry; -import java.util.TreeSet; - -import org.geotools.coverage.grid.GridGeometry2D; -import org.geotools.geometry.DirectPosition2D; -import org.opengis.referencing.crs.CoordinateReferenceSystem; -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; import com.raytheon.uf.common.dataplugin.grib.GribRecord; -import com.raytheon.uf.common.datastorage.records.FloatDataRecord; -import com.raytheon.uf.common.geospatial.ISpatialObject; -import com.raytheon.uf.common.geospatial.MapUtil; -import com.raytheon.uf.common.geospatial.PointUtil; import com.raytheon.uf.common.monitor.xml.SCANModelParameterXML; import com.vividsolutions.jts.geom.Coordinate; @@ -84,9 +72,9 @@ public class FreezingLevel { // reference time Calendar refTime = null; - private transient final Log logger = LogFactory.getLog(getClass()); - + public FreezingLevel(String modelName) { + this.modelName = modelName; times = new HashMap(); zeroCount = 0; @@ -108,79 +96,6 @@ public class FreezingLevel { } } - /** - * find (x,y) coordinate for lat,lon(coor) - * @param coors - */ - public DirectPosition2D findXYloc(Coordinate coor, String type){ - ScanDataCache cache = ScanDataCache.getInstance(); - - ISpatialObject iso = cache.getModelData().getGribRecord(modelName, type).getSpatialObject(); - CoordinateReferenceSystem crs=iso.getCrs(); - GridGeometry2D mapGeometry = MapUtil.getGridGeometry(iso); - DirectPosition2D resultPoint; - try { - resultPoint = PointUtil.determineExactIndex( - coor, crs, mapGeometry); - System.out.println("Freezing level -- lat,lon:"+coor+" = "+resultPoint); - return resultPoint; - } catch (Exception e) { - System.out.println("Error: Freezing level -- unable to find x,y coordinate for lat,lon:"+coor); - e.printStackTrace(); - } - return null; - } - - /** - * get the bi-linear interpolation value amount the nearest 4 points - * - * @param modelName, prodType, coor - * @return bi-linear interpolation amount the nearest 4 points - * @throws VizException - */ - public double getValue(String modelName, String prodType, Coordinate coor) { - double value = -99999.0; - try { - //xyLoc is the location in x,y - DirectPosition2D xyLoc = findXYloc(coor, prodType); - - //data from hdf5 - ScanDataCache cache = ScanDataCache.getInstance(); - GribRecord gribRec = cache.getModelData().getGribRecord(modelName, prodType); - FloatDataRecord rec = (FloatDataRecord) gribRec.getMessageData(); - - //dimension of the record from hdf5, recNx =151 and recNy=113 during development - int recNx = gribRec.getSpatialObject().getNx(); - int recNy = gribRec.getSpatialObject().getNy(); - - //get four nearest points/values form the record around xyLoc - int x0=(int)(xyLoc.x); - int x1=x0+1; - int y0=(int)(xyLoc.y); - int y1=y0+1; - - double p1=xyLoc.x-x0; - double p2=1-p1; - double p3=xyLoc.y-y0; - double p4=1-p3; - - double value2 = rec.getFloatData()[(recNx * y0) + x0]; - double value3 = rec.getFloatData()[(recNx * y0) + x1]; - double value0 = rec.getFloatData()[(recNx * y1) + x0]; - double value1 = rec.getFloatData()[(recNx * y1) + x1]; - - //do a bi-linear interpolation amount the nearest 4 points - value = (p1*p4*value1)+(p2*p4*value0)+(p1*p3*value3)+(p2*p3*value2); - logger.info("bi-linear interpolation value: "+value+" "+value0+" "+value1+ - " "+value2+" "+value3+" for coor:"+coor+" "+recNx+","+recNy); - } catch (Exception e) { - logger.error("No Grib value available....." + modelName + " " - + prodType+" lat,lon:"+coor); - e.printStackTrace(); - } - return value; - } - /** * Give me the freezing level for an array of points * @@ -192,7 +107,6 @@ public class FreezingLevel { HashMap freezingMap = new HashMap(); ScanDataCache cache = ScanDataCache.getInstance(); - //get data from hdf5 files for (Coordinate coor : coors) { HashMap ghValues = new HashMap(); @@ -200,46 +114,34 @@ public class FreezingLevel { for (Entry entry : getGHLevelMap().entrySet()) { if (cache.getModelData().isType(modelName, entry.getKey())) { - ghValues.put(entry.getValue(), getValue(modelName, entry.getKey(), coor)); - } else { - ghValues.put(entry.getValue(),null); + + ghValues.put(entry.getValue(), cache.getModelData() + .getValue(modelName, entry.getKey(), coor)); } } for (Entry entry : getTLevelMap().entrySet()) { if (cache.getModelData().isType(modelName, entry.getKey())) { - tValues.put(entry.getValue(), getValue(modelName, entry.getKey(), coor)); + tValues.put(entry.getValue(), cache.getModelData() + .getValue(modelName, entry.getKey(), coor)); } } - - //here's the calculation - Double fLevel = 0.0; + + Double fLevel = -99999.0; Integer jtopLevel = null; Integer ktopLevel = null; - int foundValFlag=-1;//-1=all ghValue and tValue are null, - //0=all ghValue<=-9000 and tValue<=273.16, 1=found a fLevel System.out .println("********** Starting Freezing Level Calculations *****************"); - - TreeSet ts= new TreeSet(ghValues.keySet());//want an asc sorted list - Iterator it = ts.iterator(); - - //for (Integer level : ghValues.keySet()) { - while (it.hasNext()) { - Integer level = (Integer) it.next(); + for (Integer level : ghValues.keySet()) { Double tValue = tValues.get(level); Double ghValue = ghValues.get(level); System.out.println("GH Value: " + ghValue + " TValue: " + tValue); - if (ghValue != null && tValue != null && foundValFlag ==-1){ - foundValFlag=0; - } - - if (ghValue != null && ghValue.doubleValue() > -9000) { - if (tValue != null && tValue.doubleValue() > 273.16) { + if (ghValue != null && ghValue > -9000) { + if (tValue != null && tValue > 273.16) { fLevel = (ghValues.get(ktopLevel) - ((ghValues .get(ktopLevel) - ghValue) * ((273.16 - tValues @@ -253,7 +155,6 @@ public class FreezingLevel { + " - " + tValues.get(jtopLevel) + ")))) * .00328"); System.out.println("*** FreezingLevel = " + fLevel); - foundValFlag=1; freezingMap.put(coor, fLevel.floatValue()); break; } else { @@ -262,12 +163,6 @@ public class FreezingLevel { } } } - - if (foundValFlag==0) {//this means all tValue are <= 273.16 - freezingMap.put(coor, 0.0f); - System.out.println("*** FreezingLevel = 0.0"); - } - System.out .println("********** Finished Freezing Level Calculations *****************"); } @@ -357,7 +252,6 @@ public class FreezingLevel { paramXML.setModelName(model); paramXML.setParameterName(param); String sql = getSQL(interval, model, param, refTime); - System.out.println("Freezing level sql="+sql); GribRecord modelRec = DATUtils.getMostRecentGribRecord(interval, sql, paramXML); @@ -467,8 +361,8 @@ public class FreezingLevel { + level + "\'" + " limit 1)) and reftime='" - + refTimeStr + "' and forecasttime=0" - + " order by reftime desc, forecasttime desc limit 1"; + + refTimeStr + + "' order by reftime desc, forecasttime desc limit 1"; return sql; } } diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.convsigmet/utility/edex_static/base/purge/convsigmetPurgeRules.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.convsigmet/utility/edex_static/base/purge/convsigmetPurgeRules.xml new file mode 100644 index 0000000000..607053c111 --- /dev/null +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.convsigmet/utility/edex_static/base/purge/convsigmetPurgeRules.xml @@ -0,0 +1,10 @@ + + + + + convsigmet + default + + 02-00:00:00 + + \ No newline at end of file