Gianpaolo Coro 2014-02-24 11:54:07 +00:00
parent f4ea6d905b
commit 6cc3f351f2
9 changed files with 23 additions and 23 deletions

View File

@ -2,7 +2,7 @@ package org.gcube.dataanalysis.geo.test;
import org.gcube.contentmanagement.lexicalmatcher.utils.AnalysisLogger;
import org.gcube.dataanalysis.ecoengine.configuration.AlgorithmConfiguration;
import org.gcube.dataanalysis.geo.retrieval.GeoIntersector;
import org.gcube.dataanalysis.geo.matrixmodel.MatrixExtractor;
public class TestChunkization {
@ -13,10 +13,10 @@ public class TestChunkization {
// String layertitle = "Objectively Analyzed Climatology in [07-01-01 01:00] (3D) {World Ocean Atlas 09: Sea Water Temperature - annual: dods://thredds.research-infrastructures.eu/thredds/dodsC/public/netcdf/temperature_annual_1deg_ENVIRONMENT_OCEANS_.nc}";
long t0 = System.currentTimeMillis();
AnalysisLogger.setLogger(cfg+AlgorithmConfiguration.defaultLoggerFile);
GeoIntersector intersector = new GeoIntersector(null, cfg);
MatrixExtractor intersector = new MatrixExtractor(null, cfg);
// intersector.takeTimeSlice(layertitle, 0, -180, 180, -10, 10, 0, 1, 1);
// intersector.takeTimeSlice(layertitle, 0, -10, 10, -10, 10, 0,1, 1);
intersector.takeTimeSlice(layertitle, 0, -180, 180, -90, 90, 0, 0.5, 0.5);
intersector.takeTimeInstantMatrix(layertitle, 0, -180, 180, -90, 90, 0, 0.5, 0.5);
System.out.println("ELAPSED TIME: "+(System.currentTimeMillis()-t0));
}
}

View File

@ -2,7 +2,7 @@ package org.gcube.dataanalysis.geo.test;
import org.gcube.contentmanagement.lexicalmatcher.utils.AnalysisLogger;
import org.gcube.dataanalysis.ecoengine.configuration.AlgorithmConfiguration;
import org.gcube.dataanalysis.geo.retrieval.GeoIntersector;
import org.gcube.dataanalysis.geo.matrixmodel.MatrixExtractor;
public class TestChunkizationLayer {
@ -14,9 +14,9 @@ public class TestChunkizationLayer {
String layertitle = "FAO AQUATIC SPECIES DISTRIBUTION MAP OF MEGALASPIS CORDYLA";
long t0 = System.currentTimeMillis();
AnalysisLogger.setLogger(cfg+AlgorithmConfiguration.defaultLoggerFile);
GeoIntersector intersector = new GeoIntersector(null, cfg);
MatrixExtractor intersector = new MatrixExtractor(null, cfg);
// intersector.takeTimeSlice(layertitle, 0, -10, 10, -10, 10, 0,1, 1);
intersector.takeTimeSlice(layertitle, 0, -180, 180, -90, 90, 0, 0.5, 0.5);
intersector.takeTimeInstantMatrix(layertitle, 0, -180, 180, -90, 90, 0, 0.5, 0.5);
System.out.println("ELAPSED TIME: "+(System.currentTimeMillis()-t0));
}
}

View File

@ -8,8 +8,8 @@ import java.util.List;
import org.gcube.contentmanagement.graphtools.utils.MathFunctions;
import org.gcube.contentmanagement.lexicalmatcher.utils.AnalysisLogger;
import org.gcube.dataanalysis.ecoengine.configuration.AlgorithmConfiguration;
import org.gcube.dataanalysis.geo.meta.features.FeaturesManager;
import org.gcube.dataanalysis.geo.retrieval.GeoIntersector;
import org.gcube.dataanalysis.geo.infrastructure.GeoNetworkInspector;
import org.gcube.dataanalysis.geo.matrixmodel.MatrixExtractor;
import org.geotoolkit.metadata.iso.identification.DefaultDataIdentification;
import org.opengis.metadata.Metadata;
import org.opengis.metadata.identification.Identification;
@ -23,7 +23,7 @@ public class TestLayersRetrieval {
public static void main(String[] args) throws Exception{
long t0 = System.currentTimeMillis();
AnalysisLogger.setLogger(cfg+AlgorithmConfiguration.defaultLoggerFile);
FeaturesManager featurer = new FeaturesManager();
GeoNetworkInspector featurer = new GeoNetworkInspector();
featurer.setScope(null);
List<Metadata> metae = featurer.getAllGNInfobyText("thredds", "1");
System.out.println("ELAPSED TIME: "+(System.currentTimeMillis()-t0));

View File

@ -2,8 +2,8 @@ package org.gcube.dataanalysis.geo.test;
import org.gcube.contentmanagement.lexicalmatcher.utils.AnalysisLogger;
import org.gcube.dataanalysis.ecoengine.configuration.AlgorithmConfiguration;
import org.gcube.dataanalysis.geo.insertion.RasterTable;
import org.gcube.dataanalysis.geo.retrieval.GeoIntersector;
import org.gcube.dataanalysis.geo.matrixmodel.MatrixExtractor;
import org.gcube.dataanalysis.geo.matrixmodel.RasterTable;
public class TestRasterTable {
@ -31,7 +31,7 @@ public class TestRasterTable {
config.setParam("DatabaseURL","jdbc:postgresql://localhost/testdb");
config.setParam("DatabaseDriver","org.postgresql.Driver");
GeoIntersector intersector = new GeoIntersector(null, cfg);
MatrixExtractor intersector = new MatrixExtractor(null, cfg);
int t = 0;
double x1 = -180;
double x2 = 180;
@ -41,7 +41,7 @@ public class TestRasterTable {
double xResolution = 0.5;
double yResolution = 0.5;
double[][] slice = intersector.takeTimeSlice(layertitle, t, x1, x2, y1,y2,z,xResolution,yResolution);
double[][] slice = intersector.takeTimeInstantMatrix(layertitle, t, x1, x2, y1,y2,z,xResolution,yResolution);
RasterTable raster = new RasterTable(x1, x2, y1, y2, z, xResolution, yResolution, slice, config);
raster.dumpGeoTable();

View File

@ -3,8 +3,8 @@ package org.gcube.dataanalysis.geo.test.maps;
import org.gcube.contentmanagement.lexicalmatcher.utils.AnalysisLogger;
import org.gcube.dataanalysis.ecoengine.configuration.AlgorithmConfiguration;
import org.gcube.dataanalysis.geo.algorithms.MapsComparator;
import org.gcube.dataanalysis.geo.insertion.RasterTable;
import org.gcube.dataanalysis.geo.retrieval.GeoIntersector;
import org.gcube.dataanalysis.geo.matrixmodel.MatrixExtractor;
import org.gcube.dataanalysis.geo.matrixmodel.RasterTable;
public class TestMapsComparison {

View File

@ -3,8 +3,8 @@ package org.gcube.dataanalysis.geo.test.maps;
import org.gcube.contentmanagement.lexicalmatcher.utils.AnalysisLogger;
import org.gcube.dataanalysis.ecoengine.configuration.AlgorithmConfiguration;
import org.gcube.dataanalysis.geo.algorithms.MapsComparator;
import org.gcube.dataanalysis.geo.insertion.RasterTable;
import org.gcube.dataanalysis.geo.retrieval.GeoIntersector;
import org.gcube.dataanalysis.geo.matrixmodel.MatrixExtractor;
import org.gcube.dataanalysis.geo.matrixmodel.RasterTable;
public class TestMapsComparisonAquaMapsvsFAO {

View File

@ -3,8 +3,8 @@ package org.gcube.dataanalysis.geo.test.maps;
import org.gcube.contentmanagement.lexicalmatcher.utils.AnalysisLogger;
import org.gcube.dataanalysis.ecoengine.configuration.AlgorithmConfiguration;
import org.gcube.dataanalysis.geo.algorithms.MapsComparator;
import org.gcube.dataanalysis.geo.insertion.RasterTable;
import org.gcube.dataanalysis.geo.retrieval.GeoIntersector;
import org.gcube.dataanalysis.geo.matrixmodel.MatrixExtractor;
import org.gcube.dataanalysis.geo.matrixmodel.RasterTable;
public class TestMapsComparisonExampleTCOM {

View File

@ -3,8 +3,8 @@ package org.gcube.dataanalysis.geo.test.maps;
import org.gcube.contentmanagement.lexicalmatcher.utils.AnalysisLogger;
import org.gcube.dataanalysis.ecoengine.configuration.AlgorithmConfiguration;
import org.gcube.dataanalysis.geo.algorithms.MapsComparator;
import org.gcube.dataanalysis.geo.insertion.RasterTable;
import org.gcube.dataanalysis.geo.retrieval.GeoIntersector;
import org.gcube.dataanalysis.geo.matrixmodel.MatrixExtractor;
import org.gcube.dataanalysis.geo.matrixmodel.RasterTable;
public class TestMapsComparisonTemperature {

View File

@ -3,8 +3,8 @@ package org.gcube.dataanalysis.geo.test.maps;
import org.gcube.contentmanagement.lexicalmatcher.utils.AnalysisLogger;
import org.gcube.dataanalysis.ecoengine.configuration.AlgorithmConfiguration;
import org.gcube.dataanalysis.geo.algorithms.MapsComparator;
import org.gcube.dataanalysis.geo.insertion.RasterTable;
import org.gcube.dataanalysis.geo.retrieval.GeoIntersector;
import org.gcube.dataanalysis.geo.matrixmodel.MatrixExtractor;
import org.gcube.dataanalysis.geo.matrixmodel.RasterTable;
public class TestMapsComparisonTemperatureUUID {