Changes between Version 2 and Version 3 of Ticket #1309


Ignore:
Timestamp:
May 18, 2016, 1:49:57 PM (8 years ago)
Author:
Bang Pham Huu
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #1309

    • Property Milestone 9.29.3
    • Property Summary Petascope_missing geo-reference when encode multibands in NetCDFGDAL_missing geo-reference when encode multibands in NetCDF from TIFF file (Know Fails)
  • Ticket #1309 – Description

    v2 v3  
    1 When use crsTranform() in WCPS it return a coverage in NetCDF without georeference.
     1'''Update 2: ''' The real problem is from GDAL does not support to convert a multibands (> 2 bands) GeoTIFF to NetCDF. But if subset to create 1 band from this TIFF file then can convert to NetCDF with full metadata.
    22
    3 '''Update:''' The problem only happens if use a coverage with multibands (ranges) and encode all of these ranges in NetCDF. In this example: test_projection has 3 bands (Red, Green, Blue).
     3Example with 1 band NetCDF from 1 band GeoTIFF.
     4{{{
     5gdal_translate '/home/rasdaman/tmp/test_projection/mean_summer_airtemp
     6/irr_cub2_b1.tif'
     7-of NetCDF output.nc
     8}}}
     9
     10Metasdata
     11{{{
     12Driver: netCDF/Network Common Data Format
     13Files: output.nc
     14Size is 63, 36
     15Coordinate System is:
     16PROJCS["WGS 84 / UTM zone 33N",
     17    GEOGCS["WGS 84",
     18        DATUM["WGS_1984",
     19            SPHEROID["WGS 84",6378137,298.257223563,
     20                AUTHORITY["EPSG","7030"]],
     21            AUTHORITY["EPSG","6326"]],
     22        PRIMEM["Greenwich",0],
     23        UNIT["degree",0.0174532925199433],
     24        AUTHORITY["EPSG","4326"]],
     25}}}
     26
     27
     28if use 2 bands GeoTIFF to transform to NetCDF it will lost these information
     29
     30{{{
     31gdal_translate '/home/rasdaman/test_server/NEW/rasdaman/systemtest
     32/testcases_services/test_wcs/testdata/irr_cube_2/AUT-PM10_2008-01-01.geo.tif'
     33-of NetCDF output.nc
     34}}}
    435
    536
    637{{{
    7 Describe Coverage metadata: https://www.diffchecker.com/9uk36tkw
    8 }}}
    9 
    10 
    11 If only select 1 band (Red) then it will have the full geo-referenced metadata.
    12 
    13 '''WCPS query with metadata (select 1 band)'''
    14 
    15 
    16 {{{
    17 for c in (test_projection),  d in (eobstest)
    18 return encode(crsTransform((c.Red),
    19  { Lat:"http://www.opengis.net/def/crs/EPSG/0/3542", Long:"http://www.opengis.net/def/crs/EPSG/0/3542"}, {}), "netcdf")
    20 }}}
    21 
    22 
    23 '''WCPS query without metadata (multibands)'''
    24 
    25 {{{
    26 for c in (test_projection),  d in (test_projection)
    27 return encode(crsTransform((c + d),
    28  { Lat:"http://www.opengis.net/def/crs/EPSG/0/3542", Long:"http://www.opengis.net/def/crs/EPSG/0/3542"}, {}), "netcdf")
    29 }}}
    30 
    31 '''or not use crsTransform() with sample data: irr_cube_2'''
    32 
    33 {{{
    34 for c in (irr_cube_2)
    35 return encode(c[ansi(148654)], "netcdf")
    36 }}}
    37 
    38 
    39 
    40 {{{
    41 Driver: netCDF/Network Common Data Format
    42 Files: /home/rasdaman/Downloads/ows(126)
    43 Size is 512, 512
    4438Coordinate System is `'
    4539Metadata:
    4640  NC_GLOBAL#Conventions=CF-1.5
    4741  NC_GLOBAL#GDAL=GDAL 1.11.2, released 2015/02/10
    48   NC_GLOBAL#history=Wed May 11 11:00:33 2016: GDAL CreateCopy( /tmp/rasdaman-uZVa17, ... )
     42  NC_GLOBAL#GDAL_AREA_OR_POINT=Area
     43  NC_GLOBAL#history=Wed May 18 15:47:27 2016: GDAL CreateCopy( output.nc, ... )
    4944Subdatasets:
    50   SUBDATASET_1_NAME=NETCDF:"/home/rasdaman/Downloads/ows(126)":Band1
    51   SUBDATASET_1_DESC=[260x261] Band1 (8-bit integer)
    52   SUBDATASET_2_NAME=NETCDF:"/home/rasdaman/Downloads/ows(126)":Band2
    53   SUBDATASET_2_DESC=[260x261] Band2 (8-bit integer)
    54   SUBDATASET_3_NAME=NETCDF:"/home/rasdaman/Downloads/ows(126)":Band3
    55   SUBDATASET_3_DESC=[260x261] Band3 (8-bit integer)
     45  SUBDATASET_1_NAME=NETCDF:"/home/rasdaman/tmp/test_projection/mean_summer_airtemp/output.nc":Band1
     46  SUBDATASET_1_DESC=[36x63] Band1 (32-bit floating-point)
     47  SUBDATASET_2_NAME=NETCDF:"/home/rasdaman/tmp/test_projection/mean_summer_airtemp/output.nc":Band2
     48  SUBDATASET_2_DESC=[36x63] Band2 (32-bit floating-point)
    5649Corner Coordinates:
    5750Upper Left  (    0.0,    0.0)
     
    6053Lower Right (  512.0,  512.0)
    6154Center      (  256.0,  256.0)
     55
    6256}}}
     57