GeoscienceAustralia / eqrm

Automatically exported from code.google.com/p/eqrm
Other
5 stars 4 forks source link

Removal of unnecessary attributes from Event_Set #8

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
The code that generates the event set uses some attributes for calculations of 
other attributes but never uses them after generation. This can be seen in the 
setting to None of these after the event set is saved:

        #delete these data structures to reduce memory
        event_set.area = None
        event_set.trace_end_lat = None
        event_set.trace_end_lon = None
        event_set.source_zone_id = None
        event_set.event_id = None

These attributes flow into the file based arrays.

This issue tracks the work to potentially remove these altogether.

Original issue reported on code.google.com by b...@girorosso.com on 20 Feb 2012 at 3:53

GoogleCodeExporter commented 9 years ago

Original comment by duncan.g...@gmail.com on 21 Feb 2012 at 11:48

GoogleCodeExporter commented 9 years ago

Original comment by b...@girorosso.com on 2 Mar 2012 at 12:40

GoogleCodeExporter commented 9 years ago

Original comment by duncan.g...@gmail.com on 21 Mar 2012 at 5:50

GoogleCodeExporter commented 9 years ago

Original comment by b...@girorosso.com on 22 Mar 2012 at 3:30

GoogleCodeExporter commented 9 years ago
fault_width is another attribute to remove from Event_Set. As highlighted in 
Issue 36 it's only used in event set generation.

Original comment by b...@girorosso.com on 23 Mar 2012 at 4:48

GoogleCodeExporter commented 9 years ago
There are two flow on effects from this:

1. The event_num field in event set output files may not match up as before:
If events have been generated from both zone and fault source files then 
previously event_num was unique per source file, but unique in the generated 
event set output. This is now unique.

2. Previously generated event sets will need to have the following files 
removed if either running in generate mode in parallel or load mode:
<data_dir>/event_set/
area.npy
event_id.npy
fault_width.npy
source_zone_id.npy
trace_end_lat.npy
trace_end_lon.npy

Original comment by b...@girorosso.com on 26 Mar 2012 at 3:32

GoogleCodeExporter commented 9 years ago
Revision 1024 implements these changes.

Original comment by b...@girorosso.com on 26 Mar 2012 at 11:42