Vous êtes sur la page 1sur 67

Geopsy manual: content

Contents
Next
Top of page

Geopsy Manual: Contents


1. Introduction
2. Installation
3. Tutorials
3.1. Creating a database
3.2. Refraction survey
3.3. H/V measurements
3.4. Noise array measurements
4. Database
4.1. Load signal files
4.2. Create, Open, Close and Save
4.3. Groups of signals
4.4. Preferences
4.5. File structure
5. Signal viewers
5.1. Table
5.2. Graphic
5.3. Map
6. Basic signal processing
6.1. DC Removal
6.2. Filters
6.3. Automatic Gain Control
6.4. Fast Fourier Transform
6.5. Tapering signals
6.6. Cutting signals
6.7. Merging signals
6.8. Subtracting signals
6.9. Rotate components
7. Specific processing tools
7.1. H/V
7.2. Damping
7.3. Frequencywavenumber for 2D arrays
7.4. Frequencywavenumber for 1D arrays
7.5. Spatial autocorrelation for 2D arrays
7.6. Particle motion
7.7. Refraction
8. Writing scripts
9. Developers
9.1. Reading file formats
9.2. Exporting file formats
9.3. Specific processing tools
Geopsy licenses
References

Geopsy Manual: Contents

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
Database
Viewers
Processing
Scripting

1. Introduction
This manual documents how to use Geopsy as well as the tools developed for ambient vibration processing. It
corresponds to version 2.0.0.

1. Introduction

Geopsy manual: content

1. Introduction

Geopsy manual: content


Figure 1: Main frame of Geopsy. On the left, the File and Group navigation bars. On the right, the three kinds
of viewers: table, graphic and map.
Geopsy is a graphical user interface for organising, viewing, and processing geophysical signals. These three
aspects are detailed hereafter and they are illustrated in figure 1 by a screen capture. Geopsy is also a database
used to gather all information about recorded signals. External command line or GUI programs can access this
database, enjoying the optimised core library designed for very long signals (hours of recording or tens of
millions of samples).
Though extensions to other scientific or engineering fields are potentially possible, this software has been
primarily designed for seismology and seismic prospecting. It is available under all common platforms
(Linux, Mac OS X, and Windows) and released for free under the GNU Public License. Please refer the
installation section for details.

Database
Various common signal file formats can be loaded. These formats are automatically recognised to simplify the
access to the measured signals. Reading the original file format is usually better than using conversion tools
where data losses are likely to occurs (e.g. correction factors).
There is virtually no limit to the number of signals that can be loaded at the same time. Once loaded, the
signals can be grouped in ordered lists (groups) and supplementary information can be added to each trace
(signal name, X Y Z coordinates, picks, ...). These data cannot be stored in all types of file headers due to the
heterogeneities of the signal file formats.
For this reason, a database is generated to gather in an independent and handy way all information. A database
is stored under a .sdb file that lists all signal files corresponding to a particular project or site. Hence, the
signals are not duplicated when creating a database, keeping links to the original signal files and saving disk
space. One interest of databases is to reload all signal files of a project with a simple click. Each database is
affected a directory containing the .sdb file plus other secondary files.
New files are automatically added to the database when a trace is modified (Processing) and saved inside the
database directory with a quick access format (binary). The original signals are still present in the database.

Viewers
They are three ways of viewing the signals in Geopsy: Table, Graphic and Map. Each viewer is a floating
window in the main Geopsy frame that contains a sub list of signals currently loaded (with or without a
database created). According to each viewer, it is possible make a selection of signals and to create another
viewer containing only the selected signals (drag and drop mechanism).
The table shows textual information about each signal (one per row). The number of columns and the data
displayed is entirely configurable. Each field can be directly edited. For long signals (millions of samples), it
is handy to select signals with a table because only the header information is loaded into memory, the whole
traces are not loaded from files. The contents of tables can be exported and imported to ASCII files.
The graphic shows the signal themselves with a time scale. Various options are available for plotting traces
(e.g. variable black area, normalisation, colour scale, ...). All signals are stored as time series. However, they
can be plotted as frequency spectra after Fourier transforms. A zooming facility has been implemented to ease
data inspection. Signals cannot be selected inside a graphic viewer, they are all selected by default.
Database

Geopsy manual: content


The map shows a 2D map of the signal coordinates. Scales of axis are automatically adjusted to fit the
coordinate range. Selection of signals can be performed directly with mouse picks.

Processing
Geopsy proposes two kinds of signal processing tools:
1. Basic processing (menu "Waveform"): filters, Fourier transform, taper, cut , DC removal, merge,
subtract, multiply, ... These transformations directly affect the signals and the results are automatically
updated on the screen. Reverting to the original is always possible. On saving a database, the
modified signals are saved with a raw binary format (best I/O performances) into the database's
directory. Both the original and the modified signals remain accessible in the database.
2. Advanced processing (menu "Tools"): these are tools developed for special purposes. A plugin
mechanism allows you to add new tools without upgrading the main Geopsy frame. Originally, the
available tools were dedicated to the analysis of ambient vibrations. The development of new
specialised tools are pretty welcome (developers).

Scripting
In certain cases, the graphical user interface may not be useful especially for repetitive tasks. Thanks to Qt
Script for Application (QSA from Trolltech), it has been possible to propose a versatile scripting language to
execute any of the functions available with mouse clicks. These scripts can be launched from the command
line allowing its inclusion into complex bash scripts, for instance.
The available functions within a script currently do not cover the whole functionalities of Geopsy. The users
are particularly encouraged to give their feedback on this topic to accelerate the development on the most
popular tools ().

Viewers

Geopsy manual: content


Contents
Previous
Next
Up

2. Installation
The next beta release is installed from distribution packages. This step is still under development. Developer:
CVS basic commands and registration at www.geopsy.org

2. Installation

Geopsy manual: content


Contents
Previous
Next
Up

3. Tutorials
The following tutorials are documented in this chapter:
3.1. Creating a database
3.2. Refraction survey
3.3. H/V measurements
3.4. Noise array measurements
Tutorials 3.3 and 3.4 are both built around a demo database which is build with the tutorial 3.1. You can skip
the database construction by downloading the finalised database. When opening it for the first time, you will
probably receive a warning complaining about a missing signal file. Click "No" and specify the path to the
required file (usually in "geopsy_tutorials/raw_signals"). Save the database at least once to save the modified
paths.

3. Tutorials

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
1. Download the signals
2. Unpack the archive
3. Launch geopsy
4. Load the demo signals
5. Create a table of signals
6. Modify the list of visible fields
7. Extract the component
8. Construct the station names
9. Set station coordinates
10. Creating the database on disk
11. Creating groups
12. Saving changes

3.1 Creating a database


This tutorial helps you constructing the demo database used in tutorials 3.3 and 3.4. It is divided into the
following steps:
1. Download the signals
2. Unpack the archive
3. Launch geopsy
4. Load the demo signals
5. Create a table of signals
6. Modify the list of visible fields
7. Extract the component
8. Construct the station names
9. Set station coordinates
10. Creating the database on disk
11. Creating groups
12. Saving changes

1. Download the signals


Download the raw signals: databasestep0.tar.gz. These signals were generated with HISADA code (Hisada
1994 and 1995) within the framework of the SESAME European Research project (Bonnefoy 2004,
SESAME). The reference model used to generate these signals is detailed in Wathelet 2005 (Model
description).

2. Unpack the archive


Open a terminal and execute the following commands (note: "mwathele@Canucks:~$" is my bash prompt).
Keep this terminal open until the end of this tutorial. Under Windows, doubleclick on the downloaded
archive, and copy directory "geopsy_tutorials" to another location (e.g. "My documents").

3.1 Creating a database

Geopsy manual: content


Unpacking the raw signals and the list of station coordinates
mwathele@Canucks:~$ tar xvfz databasestep0.tar.gz
...

3. Launch geopsy
For Linux or Mac users, it is interesting to start geopsy from the terminal at least once to be familiar with the
output messages or warnings. Otherwise, go to the platform specific menu to start new applications: KDE or
Gnome menus, 'Startup' for Windows,... The exact name of the shortcut depends upon your installation
parameters.
Starting Geopsy's main frame
mwathele@Canucks:~$ geopsy&

Check your configuration, specified in the installation manual, if geopsy fails to start. If it is the first time you
execute geopsy, you should see a splash screen and a first dialog box entitled "Preferences". At this stage,
click on "OK" to accept the default settings.

4. Load the demo signals


Click on menu "File" and select "Load signal" item, or alternatively hit CTRL+l, or click on "Load Files" icon
from the tool bar ( ). Change the current directory to "geopsy_tutorials/raw_signals". Select all files from
"demo_01A.1.sac" to "demo_10A.3.sac" (with mouse and SHIT key). Click on "Load" to proceed with the
loading of files. If you get a dialog box asking for the format, make sure to select "Automatic recognition" and
to unckeck "Show this dialog next time" before clicking on "OK". After a short delay (waiting for the progress
bar at the bottom right to increase up to 100%), the loaded signal should appear on the left in the Files/Groups
list. If not, please refer to the specialised sections or use the search engine of this documentation.
Note: at this stage, the signals are loaded into memory. For the purpose of this tutorial, the components, the
station names, and the coordinates of the stations have been cleared from the SAC headers. Adjusting these
fields is a common task for signals acquired on stations that do not record the information correctly. During
the next step, you will learn how to set these fields in a rational way.

5. Create a table of signals


Select "All signals" in the "Files" list. Drag and drop this item to the "Table" icon from the tool bar ( ). To
drag and drop signals, press the left mouse button on the selected signals move the pointer to the desired
destination, and release the right mouse button. Possible destinations are:
a table ( );
a graphic ( );
a map ( );
any existing viewer already opened in the main frame.
The three first destinations will create new viewers with the selected signals. The last destination will add the
selected signals to the existing viewer. A table should appear with header information of all loaded signals, as
shown in figure 1.

2. Unpack the archive

Geopsy manual: content

Figure 1: Table containing all loaded signals, empty headers.


The headers contain only the basic signal information: sampling frequency and number of samples. Other
fields (such as the component) have been set to default values for all signals.

6. Modify the list of visible fields


Click on menu "View" and select "Set data fields" item. A dialog box as shown in figure 2 lets you modify the
information displayed in the current table.
5. Create a table of signals

10

Geopsy manual: content

Figure 2: Dialog box that lets you modify the information displayed in tables.
In the left column, you have the names of the internal variables. On the right, you have the associated title in
the table. Replace one the useless fields (in this tutorial, e.g. "ID"), by the name of the file ("FILE_NAME").
Make sure (for the next steps) that the fields "NAME", "COMPONENT", "REC_X", "REC_Y", and "REC_Z"
are in the list. Click on "OK" to apply the changes to the current table. The complete names of each signal
should appear in the table.

7. Extract the component


The component is extracted from the signal file names. The components were stored in the file name structure
with a number from 1 to 3, meaning Vertical, North, and East, respectively. Click on menu "Edit" and select
"Set headers" item. A dialog box as shown in figure 3 lets you modify the header information by the means of
a series of user defined equations.

Figure 3: Dialog box that lets you modify header information of each signal contained in the current viewer.

6. Modify the list of visible fields

11

Geopsy manual: content


The white area containing the formulas is empty when you open this dialog box. Modify the fields at the top
to construct the equation:
Equation to extract the component indexes from the file names
name = file name right 5

Click on "Add" to add this equation to the main list.


Alternatively, you can download the file getcomp.formulas to add the equation. Make sure that the list of
equations is empty before loading the file. Click on "Load" and select the downloaded file.

Figure 4: Dialog box that lets you sort the signal in a viewer.
Click on "OK" to apply the equation to the signals of the current table. Sort the signals by "name" to group the
same components together. Click on menu "Edit" and select "Sort" item. A dialog box as shown in figure 4
lets you reorder signals in the current viewer according a series of userdefined criteria. Select a "Signal
name" in the bottom list, click on "Add". If the list of criteria was not empty, first remove all items by clicking
on "Remove". The position within the list is important, the first item is the main sort key. Click on "OK" to
reorder the signals in the current table.
Select all the signals with the name equal to "2.sac". Drag and drop these signals to the table icon ( ). Click
on menu "Edit" and select "Set headers" item to modify the "COMPONENT" field for the signals of the
newly created table. Enter the following equation or load the file setnorth.formulas:
Equation to set component as North
component = & North

Once the components are changed, close the current table and go back to the first table containing all the
signals. The same job must be done for "3.sac" (corresponding to East components). Enter the following
equation or load the file seteast.formulas:
Equation to set component as East
component = & East

The content of the main table is not refreshed after any changes performed in another table. To check the
result, close the main table and create a new one as described here above.

7. Extract the component

12

Geopsy manual: content

8. Construct the station names


Click on menu "Edit" and select "Set headers" item to modify the "NAME" field of all signals. Enter the
following equation or load the file setnames.formulas:
Equations to set the station names
name = & R
name &= file name right 9
name = name left 4

9. Set station coordinates


Click on menu "Edit" and select "Set receivers" item to set the receiver coordinates. A dialog box will display
the list station names with the coordinates X, Y, and Z. Click on "Load" to load the coordinate file
receivers.coord. This operation adds new rows in the station list. The added station names should be identical
to the existing names to overwrite the current coordinates. By clicking on "OK", the coordinates of the signals
are modified. To check them, a map of the station can be viewed be dragging "All signals" to the map icon
(

). The result should look like in figure 5.

8. Construct the station names

13

Geopsy manual: content

Figure 5: Station map

10. Creating the database on disk


Click on menu "File" and select "Create database" item. You will be prompted for a database name. A
directory will be created and information will be saved inside this new directory. Creating a database allows
you to create groups of signals as described in the next step.

9. Set station coordinates

14

Geopsy manual: content

11. Creating groups


Make sure that the map created in step 9 is currently active. Right click in middle of the map to display the
context menu and select "Edit" item or alternatively hit CTRL+SHIFT+e. If no "Edit" item is present in the
context menu it is likely that you right click at the wrong place. Four distinct areas are present on such XY
graph: X axis, Y axis, bottom left corner and the graph's content. A "editing ..." message should appear on the
plot. By pressing mouse left button and moving the pointer, you create virtual rectangles. All stations
coordinates falling inside this rectangle are selected. To unselect all, construct a rectangle with no station
inside. To add new selected station press SHIFT while pressing the mouse.
Three station array can be constructed from the ensemble of stations:
One small circle with stations: R01A to R10A;
Three triangle rotated by 120: R10A, R03A, R06A, R09A, R01B to R08B;
One big circle: R10A, and all stations on the big circle.
Select the stations of one array. The stations must appear in red. Hit CTRL+SHIFT+e to end the editing mode.
Drag and drop the content of the graph to the table icon to create a new table. Click on menu "Edit" and select
"New group" item. Enter a name for the group of signals (e.g. "array_A"). Close the table, and activate the
map again. Go back to editing mode by hitting CTRL+SHIFT+e again. Unselect all stations and select another
array. Other arrays should be named "Array_B" and "Array_C".
For conventional array analysis, the vertical component is often used without the North and East components.
Special groups of signals with only the Vertical components can be created for each array, for instance,
"Array_A Vertical", "Array_B Vertical" and "Array_C Vertical".
Right click on group "Array_A" in the "Groups" list on the left. Select the "Table" item to create a table
containing only this group. Select "Sort" from menu "Edit". "Insert" sort key "Component" to reorder signals
by components. Select only the signals with a Vertical component and drag it to the graphic icon ( ). Click
on menu "Edit" and select "New group" item. Enter a name for the group of signals (e.g. "array_A Vertical").
Close all windows and redo the same task for arrays B and C.

12. Saving changes


Click on menu "File" and select "Save database" item. The groups and any modification to the signals are
saved on the disk.

11. Creating groups

15

Geopsy manual: content


Contents
Previous
Next
Up
Top of page

3.2 Refraction survey


This tutorial helps you interpreting refraction experiments. Currently this feature is in development state. A
first version has been developed with na_viewer but must revised to be integrated into Dinver.

3.2 Refraction survey

16

Geopsy manual: content


Contents
Previous
Next
Up
Top of page

3.3 H/V measurements


This tutorial helps you interpreting single station measurements of ambient vibration with the H/V spectral
method. TODO

3.3 H/V measurements

17

Geopsy manual: content


Contents
Previous
Next
Up
Top of page

3.4 Noise array measurements


This tutorial helps you interpreting multiple station measurements of ambient vibration with the FK and the
SPAC methods. TODO

3.4 Noise array measurements

18

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
A bit of theory
Why creating a database?

4. Database
This chapter explains how to work with a Geopsy Database. Creating a database on the disk is not a
mandatory step. You can use Geopsy to view and to process signals on single file basis. However, you would
miss a number of interesting features such as grouping of signals and automatic storage of modified signals.
This chapter contains the following sections:
4.1. Load signal files
4.2. Create, Open, Close and Save
4.3. Groups of signals
4.4. Preferences
4.5. File structure

A bit of theory: the internal database structure


Geopsy Database is not build on an existing database engine such as MySQL. The database is only made of a
list of signals. A signal is a vector of numbers (double floating point real numbers, 64 bits) documented by a
collection of information fields, typically the information extracted from file headers.
Information fields of a signal
Field name

Type

Description

COMPONENT

string

Name of the component, it must be one of the following


keywords: Vertical, North or East

COUNT2VOLT

double

The conversion factor between 'counts' and 'volts'. 'counts'


are divided by this factor to obtain 'volts'. This value is read
from the majority of signal files. By default this value is 1.0.
When the factor is equal to unity, the amplitude scale of the
signal is automatically considered as counts, else as volts.
This parameter is readonly. Conversions to acceleration,
velocity or displacements are currently not handled. Further
improvements of the database will probably include this
feature with a secondary table containing the responses of
common sensors.

DELTAT

It is the sampling period expressed in period. This


property, as well as SAMPFREQUENCY, can be
double
modified. However, make sure that it corresponds
exactly to the true recording frequency sampling rate.

4. Database

19

Geopsy manual: content

DUPLICATE_RAYS_AVERAGEn double

This parameter is useful for travel time tomography analysis.


n varies from 1 to 10. For phase picking (see PICKn), a
travel time from source to receiver should be equivalent to a
travel time from receiver to source observed on another
signal. Couples of PICKn are identified by a unique
DUPLICATE_RAYS_ID. The average and the standard
deviation for each couple is calculated in
DUPLICATE_RAYS_AVERAGEn and
DUPLICATE_RAYS_STDERRn, respectively. This
parameter is readonly.

DUPLICATE_RAYS_ID

integer

This parameter is useful for traveltime tomography


analysis. Identifies uniquely a couple of signals with the
same ray path, where sources and receivers are just
swapped. This parameter is readonly.

double

This parameter is useful for travel time tomography analysis.


n varies from 1 to 10. See
DUPLICATE_RAYS_AVERAGEn for details.

double

Time elapsed between the first and the last sample of the
signal (in seconds). This parameter is not saved in the
structure but calculated from DELTAT and NSAMPLES.
This parameter is readonly.

END_TIME

double

Time elapsed between the first and the last sample of the
signal (in seconds). This parameter is not saved in the
structure but calculated from DURATION and T0. This
parameter is readonly.

FILE_NAME

string

The complete name of the signal file to which the signal


belongs, including its path. This parameter is readonly.

FILE_NUMBER

The number affected to the signal file to which the signal


integer belongs. This number depends upon the order of loading
files into the database. This parameter is readonly.

ID

integer

Unique number to reference the signal, used by groups.


This value is readonly.

string

Contains "Original" if the signal samples have not been


affected by any signal processing. Otherwise, the field is
blank. See saving a database for details. This value is
readonly.

MAXAMPLITUDE

double

It is the maximum amplitude reached by the signal for the


whole DURATION. The units depends upon the value of
COUNT2VOLTS. Contrary to the other fields, calculating
this value requires the signal samples to be loaded into
memory. Hence using this field may slow down Geopsy. We
advise using it only if necessary. This value is readonly.

NAME

string

Arbitrary name to identify the signal, usually it is set to the


name of the recording station.

DUPLICATE_RAYS_STDERRn

DURATION

ISORIGINALFILE

A bit of theory: the internal database structure

20

Geopsy manual: content

NSAMPLES

The number of samples in the signal. This value is


integer readonly. You can change the length of a signal by
cutting it.

NUMBER_IN_FILE

A signal file may contain various signals. This parameter


integer is this index of this signal in its file. This parameter is
readonly.

double

It is a time value that can be modified by the user, either by


editing the field or by picking phases (with the mouse) on a
graphic representation of the signal. n varies from 1 to 10.
This parameter is useful for travel time tomography analysis,
to define time limits of a taper or of a signal cut, or for any
processing that requires phase picking. Additionally, these
values are frequently used as temporary storage for header
assignations.

PICK_IDn

integer

For each PICKn, an integer value can be affected. Currently,


no processing tool is using these parameters. However, it
may be useful for GRM methods (refraction method to
implement?) where a layer number must be affect to each
PICKn.

REC_X,Y,Z

double

The coordinates of the receiver where the signal was


recorded (Cartesian system expressed in metres).

SAMPFREQUENCY

It is the sampling frequency expressed in Hz. This


parameter is not saved in the structure but calculated
double
from DELTAT. You can modified it, DELTAT is
changed accordingly.

SIGNALPTR

The memory address of the block containing the signal


address information. This parameter is readonly and reserved for
debug purpose.

PICKn

The coordinates of the source for which the signal was


recorded (Cartesian system expressed in metres). These
fields are relevant to records where the source is clearly
identified. It is generally useful for refraction and travel time
tomography analysis.

SRC_X,Y,Z

double

T0

The delay (in seconds) between the time reference and


the first sample of the signal. It can be either positive or
double negative. Various formats are accepted: "ss.ss[...]ss s",
"ss.ss[...]ss", or "hh:mm:ss.ss...ss". For all formats, a ''
sign can be added as a prefix.

TIME_REF

string

It is the time reference with the format "DD/MM/YYYY


hh:mm:ss". All signals recorded synchronously must have
the same time reference. The T0 takes the distinct startup
times into account with an arbitrary precision in the time
scale (time reference is limited to seconds). A good practice
is to set the time reference to the day of acquisition and at

A bit of theory: the internal database structure

21

Geopsy manual: content


midnight (19/05/2005 00:00:00). All T0 are then the number
of seconds since the beginning of the day. The visualisation
modules can handle such time to convert it into "hh:mm:ss"
which corresponds to the true time of measurement.

TYPE

char

It is a single character that records the current type of


signal: 'w' for waveforms, 's' for frequency spectra, and
't' for arrival time without signal. The type is readonly,
you cannot modify it directly. Conversion from 'w' to 's'
and viceversa is done after a Fourier transform.

Notes: "double" means double floating point real numbers coded on 64 bits, "integer" means a positive or
negative integer, "string" means any string of characters, and "char" is a single character. The fields marked in
bold represent the most important parameters that must be correctly defined to allow a visualisation of the
signal.
When a new signal file is loaded into the database, a new memory structure is allocated for the signal and the
fields listed above are filled in from the information contained in the file header. The information extracted
from the file header depends upon the file format (see Load signal files).
The signal samples are never directly read on opening a file which greatly speeds up the signal handling for
the user comfort. According to the user actions (e.g. visualisation of traces), it might be necessary to load the
samples into memory. In Geopsy core engine (library geopsycore), a special mechanism has been developed
to cache the signal vectors (keep signals in memory as long as possible until no space is left, then purge
rationally according to space needed). From the user point of view, it might be noticed that the first time a
signal is visualised, it may be slower than for any later access.
Any subset of the total ensemble of signals can be created. The information is never duplicated because subset
are defined by pointers to the original signal structures. The subsets are visualised through tables, graphics and
maps detailed in other sections.

Why creating a database on disk?


The various signal file formats available in seismology and geophysical prospecting generally include a
header which contain heterogeneous information. There was a need to store in a uniform format basic
information useful for the data processing implemented in Geopsy (e.g. picks of events, source and receiver
coordinates, ...).
Some signal file formats can store various signals in a single file, others not. Signal processing, such as array
computations, may be applied to only a part of a file or to signals located in various files. There was a need for
grouping signals independently of the original file organisation. Exporting signals of interest to a temporary
file before processing is not a satisfactory way of doing things because it duplicates the data on disk and there
is a risk of altering information from the file conversion. Furthermore, confusion is likely to occur between
true original signals and preprocessed signals (e.g. filtering, DC removal, ...).
Geopsy proposes an alternative with the concept of groups. A group is a list of signal ID (identification
number). A name is given to each group which explains its content. The ID are automatically affected to each
signal when loading files into Geopsy. Hence, the affectation depends upon the order of loading files. The
database concept ensures that all files are loaded in the same order each time the signals are accessed, and
consequently, that each ID effectively corresponds to a unique and well defined signal.

Why creating a database on disk?

22

Geopsy manual: content


External signal processing tools (e.g. command line softwares like Cap) can access a geopsy database to
retrieve the signals of interest. The ensemble of signals is generally referenced by the name of a group
previously created in Geopsy's main frame. The command line tools have access to the signal samples with no
care about the original file format. The geopsy core engine handles all file access and memory allocations to
ease the development of processing tools based on signals.
Each time a command line tool is started with access to a Geopsy database all the header information is
loaded into memory. This step is only based on the database's internal files. There is no access to the original
file which ensures a very quick startup of any database even if it contains a lot of signals (thousands). First
versions of Geopsy required reading of file headers which is sometimes long (e.g. GSE format with multiple
signals in a file).
The file structure of a Geopsy database is described in section File structure.

Why creating a database on disk?

23

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
How to load a file?
Selecting the file format
Automatic recognition
Database signals
Binary SEG2
Seismic Unix
Arrival times
RD3 RAMAC
NiSismo
SAC
Radan GSSI
GSE
CityShark
ASCII Multi column
SESAME SAF
Sismalp
Wave PCM
Formats not supported
Removing a file

4.1 Load signal files


This section explains how to load signal files into Geopsy and which file format are currently supported.

How to load a file?

4.1 Load signal files

24

Geopsy manual: content

Figure 1: "Files" list after loading several signal files.


Click on menu "File" and select "Load signal" item, or alternatively hit CTRL+l or the "Load signals" icon in
the tool bar. You get the open file dialog box where you can select one or more files to open. Use the SHIFT
and CTRL keys to create custom selections. Click on "Load" to proceed with the loading of files. All the
loaded files appear in the file list as shown in figure 1. This list contains all currently loaded files. File paths
are prefixed with base name of the file. According to the current preferences, the signals may be directly
displayed in a table or in a graphic, or you can get the file format dialog box as shown in section Selecting the
file format.
If the list does not appear, it is likely that it has been hidden by previous use of Geopsy. Select "Files and
groups" in menu "Windows" to show the list. The list can be moved to any part of the screen by pressing the
mouse in its title bar and dragging it to the desired position. In the vicinity of the left and the right border of
the main frame, the list is automatically docked to the main frame, otherwise it has a free position and size.
Moving the mouse the edges of the list, the shape of the cursor is changed to a double arrow, any press and
drag of the mouse will resize the list. The same behaviour occurs at the limit between the "Files" and
"Groups" lists.

Selecting the file format

How to load a file?

25

Geopsy manual: content

Figure 2: Preferences for file format selection.

Figure 3: Manual selection of file format.


In most situation, the automatic format determination does a good job. If you want to specify manually the
format, you have to edit the preferences. Click on menu "File" and select "Preferences" item, or alternatively
hit CTRL+p. In the preference dialog box, click on the "Loading files" tab. You get the screen shown in figure
2.
Select "Always ask for file format" to manually specify the file format for all loaded file. If "Use this format"
is selected, the format specified on the right is always used. "Automatic recognition" is the default and
probably the best option.
Before loading each file, you are asked to specify the file format with the dialog box shown in figure 3. If all
the selected files have the same format, you can uncheck the checkbox "Show this dialog next time". Choose
the right format in the list. Once the list is displayed after a mouse click on it, you can hit initial letters to
quickly scroll to the right format. Selecting a wrong format is generally reported, but, in some situations, it
may read erroneous information without reporting error.

Automatic recognition
The table here below gives the criteria used to recognise the file formats. The conditions are processed in
order from the first to the last row. At the first match, the format is considered to be recognised.

Selecting the file format

26

Geopsy manual: content


Conditions for recognising file formats
Conditions

File formats

file extension is ".su"

SU big endian. Currently, no automatic detection of the byte order has been
implemented for SU format. For SU little endian, the manual file format
selection is necessary.

file extension is ".rd3"

RAMAC/RD3 format for RAMAC Ground Penetrating Radar

file extension is ".dzt"

Radan format for GSSI Ground Penetrating Radar

file extension is ".ndx" or


".sis"

Sismalp format, a ".sis" or ".ndx" (and viceversa) must also exists in the
same directory.

file extension is ".wav"

Wave PCM sound file, just for fun to analyse your favourite music albums.

First line contains


"Arrival_times_file"

Arrival times format

First 16 bits are 0x 55 3A

Binary SEG2 file

First 32 bits are 0x 66 5F 9C


6E

NiSismo file format ???

First 4 characters are


"WID2"

GSE2 format, test by default for multiple signals in the file. This option may
take some time for long signals. If there are only one signal per file, select
manually "GSE2 Single Signal".

First line begins with


"Original file name"

City shark 2 file. No distinction between format 1 and 2, both are accepted.

First 10 bytes begins with


"DBSignals"

Geopsy database signals.

First line begins with


"SESAME ASCII data
format (saf) v. 1"

SESAME ASCII File format

First 4 characters are "RIFF"

Wave PCM sound file, just for fun to analyse your favourite music albums.

First field (TAB or SPC) is a


number

ASCII file, one column per signal.

NVHDR==6, IFTYPE=1 and


SAC format. The big and little endian are automatically recognised.
LEVEN is true
else

Error message, unknown format.

Database signals
It is the format used by Geopsy to automatically save modified signals. Usually you never import original
signals written under this format. This new format has been introduced in Geopsy because it is the closer to
internal memory vectors, hence I/O access are optimised.
Geopsy database signal format

Automatic recognition

27

Geopsy manual: content


Offset (bytes) Size (bytes) Description
0

10

Recognition tag: "DBSignals"

10

Version, current is 1

14

Offset to first signal in file (bytes)

18

Number of signals in file (n)

22

4*n

Number of samples in each signal (nsamp[i], 0<=i<n)

22+4*n

8*n

Conversion factor for each signal

22+12*n

nsamp[i]

For each signal (0<=i<n), the samples coded on 64 bits floating point
numbers.

Binary SEG2
This file format is described in ...???(text of the norm). It is the usual format acquired with Geometrics
instruments.

Seismic Unix
Arrival times
RD3 RAMAC
NiSismo
SAC
Radan GSSI
GSE
CityShark
ASCII Multi column
SESAME SAF
Sismalp

Database signals

28

Geopsy manual: content

Wave PCM
Formats not supported
SEGY and other instrument specific formats should be implemented as soon as possible.

Removing a file
To remove a file from the database or from the "Files" list, select "Remove" from the context menu in "Files"
list. Multiple and complex selections (SHIFT and CTRL) can be used to remove several files at the same time.
If the removed files are original files, the signal file is unaffected, only the information stored in the database
is irreversibly lost. In the other case (modified files), the signal is removed from the database directory and the
information about these signals is also lost.

Wave PCM

29

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
Creating a database
Opening a database
Closing a database
Saving a database

4.2 Create, Open, Close and Save database


This section explains how to create, to open, to close and to save a Geopsy database. The concept of a Geopsy
database has been presented in section Database.

Creating a database on disk


First load the original signal files as described in section Load signal files to create the database in memory.
Click on menu "File" and select "Create database". You will be prompted for a directory name and path with
the common file dialog box. The name of the directory is the name of the database. On clicking on "Save",
Geopsy will create the directory and it will store all files as described in section File structure.
If some signals were modified with any processing tools (Basic signal processing), the corresponding files are
saved in the same way as Saving a database.

Opening an existing database


This operation requires that no signals are loaded in the current database. Click on menu "File" and select
"Open database". Alternatively, you can click on the "Open database" icon from the tool bar ( ). The open
file dialog box lets you select the appropriate database (".sdb" files). On clicking on "Open", the files are
loaded into memory as well as the groups previously defined.
The ".sdb" file contains the absolute file paths of all original files to open. If the location of these files changes
(directories or files renamed), a warning will be issued as shown in figure 1.

Figure 1: Warning issued when signal files cannot be found.


If you want to skip the file not found, just hit "Yes". Be careful that on the next "Save database" the file will
be permanently removed from the database (not removed from the disk). If the file still exists but has been
4.2 Create, Open, Close and Save database

30

Geopsy manual: content


moved to another location, hit "No". You will be prompted to enter the new path to this file with the classical
open file dialog box. A path translator is automatically constructed to avoid repetitive warnings. You must hit
"Save database" once to store the new paths into the ".sdb" file. "Cancel" just stops the database opening, all
other signal files are skipped.

Closing a database
Right click in "Files" list, the context menu shown in figure 2 will appear. Select "Clear all". You will be
prompted for closing all active viewers. This is normal because viewers have references to signals that will be
removed by this action. If header information or signals were modified, you will be asked to save the database
first.

Figure 2: Context menu of "Files" list.


If no named database was opened, but signal files were loaded individually, this operation clears all signals
from memory but without offering the option to save changes.

Saving a database on disk


This operation requires that a database has been created or opened. Click on menu "File" and select "Save
Opening an existing database

31

Geopsy manual: content


database". Alternatively, you can click on the "Save database" icon from the tool bar ( ). The changes
brought to the header information and any new signals added to the database are saved in the ".sdb" file. The
original signal files are left untouched.
If the samples of some signals were modified by any processing tools (Basic signal processing), the signals
are saved in a Geopsy Database binary format in the database directory. The name is identical to the original
file plus "_n" where n is chosen to avoid any overwriting of exiting files. The newly generated files are added
to the database as usual files. A flag (ISORIGINALFILE) allows the user to distinguish between original and
modified signals.

Saving a database on disk

32

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
Selecting signals
Sorting signals
Creating a new group
Viewing groups
Renaming a group
Modifying a group
Deleting groups

4.3 Groups of signals


This section explains how to create and to use groups of signals. Groups of signals can be created only within
the framework of a database. When files are loaded individually this operation is not permitted. The reasons
for using groups are explained here. Groups are simply lists of signals referenced by their unique signal ID.
The original order of signals at the group creation is always preserved. This section presents also the "drag
and drop" mechanism used to associate signals.
Groups are saved in the database directory under files named ".group". These are binary files with the list of
signal IDs. The list of groups is stored in the file ".grouplist". Only one exists per database. The files are
modified or created only when the database is saved (see 4.2. Create, Open, Close and Save).

Selecting signals
As detailed in section Signal viewers, they are three ways of viewing signals: tables, graphics and maps. Each
viewer is associated with a sub set of signals. Here, we use the "table" viewer to explain the "drag and drop"
mechanism. The specificities of the "drag and drop" for each viewer are explained in section Signal viewers.
You can select the signals on a file basis with the "Files" list, or on a group basis with the "Groups" list. In
both cases, press SHIFT or CTRL key to create complex selections. "All files" and "All groups" represent all
signals (except the temporary signals, see Basic signal processing) and the union of all groups, respectively.
Press the mouse left button on the selection and move the pointer towards a viewer icon in the tool bar (e.g.
the table icon is

). Release the mouse button, a table will be created containing the selected signals.

In a table, you can select various signals with SHIFT and CTRL keys. Press the mouse left button on a
selected row and move the pointer again to the table icon. A new table is created with the restricted selection.
A signal may appear several times in a single viewer. You can drop signals into an existing table, the new
signals will be added at the end.

Sorting signals
To select signals, it may be interesting to sort the list of signals. For instance, if you want to select all the
signals measured on the vertical component, first create a table with all signals. Sort the signals by component
and select the block of signals with the vertical component.

4.3 Groups of signals

33

Geopsy manual: content

Figure 1: Dialog box that lets you sort the signal in a viewer.
Sorting can be done in the active viewer by selecting item "Sort" in menu "Edit". The "Edit" menu always
apply to all signals of the active viewer. A dialog box as shown in figure 1 will be displayed.
The selected keys are listed in the twocolumn table (Key and Order). Available keys are listed in the combo
box at the bottom. Check or uncheck the "Descending order" checkbox as necessary and click on "Add"
button to add a key to the sort. To use "Delete" or "Insert", you must select one row of the table. "Insert" will
insert the new key right before the selected key. Hit "Delete" several times to remove all keys. After clicking
on "OK", the list of keys are stored and the signals of the active viewer are sorted.
Though multiple keys of the same kind are possible, it is totally useless. Moreover, using multiple keys has an
effect only when there are equal values in the first keys.

Creating a new group


There must be an active viewer. If it is not the case, create one as described in the preceding sections. Select
item "New group" from menu "Edit". A simple dialog box lets you enter a name for the group. All types of
names are accepted (blanks, accents, ...). If the name of the group already exists in the database, you will be
prompted to overwrite the existing one. The new group is added to the "Groups" list. The ".group" file
containing the list of IDs is directly written to the disk. However, the ".grouplist" file will be effectively
written on the disk once the database is saved.

Viewing groups
Groups are manipulated in the same way as files with the drag and drop mechanism described here above.

Renaming a group
Select only one group (not the first one "All groups"). Click on the right mouse button. In the context menu
select "Rename". Type the new name in the simple dialog box and hit "OK". The ".group" file corresponding
to the group is directly renamed, but the ".grouplist" file is not affected. Do not forget to save the database to
Sorting signals

34

Geopsy manual: content


avoid any loss of the ID list belonging to this group. This situation may be repaired by renaming manually the
".group" file to its original name.

Modifying a group
Create a viewer (e.g. a table) with the group. Modify its content (sorting, adding new signals, ...). Select "New
group" in menu "Edit" and enter the name of the existing group. The original group will be overwritten.
Saving the database in this case is not necessary but strongly advised to avoid confusions with the other
actions.

Deleting groups
Select one of more groups and choose "Remove" from the context menu (after a right click in the "Groups"
list"). ".group" files are directly removed from the database directory, hence this action cannot be cancelled.
Saving the database is mandatory if you do not want to pollute the "Groups" list with empty defunct groups.

Renaming a group

35

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
Preferences dialog box
Loading files
Memory
Table
Tools
H/V
Directory paths
Storage of settings

4.4 Preferences
This section explains how to configure geopsy. Various settings can be adjusted within the graphical user
interface. This section also explains how to deal with directory paths that are automatically saved during your
work. For advanced users, the way the options are saved and how to change them are detailed.

Preferences dialog box


The preference dialog box is automatically displayed at startup when geopsy is installed on a new machine.
The defaults option values are usually valid for a majority of users. However, in certain circumstances or if
you want to optimise your work with geopsy, it may be interesting to change these options. Select item
"Preferences" from menu "File" (under Mac this item is under the Apple menu). The preference dialog box,
shown in figure 1 to 5, contains several independent tabs explained here after.

Loading files

4.4 Preferences

36

Geopsy manual: content

Figure 1: Tab for changing the "Loading files" options.


These options apply to the loading of new files into the database (item "Load file" from menu "File").
File format
There are two exclusive options: either ask for the file format interactively or always use a given file format.
"Automatic recognition" does not specify any special format but lets the automatic format recognition
algorithm select the right formats of files. The rules for selecting formats are presented in section Automatic
recognition. The default and mostly used option is the one presented in figure 1.
Time reference
The definition of the time reference is given in Database section. Either you can set the time reference
interactively for each file ("Always ask ...") or you can skip this step. If not set interactively, the time
reference is automatically deduced from the information contained in header files. However, not all file
formats have this kind of information available. The recording startup time, read until the seconds, is
considered as the time reference. The remaining milliseconds are added to T0.

Loading files

37

Geopsy manual: content


For signals recorded simultaneously but with distinct startup times (e.g. the time needed to manually start the
recordings of stations synchronised by GPS), the time reference must identical for all stations. Hence, it is
mandatory to force the time or eventually the date to a common reference. If all the signals were started the
same day, you can use the default, shown in figure 1. The reference is set at midnight, and T0 is the number of
seconds since midnight (including milli or micro seconds). If synchronous signals are distributed over several
days, it is mandatory to force the date as well. Thus, you must edit this preference before loading the files for
the first time.
Changing the time reference afterwards, once the signals are loaded, is possible but not strongly advised.
Actually, when loading the files, T0 are automatically calculated from the true time of measurement and from
the deduced or forced reference time. When editing the time reference in the database, T0 are left unchanged
and it may lead to errors in signal synchronisations. We would recommend to edit the time reference only in a
table containing all synchronous signals.
Viewing signals after loading
For some applications, especially if no database is created (single files mode), it may be appreciated to display
a table or a graphic of the signals directly after loading the files. You can choose to open a table or a graphic,
or both. A single window summarising all files or one window per file may be created. This action can be
performed only if less a certain number of files are opened together. To suppress all viewers after loading
files, uncheck the checkbox "Do it only if less than".
Signal names
Names of signals are most of the time set to the name of station specified in file headers. If you do not want to
extract this name and to leave the names as blank, uncheck the option "Use station names ...". For some
interpretation tools, such as H/V, if the signal names are blank the signals are referenced by their file names.
In some cases (e.g. when loading files from CityShark 2), it may be interesting to automatically name the
signals R001, R002,... For all file formats except CityShark, the index is the index of signal inside the file. For
CityShark format with more than 3 channels, it is assumed that threecomponent sensors are used.

Memory

Time reference

38

Geopsy manual: content

Figure 2: Tab for changing the "Memory" options.


Geopsy is built upon a powerful mechanism for allocating memory for signal vectors. With this system, it is
possible to view many signals over long periods at the same time. The program almost never ends with
memory full errors, as a specific internal swap system ensures that the memory usage is limited. The size of
this maximum is specified here. This is not a static memory allocation, hence, most of the time this amount of
memory space is never used. However, for some computations, huge amounts of memory may be necessary
(e.g. SPAC for long signals) and signals are efficiently swapped to the disk (either to the system temporary
directory or to the database directory if the current user has write permissions).
The default value is 256 Mbytes which allows reasonable computations to be executed without swapping.
However, to avoid swap and to speed up computations, it is better to exploit all resources of your computer.
The best performances are obtained when the maximum memory size is a bit lower than the true physical
memory size. In the case presented in figure 2, the true physical memory is 1 GBytes. Setting something
greater than the physical memory is possible (if your operating system supports swap memory) but inefficient.
Experience has proved that the system swap is less efficient that geopsy internal swap (the priority of memory
blocks are set by the running process as a function of the future usage of the memory, not the case for system
swap).

Memory

39

Geopsy manual: content

Table

Figure 3: Tab for changing the "Table" options.


This tab specify the information to display in all new tables. Each data field correspond to one column in the
tables. In the left column ("Data field"), the names of the internal variables chosen for display are listed.
These internal variables are described here. On the right column ("Title"), the associated titles in the tables are
listed. A default title is defined for all variable. You can change it to your convenience.
New data fields can be added by clicking on "Add". It will be added at the end of the list. If one item in the
list is selected, a new data field can be inserted ("Insert") before the current data field or it can be deleted
("Remove"). The "Default" button reset to the original default configuration.
Currently, there is no system to save/restore typical or user defined configurations. However, if you are
working under Linux, you can save and restore table configuration by editing the setting file in your home
directory. On other platforms, like Windows, you have to edit the registry with "regedt32"
(CURRENT_USER/Softwares/geopsy). Make sure that there is no running Geopsy. Open the file
"$HOME/.qt/geopsyrc" with your favourite editor (vi, kwrite, nedit,...). Search for "[TableFields]", you will
probably find two lines like these ones:
Table

40

Geopsy manual: content


ids=0^e10^e59^e55^e1^e58^e62^e2^e3^e57^e4^e5^e6^e7^e8^e9^e11^e
titles=ID^eName^eComponent^eTime reference^eSignal start^eSignal [...]

To save the current configuration, copy these lines to another text file for backup. Modify the configuration
with the Preferences dialog box. To restore the old settings, close all instances of geopsy, open the setting file
again and replace the lines "ids=..." and "titles=..." by the lines you saved. The reason for closing geopsy
before writing to the setting file is that the file is updated by geopsy on closing and it may overwrite your
changes.

Tools

Figure 4: Tab for changing the "Tools" options.


This tab helps you configuring the "Tools" menu. "Tools" menu lets you start specific processing tools
developed as plugins. Plugins are dynamic libraries containing executable code that can be added to geopsy
without recompiling the core program. The available tools that are listed in "Tools" menu are managed in this
tab. The "Tools" menu is replicated in the context menu displayed when clicking on the mouse right button in
the "Files" and "Groups" lists.

Tools

41

Geopsy manual: content


To add a new tool, you first have to download and to install the corresponding library on your computer. The
location of the library in the file hierarchy is arbitrary. Click on "Add tool", you will be prompted to select the
file (and its path) of the library (extension is ".so", ".dylib", and ".dll" for Linux, Mac OS X, and Windows,
respectively). The library name will be added at the end of the list. If the library can be opened and if it
contains the correct interface functions to dialog with geopsy core, a green light is displayed on the left. If the
light is orange, it means that the library can be loaded but no correct dialog can be establish with geopsy core.
Either, this library is using an old version of the geopsy plugin interface or you are trying to add a library
that is not a geopsy plugin. In the first case, update geopsy or try to find the right version of the tool. If the
light is red, there is problem loading the library (access permissions, disk error, ...).
To remove a tool, select it and click on "Remove". You can rearrange the tools by selecting one and by
moving upwards or downwards ("Up" or "Down" arrows). You can also add separators (horizontal lines in
menus) to better separate categories of tools. Any change to the tool list will be effective for next geopsy
startup.

H/V

Figure 5: Tab for changing the "H/V" options.


This tab is present only if you add the "H/V" tool (see preceding section). It lets you configure the graphical
outputs. The "H/V" tool produces basically two kinds of graphical outputs: H/V spectra and component
H/V

42

Geopsy manual: content


spectra. You can select both, only one of them or none of them. These graphical outputs contains XY plots
with various layers (see scifigs documentation for details). For each plot, you can select which layer you want
to see. These options are detailed in the H/V tools specific section.

Directory paths
Each time you select a file to open or to save, geopsy automatically stores the path of the selected file. The
next time you will open or save the same type of file, the dialog box will start on this directory avoiding
fastidious clicks to move from your home or your "My Documents" directory to your working directory.
Furthermore, every visited directory for this type of files is stored in the combobox at the top of the dialog box
(figure 6). You can them quickly jump to a frequently used directory.

Figure 6: Quickly jumping to frequently used directories in the file dialog box.
Within the context shown in figure 6, if the current project you are working on is located in
"/data/belgium_march02/baviere", all paths to load or save files (database, signals, formulas, ...) will begin
with "/data/belgium_march02/baviere". If you want to switch to another project located, for instance, in
"/data/M2/", you can modify the stored paths in a single click by using projectpath utility.

Directory paths

43

Geopsy manual: content

Figure 7: projectpath interface to change current directories.


projectpath is an external program usually distributed with geopsy. Follow the instructions here to download
and install it if not available on your machine. Once installed, start the software with a doubleclick or by
launching the command "projectpath&" from a terminal. You will see a window like the one shown in figure
7. Add paths to the list of projects by clicking on "New path". When you click on "Set current", all root paths
displayed in this list are searched in your stored paths and they are replaced by the selected path ("/data/M2"
in the example of figure 7).
Furthermore, if you are using exactly the same directory structure for all your projects (e.g. "db/" for geopsy
database, "fk/" for results of FK processing, "map/" for all localisations stuffs, ...), projectpath will change
only the root of the stored paths. In our example, if "/data/belgium_march02/baviere/db" was stored as the
current directory for loading databases, and if "/data/M2/db" exists, the current path for opening new
databases is changed to "/data/M2/db". If "/data/M2/db" does not exist, the current path is changed to
"/data/M2/".

Storage of settings
The default values appearing in dialog boxes displayed by geopsy are always equal to the preceding values set
by the user for these items. These values are stored in the same file (for Linux users) as fields of tables,
"$HOME/.qt/geopsyrc", under the label "[DialogOptions]". If you want to remove all user settings and return
to the original default, close all instances of geopsy and remove all entries under "[DialogOptions]".
Removing the file "$HOME/.qt/geopsyrc" has the same effect but also resets other stored settings. Under
Windows, the same reset can be done by removing key entries in the registry (with regedt32, key
"CURRENT_USER/Softwares/geopsy").

Storage of settings

44

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
".sdb" file
".grouplist" file
".group" files
".sig" files
"_n" files

4.5. File structure


This section details how a database described in section Database is saved on a file system (e.g. disks, usb
flash cards, ...). The database is saved a defined directory containing three kinds of basic files: ".sdb",
".group", and ".grouplist". Other files are also saved in this directory: modified signals (see
ISORIGINALFILE) and temporary swap files.
In the following, the database name is supposed to be "db". Hence the directory containing the database is
"db/" and the ".sdb" file is "db/db.sdb".

".sdb" file
This is a text file containing one value per line, with the following syntax.
Syntax of lines for the ".sdb" file
KEYWORD=VALUE

KEYWORD is case sensitive and it cannot contain any '=' sign. Blanks are not accepted before the
KEYWORD and around the '=' sign. The VALUE on the right can contain any characters including blanks.
The order of KEYWORDs is strict. The first line of the file is the version of the format. Currently, version is
2. The file contains a list of signals grouped by file. The general structure is:
General structure of ".sdb" file
version 2
FILE=/absolute/file/path/and/file/name/of/first/signal/file
FORMAT=7
ISORIGINALFILE=1
ID=1
... specific information about first signal
ID=2
... specific information about second signal
...
ID=n
... specific information about signal n
FILE=/absolute/file/path/and/file/name/of/second/signal/file
FORMAT=8
ISORIGINALFILE=1
ID=n+1
... specific information about first signal

4.5. File structure

45

Geopsy manual: content


ID=n+2
... specific information about second signal
...

The information about each signal contains the following keywords (the order is strict):
Information about each signal
ID=1
NAME=R01A
COMPONENT=0
T0=0
TIME REF=01/01/2003 00:00:00
DELTA T=0.00875
TYPE=0
PICK 1=102.688
PICK 2=298.102
PICK 3=0
PICK 4=0
PICK 5=0
PICK 6=0
PICK 7=0
PICK 8=0
PICK 9=0
PICK 10=0
PICK ID 1=1
PICK ID 2=0
PICK ID 3=0
PICK ID 4=0
PICK ID 5=0
PICK ID 6=0
PICK ID 7=0
PICK ID 8=0
PICK ID 9=0
PICK ID 10=0
RECEIVER=1988 2002 0
SOURCE=0 0 0

The number of signals in each file specified in "db.sdb" must be equal to the real number of signals stored in
the signal file. On opening a database, the signal files are not checked. Though a database may be created
outside geopsy, this method is not advised and may lead to unstable behaviours. However, the original files
are never modified and the ".sdb" is written only when choosing "Save database" from menu "File", hence
there is absolutely no risk to corrupt the original information.

".grouplist" file
There is only one ".grouplist" file per database. It contains the list of groups referenced by their names. Each
characters is coded on 16 bits which forbid its modification with any text editor. Under Linux, you can
visualise this file with bvi or with kwrite (set encoding to UTF16). The binary format depends upon the export
format of QStringList. The first 32 bits is the number of groups. Then, each name is stored with a first 32 bits
for the string length and the characters coded on 16 bits.

".group" files
This is a binary file that contains the list signal IDs belonging to the group. The format is very simple: a list of
integers (32 bits). The base name of these files is the group's name. Under Linux, you can visualise this file
with bvi.
".sdb" file

46

Geopsy manual: content

".sig" files
When geopsy is running low on memory space, it may be forced to swap signal vectors to the disk. If the
current user have sufficient permissions in the database directory, temporary files are written in this directory.
When no instance of geopsy is running, none of these files must exist. In case of crash, it may be possible that
some of these file were not correctly cleared. You can remove all of them without any consequences assuming
that no database is currently running.

"_n" files
When saving a database, the modified signals are automatically saved to the database directory. These files
have the same names as their original files with a suffix "_n", n being a unique number. Do not remove these
files manually. You can remove these files by removing their entries in the database.

".sig" files

47

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
File export
Waveform
Tools
"Edit" menu
Sorting signals
Editing headers
Editing receivers
Creating new groups

5. Viewers
Any subset of the total ensemble of opened signals can be created with the "drag and drop" mechanism
explained in section Selecting signals. The subsets are visualised through tables, graphics and maps detailed in
this chapter:
5.1. Table
5.2. Graphic
5.3. Map
The various actions that can be performed with a subset of signals (either a table, a graphic or a map) are
described here after.

File export
Select item "Export" from menu "File". You will be prompted to select the file format. Various formats are
currently proposed:
SEG2
SAC: little or big endian
SU: little or big endian
ASCII: one or multi columns
Surf: surfacewave inversion from R. Herrmann
SAF: Sesame ASCII file format
WAV: PCM sound file, to create sound from seismic signals (generally requires a strong modification
of the sampling frequency: 44 kHz for usual music records).
Not all these formats support multiple signals in a single file. If those case you will be prompted to select an
export directory or to enter the names manually.

Waveform
Basic signal processing can be performed on all the signals of the active viewer. These processing are
gathered in menu "Waveform". For details, refers to chapter Basic signal processing.

5. Viewers

48

Geopsy manual: content

Tools
Tools are developed as plugins and provide specific signal processing (menu "Tools"). As for basic signal
processing, the selected tool is applied to the signals of the active viewer. For details, refers to chapter
Specific processing tools.

"Edit" menu
All menu items in "Edit" menu apply to all signals contained in the active viewer.

Sorting signals
This feature is explained in section Sorting signals.

Editing headers
This feature helps you modify the header information by the means of generic formulas.

Editing receivers
This feature helps you modify the coordinates of receivers. The signal names are considered as names of
stations to which corresponds only one unique set of coordinates.

Creating new groups


This feature is explained in section Creating a new group.

Tools

49

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
Signal selection
Cell editing
Export
Import

5.1. Table
Basically, a table allows you to view and to edit the header information about signals. Each row represents a
signal and each column is an information field. The order and the list of displayed fields is specified by the
table preferences for all newly created table. You can also change the displayed information for the active
table only by selecting item "Set data fields" from menu "View". Columns and rows can be resized (press
mouse at the limit between two columns or cells). However, automatic resizing is usually correct.

Signal selection
Signals are selected with the mouse left button. If the SHIFT key is also pressed the selection is extended from
the current row to the selected row. If the CTRL key is pressed at the same time as the mouse left button, the
selected row is added to the selection and become the current row. The current row contains the active cell.
Pressing the mouse left button on any selected row and moving the pointer initialise the drag and drop
mechanism marked by a modified mouse cursor. A circle crossed by a line means that the signals cannot be
dropped at this place. When it changes to a plus sign, the mouse left button can be released to drop the signals
to the destination (an existing viewer or the icons of viewers:

).

Cell editing
To edit the contents of a cell, doubleclick on it and modify the value. The signal internal structure is
automatically modified. However, if other tables are opened and if they also contains the modified signal, the
changes are not updated automatically. To update them, select one of them and choose "Refresh now" from
menu "View", or alternatively type CTRL+r.
You can edit any cells, but some of them are linked to readonly fields (e.g. NSAMPLES, the number of
samples). Error messages are displayed in those cases and the edition has no consequences.

Export
Copy and paste action are not possible like in common tabular softwares. However, it is possible to export the
information contained in a table to a text file (column separated by TABs) which can be in turn loaded in any
usually tabular software. The file can be edited and imported in the table to apply the changes. The same
restrictions as when editing readonly cells individually apply.
To export a table, select "Export" from menu "File". A combobox lets you select the export format. Select the
last one ("Table"). The resampling parameter is ignored. Enter the file name to export. A default extension
5.1. Table

50

Geopsy manual: content


(".txt") is provided for compatibility with usual tabular software. Comment are marked with '%' at the
beginning of lines. Not all fields attached to a signal are exported but only the fields displayed in the active
table. The list of fields is given by field IDs separated by TABs (not to be confused with signals IDs) in the
first uncommented line.
Example of a file exported from a table
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%
%

This file contains all the variables that were listed in Geopsy's Table
You can edit this file as you want. The names of columns appear here only
for readability. All columns must be separated by only one tabulation.
Lines starting with "%" are always ignored when importing. The first line
starting without "%" must contains the ID of each variable. Those IDs are
listed below: (variables marked with * could not be changed by the user)
ID_VAR_ID*
= 0
ID_VAR_T0
= 1
ID_VAR_DELTAT*
= 2
ID_VAR_NSAMPLE*
= 3
ID_VAR_REC_X
= 4
ID_VAR_REC_Y
= 5
ID_VAR_REC_Z
= 6
ID_VAR_SRC_X
= 7
ID_VAR_SRC_Y
= 8
ID_VAR_SRC_Z
= 9
ID_VAR_NAME
= 10
ID_VAR_TYPE*
= 11
ID_VAR_PICK1
= 12
ID_VAR_PICK2
= 13
ID_VAR_PICK3
= 14
ID_VAR_PICK4
= 15
ID_VAR_PICK5
= 16
ID_VAR_PICK6
= 17
ID_VAR_PICK7
= 18
ID_VAR_PICK8
= 19
ID_VAR_PICK9
= 20
ID_VAR_PICK10
= 21
ID_VAR_PICK_ID1
= 22
ID_VAR_PICK_ID2
= 23
ID_VAR_PICK_ID3
= 24
ID_VAR_PICK_ID4
= 25
ID_VAR_PICK_ID5
= 26
ID_VAR_PICK_ID6
= 27
ID_VAR_PICK_ID7
= 28
ID_VAR_PICK_ID8
= 29
ID_VAR_PICK_ID9
= 30
ID_VAR_PICK_ID10
= 31
ID_VAR_FILE_NUMBER*
= 32
ID_VAR_NUMBER_IN_FILE*
= 33
ID_VAR_DUPLICATE_RAYS_ID*
= 34
ID_VAR_DUPLICATE_RAYS_AVERAGE1* = 35
ID_VAR_DUPLICATE_RAYS_AVERAGE2* = 36
ID_VAR_DUPLICATE_RAYS_AVERAGE3* = 37
ID_VAR_DUPLICATE_RAYS_AVERAGE4* = 38
ID_VAR_DUPLICATE_RAYS_AVERAGE5* = 39
ID_VAR_DUPLICATE_RAYS_AVERAGE6* = 40
ID_VAR_DUPLICATE_RAYS_AVERAGE7* = 41
ID_VAR_DUPLICATE_RAYS_AVERAGE8* = 42
ID_VAR_DUPLICATE_RAYS_AVERAGE9* = 43
ID_VAR_DUPLICATE_RAYS_AVERAGE10* = 44
ID_VAR_DUPLICATE_RAYS_STDERR1*
= 45
ID_VAR_DUPLICATE_RAYS_STDERR2*
= 46
ID_VAR_DUPLICATE_RAYS_STDERR3*
= 47
ID_VAR_DUPLICATE_RAYS_STDERR4*
= 48

Export

51

Geopsy manual: content


% ID_VAR_DUPLICATE_RAYS_STDERR5*
= 49
% ID_VAR_DUPLICATE_RAYS_STDERR6*
= 50
% ID_VAR_DUPLICATE_RAYS_STDERR7*
= 51
% ID_VAR_DUPLICATE_RAYS_STDERR8*
= 52
% ID_VAR_DUPLICATE_RAYS_STDERR9*
= 53
% ID_VAR_DUPLICATE_RAYS_STDERR10* = 54
% ID_VAR_TIME_DATUM
= 55
% ID_VAR_FILE_NAME
= 56
% ID_VAR_DURATION
= 57
% ID_VAR_END_TIME
= 58
% ID_VAR_COMPONENT
= 59
% ID_VAR_MAXAMPLITUDE
= 60
% ID_VAR_ISORIGINALFILE
= 61
% ID_VAR_SAMPFREQUENCY
= 62
% ID_VAR_SIGNALPTR
= 63
%
%
%Variables:
%ID Name Component Time reference Signal start Signal end Sampling frequency
0 10 59 55 1 58 62 2 3 57 4 5 6 11
%
2 R01A North 01/01/2003 00:00:00 0.0000 s 00:06:45.3875 114.286
0.00875
3 R01A East 01/01/2003 00:00:00 0.0000 s 00:06:45.3875 114.286
0.00875
5 R01B North 01/01/2003 00:00:00 0.0000 s 00:06:45.3875 114.286
0.00875
6 R01B East 01/01/2003 00:00:00 0.0000 s 00:06:45.3875 114.286
0.00875

dt

N samples D

46330
46330
46330
46330

00:06:45.
00:06:45.
00:06:45.
00:06:45.

46330
46330
46330
46330

00:06:45.
00:06:45.
00:06:45.
00:06:45.

...
62
63
65
66

R09C
R09C
R10A
R10A

North
East
North
East

01/01/2003
01/01/2003
01/01/2003
01/01/2003

00:00:00
00:00:00
00:00:00
00:00:00

0.0000
0.0000
0.0000
0.0000

s
s
s
s

00:06:45.3875
00:06:45.3875
00:06:45.3875
00:06:45.3875

114.286
114.286
114.286
114.286

0.00875
0.00875
0.00875
0.00875

Import
Select "Import table" from menu "File". The first uncommented line must contains the list of fields to modify
specified with IDs separated by TABs (see Export). The first signal of the active table is modified according
to the second uncommented line of the imported file. The second signal with the third uncommented line and
so on until reaching either the last signal or the last line of the file.
To avoid errors when importing files, it is better to leave the exported table active while modifying the
exported file and to reimport the modified file with the same active table, to be sure that the order and the
number of signals is exactly the same. In this case, never remove lines from the exported file. To limit the
number of potential errors, you can remove all columns except the ones you really want to change. This
method for modifying the fields of a table must be used with care and should be used only when there is no
other choice.

Import

52

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
SignalDisplay Layer: signal properties
SignalDisplay Layer: picking
Y axis: zoom blocked
Signal selection
Time or frequency spectra

5.2. Graphic
A graphic is an XY plot where one or more signals are represented as a function of time or frequency. When
only one signal is represented, the Y scale is the signal amplitude (count or volts). When various signals are
shown (see figure 1), the Y scale ranges from 0.5 to n+0.5 where n is the number of signals. The axis label are
generally replaced by the names of signals suffixed by the signal's component. The baseline (reference line
with a null amplitude) of each signal is located at y=1, 2,..., n. The signals are drawn around their baseline.
The maximum amplitude around this baseline is adjusted by the normalisation parameters described hereafter.

Figure 1: Graphic viewer, definition of areas: red = graphic's background,


yellow = Y axis, green = X axis, and blue = graphic's content.
The graphic viewer makes use of a general XY plot object from the scifigs library. More information about it
can be found in the scifigs documentation. scifigs offers highly configurable XY plots which can be saved and
restored easily. Usually, figures are exported to bitmap formats like jpeg or png, or as postscripts or pdf. In
this case, any modification of the aspect (fonts, scales, ticks, ranges, ...) require the original program to be
rerun. One of the reason for changing the aspect would be to provide a figure on two kinds of supports: a
printed book and a slide presentation for instance. With scifigs, you can save the aspects and the data with
their real scales (files ".mkup" and ".layer", respectively). figue, is an external program released with scifigs
library, that allows you to construct complex figures from these files grabbed here and there from programs
5.2. Graphic

53

Geopsy manual: content


linked with scifigs (like geopsy).
A graphic is divided into four distinct areas.
Red: graphic's background (context menu (a));
Yellow: Y axis (context menu (c));
Green: X axis (context menu (c));
Blue: graphic's content (context menu (b)).

Figure 2: Context menus for graphic: (a) graphic's background,


(b) graphic's content, and (c) axis.
The graphic's contents is itself divided in layers. Various types of layer have been developed to plot curves,
points, grids, ... Signals are plotted in a special type of layer developed especially for geopsy. Only the
parameters linked to this layer are discussed here.
In each area, a particular context menu (mouse right button, figure 2) is available to control the object. In each
area, a doubleclick is equivalent to "Properties" in menus in figure 2. CTRL+m is equivalent to a right click
in the graphic's background (red zone). This feature is useful when the background is not visible, i.e. when
axis are hidden.
The makeup is the set of parameters that describe the aspect of the graphic, modified by the means of
"Properties" in each specific area. You can save the current set or restore an existing one ("Save makeup" or
"Restore makeup", figure 2(a)). In a similar way, the data contained in the visible layers of the graphic's
contents can be saved to or restore from a file ".layer" (figure 2(b)). Note that ".layer" files need
complementary files named ".layer.bin" which contained binary data. Do not separate these files when
moving or copying to other locations.
Note: the export of the layer developed for signals as ".layer" is currently not implemented. To avoid space
consumption on disk, the complete geopsy core should be used in figue, which is more complex than other
standard layers. A bitmap layer might be an alternative. However, you are free to import other types of layers
in graphic viewer for comparison purposes (e.g. a segmented line representing traveltimes estimated
elsewhere). Currently, to export the signals to a figure, adjust the axis to their final sizes, set a resolution
compatible with your final medium (e.g. 300 or 600 dpi for a laser printer, 72 to 100 dpi for screen or web
publication) and export the graphic as bitmap (png or jpeg).

5.2. Graphic

54

Geopsy manual: content

SignalDisplay Layer: signal properties


You can change the appearance of the signal layer by selecting "Properties" from the context menu of the
graphic's contents, or doubleclick in the graphic's contents (blue area in figure 1). Switch to tab "Signals", a
dialog box like the one shown in figure 3 will let you edit the current properties.

Figure 3: Signal properties.


On the left, "Type" box lets you select the features you want for plotting signals.
"Colours": the amplitude of the signals is represented with a colour scale. This mode of representation
has some constraint: the sampling frequency of all signals must be the same and the differences of T0
must a multiple of the sampling period. This mode is generally reserved for reflection data (radar or
seismic).
"Wiggle": if selected, an oscillating line is drawn
"Variable area": the positive (this option should be replaced by negative or positive) areas are
coloured in black.
The right part contained the normalisation parameters:
"Normalise by": in a first step, maxima are calculated on each signal by one of the proposed
methods:
"max of all traces": a unique maximum is the maximum of the maxima found on each trace.
"max of each trace": the maxima are the maxima found on each trace. The normalisation
varies from one trace to another.
"visible max of all traces": a unique maximum is the maximum of the maxima found on the
currently visible part of each trace.
"visible max of each trace": the maxima are the maxima found on the currently visible part of
each trace. The normalisation varies from one trace to another.
"specified value": an arbitrary value can be specified.
SignalDisplay Layer: signal properties

55

Geopsy manual: content


"Clip": in a second step, a clip value is calculated (as a function of the maximum or the maxima if
"percentage" is selected). If "each trace" is selected in the normalisation, the clip value may change
from one trace to another.
"no": the clip value is the maximum or the maxima, no visualisation clip effect.
"value": an arbitrary value can be fixed.
"percentage": the clip value is set as a percentage of the maximum or the maxima.
"Overlap": in a third step, the time dependent offsets from the signal baseline are calculated. These
offsets are equal to the half of the overlap value (no division by 2 for frequency spectra) if the
amplitude of the signal is equal to the maximum of the considered signal (case of "each trace"
normalisation). An overlap of 1 ensures that the signals will never overlap.
The procedure remains valid when only one signal is plotted, except that "max of each" or "max of all" have
no effects. An example of signals normalised by "visible max of each trace", clipped at 25%, and with an
overlap of 4 is given in figure 3.

Figure 3: Signal normalisation, clipping and overlapping.


The y of the baselines may also be calculated according to the receiver positions ("Use receiver coordinates").
An horizontal line is automatically adjusted to the receiver X,Y coordinates with a least square method. The
receivers coordinates are then projected on to this line to calculate distances along this line. The scale of the Y
axis is the distance along this line.
For colour representation of signals, the values of the colour palette can be adjusted by clicking on "Default
values for colour palette". The normalisation and the clipping settings are taken into account.
The display settings are saved in file "$HOME/.qt/geopsyrc" under the rubric "DialogOptions", entries
"Signalgcprop/*" (for Linux users). For Windows users, this information is located in the registry (regedt32).
The settings are automatically saved when the properties of the graphic's contents are edited. The saved
settings are restored only each time a new graphic viewer is created.

SignalDisplay Layer: signal properties

56

Geopsy manual: content

SignalDisplay Layer: picking


Picks are time markers that you can use to identify particular times (e.g. Vp arrivals for refraction, time limits
for signal processing such as a time domain taper). There are 10 distinct time picks you can use. You can
change select the visible time picks as well as their colours with the tab "Pick" in the graphic's contents
properties (figure 4). These parameters are saved and restored in the same way as other settings.

Figure 4: Signal picks, visibility and colours.


You can modify picks in a table by editing the corresponding fields. However, it is usually edited in a graphic
viewer with mouse clicks. As shown in figure 2(b), select menu "Pick" from the graphic's contents menu. You
will be prompted to select one of the ten picks to edit.
In certain circumstances, it may be useful to magnify the signal around the picks, select "Magnifier window"
to display a signal signal viewer with a zoomed time scale. It is a usual graphic viewer, with a vertical line to
mark the current position of the mouse (created with ParallelBands layer, hence you can hide it if you want).
All the common properties of a graphic viewer may be changed, for instance to enlarge the time interval or to
fix the Y scale. The X interval is kept constant as the mouse moves.
The active trace is highlighted in red and the current pick number is displayed in the bottom right corner. If
"Picking disabled" is displayed, it is likely that you are in "Zooming" or "Editing" mode (displayed in bottom
left corner). In this case, the clicks will not have any effects. First you have to quit this mode by hitting
CTRL+SHIFT+z or by selecting "Zoom" in the context menu (figure 2(b)). Once "Setting pick n" is
displayed, any click on the mouse left button will modify the value of the current pick. Use the "Up" and
"Down" arrows to change the active signal, "Left" and "Right" arrows to switch to other picks. If hitting those
keys has no effect, check that the main graphic viewer is active, if not click in its title bar (this is frequently
the case when a magnifier is used).

SignalDisplay Layer: picking

57

Geopsy manual: content

Y axis: zoom blocked


By default, the minimum and the maximum visible limits of the Y axis are fixed. You cannot change them
with the zoom (figure 2(b)). You can still change them by editing the axis properties (min and max). The
blocked zoom lets zoom in the signals with a rectangle which Y limits are ignored. Only the X interval (the
time or the frequency) is taken into account. You can unlock this feature by unchecking the option "Zoom
blocked" in tab "General" of the Y axis properties dialog box. This feature may be manually set for X axis but
it is less useful.

Signal selection
Contrary to tables, it is not possible to select particular signals in a graphic viewer. The drag and drop
mechanism works in a similar way but all the signals are considered rather than a selection. Graphic viewers
also accept drops of signals that are added at the end.

Time or frequency spectra


If the signals to plot are all of the same TYPE, the X scale is adjusted automatically (time or frequency). It
may append that the signals are not of the same type, in this case, the X title is set as "Time or Frequency".
Usually, the orders of magnitude of the X axis for time and frequency are quite different, hence the plot is
partially unreadable. To recover signals, either as time series or frequency, select either "FFT/Time" or
"FFT/Frequency" from menu "Waveform". If the signals are zoomed in (marked by scroll bars along X and Y
axis), and if you transform time series into spectra and viceversa, it is likely that the current zoom rectangle
will not be adequate for the new X scale. Thus, it is better to unzoom (or CTRL+), until the scroll bars
disappear, before or after a FFT transformation.

Y axis: zoom blocked

58

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
Map scale
Signal selection

5.3. Map
A map is a twodimensional representation of the receiver coordinates in the XY plane. Like the graphic
viewer, it makes use of a general XY plot object from the scifigs library. More information about it can be
found in the scifigs documentation. The area of a map is partitioned in the same way as a graphic viewer. The
main layer is a XYNamePlot which means that signals (or stations) are represented by configurable symbols
(shape, size, colour, ...) and by their names the relative positions of which can be adjusted (top, left, right,
bottom, distance). To create plots suitable for publication, you can save the layer to a ".layer" file, edit the
structured text file to customise your presentation (see scifigs documentation), and restore the modified layer
into figue.

Map scale
Scales of maps are intrinsic properties of XY plot objects (see scifigs documentation for details). Some tips
are given here.
Both X and Y axis have by default the same scale. The scale is automatically adjusted so that all the receiver
coordinates of the signals contained in the viewer remain visible. Resizing the viewer has no effect on the
scale, it changes only the axis minimum and maximum values. To change the scale, edit the axis properties
doubleclick or context menus, "Properties"), tab "Geometry". Modify the scale (e.g. 400, for 1cm = 4m).
Make sure the scales are the same for X and Y axis to avoid distortions. Alternatively, you can resize the map
viewer (this saves the size to the user settings). Then create a new viewer with the drag and drop mechanism
(or redo the what you did to create the present one):
Select all signals (see hereafter);
Leave the editing mode;
Press the mouse left button and move the pointer to the map icon (
Release the mouse button.

5.3. Map

);

59

Geopsy manual: content

Figure 1: Selection of signals on map viewer.


Four coordinates are selected.

Signal selection
Apart from the visualisation, maps offer the advantage over tables that you can select station according to
their localisations. In the graphic's contents, click on the mouse right button to activate the context menu,
select "Edit". The object switch to the editing mode marked by "Editing ..." in red in the lower left corner (see
figure 1). When you press and move the mouse in this mode, a dotted rectangle is displayed. When releasing
the mouse, all coordinates that fall within this rectangle are selected (marked as bold and red), others are
unselected. To add selected signals (without unselecting signals outside the rectangle), press SHIFT when
releasing the mouse. To leave the the "Editing" mode hit CTRL+SHIFT+e or select "Edit" again. If several
signals have the same coordinates they are indistinctively selected together.
The drag and drop mechanism is deactivated when the "Zooming" or the "Editing" mode is switched on. To
move the selected signals to another viewer, first leave these modes and drag and drop as usual.

Map scale

60

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
Modified signals
Temporary signals

6. Basic signal processing


This chapter explains how to transform signals with a set of basic processing. They all apply to the active
signal viewer.
This chapter contains the following sections:
6.1. DC Removal
6.2. Frequency filters
6.3. Automatic Gain Control
6.4. Fast Fourier Transform
6.5. Tapering signals
6.6. Cutting signals
6.7. Merging signals
6.8. Subtracting signals
6.9. Rotate components
Some of these processing either modify existing signals or create new temporary signals. Each processing is
performed in a specific domain (e.g. time of frequency). If the signals of the active viewer are not in the rigth
domain, they are internally converted with the Fast Fourier Transform before processing. The initial domain is
restored after processing.

Modified signals
On opening a database, all signals (either orignal or not) belong to one unique file. The amplitude vectors are
stored on disks and a copy is made into memory on request (e.g. calculating MAXAMPLITUDE in a table,
viewing signals in a graphic). When a process modifies the signal (e.g. a filter), only the amplitude vector in
memory is affected. The original file remains unchanged. The signal is marked as modified.
For those signals, it is possible to erase the changes and to reload the amplitude vector stored in the disk file.
Select "Revert to saved" from menu "Waveform". The signal is then marked as untouched.
On closing a database, if there are still marked signals, a warning will be issued to remind you to save the
changes. When the database is saved, the modified signals are saved in the database directory with a binary
format. Those signals become individual new signals in the database (not specifically linked to the original
signals). They are just stored in a file name closed to the original file name (decorated by "_n", n being
unique).

6. Basic signal processing

61

Geopsy manual: content

Temporary signals
Some processing create new temporary signals (e.g. cut). These signals have no storage on the disk to revert
from. They are totally lost, without warning, on closing database, nor they are saved when you save a
database. Temporary signals are easily recognized in a table which displays the FILE_NAME. The file name
is set to "### Temporary signal ###".
If you want to check if there are temporary signals in your opened database, Drag "All signals" from "Files"
list to a table. Look at the FILE_NAME field.
To export those files to a disk file, create a viewer with them gathered and select "Export ..." for menu "File".
Select the appropriate format in the list. If you want to include them permanently in the database, "SAC"
format is a good choice. Load the generated file(s) into the database and save the database. Note: the exported
files must not be in a temporary location, create them in a permanent directory (e.g. the database directory).

Temporary signals

62

Geopsy manual: content


Contents
Previous
Next
Up

6.1. DC removal
Time Domain

Figure 1: needed parameters for Suppress DC.


A value can be subtracted from the signal amplitudes (e.g. to remove constant shifts of signals). On selecting
"Suppress DC" from menu "Waveform", a dialog box like the one displayed in figure 1 is shown.
If "Mean value" is selected, the value to be subtracted is the arithmetic average of the amplitude signal
calculated over the whole signal duration. If "value" is selected, the value entered in the field is subtracted
from all samples. It might either positive of negative.

6.1. DC removal

63

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
Butterworth
Spectral amplitude taper

6.2. Frequency filters

Figure 1: frequency filter paramters.


Four types of filters are available:
Low pass: remove all frequency components above a frequency threshold (F2);
High pass: remove all frequency components below a frequency threshold (F1);
Band pass: remove all frequency components outside an interval [ F1, F2 ] ;
Band reject: remove all frequency components inside an interval [ F1, F2 ] .
Two methods for filtering signals are implemented in geopsy.

Butterworth
Time Domain
Butterworth: this is a causal filter of adjustable order. The lowest order is the best (shortest) in the time
domain, and the higher orders being better in the frequency domain. More information about such filters can
be found for instance at sepwww.stanford.edu. Causality is an option of the filter. Causal filters are outphasing
and viceversa.

Spectral amplitude taper


Frequency Domain
6.2. Frequency filters

64

Geopsy manual: content

Figure 2: filter function in frequency domain.


This filter does not alter the phase of the signals but it is not causal. The width of the transition is specified in
the parameters (number between 0 and 1). A cosine function is used in the transition ranges.
The transition range is defined from the width and the corner frequencies F1 and F2. In figure 2, the spectrum
of a deltalike function (uniform spectum) as been taken as an example. The spectum is filtered with the four
types of filters. The light coloured lines around the main one are located at Fi*(1width) and Fi*(1+width), i
being 1 (red) or 2 (blue).
The specified frequencies are the limits above or below which the energy of the filtered signals is null. For
instance, in the case of a band reject filter calculated between 0.5 and 3 Hz, there will absolutely no energy
between 0.5 and 3 Hz.

Spectral amplitude taper

65

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
Butterworth
Spectral amplitude taper

6.3. Automatic Gain Control


Time Domain

6.3. Automatic Gain Control

66

Geopsy manual: content


Contents
Previous
Next
Up
Top of page
Butterworth
Spectral amplitude taper

6.4. Fast Fourier Transform


Time to Frequency Domains (and vice versa)

Figure 1: Fast Fourier Transform menu.


All Fourier Transforms in geopsy are based on the algorithms developed by Matteo Frigo and Steven G.
Johnson (MIT) and encapsulated in FFTW library. Called the "Fastest Fourier Transform in the West", it
accepts arbitrary input size for signals. On the contrary, the classical Fast Fourier Transform required the size
to be a power of 2. Various papers are found in the litterature about FFTW the references of which are given
at www.fftw.org.
Changing from Time Domain to Frequency Domain is not considered as a modification of the signal
amplitudes, but it only alters the header information (TYPE). Hence, the transformed signals are never saved
as spectra. Theoretically, successive transformations do not modify the original signal. However, due
precision limits, the signal may be slightly modified. If you suspect errors of this kind, select "Revert to
saved" in "Waveform" menu to get the original signal back.
about menu..., axis (ref to graphic)

6.4. Fast Fourier Transform

67