Giter Club home page Giter Club logo

Comments (11)

mpu-creare avatar mpu-creare commented on June 17, 2024

This code might be useful: https://github.com/creare-com/pydem/blob/master/pydem/utils.py#L145

from podpac.

mpu-creare avatar mpu-creare commented on June 17, 2024

This might also be useful: https://pyproj4.github.io/pyproj/stable/api/crs/crs.html

from podpac.

CFoye-Creare avatar CFoye-Creare commented on June 17, 2024

Left to-do

  • Finish Unit Tests
  • Check for units

from podpac.

CFoye-Creare avatar CFoye-Creare commented on June 17, 2024
  • cKDTree with boxsize wraparound implementation for stacked NearestNeighbor
  • UTM projection handling

from podpac.

mpu-creare avatar mpu-creare commented on June 17, 2024

For coords.horizontal_resolution(units='m', type='nominal'), let's talk about the different types

types =

  • "nominal" <-- this is wrong but cheap to calculate. Give a 'nominal' resolution over the entire domain
  • "summary" <-- This is still approximate, gives the mean and standard deviation to each point
  • "full" <-- min distance between every point (dx, dy, basically)
  • "full_exact" <-- uses brute-force for the stacked coordinates

This is a proposal, feel free to propose something better.

from podpac.

CFoye-Creare avatar CFoye-Creare commented on June 17, 2024

Implemented 3 of the 4 types:

  • "nominal" <-- this is wrong but cheap to calculate. Give a 'nominal' resolution over the entire domain
  • "summary" <--- Returns average and std.dev for each point.
  • "full" <--- returns the exact distance between every point, or every dx,dy if coordinates are unstacked

from podpac.

CFoye-Creare avatar CFoye-Creare commented on June 17, 2024

9851b1c

from podpac.

CFoye-Creare avatar CFoye-Creare commented on June 17, 2024

e05a662

from podpac.

CFoye-Creare avatar CFoye-Creare commented on June 17, 2024

Wrote some code to address the problem of lat/lon evaluating to different distances based upon the other dimension's value. However, I realized once passing in non-square unstacked coordinates that I failed to account for the difference resolution changing for each differing value of the other dimension.

Let our unstacked coordinate system be a $M$ by $N$ matrix, where $M$ is the number of rows (in grid squares), and $N$ is the number of columns. See Blender visualization:

image

Previously, we were returning two arrays of size $M$ and size $N$. This meant we were returning either a single row/column or a selection of each column. For example:
image
Another example:
image

Instead, we want to return this for latitude:
image

So, for latitude we want to return a $N$ by $M$ matrix.

For longitude:
image
So, for longitude we want to return a $M$ by $N$ matrix.

For the "summary" type resolution, we can simply average/compute std.dev of all of these values.

from podpac.

CFoye-Creare avatar CFoye-Creare commented on June 17, 2024

The $M+1$ or $N+1$ implementation is not possible due to the fact we don't store the values in the +1 dimension in our coords.

from podpac.

mpu-creare avatar mpu-creare commented on June 17, 2024

closed by #505

from podpac.

Related Issues (20)

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.