denispeplin / wunder_task

Lat/lon operations

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Wunder

Play with coordinates. Get a task description here

Installation

mix deps.get
mix do ecto.create, ecto.migrate

Usage

Read pairs and create bounding boxes

Wunder.BoundingBox.read()

Save pairs + coordinates and match boxes

Wunder.save_data() |> Wunder.Models.Box.matching_coordinates()

Match pair of coordinates to a box

box = Wunder.Repo.get!(Wunder.Models.Box, 123)
Wunder.PairToBox.match(box, [{1, 2}, {3, 4}])

Testing

MIX_ENV=test mix do ecto.create, ecto.migrate
mix test

Notes

Project includes pairs.csv (162 valid pairs) and coordinates.csv (1314 coordinates), but only 5 coordinates match to corresponding boxes.

About

Lat/lon operations


Languages

Language:Elixir 100.0%