Giter Site home page Giter Site logo

lazio.jl's Introduction

Build Status Build status codecov

LazIO

Extends LasIO with LASzip integration.

Uses the LASzip shared library to read compressed las files (*.laz) into the uncompressed format that LasIO reads natively.

julia> using LazIO

# Open file and iterate over points
julia> ds = LazIO.open("test/libLAS_1.2.laz")
LazIO Dataset of test/libLAS_1.2.laz with 497536 points of version 0.

# Each point is correctly scaled and has its return_number and classification widened
julia> p = ds[1]
LazIO.Point0(1.44013394e6, 375000.23, 846.66, 0x00fa, 0x00, 0x00, 0x00, false, 2, false, false, false, 0x00, 0x001d)

# This results in accessible attributes, such as edge_of_flightline and withheld
julia> fieldnames(typeof(p))
(:x, :y, :z, :intensity, :return_number, :number_of_returns, :scan_direction, :edge_of_flight_line, :classification, :synthetic, :key_point, :withheld, :user_data, :point_source_id)

# LazIO implements the GeoInterface
julia> using GeoInterface
julia> GeoInterface.coordinates(p)
3-element Vector{Float64}:
      1.44013394e6
 375000.23
    846.66
julia> GeoInterface.extent(ds)
Extent(X = (1.44e6, 1.44499996e6), Y = (375000.03, 379999.99), Z = (832.1800000000001, 972.6700000000001))

# Or one can use the Tables interface
julia> using DataFrames
julia> DataFrame(ds)
497536×14 DataFrame
    Row │ x          y               z        intensity  return_number  number 
        │ Float64    Float64         Float64  UInt16     UInt8          UInt8  
────────┼───────────────────────────────────────────────────────────────────────
      11.44013e6       3.75e5      846.66        250              0         
      21.44012e6       3.75e5      846.55        245              0
      31.44011e6       3.75001e5   846.44        239              0
      41.4401e6   375001.0         846.32        251              0
      51.44009e6       3.75001e5   846.21        229              0         
      61.44009e6       3.75002e5   846.1         249              0
      71.44008e6       3.75002e5   846.0         189              0
      81.44007e6       3.75002e5   845.9         250              0

lazio.jl's People

Contributors

crghilardi avatar dependabot[bot] avatar evetion avatar femtocleaner[bot] avatar github-actions[bot] avatar juliatagbot avatar visr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

lazio.jl's Issues

Default Int32 coordinates type overflow issue

The default data type for X/Y coordinates leads to an integer overflow in some cases.
For some datasets, the projected coordinates are scaled by a factor, and they don't fit into Int32.

Would it be possible to add a check and change the type accordingly?

Determine offset in write table interface check

Following code will error out while it shouldn't. Rethink the flip checks.

using LazIO
min_y = -16.366242659155276
max_y = 6.957395069293919e-7
LazIO.determine_offset(min_y, max_y, 0.01)

ERROR: Can't fit offset for max with this scale, try to coarsen it.

TagBot trigger issue

This issue is used to trigger TagBot; feel free to unsubscribe.

If you haven't already, you should update your TagBot.yml to include issue comment triggers.
Please see this post on Discourse for instructions and more details.

If you'd like for me to do this for you, comment TagBot fix on this issue.
I'll open a PR within a few hours, please be patient!

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.