GithubHelp home page GithubHelp logo

levler's Introduction

levler

Converts a dxf file with points and readings from an automatic level to contours

What it does:

Takes a dxf file like this one: user input file preview And adds contour lines and relative heights: output file preview

Usage

python level_to_contour.py -h
positional arguments:
  input_file            input file name (required)

options:
  -h, --help            show this help message and exit
  -z ZERO, --zero ZERO  level reading at your zero point
  -o OUTPUT_FILE, --output_file OUTPUT_FILE
                        output file name
  -s, --show_3d         Show a 3d model of the interpolation
  -c, --export_csv      Export a csv as well
  --csv_only            Export only the csv
  -d CONTOUR_Z_DISTANCE, --contour_z_distance CONTOUR_Z_DISTANCE
                        contour z distance
  -r RESOLUTION, --resolution RESOLUTION
                        subdivisions of interpolation grid
  -v, --verbose         verbose

Input file format:

To make such a dxf file, use the acad.dwt template, insert your plot outline and then use PDMODE command to set the point rendering mode to 2. Use the POINT command to place a point and then use MTEXT to add the automatic level reading next to the point. The program will only consider the first line as a value, if there is any text or %%p it will be ignored. Repeat for all readings. Save the file as 2004 dxf.

How it works:

The program associates POINT objects as the coordinates of the point where a level reading was taken, and uses the nearest MTEXT object as the reading value to calculate the height from the zero point.

Requirements

GTK+ libraries (https://github.com/tschoonj/GTK-for-Windows-Runtime-Environment-Installer/releases) scipy matplotlib

TODO

  • 3d point input
  • use MTEXT values as heights instead of readings
  • Generate cross sections

levler's People

Contributors

erikoui avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.