https://github.com/andrew-plowright/tilemanager
Create and detect tiling schemes for raster datasets
Science Score: 23.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
○.zenodo.json file
-
○DOI references
-
○Academic publication links
-
✓Committers with academic emails
2 of 2 committers (100.0%) from academic institutions -
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (17.2%) to scientific vocabulary
Last synced: 11 months ago
·
JSON representation
Repository
Create and detect tiling schemes for raster datasets
Basic Info
Statistics
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 1
- Releases: 0
Created over 9 years ago
· Last pushed over 1 year ago
Metadata Files
Readme
Changelog
README.Rmd
--- output: github_document --- TileManager: Tools for creating and detecting tiling schemes for geospatial datasets --------------- **Authors:** Andrew Plowright
**License:** GPL 3 [](https://travis-ci.org/andrew-plowright/TileManager) ```{r global_options, include = FALSE} knitr::opts_chunk$set( collapse = TRUE, comment = "#>", fig.path = "man/figures/", fig.height = 4, fig.width = 6 ) knitr::opts_knit$set( global.par = TRUE ) ``` ```{r, echo = FALSE} par(mar = c(3,3,1,0.1)) ``` This package provides tools for working with tiled geospatial datasets. # News ## 2024-03-08, v.1.0.0 The latest release of `TileManager` is a complete refactor of the old library, which used the obsolete `raster` and `sp` packages. The new version uses `terra` and `sf` instead. Although the structure of the `tileScheme` class remains similar, any spatial outputs from this library now use `sf` formats. Furthermore, `tileScheme` objects are now saved to the Geopackage format instead of SHP files. # Introduction Use the `tileScheme` function to create a set of tiles from a Raster or Extent object. ```{r demo1} library(TileManager) library(terra) # Load a test raster chm <- rast(system.file("ex/chm.tif", package="TileManager")) # Generate a tile scheme ts <- tileScheme(chm, dim = c(30,30), buffer = 5) plot(chm) plot(ts, add = T) ``` Use the `remove_empty` argument to drop tiles with no Raster values. ```{r demo2} ts <- tileScheme(chm, dim = c(20,20), buffer = 2.5, remove_empty = TRUE) plot(chm) plot(ts, add = T) ``` Other handy features: * The `origin` argument can be used to force the tile scheme to snap to a pair of coordinates. * The `spill` argument controls whether or not the buffers extent beyond the input's original extent. * By default, tile dimensions are in map units. Using the `cells` argument, they can be defined by a number of Raster cells. # Non-overlapping buffers Non-overlapping buffers (often abbreviated to **nbuffs**) are useful for re-assembling tiled data. Essentially, they preserve buffers only where they _do not overlap onto neighboring tiles_ (i.e.: along the edge of the tile scheme). This allows you to recombine tiles without worrying about overlapping areas _and_ without losing any information along the data edges. In the example below: * The __solid blue__ is the tile * The __dashed red__ is the buffer * The __solid purple__ is the non-overlapping buffer ```{r nbuff-sample, echo = FALSE} plot(chm, xlim = c(439871, 439960), ylim = c(5526705, 5526756), xlab = "", ylab = "", legend = FALSE) plot(ts, add = T) ``` # Methods Some useful methods are provided for subsetting the tile scheme, or for converting it into other formats. Get buffers as a `sf` object: ```{r} ts[["buffs"]] ``` Subset a specific tile by name, number or row/col: ```{r} # By name ts["R2C2"] # By number ts[7] # By row/col ts[2,3] ``` Subset entire rows or columns: ```{r} # One row ts[4,] # Multiple columns ts[,2:3] ``` # Saving and loading The tile scheme can be saved as a single Geopackage. In this case, `tiles`, `buffs` and `nbuffs` will all be written to separate tables. Other metadata (such as the buffer size) are written to a `metadata` table. ```{r, eval = FALSE} # Create tile scheme ts <- tileScheme(chm, dim = c(30,30), buffer = 5) # Save tile scheme tileSave(ts, "C:/myfiles/tilescheme.gpkg") # Load tile scheme ts <- tileLoad("C:/myfiles/tilescheme.gpkg") ```
Owner
- Name: Andrew Plowright
- Login: andrew-plowright
- Kind: user
- Location: Vancouver, BC
- Company: Canada Centre for Mapping and Earth Observation
- Twitter: PlowrightAndrew
- Repositories: 7
- Profile: https://github.com/andrew-plowright
🛰 Remote sensing, geospatial analysis, natural resource management 🏞
GitHub Events
Total
- Push event: 1
Last Year
- Push event: 1
Committers
Last synced: over 2 years ago
Top Committers
| Name | Commits | |
|---|---|---|
| Andrew Plowright | a****t@a****a | 28 |
| Andrew Plowright | a****t@a****a | 27 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: over 2 years ago
All Time
- Total issues: 1
- Total pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Total issue authors: 1
- Total pull request authors: 0
- Average comments per issue: 4.0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 0
- Pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Issue authors: 0
- Pull request authors: 0
- Average comments per issue: 0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- spono (1)