Files
dougal-software/etc/surveys/_example.yaml
2020-08-17 11:19:01 +02:00

191 lines
6.4 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Example of a survey configuration file.
#
# These files, of which there should be one per project,
# describe where to find the relevant data and other
# parameters of interest.
archived: true # If true, the data in the database will be “frozen”.
id: EQ20211 # Not used. See bin/create_survey.sh
name: "Snorre" # Not used. See bin/create_survey.sh
schema: survey_1 # This must be the schema returned by bin/create_survey.sh
epsg: 23031 # The EPSG code used in bin/create_survey.sh
binning: # P6 data. Eventually will be replaced with the location of the P6 file.
theta: 206.47 # Direction of I axis, degrees
I_inc: 1 # Increment along I
J_inc: 1 # Increment along J
I_width: 12.50 # Inline bin width
J_width: 12.50 # Crossline bin width
origin:
easting: 479735.00
northing: 6565048.00
I: 5000
J: 1000
preplots: # List of preplot files
-
type: sps # Always "sps"
class: "S" # Source preplots
path: /srv/Data/EQ20211/preplots/Preplot_Source.sps
format:
# The “SPS” files seen in the while have all different layouts. Rather than
# forcing our own choice of layout upon the user, we let him describe what
# his files look like.
# This is done by providing:
# * a list of field widths (negative values cause that number of columns to be skipped)
# * a list of field names, its length must equal the number of positive field widths
# * a list of type conversions this is the name of a Python function to which the
# value will be passed. An exception is that `int` is our own custom function that
# can take a string like "3.0" without barfing.
widths: [ -1, 10, 10, -25, 10, 10 ]
names: [ "line_name", "point_number", "easting", "northing" ]
types: [ "int", "int", "float", "float" ]
-
type: sps
class: "V" # Vessel preplots
path: /srv/Data/EQ20211/preplots/Preplot_Vessel.sps
format:
widths: [ -1, 10, 10, -25, 10, 10 ]
names: [ "line_name", "point_number", "easting", "northing" ]
types: [ "int", "int", "float", "float" ]
raw:
# This section tells us where to find the raw data and what kind it is.
# (raw data is what is produced by the navigation system during or right after acquisition)
p190: # We have raw P1/90 files
timestamp_format: "%d%m%Y" # Different software can't seem to agree on what format to use
pattern:
# Some of the information we want is not even *in* the P1/90 but is conveyed
# via the file name. So we parse the file name via a regular expression to
# get those details. There are two items of data that we *must* get from the
# file name: the sequence and the sailline number.
# The following items are:
# * regex: a Python (and ideally JavaScript) compatible regular expression
# * flags: regular expression flags
# * captures: the capture groups. "line" and "sequence" are required.
regex: '^.*(10|20)([0-9]{4})([0-9])([0-9]{3})S00000\.([0-9]+)\.[Pp]?190$'
flags: i
captures: [ "direction", "line", "attempt", "sequence", "file_no" ]
globs:
# A list of glob expressions to capture P1/90 files
- "*.P190"
paths:
# A list of directories to search for P1/90 files
- /srv/Data/EQ20211/_live/raw
final:
# This section is analogue to "raw" above, but for final data.
# (final data is what is given to the client)
p190:
timestamp_format: "%d%m%Y"
pattern:
regex: '^.*(10|20)([0-9]{4})([0-9])([0-9]{3})S00000\.([0-9]+)\.[Pp]?190$'
flags: i
captures: [ "direction", "line", "attempt", "sequence", "file_no" ]
globs:
- "*.190"
- "*.p190"
- "*.P190"
paths:
- /srv/Data/EQ20211/_live/final
labels:
FDSP:
view:
colour: "#80CBC4"
description: "First shot of the day"
model:
user: false
multiple: false
FSP:
view:
colour: "#03A9F4"
"description": "First shot point"
model:
user: true
multiple: false
Guns:
view:
"colour": "#F48FB1"
"description": "Gun events"
model:
user: true
#multiple: true # This is the default
LDSP:
view:
colour: "#4DB6AC"
description: "Last shot of the day"
model:
user: false
multiple: false
LSP:
view:
colour: "#00BCD4"
description: "Last shot point"
model:
user: true
multiple: false
Nav:
view:
colour: "#EF9A9A"
description: "Navigation events"
model:
user: true
multiple: true
Nav Proc:
view:
colour: "#FFCC80"
description: "Navigation processing events"
model:
user: true
multiple: true
Missed shot:
view:
colour: "#C0C0C0"
description: "Missing shot"
model:
user: false
multiple: true
NTBP:
view:
colour: "#C0C0C0"
description: "Not to be processed"
model:
user: true
multiple: true
QC Error:
view:
colour: "#FF0000"
description: "This shot fails one or more QC checks"
model:
user: false
multiple: true
Daily:
view:
colour: "#C0C0C0"
description: "Of interest in the daily report"
model:
user: true
multiple: true
Weekly:
view:
colour: "#C0C0C0"
description: "Of interest in the weekly report"
model:
user: true
multiple: true
Final report:
view:
colour: "#C0C0C0"
description: "Of interest in the final report"
model:
user: true
multiple: true
Shift handover:
view:
colour: "#C0C0C0"
description: "Of interest during shift handover"
model:
user: true
multiple: true