Therion for divers

I don't expect this to be an exhaustive guide on Therion and diving and I'm not even the most experienced on this forum. As there is very little online about Therion for divers, I thought I would put together all the stuff I struggled to figure out in one place.

Data
The .th file is the fundamental difference when using Therion for diving. Most of us now just generate the .th file using one of the many apps and don't really need to pay too much attention to it. With diving, we are almost always going to have to write it ourselves. Here is an example .th file ill step through the differences between a normal dry surveying .th file and a diving one.

survey sump_1 -title "Sump 1"
centerline
team "An Ero"
team "B Odgit "
date 2022.8.26
calibrate depth 0 -1
units length depth meters
units compass degrees
data diving from to length compass depthchange left right up down
extend left
0 1 6 152 0 0.5 10 15 4
1 2 3 120 0 0 10 15 4
2 3 3 120 0 0 2.8 5 2.1
3 4 3.3 88 2.3 2.2 2.3 5.4 0.6
4 5 3 74 0.3 3.8 2.1 2.7 0
5 6 3 118 0.5 1.6 1.9 3.3 0
6 7 6 118 0.7 0.8 0.9 3.4 0
7 8 6 165 0.2 0 2 3.3 0.5
8 9 2 112 0.6 2.1 2 0 0
9 10 3 90 -1.4 2 4 0 1
10 11 3 110 -1.6 0 5 0 0
11 12 6 140 -2.9 4 7 0 0
endcenterline
endsurvey

The first change from normal dry data is the calibration.

calibrate depth 0 -1

This is done so you can enter depths as positive numbers as shown on your depth gauge and how you have probably written them in your notes.

Next, you need to add depth to the units and specify meters or feet. The compass will be the same as normal unless you're using something very odd.
units length depth meters
units compass degrees

"diving" needs to be set in the data line instead of "normal". You also get a choice here to enter your depths as either fromdepth and todepth or depthchange. I prefer depthchange due to how I pre-process my data. If you have taken LRUD with a pinger or measuring tape, you also need the left right up down columns. If you don't have LRUD data delete these or Therion will throw an error.
data diving from to length compass depthchange left right up down

If you want more information on data Therion takes its format from Survex which is documented here.
 

Tseralo

Active member
Drawing

Drawing from memory


There are two ways to draw up a sump, in it or at home. Most brits do the latter, and BCRA 2a is acceptable here in other places it's not. However, you choose to draw the first step is the same generate a .xvi.

In your .thconfig file add these lines.
export map -projection plan -output Sump1Plan.xvi
export map -projection extended -output Sump1Extended.xvi

This will generate two special background images for your .th2 files. If your working on a specific elevation you will need to see set the projection to that as you would the pdf export.

Once you have your .xvi create a .th2 file, within that file insert a scrap, then scroll down on right hand menu and then under background images insert your .xvi
Screenshot 2022-11-07 213702.png


This should automatically set the scale of your drawing and give you a grey line with a bunch of dots. If your data had LRUD you should also see grey boxes which are effectively the splays.

Screenshot 2022-11-07 214111.png


As you might have guessed the dots are your stations and the black is your dive line. However, this is a background image we need to mark the stations properly so Therion can join your drawing to other drawings.

On each station dot add a point of type "survey station". Because of the xvi Therion should name each station to match the underlying data. Occasionally it gets it wrong so if your drawing warps oddly check them.

Screenshot 2022-11-07 214638.png


At this point, if you plan to draw it up from memory, you can draw as you would any other dry survey. I'm not going to go into detail on how to do that here.

Drawing in cave

If you wish to generate a file, you can sketch in the cave or give it to someone that needs crayons to draw and read on.

In your .thconfig add the following layout

layout gridded
grid bottom
grid-size 1 1 1 m

map-header 0 0 off
legend off
endlayout

Next export your plan or elevation using that layout

export map -layout gridded -proj plan -o sumpPlan.pdf

This will give you something which looks like this.


Screenshot 2022-11-07 215535.png


From here you can print it on waterproof paper, tape it to and slate and take it into the cave to sketch to your heart's content.

Once you have your sketches, import them as you would if you were drawing from sexytopo or an old trad drawing. There is a good tutorial on how to do that here by Gotzone.

Adding dive line

If you wish to add the dive line to your drawing, you can use the layout config to show the centre line and colour it. If your survey also has dry sections, it will show in there in look a bit rubbish in my opinion.

Instead, i created a custom dive line. In your layout in your .thconfig file add the following

#custom Dive line
code metapost
def l_u_diveline (expr P) =
T:=identity;
pickup PenB;
thdraw P withcolor (1, 0.5, 0);
enddef;
initsymbol("l_u_diveline");
endcode

You can then create a line along the centerline of your xvi and set its type as "u:diveline". If you wish to change the colour change the 3 numbers in "thdraw P withcolor (1, 0.5, 0);" they are RBG 0-1
 

Steve Clark

Well-known member
This is great, well done. Really clear and will save hours for people figuring out how to do this from scratch.

What can be useful is to plot the LRUD's on paper bit you take in the water for dive 2. In your 'gridded' layout, just add this line :

color map-fg [90 90 90]

That will plot the xvi trapeziums in the background as a guide to passage shape.

More code for this is discussed in this thread on a similar topic - https://ukcaving.com/board/index.ph...lan-from-a-lrud-survey-data.29800/post-363991

edit :

adding :

debug station-names

will put the station names on the underwater sheet too (e.g. if they are labelled with tags in the water)
 

andrew

Member
A good guide.

May I suggest that it is not good to preprocess your data. One of the great advantages of Survex and therefore Therion is that you can input most valid forms of survey data just as you recorded it in the cave. With an overly simplified and exaggerated case I will try to explain one case where translated forms of data change the maths behind the distribution of errors due to the difference between cumulative and non-cumulative errors.

If we look at the depth only and have 3 legs going to 8m deep. Generally if you are diving you will use a depth gauge and record the depths of
0m 3m, 5m and 8m on the respective stations. If this is translated to change depth for the legs we get 3m, 2m, 3m respectively. It appears equivalent. However, if we consider the accuracy and precision of the readings and look at worst case. In this case we are reading to the closest whole number so each reading could be 0.5m each side, so 3m could be anywhere between 2.5-3.5 (yes it should be 3.49999....but), 5 -> 4.5-5.5 and 8 -> 7.5-8.5. If we now look at what that could be using change in depth, 3m is 2.5-3.5 and 2 is 1.5-2.5, however as these are 'change in' depths to get to the end of the third leg for the worst cases we get 2.5+1.5+2.5= 6.5 or 3.5+2.5+3.5 = 9.5.
This means that at 8m depth for the directly recorded result the possible error is 1m (8.5-7.5) but for the change in depth the error is 3m (9.5-6.5) Hopefully Survex uses this information to distribute the error when loops are closed.

Another important part of surveying is making sure your data is safe for the future, to this end the BCA cave data repository is available. Data can be secret or open and anyway between.

Obviously only the open data is available to view, however, there are other repositories.

Andrew
Cave Surveying Group
 

Steve Clark

Well-known member
I am also a fan of keeping the data in as raw a form as possible all the way to the therion processing. I think it keeps things much clearer and is less prone to transcription errors. The beauty of the therion flexible data format is that you can format the data in exactly the same way as you recorded it originally. It can be different for each centreline and each surveyor's methodology.

As Andrew said above, if you use absolute depths it also gives you the flexibility to change all the depths using the calibrate command if you need to adjust for differences in different depth gauges. On a project with multiple survey divers and different computers, we attempted to get everyone to capture a check depth at a particular point around 30m on the way in. We found +/-0.5m difference between brands. Not exactly significant I guess.

In clear water cave, we use a graphical layout to record the stations and LRUDs. This lends itself to using interleaved (newline) diving data format which is very clear and easy to check in the code against the survey sheet.

2022-11-14 21.17.53.jpg


The attached file would code like this :

data diving station depth left right up down newline tape compass

SURFACE 0.0 1 1 0 2 # line at surface
3.0 020
STN01 2.0 1 4 2 1
2.0 040
STN02 4.2 2 4 2 0.5 # this is a wrap
9.4 043
STN03 9.1 0 3 0 3 # line on the roof
# end of survey

The graphical format also makes it really obvious if you have forgotten to collect a bit of data - the box will be blank.
 

Tseralo

Active member
Good point on the accuracy my main reason for processing is to help normalise someone of the different tools we have used and make data entry easier.

Trad often only has one depth per leg (to station) so you either need to user interleaved or duplicate data. Personally I dislike interleaved as it feels messy to me.

Mnemo gives two compass bearings per leg which survex/therion dosent support as far as I’m aware so they need to be averaged for more accuracy. Plus in and out depths on the same station which can be averaged as if they are not you get some drift and the ends of the sump don’t match.

ENC3 has a really high refresh rate and it gives so many stations that drawing in therion is impossible. I wrote some code to average that out while maintaining accuracy.

As for the data archive, it’s a noble idea but personally I stopped using SVN about 12 years ago and it was as old hat then. I spend all day in git so I store all my continental projects data on GitHub in private repos for now.
 

andrew

Member
Good point on the accuracy my main reason for processing is to help normalise someone of the different tools we have used and make data entry easier.

Trad often only has one depth per leg (to station) so you either need to user interleaved or duplicate data. Personally I dislike interleaved as it feels messy to me.

But why normalise, surely accuracy is best aimed for and the way the data was collected gives clues to the likely reliability. If data is collected as interleaved surely that is how it should be recorded.
Mnemo gives two compass bearings per leg which survex/therion dosent support as far as I’m aware so they need to be averaged for more accuracy. Plus in and out depths on the same station which can be averaged as if they are not you get some drift and the ends of the sump don’t match.

I assume you mean two bearings in the same direction, with different or the same compass? Survex does forward and backward compass. But loosing the fact you have two readings is not good, it is likely that taking two readings is better than only taking one (although there is lots to debate about this and back bearings.) I don't believe survex can handle this, but it probably should. Maybe it should be brought up on the survex list, especial if there are programs that do it this way. Survex adapted to distoX by allowing multiple readings of all instruments.
Taking readings on the way out is probably another traverse, so should be recorded as such.
ENC3 has a really high refresh rate and it gives so many stations that drawing in therion is impossible. I wrote some code to average that out while maintaining accuracy.

Yep probably another adaption that is needed, again one for the survex list
As for the data archive, it’s a noble idea but personally I stopped using SVN about 12 years ago and it was as old hat then. I spend all day in git so I store all my continental projects data on GitHub in private repos for now.
Just because it is old does not mean that SVN is not the most suitable. The main thing is the archive is BCA owned and therefore maintianed, so as peoples interest wanes in Surveying the data is maintained by the next generation. This cannot be said for things like GitHub, popular now, but so many have been there and gone, cave data has been lost because of it, the repository is still there.
Although Git has major disadvantages for archive purposes, we do intend to support it, as you say if is flavour of choice at the moment.
 

Pitlamp

Well-known member
I don't pretend to understand much of the above - I just get the underwater numbers and give them to "them as know" what to do with them. But I do a lot of underwater cave surveying, so maybe I can add a little useful practical perspective?

The standard CDG method is all about compromise. The main problem when surveying underwater is that you often get very little time to read the instruments due to rapid vis reduction. There are often time constraints related to air consumption. Also, you can't really survey on the way in, whilst laying line. So in most cases a diver will emerge with a single set of data, obtained on the way back out along the line just laid. In other words the normal practice is you try to get just one good line survey done, as carefully as the cave allows, when returning along the new line on the same dive it was laid. (There are circumstances where there are exceptions to this principle; see below.) On the next dive the focus is on getting straight to the previous terminus, laying more new line and surveying that on the way back (and so on).

Andrew said: "But loosing the fact you have two readings is not good, it is likely that taking two readings is better than only taking one (although there is lots to debate about this and back bearings.)". I can't disagree with this sentence but thought it was worth mentioning that getting more than one bearing per survey leg from a diver may be a luxury that's often not going to happen. So it may be less of a problem, if survey software can't accommodate more than one bearing, than you might think. Then again, sometimes divers devote whole dives to surveying very carefully, in which case two bearings per survey leg may be practicable (i.e. surveying a section of line both ways). In this case, a programme which does cope with more than one bearing would certainly be useful.
 

alastairgott

Well-known member
I guess there are benefits of using this Mnemo thing (having only just looked it up) but what happens if someone’s lined the sump with SRT rope or line which is knotted at 5m+ intervals. Mnemo does seem like an option to use in some perfect cases. But on my mind it’s a lot of money to spend on something which doesn’t collect the quality of data that Steve Clark has shown above. Ie LRUDs.

The system also seems to rely on having a tight line between belay points, if there were some play in the line and you were able to hold the device off kilter by 5,10,15 degrees whilst still running it along the line, then you’ll have bad data, no amount of wizardry and automatic capabilities will offset bad data.

But still, nice bit of kit if used effectively.
 

Steve Clark

Well-known member
It clunky, but if you are using non-interleaved data then you can maybe use double bearings in therion. You could just enter the shot twice in the centerline data. Therion would presumably use both and average them? maybe? I've not tested this.

If not, you could enter two centerlines and it would treat them as two surveys and average them.
 

andrew

Member
I believe that Survex handles multiple legs taken on the same trip differently from if two centrelines are combined, although if all the stations are tied together I'm not so sure.
For a group of legs taken at the 'same' time with the same instrument I believe Survex just takes an average, unsure as to whether of the displacement or each reading for each instrument, or even if this gives the same outcome. Currently it assumes the same instrument, and because it was an amendment to accommodate the DistoX it expects one reading for each of the tape, compass and clino. However, there have been instruments that only do the compass and clino so taking one tape reading and multiple comp and clino would be reasonable. The problem with just putting the leg in twice, apart from it looking messy, is that it indicates that the tape has also been read twice. Instruments with the reading taken twice are arguable more reliable that only taken once, hopefully the loop closing algorithm uses that!
 

andrew

Member
I was intrigued by the puzzle of getting this data neatly into Survex so used the mailing list to get more help. Olly came back with an answer for the double compass reading and seems amenable to amending Survex to except these sort of data methods, although some of them will require thought on how to handle them.

For the two compass readings Olly wrote
I'd suggest just handling the extra compass and/or clino here as
backcompass/backclino suitably calibrated so they actually work
in the same direction as the forward instruments:

*calibrate backclino 0 -1
*calibrate backcompass 180

Survex also supports backtape (since 1.2.25) so you can take your pick
of which instruments you have a secondary for (backtape doesn't need a
special calibration for this use, since distance is the same whichever
way round you measure it).

You can specify a separate accuracy for backcompass and compass, so this
is supported via the backsight approach. Averaging will take into
account the accuracies specified via *sd so you'll get an average heavily
weighted towards the better compass here.

The full answers can be read on the list.
 

Duncan Price

Active member
I used Therion to draw up the Pwll-y-Cwm survey in 2011 which became a matter of some urgency as it was required for Bonnie Cotier's inquest...

The centreline was done first using forward compass bearings along the (then new) line tagged at 5 m intervals. LRUD measurements were done using a SONAR wand later along the same line every 5 m and at belays. Nowadays I'd use our underwater DistoX as a glorified underwater compass. We recently did the 84 m long 22-23 static sump in Wookey Hole with a tape measure pre-laid through the sump and the DistoX. I made LRUD measurements using the SONAR wand. MaxF (of this parish) also did photogrammetry and has done a lot in Porth-yr-Ogof. For the 22-23 sump we got good closure with the overland survey via Cam Valley Crawl.

I don't believe the Pwll-y-Cwm survey has ever been published so here it is (the larger scale plan of the entrance area was given to the coroner):
 

Attachments

  • pyc.png
    pyc.png
    78.4 KB · Views: 145
Top