Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GADM license violation #35

Open
bryce-carson opened this issue Jul 17, 2024 · 9 comments
Open

GADM license violation #35

bryce-carson opened this issue Jul 17, 2024 · 9 comments
Assignees
Labels
UNSTABLE The work is to be completed in the unstable branch

Comments

@bryce-carson
Copy link
Collaborator

bryce-carson commented Jul 17, 2024

Problem

@ashokkrish, according to the license of GADM data, we aren't allowed to redistribute the shape files (*sp_1.rda) without receiving prior permission to do so. I imagine this is frequently violated by users of GADM because they haven't read the license terms for the data. Have you received prior permission to do so, or should I modify spatialEpisim to download the data on demand on the user's machine, rather than these files being redistributed with spatialEpisim and increasing its download requirements (currently downloading spatialEpisim will require you to download the shapefiles for all countries, even if you're only interested in one).

Quoted from a License file included in a ZIP of a shapefile downloaded from https://www/gadm.org/

These data were extracted from the GADM database (www.gadm.org), version 3.4, April 2018. They can be used for non-commercial purposes only. It is not allowed to redistribute these data, or use them for commercial purposes, without prior consent. See the website (www.gadm.org) for more information.

See https://www.gadm.org/license.html for the license that applies to all formats, which imposes the same restrictions.

Alternative solutions to the problem

One

Either you've already contacted the GADM copyright holders and received prior permission to redistribute the files to suit our purposes, or you should do so that we may continue to redistribute them without continuing to violate their license.

Two

library(geodata)

##' Returns a SpatVector for the requested country on demand, either retrieving
##' the data from disk if it has been downloaded before, or downloading it for
##' the first time.
##'
##' The level one boundaries are the least granular administrative boundaries
##' that countries create to subdivide themselves.
##' @title Retrieve a SpatRaster of level 1 boundaries from local or remote disk
##' @param countryISO3C The uppercase ISO three character code a recognized
##'   country.
##' @return SpatVector
##' @author Bryce
lvl1AdminBorders <- function(ISO3C) {
  geodata::gadm(country = ISO3C,
                level = 1,
                path = here("gadm",
                            sprintf("gadm36_%s_1_sp.rds", tolower(ISO3C))),
                version = "3.6",
                resolution = 1)
}
@ashokkrish
Copy link
Owner

Thanks, I will fill out this form (https://rasterra.com/contact/gadm_contact_form) and seek permission.

@bryce-carson
Copy link
Collaborator Author

Thanks, I will fill out this form (https://rasterra.com/contact/gadm_contact_form) and seek permission.

Okay. For the future, you prefer that we distribute the files (if we are given permission) rather than download them on demand? The difference between the two is that:

  1. There is a remote possibilty that the GADM servers will be offline/unavailable at some point when a user wants to use spatialEpisim, and R won't be able to download the data; or they are trying to use spatialEpisim without being connected to the web and will likewise be unable to download the data when needed by the application.
  2. The user will be forced to download a lot of data before they can use spatialEpisim, but with the on-demand solution in TWO this won't occur. It would also immediately resolve the issue.

If we aren't given permission, then we must use solution two regardless.

@ashokkrish
Copy link
Owner

GADM servers are unreliable. I have experienced it during holidays and late late nights. I prefer we give this along with the code.

@bryce-carson
Copy link
Collaborator Author

GADM servers are unreliable.

That's unfortunate. Alright; we'll hope we are given permission.

@bryce-carson bryce-carson added the UNSTABLE The work is to be completed in the unstable branch label Jul 18, 2024
@bryce-carson
Copy link
Collaborator Author

@Toby-exe, while this ticket is unresolved, I think it's alright if we validate the uploaded coordinate data using the rnaturalearth package; that package is fully open-source, so there's no licensing issue. Conveniently, you've already completed the work for #5 & #25 when the vector/polygon data is taken from the rnaturalearth package.

Can you push those changes (before you began hacking on them further to enable use of GADM data) to the unstable branch on the GitHub remote?

@bryce-carson
Copy link
Collaborator Author

@ashokkrish, while we wait for a reply from the people who administrate and contribute to GADM, we should consider switching all of our vector data to use the rnaturalearth package. I read a small, limited blog post about various terrestrial vector data packages, and it looks like rnaturalearth has the benefit of being fully open source so we don't need to worry about a licensing issue.

Although, we are Canadian, so we're afforded some extra protections by our copyright laws; however, using GitHub, a U.S.-based company, to redistrubute the GADM files may pose some issues. Can you speak with the copyright office at Mount Royal to get some advice?

The simplest solution is hope we're given license by the GADM people, and have @Toby-exe resolve #5 and #25 with rnaturalearth only. The next simplest solution is to let @Toby-exe continue to hack on his solution to those issues and present one that will work without the rnaturalearth package. The most complex solution is to change all of our spatial vector data sources to rnaturalearth.

@bryce-carson
Copy link
Collaborator Author

@ashokkrish Any response from the GADM folks yet?

@bryce-carson
Copy link
Collaborator Author

I took a look at OpenStreetMap, and it has rather details administrative boundary data for the DRC, at least. It's license is compatible. We could use their database, which has an open license. It's a huge file, however. We could filter the database down to only what we need and redistribute that, perhaps.

https://www.openstreetmap.org/copyright

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
UNSTABLE The work is to be completed in the unstable branch
Projects
None yet
Development

No branches or pull requests

2 participants