Giter Club home page Giter Club logo

biodiversityobservationnetworks.jl's People

Contributors

gottacatchenall avatar karinorman avatar thomalpas avatar tpoisot avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

biodiversityobservationnetworks.jl's Issues

JuliaFormatter

In response to

Looks good, should we merge and then apply blue style w/ JuliaFormatter?

Originally posted by @gottacatchenall in #5 (review)

Definitely -- it might be a good idea to add a formatter file at the repo's root. I don't like everything in BlueStyle, but we do want a formatter.

Alternatively, can it be running at github actions time?

Working group roadmap 🗺️

During the spatial metaweb working group meetings, we discussed a roadmap for the package development and writing of the package manuscript. This is what we planned (in chronological order):

  • [ ] API simulation to batching
  • v0.1 goes live
  • Vignette and documentation
  • Test if having species distributions in estimate is better (since it is already a part of the uncertainty score)
  • GEO BON flex
  • Cube algorithm
  • Trade-offs in temporal sampling (costs)
  • Input layer of the number of unknown interactions (and type ? score ?)
  • Preprint (December 2022) - Methods (Pkg), Ecography (maps)
  • Modify simulation so optimization

We should check off the ones that have already been done, and write the others as individual issues and milestones, when appropriate.

API change for `seed` and `seed!` required

In order to write things like X |> seed(BalancedAcceptance()) |> refine(AdaptiveSpatial()), all seed and seed! methods need to return a tuple matching the arguments to the curried methods for refine and refine!.

This sounds like word salad but -- I'll make this happen when #5 is merged

Ideas for v1.0

  • Error handling

    • Each invalid call should throw an error of abstract type BONException
    • Have a documentation section for each subtype of BONException to enable user debugging
  • Algorithms

    • cube sampling (refiner)
    • Environmental uniquness via KNN (seeder)
      • Take the vector of layers at each cell in the raster and applies knn to each cell in the raster. choose the closest cell in the raster to the k cluster centers
    • fractal triad, or some scale dependence thing, maybe
  • Documentation

    • A tutorial section that gives background info not specific to the package for new users
    • Uniqueness vignette includes KNNUniqueness and has more text
    • Vignette on cube smapling

:bug: overloads of `seed` and `refine` for `SDMLayers`

bbox = (left=-83.0, bottom=46.4, right=-55.2, top=63.7);
h = convert(Float32, SimpleSDMPredictor(WorldClim, BioClim, 7; bbox...))
h |> seed(BalancedAcceptance)

fails with

ERROR: MethodError: no method matching seed!(::Vector{CartesianIndex}, ::BalancedAcceptance{Int64, Float64}, ::SimpleSDMResponse{Float32})
Closest candidates are:
  seed!(::Vector{CartesianIndex}, ::ST) where ST<:BONSeeder at ~/.julia/packages/BiodiversityObservationNetworks/IR0dX/src/seed.jl:30
  seed!(::Vector{CartesianIndex}, ::ST, ::Matrix{T}) where {ST<:BONSeeder, T<:AbstractFloat} at ~/.julia/packages/BiodiversityObservationNetworks/IR0dX/src/seed.jl:9

Overload \circ

Hear me out: (BalancedAcceptance(numpoints=100)∘AdaptiveSpatial(numpoints=10))(X)

This specifies a complete pipeline for a matrix of entropy, and it's probably the most concise notation we can think of.

Devt. next steps

Little heads up that I've moved this package under the lab org so it reflects the contributors -- nothing else changes (tagging @gottacatchenall )

API change(ish)?

@gottacatchenall what is your input on the following additional way to use the package: rand(method, landscape, coordinates)?

Hear me out: what if we want to get 1000 points using a first method, and then 100 using a second method. Something like:

landscape |> rand(method1) |> rand(method2)

would be very cool to write, right? As far as I can tell the only change required would be to make sure that the methods return (landscape, coordinates), and maybe an additional method so that rand(method) is a function that unpack its arguments?

This would deviate from what rand does, so we may want to think about a rename? monitoringsites?

[RFC] Deciding on methods for optimizing spatial sampling methods to implement

This package implements methods for optimizing the location of spatial sampling for biodiversity monitoring as part of the block 3 for the GEOBON manuscript project.

The following methods are primarily what I've seen in the literature for optimizing spatial sampling.

Opening this up as a place for discussion to decide on a final list of methods before implementing.


1. Fractal Triads Simpson et al 2021
Proposed to measure phenomena across scales. Of those listed here, this is the simplest, as it always recommends a set of nested triangles, and does not use any information about the landscape/species (e.g. an SDM) to design points.

2. Generalised random-tessellation stratification (GRTS) Stevens and Olsen (2004)
Argues spatially balanced sampling is best, where spatially balanced is defined as meaning both points are not clumped together, but also that all spatially contiguous subsamples of this total sample are also spatially balanced. Proposes a method to generate balanced samples better than random sampling.

3. Pivotal Method (Grafstrom 2011)
Proposed improvement to GRTS

4. Balanced acceptance sampling (van Dam-Bates et al 2018)
Proposed improvement to GRTS and Pivotal method


Methods below this line are different in that they use some spatial information to design samples (e.g. environmental predictors for an SDM, or an SDM with uncertainties)

5. Spatial Simulated Annealing van Groenigen 1998, and computational improvement by (Chen et al 2013). Optimizes spatial locations such that they minimize covariance among a set of spatial covariates (e.g. environmental raster data).

6 Adaptive sampling (Andrade-Pacheco et al 2020)
Prioritizes spatial location based on current uncertainty of measurement there

integration with `SDMLayers`

Needs an implementation of rand or _generate that handles SDMLayers as inputs, in particular, handling of nothing values

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.