aodn / content

Tracks AODN Portal content and configuration issues
0 stars 0 forks source link

Cars_monthly_data displayed incorrectly in the portal after move to thredds #227

Closed jonescc closed 7 years ago

jonescc commented 8 years ago

Refer https://github.com/aodn/aodn-portal/issues/2245

valid_max/actual values do not match for LONGITUDE variable causing display issues.

ggalibert commented 7 years ago

I believe this is not a content issue but a software issue.

CF variable attributes valid_min/max do not have to match variable actual min and max values. For this purpose for LATITUDE and LONGITUDE we already have geospatial_lat/lon_min/max attributes.

CF says:

valid_max = Largest valid value of a variable. valid_min = Smallest valid value of a variable.

Our CF checker doesn't check that attributes valid_min/max must match the variable actual min and max values.

See below the content of the NetCDF file for information:

ggalibert@ggalibert-Latitude-E7450:~/$ ncdump -v LATITUDE,LONGITUDE http://thredds.aodn.org.au/thredds/dodsC/CSIRO/Climatology/CARS/2009/AODN-product/CARS2009_Australia_weekly.nc
netcdf CARS2009_Australia_weekly {
dimensions:
    DAY_OF_YEAR = 52 ;
    DEPTH = 8 ;
    LATITUDE = 93 ;
    LONGITUDE = 115 ;
variables:
    ...
    double LONGITUDE(LONGITUDE) ;
        LONGITUDE:name = "LONGITUDE" ;
        LONGITUDE:standard_name = "longitude" ;
        LONGITUDE:long_name = "longitude" ;
        LONGITUDE:units = "degrees_east" ;
        LONGITUDE:axis = "X" ;
        LONGITUDE:valid_min = -180. ;
        LONGITUDE:valid_max = 180. ;
        LONGITUDE:_FillValue = 2.2250738585072e-308 ;
        LONGITUDE:reference_datum = "geographical coordinates, WGS84 projection" ;
    double LATITUDE(LATITUDE) ;
        LATITUDE:name = "LATITUDE" ;
        LATITUDE:standard_name = "latitude" ;
        LATITUDE:long_name = "latitude" ;
        LATITUDE:units = "degrees_north" ;
        LATITUDE:axis = "Y" ;
        LATITUDE:valid_min = -90. ;
        LATITUDE:valid_max = 90. ;
        LATITUDE:_FillValue = 2.2250738585072e-308 ;
        LATITUDE:reference_datum = "geographical coordinates, WGS84 projection" ;
       ...
// global attributes:
        ...
        :geospatial_lat_min = -50. ;
        :geospatial_lat_max = -4. ;
        :geospatial_lon_min = 104. ;
        :geospatial_lon_max = 161. ;
        ...
data:

 LONGITUDE = 104, 104.5, 105, 105.5, 106, 106.5, 107, 107.5, 108, 108.5, 109, 
    109.5, 110, 110.5, 111, 111.5, 112, 112.5, 113, 113.5, 114, 114.5, 115, 
    115.5, 116, 116.5, 117, 117.5, 118, 118.5, 119, 119.5, 120, 120.5, 121, 
    121.5, 122, 122.5, 123, 123.5, 124, 124.5, 125, 125.5, 126, 126.5, 127, 
    127.5, 128, 128.5, 129, 129.5, 130, 130.5, 131, 131.5, 132, 132.5, 133, 
    133.5, 134, 134.5, 135, 135.5, 136, 136.5, 137, 137.5, 138, 138.5, 139, 
    139.5, 140, 140.5, 141, 141.5, 142, 142.5, 143, 143.5, 144, 144.5, 145, 
    145.5, 146, 146.5, 147, 147.5, 148, 148.5, 149, 149.5, 150, 150.5, 151, 
    151.5, 152, 152.5, 153, 153.5, 154, 154.5, 155, 155.5, 156, 156.5, 157, 
    157.5, 158, 158.5, 159, 159.5, 160, 160.5, 161 ;

 LATITUDE = -50, -49.5, -49, -48.5, -48, -47.5, -47, -46.5, -46, -45.5, -45, 
    -44.5, -44, -43.5, -43, -42.5, -42, -41.5, -41, -40.5, -40, -39.5, -39, 
    -38.5, -38, -37.5, -37, -36.5, -36, -35.5, -35, -34.5, -34, -33.5, -33, 
    -32.5, -32, -31.5, -31, -30.5, -30, -29.5, -29, -28.5, -28, -27.5, -27, 
    -26.5, -26, -25.5, -25, -24.5, -24, -23.5, -23, -22.5, -22, -21.5, -21, 
    -20.5, -20, -19.5, -19, -18.5, -18, -17.5, -17, -16.5, -16, -15.5, -15, 
    -14.5, -14, -13.5, -13, -12.5, -12, -11.5, -11, -10.5, -10, -9.5, -9, 
    -8.5, -8, -7.5, -7, -6.5, -6, -5.5, -5, -4.5, -4 ;
}
jonescc commented 7 years ago

I was looking at monthly averages not daily ones min/max is -180/180 but values go to 360. Is this valid? If so we need to raise with unidata. See below for monthly averages values.

netcdf CARS2009_World_monthly {
dimensions:
        DAY_OF_YEAR = 12 ;
        LONGITUDE = 721 ;
        LATITUDE = 331 ;
        DEPTH = 5 ;
variables:
        double DAY_OF_YEAR(DAY_OF_YEAR) ;
                DAY_OF_YEAR:name = "DAY_OF_YEAR" ;
                DAY_OF_YEAR:long_name = "day_of_year" ;
                DAY_OF_YEAR:climatology = "climatology_bounds" ;
                DAY_OF_YEAR:units = "days since 2009-1-1" ;
                DAY_OF_YEAR:axis = "T" ;
                DAY_OF_YEAR:valid_min = 0. ;
                DAY_OF_YEAR:valid_max = 366. ;
                DAY_OF_YEAR:_FillValue = 2.2250738585072e-308 ;
        double LONGITUDE(LONGITUDE) ;
                LONGITUDE:name = "LONGITUDE" ;
                LONGITUDE:standard_name = "longitude" ;
                LONGITUDE:long_name = "longitude" ;
                LONGITUDE:units = "degrees_east" ;
                LONGITUDE:axis = "X" ;
                LONGITUDE:valid_min = -180. ;
                LONGITUDE:valid_max = 180. ;
                LONGITUDE:_FillValue = 2.2250738585072e-308 ;
                LONGITUDE:reference_datum = "geographical coordinates, WGS84 projection" ;
...
 LONGITUDE = 0, 0.5, 1, 1.5, 2, 2.5, 3, 3.5, 4, 4.5, 5, 5.5, 6, 6.5, 7, 7.5, 
    8, 8.5, 9, 9.5, 10, 10.5, 11, 11.5, 12, 12.5, 13, 13.5, 14, 14.5, 15, 
    15.5, 16, 16.5, 17, 17.5, 18, 18.5, 19, 19.5, 20, 20.5, 21, 21.5, 22, 
    22.5, 23, 23.5, 24, 24.5, 25, 25.5, 26, 26.5, 27, 27.5, 28, 28.5, 29, 
    29.5, 30, 30.5, 31, 31.5, 32, 32.5, 33, 33.5, 34, 34.5, 35, 35.5, 36, 
    36.5, 37, 37.5, 38, 38.5, 39, 39.5, 40, 40.5, 41, 41.5, 42, 42.5, 43, 
    43.5, 44, 44.5, 45, 45.5, 46, 46.5, 47, 47.5, 48, 48.5, 49, 49.5, 50, 
    50.5, 51, 51.5, 52, 52.5, 53, 53.5, 54, 54.5, 55, 55.5, 56, 56.5, 57, 
    57.5, 58, 58.5, 59, 59.5, 60, 60.5, 61, 61.5, 62, 62.5, 63, 63.5, 64, 
    64.5, 65, 65.5, 66, 66.5, 67, 67.5, 68, 68.5, 69, 69.5, 70, 70.5, 71, 
    71.5, 72, 72.5, 73, 73.5, 74, 74.5, 75, 75.5, 76, 76.5, 77, 77.5, 78, 
    78.5, 79, 79.5, 80, 80.5, 81, 81.5, 82, 82.5, 83, 83.5, 84, 84.5, 85, 
    85.5, 86, 86.5, 87, 87.5, 88, 88.5, 89, 89.5, 90, 90.5, 91, 91.5, 92, 
    92.5, 93, 93.5, 94, 94.5, 95, 95.5, 96, 96.5, 97, 97.5, 98, 98.5, 99, 
    99.5, 100, 100.5, 101, 101.5, 102, 102.5, 103, 103.5, 104, 104.5, 105, 
    105.5, 106, 106.5, 107, 107.5, 108, 108.5, 109, 109.5, 110, 110.5, 111, 
    111.5, 112, 112.5, 113, 113.5, 114, 114.5, 115, 115.5, 116, 116.5, 117, 
    117.5, 118, 118.5, 119, 119.5, 120, 120.5, 121, 121.5, 122, 122.5, 123, 
    123.5, 124, 124.5, 125, 125.5, 126, 126.5, 127, 127.5, 128, 128.5, 129, 
    129.5, 130, 130.5, 131, 131.5, 132, 132.5, 133, 133.5, 134, 134.5, 135, 
    135.5, 136, 136.5, 137, 137.5, 138, 138.5, 139, 139.5, 140, 140.5, 141, 
    141.5, 142, 142.5, 143, 143.5, 144, 144.5, 145, 145.5, 146, 146.5, 147, 
    147.5, 148, 148.5, 149, 149.5, 150, 150.5, 151, 151.5, 152, 152.5, 153, 
    153.5, 154, 154.5, 155, 155.5, 156, 156.5, 157, 157.5, 158, 158.5, 159, 
    159.5, 160, 160.5, 161, 161.5, 162, 162.5, 163, 163.5, 164, 164.5, 165, 
    165.5, 166, 166.5, 167, 167.5, 168, 168.5, 169, 169.5, 170, 170.5, 171, 
    171.5, 172, 172.5, 173, 173.5, 174, 174.5, 175, 175.5, 176, 176.5, 177, 
    177.5, 178, 178.5, 179, 179.5, 180, 180.5, 181, 181.5, 182, 182.5, 183, 
    183.5, 184, 184.5, 185, 185.5, 186, 186.5, 187, 187.5, 188, 188.5, 189, 
    189.5, 190, 190.5, 191, 191.5, 192, 192.5, 193, 193.5, 194, 194.5, 195, 
    195.5, 196, 196.5, 197, 197.5, 198, 198.5, 199, 199.5, 200, 200.5, 201, 
    201.5, 202, 202.5, 203, 203.5, 204, 204.5, 205, 205.5, 206, 206.5, 207, 
    207.5, 208, 208.5, 209, 209.5, 210, 210.5, 211, 211.5, 212, 212.5, 213, 
    213.5, 214, 214.5, 215, 215.5, 216, 216.5, 217, 217.5, 218, 218.5, 219, 
    219.5, 220, 220.5, 221, 221.5, 222, 222.5, 223, 223.5, 224, 224.5, 225, 
    225.5, 226, 226.5, 227, 227.5, 228, 228.5, 229, 229.5, 230, 230.5, 231, 
    231.5, 232, 232.5, 233, 233.5, 234, 234.5, 235, 235.5, 236, 236.5, 237, 
    237.5, 238, 238.5, 239, 239.5, 240, 240.5, 241, 241.5, 242, 242.5, 243, 
    243.5, 244, 244.5, 245, 245.5, 246, 246.5, 247, 247.5, 248, 248.5, 249, 
    249.5, 250, 250.5, 251, 251.5, 252, 252.5, 253, 253.5, 254, 254.5, 255, 
    255.5, 256, 256.5, 257, 257.5, 258, 258.5, 259, 259.5, 260, 260.5, 261, 
    261.5, 262, 262.5, 263, 263.5, 264, 264.5, 265, 265.5, 266, 266.5, 267, 
    267.5, 268, 268.5, 269, 269.5, 270, 270.5, 271, 271.5, 272, 272.5, 273, 
    273.5, 274, 274.5, 275, 275.5, 276, 276.5, 277, 277.5, 278, 278.5, 279, 
    279.5, 280, 280.5, 281, 281.5, 282, 282.5, 283, 283.5, 284, 284.5, 285, 
    285.5, 286, 286.5, 287, 287.5, 288, 288.5, 289, 289.5, 290, 290.5, 291, 
    291.5, 292, 292.5, 293, 293.5, 294, 294.5, 295, 295.5, 296, 296.5, 297, 
    297.5, 298, 298.5, 299, 299.5, 300, 300.5, 301, 301.5, 302, 302.5, 303, 
    303.5, 304, 304.5, 305, 305.5, 306, 306.5, 307, 307.5, 308, 308.5, 309, 
    309.5, 310, 310.5, 311, 311.5, 312, 312.5, 313, 313.5, 314, 314.5, 315, 
    315.5, 316, 316.5, 317, 317.5, 318, 318.5, 319, 319.5, 320, 320.5, 321, 
    321.5, 322, 322.5, 323, 323.5, 324, 324.5, 325, 325.5, 326, 326.5, 327, 
    327.5, 328, 328.5, 329, 329.5, 330, 330.5, 331, 331.5, 332, 332.5, 333, 
    333.5, 334, 334.5, 335, 335.5, 336, 336.5, 337, 337.5, 338, 338.5, 339, 
    339.5, 340, 340.5, 341, 341.5, 342, 342.5, 343, 343.5, 344, 344.5, 345, 
    345.5, 346, 346.5, 347, 347.5, 348, 348.5, 349, 349.5, 350, 350.5, 351, 
    351.5, 352, 352.5, 353, 353.5, 354, 354.5, 355, 355.5, 356, 356.5, 357, 
    357.5, 358, 358.5, 359, 359.5, 360 ;
ggalibert commented 7 years ago

I've just renamed the issue with monthly instead of weekly. The issue is relevant for the monthly file.

ggalibert commented 7 years ago

I have updated the 2 files with valid_min/max set to [0; 360] for LONGITUDE. Files have been uploaded to S3 and map on portal looks fine. screenshot from 2016-09-27 17 01 13