home.social

#quadtree — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #quadtree, aggregated by home.social.

fetched live
  1. Тап по тысяче точек за O(log n): QuadTree и сферическая геометрия в гео-соцсети

    9 лет назад я разрабатывал геолокационную соц.сеть на заказ, где мы отображали чаты на карте. До релиза не дошло, но интересного опыта было получено много. В очередной статье из серии рассказываю про то, как обрабатывать нажатия на MapBox и любой другой карте (Google, Yandex – не важно) и находить нужные объекты на ней, привязанные к координатам.

    habr.com/ru/articles/1051948/

    #iOS #Swift #алгоритмы #QuadTree #структуры_данных #пространственный_индекс #сферическая_геометрия #Mapbox #карты #оптимизация

  2. Тап по тысяче точек за O(log n): QuadTree и сферическая геометрия в гео-соцсети

    Как-то раз я разрабатывал геолокационную соцсеть. Эта статья – продолжение предыдущей, в ней описывается, как определить, на что на карте нажал пользователь, если движок нам не предоставляет такую информацию. Как только маркеры на карте перестают быть UIView и становятся точками в GL-слое, карта больше не знает, на что ты тапнул: она отдаёт только координату пальца, а дальше твои проблемы. Разбираю, как клиентский QuadTree на плоскости сферического меркатора превращает «на какое из тысячи облаков я попал» и «какие показать в кадре» из O(n)-перебора в спуск по дереву за O(log n). Заодно — зачем для перевода «пиксели ↔ метры ↔ координаты» пришлось портировать в Swift кусок сферической тригонометрии из Google Maps Utils, и почему «честный» top-N в отборе аур проиграл намеренно неравномерному 20/60/20.

    habr.com/ru/articles/1051694/

    #алгоритмы #QuadTree #структуры_данных #пространственный_индекс #сферическая_геометрия #Mapbox #карты #оптимизация

  3. 🥳 Ah, the timeless joy of explaining quadtrees to an audience who couldn't care less! 🌳 Why not just spend an afternoon watching paint dry instead? 🎨 It's a hands-on guide to wasting perfectly good processor cycles while pretending to teach efficiency! 🕰️
    growingswe.com/blog/quadtrees #quadtree #humor #inefficiency #tech #education #programming #HackerNews #ngated

  4. 🤔🎨 Ah, yes, yet another attempt to make data structures "fun" by shoehorning them into #Clojure. Who wouldn't want to spend their weekend navigating a "functional" #quadtree demo that ironically leaves mobile users clicking aimlessly? 📱🔍
    lbjgruppen.com/en/posts/functi #dataStructures #functionalProgramming #UXdesign #HackerNews #HackerNews #ngated

  5. More manure from the Kaka Farm!

    https://github.com/Halfwake/guile-quad-tree/commit/edb94c2529dacc32e744125a70057d899dbd727f

    • Add some area querying procedures tests, one for region (a rectangle) the other for a circle.

    • Use SRFI-64 test-group. Need further work on better naming of groups, maybe.

    • Made format in the tests.scm file only print when *debug* is true.

    • Rename helper-insert procedure to a more meaningful name.

    • Add a the #:replace-when-same-position? keyword argument to the quad-tree-insert procedure. If true, and the position of the inserted item is already inhabited by another item, the item is replaced.

    • Add and use some auxiliary region procedures region-half-width and region-half-height.

    • Add docstring to the make-point-box. This is not Common Lisp, but I wish we had that kind of docstring in the language.

    • Export the <region> type. I am not sure if exporting so much is a good thing.

    • Write region-intersects-circle? in a wee bit better way, I think.

    #gnu #guile #kakafarm #lisp #quadtree #scheme

  6. MassivePoints 0.12.0 is released.

    * Fixed boundary coordinate precision on calculation for splitting.
    * Fixed the globe bound.
    * Added coordinate points validation process on sample code.
    * Added more xml comments.

    #dotnet #gis #quadtree

    github.com/kekyo/MassivePoints

  7. MassivePoints 0.10.0 is released.

    * Split session interface between updatable and readable.
    * Supported multi-dimensional coordinate points. (1D, 2D, 3D and more)

    #dotnet #gis #quadtree

    github.com/kekyo/MassivePoints

  8. MassivePoints 0.9.0 is released.

    * Added bulk insert features.
    * Improved concurrency.
    * Implemented index shrinking.

    #dotnet #gis #quadtree

    github.com/kekyo/MassivePoints

  9. MassivePoints 0.8.0 is released.

    .NET implementation of QuadTree, hold a very large number of 2D coordinates and perform fast range searches, with in-memory and database offloading.

    #dotnet #gis #quadtree

    github.com/kekyo/MassivePoints

  10. Randomly stumbled into #kdtree #quadtree #algorithm today and it happened to allllmost line up with a work problem I've been pondering.

    My problem involves moving objects. Not just moving, but I want to query them at different points in time.

    I think if I just add a time dimension (HexTrees?) it might work...? I'm not clear on the details of the actual algorithm or how this would work. #software #math

  11. Been getting several DMs about the #GenerativeArt banner image in my profile. It's an old render (from 2010) of a recursive #Voronoi projected into a #Quadtree. This video shows the interplay of 2 conceptual hierarchies:

    1) Verlet particles with attractive/repulsive force fields are spawned in a squared 2d space and negotiate their positions over time. These positions are also used as sites for creating a dynamic Voronoi diagram to define cell structures around each particle. Each resulting Voronoi region can then become the physical (and constantly changing) bounds for the next level of recursion, spawning more particles to subdivide it into smaller regions. Each cell at each level is using its own Voronoi instance with sub-regions clipped to their respective parent region. The process becomes more and more local... The setup in the video has a maximum tree depth of 3.

    2) A quadtree is used to visualize the hierarchy of cells from phase 1 and its depth structure represented as extruded 3D model (in isometric perspective). For this video the quadtree has a depth of 10 levels with the maximum level of recursion tracing/coinciding with the Voronoi cell edges. The elevation of cell walls depends on the depth of the cell in the original tree, with the cells at deepest level resulting in the tallest structures. Furthermore, the elevation is modulated by the distance of each point to the nearest vertex of its parent cell polygon/region...

    #Toxiclibs #Sunflow #GenerativeDesign #Architecture