vectorpipe | Convert Vector data to VectorTiles with GeoTrellis | Map library

 by   geotrellis Scala Version: v1.1.0 License: Non-SPDX

kandi X-RAY | vectorpipe Summary

kandi X-RAY | vectorpipe Summary

vectorpipe is a Scala library typically used in Geo, Map applications. vectorpipe has no bugs, it has no vulnerabilities and it has low support. However vectorpipe has a Non-SPDX License. You can download it from GitHub.

VectorPipe (VP) is a library for working with OpenStreetMap (OSM) vector data and writing geometries to vector tile layers. Powered by Geotrellis and Apache Spark. OSM provides a wealth of data which has broad coverage and a deep history. This comes at the price of very large size which can make accessing the power of OSM difficult. VectorPipe can help by making OSM processing in Apache Spark possible, leveraging large computing clusters to churn through the large volume of, say, an OSM full history file. For those cases where an application needs to process incoming changes, VP also provides streaming Spark DataSources for changesets, OsmChange files, and Augmented diffs generated by Overpass. For ease of use, the output of VP imports is a Spark DataFrame containing columns of JTS Geometry objects, enabled by the user-defined types provided by GeoMesa. That package also provides functions for manipulating those geometries via Spark SQL directives. The final important contribution is a set of functions for exporting geometries to vector tiles. This leans on the geotrellis-vectortile package.
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              vectorpipe has a low active ecosystem.
              It has 58 star(s) with 13 fork(s). There are 14 watchers for this library.
              OutlinedDot
              It had no major release in the last 12 months.
              There are 17 open issues and 33 have been closed. On average issues are closed in 167 days. There are 6 open pull requests and 0 closed requests.
              It has a neutral sentiment in the developer community.
              The latest version of vectorpipe is v1.1.0

            kandi-Quality Quality

              vectorpipe has no bugs reported.

            kandi-Security Security

              vectorpipe has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.

            kandi-License License

              vectorpipe has a Non-SPDX License.
              Non-SPDX licenses can be open source with a non SPDX compliant license, or non open source licenses, and you need to review them closely before use.

            kandi-Reuse Reuse

              vectorpipe releases are available to install and integrate.
              Installation instructions, examples and code snippets are available.

            Top functions reviewed by kandi - BETA

            kandi's functional review helps you automatically verify the functionalities of the libraries and avoid rework.
            Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of vectorpipe
            Get all kandi verified functions for this library.

            vectorpipe Key Features

            No Key Features are available at this moment for vectorpipe.

            vectorpipe Examples and Code Snippets

            VectorPipe,Getting Started,Importing Data
            Scaladot img1Lines of Code : 14dot img1License : Non-SPDX (NOASSERTION)
            copy iconCopy
            val df = spark.read.orc(path)
            
            import vectorpipe.sources.Source
            val df = spark.read
                          .format(Source.Changes)
                          .options(Map[String, String](
                            Source.BaseURI -> "https://download.geofabrik.de/europe/isle-of-m  
            VectorPipe,Local Development,IntelliJ IDEA
            Scaladot img2Lines of Code : 7dot img2License : Non-SPDX (NOASSERTION)
            copy iconCopy
            import Dependencies._
            
            lazy val mainRunner = project.in(file("mainRunner")).dependsOn(RootProject(file("."))).settings(
              libraryDependencies ++= Seq(
                sparkSql % Compile
              )
            )
              
            VectorPipe,Getting Started,With a REPL
            Scaladot img3Lines of Code : 6dot img3License : Non-SPDX (NOASSERTION)
            copy iconCopy
            spark-shell --packages com.azavea.geotrellis:vectorpipe_2.11:2.1.3
            
            // Make JTS types available to Spark
            import org.locationtech.geomesa.spark.jts._
            spark.withJTS
            
            import vectorpipe._
              

            Community Discussions

            QUESTION

            scala for mapbox vector tiles - getting an 'id' field into the Features written to vector tiles
            Asked 2019-Mar-27 at 20:37

            I'm writing MapBox vector tiles using geotrellis vectorpipe.

            see here for the basic flow: https://geotrellis.github.io/vectorpipe/usage.html

            Typically GeoJson Features can have an id field, so that Features can be rolled up into FeatureCollections. I need to make use of this field, but vectorpipe doesn't (natively) have this capability.

            This is the Feature type used, and you can see it only has space for 1) a Geometry and 2) a data object D (which ends up populating properties in the output). There is no spot for an id.

            https://geotrellis.github.io/scaladocs/latest/index.html#geotrellis.vector.Feature

            Upstream there's a method called writeFeatureJsonWithID() that does let you inject an id field into a Feature when writing GeoJson.

            https://github.com/locationtech/geotrellis/blob/master/vector/src/main/scala/geotrellis/vector/io/json/FeatureFormats.scala#L41-L49

            My question is this:

            I have worked through the vectorpipe code (https://github.com/geotrellis/vectorpipe), and I can't figure out if/where the data ever exists as GeoJson in a way where I can override and inject the id, maybe using the writeFeatureJsonWithID() or something I write explicitly. A lot of conversions are implicit, but it also may never explicitly sit as json.

            Any ideas for how to get an id field in the final GeoJson written to vector tiles?

            EDIT

            Right now I think the trick is going to be finding a way to override .unfeature() method here:

            https://github.com/locationtech/geotrellis/blob/master/vectortile/src/main/scala/geotrellis/vectortile/Layer.scala

            The problem is that the internal.vector_tile.Tile is private, so I can construct it without forking the project.

            ...

            ANSWER

            Answered 2019-Mar-27 at 20:37

            Ended up having to fork geotrellis, hard-code a metadata => id function in Layer.unfeature() and compile locally to include in my project. Not ideal, but it works fine.

            Also opened an issue here: https://github.com/locationtech/geotrellis/issues/2884

            Source https://stackoverflow.com/questions/55272028

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install vectorpipe

            Add the following to your build.sbt:. Note: VectorPipe releases for version 2.0.0+ are hosted on SonaType. If you need earlier releases, they can be found on Bintray. If using SBT for older releases, you will also need to include resolvers ++= Resolver.bintrayRepo("azavea", "maven") in your build.sbt.

            Support

            For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/geotrellis/vectorpipe.git

          • CLI

            gh repo clone geotrellis/vectorpipe

          • sshUrl

            git@github.com:geotrellis/vectorpipe.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link