Repository navigation
Plan: octrees, filters, distributed forests and rendering (#498) - #517
berkgeveci wants to merge 1 commit into
Conversation
|
|
||
| - **piecewise constant**: `leaves()`, and every D4 and D5 filter; | ||
| - **the dual grid**: leaf centres as points, a cell for each corner where leaves | ||
| meet (VTK's hyper tree grid dual), linear on it. Contour and derivatives use it; |
There was a problem hiding this comment.
D7 takes gradients from face neighbours by least squares, not from the dual. One of the two needs to change.
| cell's triangles where it is crossed, carrying other fields to the points. Its | ||
| triangles are VTK's hyper tree grid contour's (a test compares them). | ||
| `gradients` of a cell field uses face neighbours: a least-squares fit over the | ||
| face neighbours' centres, weighted by inverse squared distance, exact for a |
There was a problem hiding this comment.
A leaf beside finer leaves has as its face neighbour the refined node of its own size. What value does that node give: one read from the file, or average_up computed first? From from_cells data, refined nodes have none.
| - **One layer suffices with 2:1 balance**, which xRAGE and RAMSES enforce: every | ||
| dual cell of an owned leaf lies in its neighbourhood. Balance is checked, and | ||
| a reply that is itself refined is probed again one level deeper. | ||
| - **Owners are found by boxes**, not by a key-to-rank function, which xRAGE's |
There was a problem hiding this comment.
Boxes fit imported data. If Tack later partitions forests itself, would the curve's owner lookup replace the box search there, with the ring built the same way?
|
|
||
| A rank emits a dual cell, a triangle, a face or a gradient only when its **owner | ||
| leaf** is its own: for a dual cell the finest leaf around its corner, the lowest | ||
| slot on a tie; for a face the smaller side, the lower on a tie; for a gradient |
There was a problem hiding this comment.
The output is the same however the ranks are cut only if "slot" means something every rank computes the same way, such as (tree, level, key). An index into the local forest differs from rank to rank. Please define it.
| owned or duplicate, and mark the duplicates. | ||
|
|
||
| Reductions across ranks (`average_up` over split trees, `project_along`'s | ||
| columns, histograms) go through `all_reduce` and `exclusive_scan` in global-id |
There was a problem hiding this comment.
all_reduce of each rank's partial sums adds them in an order that depends on the partition, so the floating-point bits differ when a tree is cut differently. Getting the same bits needs a fixed order of combination (gather, then sum in global order) or exact summation. Otherwise, say the results agree to rounding, not bit for bit.
| continuous across sizes. A device class, so a marcher or a kernel of one's own | ||
| calls it. | ||
| - **`corner_values(octree, field)`**: the tents' values at each leaf's corners, | ||
| computed once (7 s at 82M cells), after which a sample is trilinear in its leaf. |
There was a problem hiding this comment.
On which device? A time series pays this once a step, and again whenever the field changes. If that's on the CPU, the plan should say whether it becomes a kernel.
|
The filters, the D10 rule (seams decided by which leaf owns them) and the rendering look right. One scope question first. This plan reads forests that other codes made. Is a p4est-like layer (refine and coarsen, balance enforced, partition along a space-filling curve, ghosts) meant to come later in Tack, or with #493 in the other repository? I'd like it in Tack, under both, so that D8 to D10 and #493 share one forest, with partitioning by box search for imported data and by the curve for forests Tack makes. If that's later, a line in "Not in this plan" saying where it goes would settle it. |
The plan for #498, as
docs/design/plans/octrees.md. It plans the move of the octree study (branchvis/octreeson berkgeveci/tack-fork, about 13,000 lines and 200 tests, never reviewed) into Tack, in nine PRs.Measured in the study:
Decisions D1-D13, each with a recommendation; reply per decision. In three groups:
with_fields;tdnames where the meaning is the same (td.contour(octree, ...));REMOTECELLplaceholders;ghost_cells(pieces, layers=1, world=), byRouting;tack.communication(a fragment a box in kd order, direct send);tack-rendering(tack.rendering).Out of this plan: file I/O, the demand-driven VTK reader, simulating on octrees (#493, to a separate repository), readers and in-situ adaptors, and repartitioning.
Docs only:
mkdocs build --strictis clean.This plan will be merged (accepted) after the 0.8 release.
🤖 Generated with Claude Code