[Met_help] [rt.rap.ucar.edu #41189] History for extracting images from MODE .ps files

RAL HelpDesk {for John Halley Gotway} met_help at ucar.edu
Thu Sep 30 12:41:21 MDT 2010


----------------------------------------------------------------
  Initial Request
----------------------------------------------------------------

  Hello,

Is it possible to pull selected graphics of forecast and observed 
objects out of the postscript files generated by MODE?  How would you 
suggest I go about doing this?  Ultimately I would like to be able to 
post them to the web so that they can be viewed more easily, but my 
experience with .ps files is pretty limited.  This isn't something that 
is an immediate priority, but I'd like to get a sense of what sort of 
work might be involved.

Thanks,
Faye


----------------------------------------------------------------
  Complete Ticket History
----------------------------------------------------------------

Subject: extracting images from MODE .ps files
From: John Halley Gotway
Time: Wed Sep 29 11:31:50 2010

Faye,

Yes, there is a way to cut out tiles from PostScript files.  We've
done this in the past using the "psselect" and "convert" commands.

Here's an example from the DTC Hydromet Testbed website where we've
done this:
   http://verif.rap.ucar.edu/eval/hmt/2010/loops/loop_objects.php?date=2010010112&thr=hires&acc=06

It'll take some trial and error to get the tile cut out in exactly the
way you'd like.  Here's an example of doing this for the MODE
PostScript output generated by the test script:
   cd METv2.0/out/mode
   # To select out just the first page
   psselect -p 1
mode_RH_ISBL_500_vs_RH_ISBL_500_120000L_20050807_120000V_000000A.ps
page1.ps
   # Crop out the forecast objects
   convert page1.ps -crop 215x150+20+222  -page 1 crop_fcst.png
   # Crop out the observation objects
   convert page1.ps -crop 215x150+235+222 -page 1 crop_obs.png

The corresponding images are attached.  Hopefully, this will get you
started.  But the convert command has a TON of options.  You can
resize images, rotate them, and add text, to name just a few.
Just type "convert -help" to see the long list of options.

Hope that helps.

John Halley Gotway
met_help at ucar.edu

RAL HelpDesk {for Faye Barthold} wrote:
> Wed Sep 29 08:46:34 2010: Request 41189 was acted upon.
> Transaction: Ticket created by Faye.Barthold at noaa.gov
>        Queue: met_help
>      Subject: extracting images from MODE .ps files
>        Owner: Nobody
>   Requestors: Faye.Barthold at noaa.gov
>       Status: new
>  Ticket <URL:
https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=41189 >
>
>
>   Hello,
>
> Is it possible to pull selected graphics of forecast and observed
> objects out of the postscript files generated by MODE?  How would
you
> suggest I go about doing this?  Ultimately I would like to be able
to
> post them to the web so that they can be viewed more easily, but my
> experience with .ps files is pretty limited.  This isn't something
that
> is an immediate priority, but I'd like to get a sense of what sort
of
> work might be involved.
>
> Thanks,
> Faye

------------------------------------------------
Subject: Re: [rt.rap.ucar.edu #41189] extracting images from MODE .ps files
From: Faye Barthold
Time: Thu Sep 30 10:44:28 2010

  Thanks, this definitely helps me get started.

Faye

On 9/29/2010 1:31 PM, RAL HelpDesk {for John Halley Gotway} wrote:
> Faye,
>
> Yes, there is a way to cut out tiles from PostScript files.  We've
done this in the past using the "psselect" and "convert" commands.
>
> Here's an example from the DTC Hydromet Testbed website where we've
done this:
>
http://verif.rap.ucar.edu/eval/hmt/2010/loops/loop_objects.php?date=2010010112&thr=hires&acc=06
>
> It'll take some trial and error to get the tile cut out in exactly
the way you'd like.  Here's an example of doing this for the MODE
PostScript output generated by the test script:
>     cd METv2.0/out/mode
>     # To select out just the first page
>     psselect -p 1
mode_RH_ISBL_500_vs_RH_ISBL_500_120000L_20050807_120000V_000000A.ps
page1.ps
>     # Crop out the forecast objects
>     convert page1.ps -crop 215x150+20+222  -page 1 crop_fcst.png
>     # Crop out the observation objects
>     convert page1.ps -crop 215x150+235+222 -page 1 crop_obs.png
>
> The corresponding images are attached.  Hopefully, this will get you
started.  But the convert command has a TON of options.  You can
resize images, rotate them, and add text, to name just a few.
> Just type "convert -help" to see the long list of options.
>
> Hope that helps.
>
> John Halley Gotway
> met_help at ucar.edu
>
> RAL HelpDesk {for Faye Barthold} wrote:
>> Wed Sep 29 08:46:34 2010: Request 41189 was acted upon.
>> Transaction: Ticket created by Faye.Barthold at noaa.gov
>>         Queue: met_help
>>       Subject: extracting images from MODE .ps files
>>         Owner: Nobody
>>    Requestors: Faye.Barthold at noaa.gov
>>        Status: new
>>   Ticket<URL:
https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=41189>
>>
>>
>>    Hello,
>>
>> Is it possible to pull selected graphics of forecast and observed
>> objects out of the postscript files generated by MODE?  How would
you
>> suggest I go about doing this?  Ultimately I would like to be able
to
>> post them to the web so that they can be viewed more easily, but my
>> experience with .ps files is pretty limited.  This isn't something
that
>> is an immediate priority, but I'd like to get a sense of what sort
of
>> work might be involved.
>>
>> Thanks,
>> Faye

------------------------------------------------


More information about the Met_help mailing list