Skip to content

Manage your Survey from field to finish: Reduce and plot Leica .GSI as .DXF

License

Notifications You must be signed in to change notification settings

adambonneruk/pyradials

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 

Repository files navigation

Manage your Survey from field to finish: Reduce and plot Leica .GSI as .DXF

Introduction

Background

PyRadials is a solution to a challenge I set myself over fifteen years ago: "could I create a software that takes total station data, reduce coordinates, and create a CAD drawing with all the right shapes in place?". PyRadials is built around a "survey project" workflow. You open the application, create a new "survey" and start adding instrument data (total station setups) and GPS coordinates to the project. Using the reuced coordinates, a code table and the application itself, a CAD drawing can produced ready for final drafting in another app.

Features include the project workflow/GUI engine, traverse calcuation and reporting engine, reducing coordinates (X,Y,Z) from observations (φ,θ,r), plotting to .DXF and integration to what3words.

main gui demo gif

Using PyRadials

Windows users can download the PyRadials installer right now, this will give you some options on how you'd like to get running with the software. Support for Leica TPS1100 .GSI files, .CSV "Point,X,Y,Z" coordinates and AutoCAD .DXF is provided out-the-box.

Advanced windows users, users of other operating systems and developers wanting to add/enhance features in the application will instead need to run from source. This application uses Python to operate, more information can be found in the build and compile instructions section.

Name

PyRadials is named after the Python programming language and Radials, a term given to the (slope) distance in the spherical coordinate sytem. The "Py" prefix is a simple yet effective way to communicate the programming language used. The "Radials" name is more nerdy: I enjoy seeing the radial lines plotted in the drawing, showing how different instrument setups "work together" when laid out over one another to create a full survey, a sort of "manifestiation" of the laser beams used as part of the Total Stations's EDM.

example autocad drawing showing the used of radial lines drawn between the station/instrument and an observation/detail point

What's the catch?

PyRadials is MIT-Licenced FOSS (free and open source) software. You are able to use and modify the package with very limited restrictions, including commercial use. It's important to note usage usage of the software is without waranty. Please read the licence.

The project as a whole operates as a "free to use, paid support" model. If you want a feature you can either wait, build it yourself (raise a PR!), or contact me. The licence and "free to use, paid support" model seeks to ensure accessibility and availability while providing avenues for users to obtain assistance and guidance as needed.

Frequent updates and changes are expected in the coming weeks and months. I welcome everyone to get involved!

Software Design, Features, and Philosophy

Project Terminology

survey project
- stations
- jobs
- drawings

stations
- STN1
- STN2
- etc.

jobs (data files)
- EXAMPLE.GSI
- GNSSSTNS.CSV

reading
- code
- attribute(s)
- horizontal angle, vertical angle, slope distance
- reflector height
- date and time information
- easting, northing, elevation

Branding and Styling Approach

PyRadials graphics are found in the docs/graphics folder. The colour scheme for this project is #84B182 primary and #FF003F secondary. When applicable we use the Michroma font.

Mathematical Terminology

This table serves as a handy reference when switching between survey/instrument and physics terms. It's important to note the azimuth and horizontal angle are not the same.

symbol name physics term instrument name notes
r radius radial slope distance measured in m, relates to redius of a circle
θ theta zenith/inclination vertical angle on 0 = zenith / top; 90 = forward
φ phi azimuth horizontal angle azimuth = (90 - horizontal_angle) % 360

An azimuth (φ) is commonly defined as pointing along the positive x-axis. Thus, azimuth 0 points in the direction of the positive x-axis (in survey terms "East"; whereas the Total Station typically points towards relative "North"/"forwards" when at 0°00'00").

Instrument Configuration Steps

Leica TPS1100 Series

Setup Instrument Recording (RMask) and Display (DMask) masks

Note: This is a one-time activity, ensuring the .GSI is produced with the correct polar (spherical) coordinates.

  • Select 5 Configuration and Enter
  • Select 1 Instrument Config. and Enter
  • Select 01 Units. Decimals and Enter
  • Set the following:
    Angle Unit  : 360°
    Angle Dec   : 4 Dec.
    Dist.Unit   : Meter [m]
    Dist.Dec    : 3 Dec.
    V-Diplay    : Zenith angle
    
  • F1 CONT
  • Select 05 Display and Record and Enter
  • Set the following:
    Displ.Mast  : Standard 1
    Coord.Seq.  : E/N as in DMask
    REC-Mask    : Polar (16)
    
  • F3 DMask
  • Set the following:
    Define     : Displ.Mask 1
    Mask name  : Standard 1
    1st word   : Point Id
    2nd word   : Refl Ht.
    3rd word   : V
    4th word   : Slope Dist
    5th word   : East
    6th word   : North
    7th word   : Elev
    8th word   : ppm/mm
    
  • F1 CONT
  • F4 RMask
  • Set the following:
    Define     : Rec-Mask 4
    Mask name  : Polar (16)
    REC format : GSI16 (16 Char)
    1st word   : Point Id (11)
    2nd word   : Hz (21)
    3rd word   : V (22)
    4th word   : Slope Dist (31)
    5th word   : East (81)
    6th word   : North (82)
    7th word   : Elev (83)
    8th word   : ppm tot/mm (51)
    9th word   : Refl. Ht. (87)
    10th word  : MM DD hh mm (19)
    11th word  : YY ss.sss (18)
    12th word  : Horiz.Dist (32)
    
  • F1 CONT
  • F1 CONT
  • F1 BACK
  • F1 BACK

Start a New Job + Setup

  • SHIFT Button + 💡 Button
  • F1 CONT
  • Select 1 Meas job management and Enter
  • F2 NEW
  • Give the job a name EXAMPLE
  • F1 CONT
  • F1 CONT
  • Select 2 Data job management and Enter
  • Move to the EXAMPLE job
  • F1 CONT
  • F5 SETUP
  • Ensure the Meas job and Data job are set correctly:
    Meas job : EXAMPLE.GSI
    Data job : EXAMPLE.GSI
    
  • Select codelist (see codelist) and Enter
  • F1 STN
  • Enter details for Station 1 / STN1:
    Station Id   : STN1
    Inst. Ht.    : 1.234
    Stn. East    : 1000.000
    Stn. North   : 2000.000
    Stn. Elevel. : 50.000
    
  • Orientate your instrument to approximate north (using Compass or Compass App)
  • F4 SetHz
  • F4 Hz=0
  • F1 SET
  • F3 REC
  • F1 CONT
  • CODE Button
  • Select RO / REF OBJECT code and set STN ID to STN2
  • F1 REC
  • Set correct reflector type (this is based on your equipment and config) to switch between Prism & Reflectorless use: FNC Button + F4
  • Enter details for foresight to Station 2 / STN2:
    Point Id   : STN2
    Refl. Ht.  : 0.100
    
  • Take the Shot to the Foresight
  • F1 ALL
  • Optional: Take a reverse shot to the Foresight
  • Begin Survey!
  • CODE Button for first observable survey detail code
  • F1 ALL or F2 DIST + F3 REC

Continue a Job with a New Setup

  • SHIFT Button + 💡 Button
  • F1 CONT
  • F5 SETUP
  • Ensure the Meas job and Data job are set correctly:
    Meas job : EXAMPLE.GSI
    Data job : EXAMPLE.GSI
    
  • Select codelist (see codelist) and Enter
  • F4 QSET
  • Search for your backsight and station details:
    Station Id   : STN2
    Backs. Id    : STN1
    Inst. Ht.    : 1.654
    Refl. Ht.    : 0.100
    
  • Measure to Backsight point / Check Horisontal Distance
  • Set correct reflector type (this is based on your equipment and config) to switch between Prism & Reflectorless use: FNC Button + F4
  • F2 DIST
  • F4 CONT
  • Record the Setup
  • F3 REC
  • CODE Button
  • Select RO / REF OBJECT code and set STN ID to backsight STN1
  • F1 REC
  • Set correct reflector type (this is based on your equipment and config) to switch between Prism & Reflectorless use: FNC Button + F4
  • Enter details for foresight to Station 1 / STN1:
    Point Id   : STN1
    Refl. Ht.  : 0.100
    
  • Take the Shot to the Backsight
  • F1 ALL
  • Optional: Take a reverse shot to the Backsight
  • Begin Survey!
  • CODE Button for first observable survey detail code
  • F1 ALL or F2 DIST + F3 REC

Installing and using PyRadials (for Users)

tbc

Build and Compile PyRadials (for Developers)

Python Virtual Environment

Note: without setting up the correct venv, you will likely see ModuleNotFoundError errors when using this solution, if you're new to venv I recommend a quick web/video search!

Create a Python Virtual Environment (once only, for reference)

# Create the Virtual Environment, named venv
py -m venv venv

# Upgrade PIP
py -m pip install --upgrade pip
py -m pip install --upgrade setuptools

# List installed packages
py -m pip list --local

# Capture installed packages
pip freeze > 'requirements.txt'

Using a Python Virtual Environment

# Create the Virtual Environment, named venv
py -m venv venv

# Activate Virtual Environment (Windows Terminal)
.\venv\Scripts\Activate.ps1

# Install Prerequisites
py -m pip install -r '.\requirements.txt'

Make

Use python script to compile solution and installer .exe's

py 'scripts/make.py'

Compile .exe using PyInstaller only

pyinstaller 'pyradials/pyradials.spec' --noconfirm

Compile installer .exe using NSIS only (requires solution .exe)

makensis 'installer/pyradials.nsi'

Contributing to this Project

This project welcomes contributions of all types. We ask that before you start work on a feature that you would like to contribute, please read the Contributor's Guide.

Contact

Bugs, Documentation bugs, Enhancement requests, Help/Questions should all be be put to the team using GitHub's built-in Issue tracker.

Specific "free to use, paid support" requests can send me an email/message.

Security Policy for this Project

This project seeks to build secure, versatile and robust installed/portable software. If you find an issue, please report it following the Security Policy.

Licence

The MIT License is short and to the point. It lets people do almost anything they want with your project, like making and distributing closed source versions. See the full Licence.

Some parts of the project may have other licences (such as fonts or graphics), they are discussed in their relevant folders.

Useful Links

note: that by clicking on external links provided on this readme, you are leaving our project. We do not endorse or take responsibility for the content, privacy practices, or any other aspect of external sites. Proceed at your own discretion.

Software used for development

Libraries and documentation used during developement

Font used by this Project

  • Michroma is an open font based on the classic Microgramma utilised by "Star Trek"

Hardware Documentation

Further Reading

Reference Articles

Credits

The following organisations, projects, and people helped make PyRadials happen, so I've linked to their sites/projects with a short explanation of their contribution:

  • Geo Spatial Survey Solutions Ltd.: Survey company offering an accurate measuring service using sophisticated electronic measuring equipment. Thanks for their advice and support!
  • SEP Geophysical Ltd.: A multidisciplinary geophysical company providing a comprehensive range of services to clients from various industries, part of the Survey & Engineering Projects family of businesses. Thanks for their knowledge and equipment hire!

About

Manage your Survey from field to finish: Reduce and plot Leica .GSI as .DXF

Topics

Resources

License

Stars

Watchers

Forks