Examples of GridDataset


Examples of ucar.nc2.dt.GridDataset

  }

  public void testNcmlGrid() throws IOException {
    String filename = "file:"+TestAll.cdmUnitTestDir + "formats/gini/aggDateFormat.ncml";

    GridDataset gds = ucar.nc2.dt.grid.GridDataset.open( filename);
    System.out.println(" TestNcmlAggDirDateFormat.openGrid "+ filename);

    NetcdfFile ncfile = gds.getNetcdfFile();
    testDimensions( ncfile);
    testAggCoordVar( ncfile);
    testReadData( gds);

    gds.close();
  }
View Full Code Here

Examples of ucar.nc2.dt.GridDataset

      if (debugEnhance) System.out.printf("proto.enhance() parseInfo = %s%n", builder.getParseInfo());

      // turn it into a GridDataset, so we can add standard metadata to result, not dependent on CoordSysBuilder
      // also see  ucar.nc2.dt.grid.NetcdfCFWriter - common code could be extracted
      Formatter parseInfo = new Formatter();
      GridDataset gds = new ucar.nc2.dt.grid.GridDataset(result, parseInfo); // LOOK not sure coord axes will read ??
      if (debugEnhance) System.out.printf("proto GridDataset parseInfo = %s%n", parseInfo);

      // now make standard CF metadata for gridded data
      for (GridDatatype grid : gds.getGrids()) {
        Variable newV = result.findVariable(grid.getFullName());
        if (newV == null) {
          logger.warn("FmrcDataset cant find "+grid.getFullName()+" in proto gds ");
          continue;
        }
View Full Code Here

Examples of ucar.nc2.dt.GridDataset

    //CoordSysBuilderIF builder = result.enhance();
    //if (debugEnhance) System.out.printf("parseInfo = %s%n", builder.getParseInfo());

    // LOOK better not to do this when you only want the NetcdfDataset
    Formatter parseInfo = new Formatter();
    GridDataset gds = new ucar.nc2.dt.grid.GridDataset(result, parseInfo);
    if (debugEnhance) System.out.printf("GridDataset2D parseInfo = %s%n", parseInfo);
    return gds;
  }
View Full Code Here

Examples of ucar.nc2.dt.GridDataset

              .append(topDirectory.endsWith("/") ? "" : "/")
              .append(name).toString();
      return NetcdfDataset.acquireDataset(null, filename, null, -1, null, null); // no enhancement
    }

    GridDataset gds = getGridDataset(matchPath);
    return (gds == null) ? null : (NetcdfDataset) gds.getNetcdfFile();
  }
View Full Code Here

Examples of ucar.nc2.dt.GridDataset

    String url = "C:/data/NAM_CONUS_12km_20060227_1200.grib2";

    // String url = "http://motherlode.ucar.edu:8080/thredds/dodsC/fmrc/NCEP/NDFD/CONUS_5km/NDFD-CONUS_5km_best.ncd";

    GridDataset ncd = ucar.nc2.dt.grid.GridDataset.open(url);
    GridDatasetInfo info = new GridDatasetInfo(ncd, null);
    FileOutputStream fos2 = new FileOutputStream("C:/TEMP/gridInfo.xml");
    info.writeXML(info.makeGridForm(), fos2);
    fos2.close();
View Full Code Here

Examples of ucar.nc2.dt.GridDataset

      // copy on write
      State localState = new State(state);

      if (checkProto) {
         // add Variables, GeospatialCoverage, TimeCoverage
        GridDataset gds = fmrc.getDataset2D(null);
        if (null != gds) {
          localState.vars = MetadataExtractor.extractVariables(this, gds);
          localState.gc = MetadataExtractor.extractGeospatial(gds);
          localState.dateRange = MetadataExtractor.extractDateRange(gds);
        }
View Full Code Here

Examples of ucar.nc2.dt.GridDataset

  }

  // LOOK : all of these guys could use ehcache
  public GridDataset getDataset2D(NetcdfDataset result) throws IOException {
    checkNeeded( false);
    GridDataset gds = fmrcDataset.getNetcdfDataset2D(result);
    return gds;
  }
View Full Code Here

Examples of ucar.nc2.dt.GridDataset

    return gds;
  }

  public GridDataset getDatasetBest() throws IOException {
    checkNeeded( false);
    GridDataset gds =  fmrcDataset.getBest();
    return gds;
  }
View Full Code Here

Examples of ucar.nc2.dt.GridDataset

    return gds;
  }

  public GridDataset getDatasetBest(FeatureCollectionConfig.BestDataset bd) throws IOException {
    checkNeeded( false);
    GridDataset gds =  fmrcDataset.getBest(bd);
    return gds;
  }
View Full Code Here

Examples of ucar.nc2.dt.GridDataset

    return gds;
  }

  public GridDataset getRunTimeDataset(Date run) throws IOException {
    checkNeeded( false);
    GridDataset gds =  fmrcDataset.getRunTimeDataset(run);
    return gds;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.