[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[THREDDS #ZTS-349029]: datascan info



Hi Cristina,

The addTimeCoverage does not currently support extracting the end time
from the file name. It only supports getting the start time from the
file name and then using a duration to get the range.

I will add this enhancement to our list but I'm not sure when we will be
able to work on it. Our main focus in the automated metadata extraction
area is on being able to recognize information in the datasets and extract
it automatically. E.g., the FMRC aggregation knows it is dealing with
gridded data and automatically determines the time and spatial extents.

Sorry I don't have a quick solution for you.

Ethan

> Through my THREDD catalog (catalog.xml) I have a reference to a
> specific xml in which I
> have:
> - a first general metadata section in which I define time coverage
> for the entire
> dataset: from 30 jun 206 to 9 jun 2010
> <timeCoverage>
>   <start>2006-06-30T21:00:00</start>
>   <end>2010-06-09T06:00:00 </end>
>   <resolution>1 day</resolution>
> </timeCoverage>
> 
> -a second "monthly" metadata section in which I redefine the time
> coverage for a
> specific month (in the example JULY 2006)
> <metadata>
>   <timeCoverage>
>     <start>2006-06-30T21:00:00</start>
>     <end>2006-07-31T06:00:00</end>
>     <resolution>1 days</resolution>
>   </timeCoverage>
> </metadata>
> - a Third "daily" metadata section in which I redefine the time
> coverage for the single
> day dataset.
> <metadata>
>   <timeCoverage>
>     <start>2006-06-30T21:00:00</start>
>     <end>2006-07-01T06:00:00</end>
>     <resolution>1 days</resolution>
>   </timeCoverage>
> </metadata>
> 
> (NOTE: look at the xml at the end of this email.)
> 
> I build this xml catalog, manually with a shell script that looks in
> a specific
> directory, find all the year DIRECTORY, for each year looks for month
> DIRECTORY and then
> for each month DIRECTORY find all the existing file. Then it build the
> catalog specifing
> for each daily dataset, different timecoverage.
> 
> Please notice that I build the time coverage metadata starting from
> the file name. the
> file name is something like: yyyymmdd??????.nc
> Then parsing this name I can get: year (yyyy), month (mm), day (dd).
> Then the <end> element = yyyy-mm-ddT06:00:00
> Then I build the <start> element subtracting 1 day from the <end> date.
> 
> MY QUESTION IS: MAY I DO THE SAME WITH DATASETSCAN?
> 
> IN THE HELP
> http://www.unidata.ucar.edu/projects/THREDDS/tech/reference/DatasetScan.html
> 
> iI seems that I can use the addTimeCoverage element only to construct
> start/duration
> timeCoverage elements and uses the dataset name to determine the start time.
> 
> But in my case, from the filename I can determine the <end> date. The
> <start> date is
> <end> date -1day.
> 
> FOR MY NEEDS IT IS IMPORTANT TO BE ABLE TO PUT CLEARLY IN THE THREDDS
> PAGES BOTH THE
> <START> (=<END> -1day) AND THE <END> ELEMENT.
> 
> Could you teach me how to set automatically with datasetscan the <end>
> element and the
> <start> element=<end>-1day (in time coverage metadata)?
> 
> thank in advanced
> 
> cristina
> 
> -------------------------------------------------------------------
> Cristina Tronconi
> Istituto di Scienze dell'Atmosfera e del Clima - sezione di Roma
> Consiglio Nazionale delle Ricerche


--------------------------------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>

<catalog name="Mersea project datasets inventory" version="1.0.1"
    xmlns="http://www.unidata.ucar.edu/namespaces/thredds/InvCatalog/v1.0";
    xmlns:xlink="http://www.w3.org/1999/xlink";
    expires="2010-06-09 09:27:54">

   <service name="thisDODS" serviceType="Compound" base="" >
      <service name="OpenDAP" serviceType="OpenDAP" base="/thredds/dodsC/" />
      <service name="HTTPServer" serviceType="HTTPServer"  
base="/thredds/fileServer/" />
      <datasetRoot path="sst_nrt_v1_not_aggr"  
location="/var/lib/tomcat5/content/thredds/public/gos/mfstep/NRT" />
   </service>

   <dataset name= "nrt_v1_not_aggregated"  
ID="GOS-L4HRfnd-MED_NRTv1-OBS-not-aggr">

     <metadata inherited="true">
        <serviceName>thisDODS</serviceName>

        <property name="aggregation-level" value="view"/>
        <documentation  
xlink:href="http://www.mersea.eu.org/html/information/catalog/products/ID_SST.html";
 xlink:title="GOS High Resolution gridded SST foundation over Mediterranean  
Sea">
        </documentation>

        <authority>ISAC  - CNR</authority>
        <dataType>Grid</dataType>
        <dataFormat>NetCDF</dataFormat>
        <documentation type="rights">Freely available for scientific  
use</documentation>
        <documentation xlink:href="http://www.mersea.eu.org";  
xlink:title="MERSEA Project Web page"/>
        <documentation type="summary">DODS Data Prepared for the  MERSEA IP EU 
Project.</documentation>
        <creator>
          <name vocabulary="ISAC - CNR">
             Institute of Atmospheric Sciences and Climate of the  Italian 
National Research Council
          </name>
        </creator>

        <variables vocabulary="CF-1.0">
           <variable name="analysed_sst"  vocabulary_name="analysed_sst" 
units="kelvin">Analysed foundation sea  surface temperature over Mediterranean 
sea</variable>
        </variables>

        <geospatialCoverage zpositive="down">
          <northsouth>
             <start>30.25</start>
             <size>15.75</size>
             <resolution>0.0625</resolution>
             <units>degrees_north</units>
           </northsouth>

           <eastwest>
              <start>-18.125</start>
              <size>54.375</size>
              <resolution>0.0625</resolution>
              <units>degrees_east</units>
           </eastwest>
         </geospatialCoverage>
         <documentation  
xlink:href="http://www.mersea.eu.org/html/information/catalog/products/GOS-MED-L4-SST-NRTv1-OBS.html";
 xlink:title="Near Real Time (NRT) / Multi Sensor  (v1)"/>

         <timeCoverage>
                 <start>2006-06-30T21:00:00</start>
                 <end>2010-06-09T06:00:00 </end>
                 <resolution>1 day</resolution>
          </timeCoverage>
      </metadata>
    <dataset name= "JUL_2006" ID="nrt_v1_2006_JUL">
            <metadata>
               <timeCoverage>
                 <start>2006-06-30T21:00:00</start>
                 <end>2006-07-31T06:00:00</end>
                 <resolution>1 days</resolution>
               </timeCoverage>
             </metadata>
        <dataset name="20060701"  ID="nrt_v1_20060701"  serviceName="thisDODS"  
urlPath="sst_nrt_v1_not_aggr/2006/07/20060701-GOS-L4HRfnd-MED_NRTv1.nc.gz">
             <metadata>
               <timeCoverage>
                 <start>2006-06-30T21:00:00</start>
                 <end>2006-07-01T06:00:00</end>
                 <resolution>1 days</resolution>
               </timeCoverage>
             </metadata>
        </dataset>
        <dataset name="20060702"  ID="nrt_v1_20060702"  serviceName="thisDODS"  
urlPath="sst_nrt_v1_not_aggr/2006/07/20060702-GOS-L4HRfnd-MED_NRTv1.nc.gz">
             <metadata>
               <timeCoverage>
                 <start>2006-07-01T21:00:00</start>
                 <end>2006-07-02T06:00:00</end>
                 <resolution>1 days</resolution>
               </timeCoverage>
             </metadata>
        </dataset>
    </dataset>
   </dataset>
</catalog>
--------------------------------------------------------------------------------------------------------------------


Ticket Details
===================
Ticket ID: ZTS-349029
Department: Support THREDDS
Priority: High
Status: Closed