[Shake-dev] EqInfo.pm, Event.pm problem in v3.5
Peter Lombard
lombard at seismo.berkeley.edu
Fri Jan 29 00:25:42 UTC 2010
Wan,
Ok, if Event.pm has to provide a "network" field to EqInfo.pm, so it shall
be. Attached is revised code to make that happen.
However, as you will see in the comments in the code, I don;t have any idea
what value to assign to the "network", so I have left it unassigned. At least
if fills up a slot so the following variables in EqInfo's new() method get the
right values.
Please update this in SVN.
Pete
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Event.pm
Type: application/octet-stream
Size: 5717 bytes
Desc: not available
URL: <http://geohazards.usgs.gov/pipermail/shake-dev/attachments/20100128/d2320649/attachment.obj>
-------------- next part --------------
Kuo-Wan Lin writes:
> Hi Pete,
>
> Thanks for the Makefile corrections.
>
> The network tag in EqInfo is an 'optional' field and is meant to avoid
> ID collision. The network tag is part of the earthquake information and
> is of course not used in grind but will be carried over to the output
> grid.xml. The network originator tag still identifies the ShakeMap
> producer network. This was added at the request of the NEIC web group
> to distinguish the authoritative earthquake solution.
>
> Event.pm is very specific to networks that adapted it to create
> event.xml (also watcher output) and is not used elsewhere during
> ShakeMap processing. We don't use it locally and it was left untouched
> for the network to decide at this time.
>
>
> Wan
>
> Peter Lombard wrote:
> > Bruce and Wan,
> >
> > There is a problem with EqInfo.pm and Event.pm modules in ShakeMap 3.5.
> >
> > Event.pm creates a new EqInfo obect with:
> > my $eir = new EqInfo($lat, $lon, $mag, $depth, $yr,
> > $mon, $day, $hr, $min, $sec, $loc, $type);
> >
> > But EqInfo.pm expects a "network" parameter between "sec" and "location":
> > sub new {
> >
> > my $class = shift;
> > my $self = {};
> >
> > bless $self, $class;
> > $self->lat(shift);
> > $self->lon(shift);
> > $self->mag(shift);
> > $self->depth(shift);
> > $self->yr(shift);
> > $self->mon(shift);
> > $self->day(shift);
> > $self->hr(shift);
> > $self->min(shift);
> > $self->sec(shift);
> > $self->network(shift);
> > $self->loc(shift);
> > $self->type(shift);
> >
> > return $self;
> > }
> >
> > I don't find any code that uses this network parameter from EqInfo. And it is
> > not in the version of EqInfo.pm that I sent you in November.
> >
> > Any idea what it is for?
> >
> > Pete
> > _______________________________________________
> > Shake-dev mailing list
> > Shake-dev at geohazards.usgs.gov
> > https://geohazards.usgs.gov/mailman/listinfo/shake-dev
> >
> >
>
> --
> Kuo-Wan Lin
> U.S. Geological Survey
> DFC P.O. Box 25046, MS 966
> Denver, CO 80225-0046
>
> klin at usgs.gov
> (O) 303-273-8563
> (F) 303-273-8600
>
More information about the Shake-dev
mailing list