Repository navigation
Tack 0.5.0
The headline: the API freeze. Arrays are NumPy-style (tack.Array is
storage; "field" means a dataset's field only), devices are values
(tack.device("cuda:1")), kernels use NumPy's and GLSL's names in place
of Taichi's, and the dataset package is tack.dataset, with one name per
operation: see the Breaking entries under Changed. Around it:
several devices of one type in one process, datasets that compute on their
own device, launches queued on every GPU backend with asyncio waits,
compiled kernels kept on disk, a debug mode that checks every array index,
a CPU thread pool compiled from LLVM IR, indexable device classes with
tack.arrays' implicit arrays in the core, and structure-of-arrays
storage. Windows works for the first time, on the CPU and on CUDA.
Validated on Linux (CPU; CUDA on an RTX 4060 Ti, an RTX 6000 Ada, an H100
and four A100s in one process; HIP on two MI210s; Level Zero on an Intel
Max 1100), macOS (CPU and Metal on an M1 Max) and Windows Server 2022 (CPU,
and CUDA on a T4), with debug mode and both id widths of the dataset tests,
together with tack-examples' 57 examples. The dataset filters agree with
VTK's at 10k to 1M cells and with Viskores' on CUDA, and run faster than
0.4.0's on the CPU and on CUDA, the backends compared. One thing is untested: memory export
(Array.export_memory) on Windows. A GPU in TCC mode, as Data Center GPUs
run on Windows Server, cannot export at all.
Added
-
Windows. The whole suite passes on Windows Server 2022 on the CPU and
with CUDA (a T4), after the fixes below: the disk cache stopped writing
when Windows refused to replace an open file, and CUDA failed on a GPU
without memory pools. The CPU's fan-out takes theThreadPoolExecutorthere, as
before: the JIT-compiled pool is POSIX only, so a launch needs more work
before it is worth threading (a fan-out costs 70–130 µs on Windows
against a few on Linux). -
Indexable objects. A
@tack.device_classthat defines__getitem__,
__setitem__and__len__as@tack.funcmethods is indexed in kernels
as an array is:obj[i],obj[i] = v,obj[i] += v(the index evaluated
once) andlen(obj), which may bound the parallel loop. Several indices,
obj[i, j], arrive as one vector. One kernel then takes a stored array or
any indexable object, compiled once for each. An instance tuple of
numbers,self.shape = (nx, ny), is one runtime scalar per entry, read
asobj.shape[k]with a literalk; a new shape does not recompile. A
class tuple,shape = (4, 4), is read the same way and compiled in. A
store without__setitem__, and an atomic on an indexable object, are
refused when the kernel compiles. -
tack.arrays: the implicit arrays (CountingArray,ConstantArray,
CartesianProduct,UniformCoordinates,Permutation,Concatenate,
View,Strided,ExtractComponent,Components,Function,
Transform,Cast,RandomUniform,RandomNormal) move from
tack.dataset.arraysinto tack-core and are indexable objects: any
kernel takes them as it takes a stored array,a[k]andlen(a), not
only through a dataset field. Breaking: import them from
tack.arrays;tack.datasetno longer re-exports them. -
tack.algorithms(scans, sorts,gather,unique,reduce_by_key, the
statistics,copy) take implicit arrays as inputs, read in their kernels
without storing them, and implicit arrays havesum,min,maxand
meanwith a stored array's semantics (computed into a temporary, then
reduced). An implicit array is on the device of the arrays it holds
(a.device), so these run and allocate there. -
Writable implicit arrays: a kernel's store into a
View,Stridedor
Permutationlands in the array it wraps (a permutation's is a scatter),
Components(x, y, z)writes each component to its own array, and
ConcatenateandExtractComponentwrite through too. An array is
writable when what it writes through is; a store into a computed array
is refused when the kernel compiles, and a read-only stored array stays
read-only behind a wrapper. -
Structure-of-arrays storage.
tack.soa(x, y, z)makes a vector array
(a matrix array withdtype=tack.mat2()...) whose components are
existing arrays of scalars, without copying, so data that arrives one
array per component (another library's tensors throughfrom_dlpack,
a device pointer througharray_from_ptr, on the CPU or a GPU) is a
tack.Arrayas it is.layout="soa"onempty,zeros,ones,
full,array,asarrayand the*_likeconstructors (which keep a
prototype's layout) makes new ones;a.layoutis"aos"or"soa"
anda.componentsgives the component arrays. Kernels index an SOA
array exactly as an interleaved one, loads, stores, components,
augmented stores and vector atomics, each component its own kernel
parameter; one kernel takes either layout, compiled once for each. On
the host it reads and writes as any vector array, andcopytoand
tack.array(a, layout=...)convert between layouts. Not available for
an SOA array: a scalar atomic at a flat component index, and export as
one buffer (DLPack,export_memory, VTK), which its components do. -
tack.__version__, the installed tack-core's version, and a docstring
fortack(help(tack)said nothing: the docstring followed code). -
NumPy-style arrays.
tack.Arrayis backend storage;tack.dataset.Field
is a function space plus coefficients, and "field" means only that now.
Constructors take the shape first, as NumPy's do:tack.empty(shape, dtype=f32),zeros,ones,full(shape, fill_value, dtype=None),
arange([start,] stop[, step], dtype=None),empty_like,zeros_like,
ones_like,full_like,array(obj, dtype=None),asarray,concat
andarray_from_ptr(ptr, shape, dtype). Any NumPy dtype is accepted
where a dtype is (np.float32,"float32"). Python floats default to
f32 and ints to i32 (i64 if a value needs it), since f64 is not on every
backend; a NumPy array keeps its dtype. Vectors and matrices are element
types:tack.empty((n,), tack.vec3()),vec(n, dtype),mat2...mat4,
mat(rows, columns, dtype);shapecounts elements anda.numpy()
gives(*shape, 3). Data moves witha.numpy()ornp.asarray(a),
await a.numpy_async(),tack.copyto(a, host)(strict, as
np.copyto: the host values havea.numpy()'s shape or broadcast to
it) anda.fill(value). Arrays also havendim,nbytesand
reshape(*shape)with one-1. -
asynciowaits:await tack.sync_async()andawait a.numpy_async()wait for the device in a worker thread, so an
application's event loop (trame, Jupyter, a server) keeps running
while kernels finish; kernel calls themselves are unchanged. On CUDA
the wait is an event on the context's stream, on Metal the last
committed command buffer, on Level Zero a host-visible event signalled
by a barrier on the backend's command list, on HIP an event on the
device's stream; on the CPU, whose launches complete before returning,
the wait is inline. During a 490 ms CUDA kernel another task ran 436
times while one awaitedsync_async, and not once undertack.sync();
during a 685 ms Level Zero kernel (Intel Max 1100), 311 to 384 times;
during a 1.45 s HIP kernel (MI210), 1353 times.
Level Zero'sto_numpy,read_rangeand reductions now wait on such
an event outside the backend's lock, so another thread may launch
while one waits. Every HIP wait (tack.sync(), reads, reductions) is
on an event too, through ctypes: hip-python's wrappers hold the GIL
while the runtime waits, which stopped every other Python thread for
the length of the kernel, and ROCm'shipStreamSynchronizeholds the
stream, so a launch from another thread took the whole wait (350 ms)
and now takes 60 µs. CUDA reads wait for the stream before they copy,
for the same reason: a copy to pageable host memory waited with the
context held, and a launch from another thread took the whole wait
(910 ms on an H100), now 43 µs. -
Compiled kernels are kept on disk, so a later process starts warm: the
first contour of a 21³ grid in a new process went from 445 ms (CPU) and
1.1 s (Metal) to 31 ms on an M1 Max. The lowered kernel and each
compiled variant are stored, keyed by content; an edited kernel, device
function, constant or template class, another Tack or another machine
compiles again.TACK_CACHE_DIRchooses the directory (by default the
platform's per-user cache directory) andTACK_CACHE=offturns it off;
tack.cache.configure()does either from Python. For MPI jobs on a
shared file system,python -m tack.cache packgathers a warm-up run's
entries into one bundle, which each rank reads once (or rank 0 reads and
broadcasts,tack.cache.load_bundle(comm=...)); under MPI nothing is
looked up or written per kernel. The entries take at most
TACK_CACHE_SIZE(1 GiB by default); the least recently used go first.
Every backend stores compiled code: CUDA its PTX, HIP its code objects,
Level Zero its native binary, with the SPIR-V to fall back on. Debug
mode's kernels are stored apart from the others.
See The Kernel Cache in the User's Guide. -
Debug mode:
tack.set_debug(True)orTACK_DEBUG=1checks every
array index in every kernel, one dimension at a time. An
out-of-bounds access is skipped (a load gives 0) and the call raises
IndexErrornaming the access, its file and line, the index and the
extent, and how many more were skipped; an access inside a device
function names it. It runs on every backend, compiles separately from
normal kernels, and does not compile per array length. Without it,
generated code is unchanged. -
pytest -m quick, a module per area of the code, 80 s on four
workers, andpytest -n autofor the whole suite across processes
(pytest-xdist is in thedevextra): 4:30 on eight workers where the
serial run took 28 minutes, with the same counts. See CLAUDE.md,
"Tests, in three tiers". -
An
interopextra for VTK and MFEM (PyMFEM), the references the dataset
tests compare against:uv sync --extra interopinstalls them from the
lock, where a lateruv syncused to remove a hand-installed copy. MFEM
is left out where PyMFEM has no wheels (anywhere but macOS on Apple
silicon and Linux x86_64). -
Datasets compute on their own device. A topology, field, set or dataset
is on the device its arrays are on (.device), and every algorithm,
derived entity,for_each,SetandCellLocatorruns and allocates
there, whatever the default device; before, any dataset off the default
device failed at its first launch ("arrays on two devices"). Parts on two
devices are refused when a dataset is made.DataSet.to_device(device)
copies one;uniform_grid,rectilinear_grid,waveletandtangle
takedevice=. Implicit arrays are on the device of the arrays they
hold:ConstantArray,UniformCoordinatesandCartesianProducttake
device=,to_devicemoves one, and one made from arrays on two devices
is refused. -
Edge sets and
extract_edges.Set(data, "edges", ids)selects edges by
their id intopology.edges(); an edge set is an iteration domain for
for_each, andas_polyhedracarries it.extract_edges(data, edges=None)gives the edges (all of them, or an edge set, its name or
ids) as line cells on the same points, each from its lower point id to its
higher, as VTK'svtkExtractEdgesfinds them: values on edges become
cell values and edge sets cell sets; cell fields are left behind. -
interpolate(data, function, space): a field whose values are a
@tack.funcof position at the space's nodes (H1of either order,L2,
Constant, values on points or cells), evaluated through the geometry
(curved included) without storing node positions. A node shared by
several cells is written once, by the first cell that has it; before, a
quadratic field took projecting the geometry into its space, a stored
array of node positions, and a kernel over them. -
Order-2
H1on triangles, quads and pixels: the six-node triangle and the
nine-node biquadratic quad, the faces of the tetrahedron's, wedge's and
hexahedron's order-2 elements. A mesh without quad faces of solids
(tetrahedra, triangles, quads) no longer derives faces for its order-2
layout.
Changed
-
The documentation site keeps every release's docs:
/latest/(the newest
release, where the site's root goes),/0.4/and on, and/dev/for
main, with a version selector and a banner on all but the latest. -
advectandstreamlineskeep their particles on the dataset's device:
seeds given as an array of 3-vectors are copied there, the particles'
positions are the output's geometry as they are, andstreamlines
chooses and numbers its paths with scans. Only counts come back to the
host; the particles and seeds used to go there and back. -
extract_surfacekeeps a solid's order-2H1fields and geometry at
order 2, the trace of the solid's: a face's corners, edge middles and (a
quad's) center are the surface cell's nodes, so their values are gathered
by entity id, not evaluated. It kept only the points' values before; a
2D mesh's boundary lines still do. -
Offsets and ids that are a linear ramp are computed where they are read
(CountingArray) rather than stored: an order-0L2space's offsets, a
structured grid'sL2offsets, and the edge groups' ids, which were also
rebuilt on everyedges().groups()call. Order-1L2on an unstructured
mesh already shared the connectivity's offsets. -
Breaking: tack.dataset names, one per operation.
external_faces(data)
isextract_surface(data), whosefacesnow default to the boundary.
to_points,to_cells,discontinuousand the publictracesare gone:
project(data, field, H1(data) | Constant(data) | L2(data) | SideTraces(data)).point_cloud(data)ismask_points(data, 1). The old
divergence, an outward sum with no volume, isnet_flux, unchanged;
divergenceis now the finite-volume divergence,net_fluxover each
cell's measure.statisticsreturns aStatisticsnamed tuple
(s.mean, nots["mean"]), andcheck_windinga cellSet.
clip(..., invert=True)isclip(..., inside=True), andcontour's
isovalueisvalue. The reference states the rules: what each kind of
algorithm returns, and that the point filters are the cell filters'
point twins (point fields carried, cell fields left behind). -
Breaking: CPU threading policy v1 is removed; the policy that has
been the default since 2026-08-10 is the only one.TACK_CPU_POLICY=v2
(or unset) is still accepted, and any other value,v1included, raises
ValueError.CPUBackend.policyandCPUBackend.marginare gone (the
margin in use is_margin()). -
The install instructions say how to install from source: Tack is not on
PyPI yet, andpip install tack-corefound nothing. The README, the
guide, the backends reference and the errors for a missing backend now
giveuv sync --extra ...orpip install -e 'packages/tack-core[...]'
in a clone. -
Breaking:
tack.deprecatedis gone: the first vis worklets
(flying_edges,compute_normals,cell_to_point,amr_blanking) and
the finite-element helpers intack.fe, with the examples written on
them (contour, marching cubes, flying edges, point-to-cell,mini_vtk,
thetack.feisolines and isosurfaces).tack.datasetsupersedes them:
contourforflying_edges,to_pointsforcell_to_point,
gradientsandprojectfor the finite-element helpers. -
Breaking:
tack-rendering(path tracer, rasterizer, volume renderer)
is archived inarchive/tack-renderingand no longer part of the
workspace, the tests or the documentation, until the dataset API and its
implementation settle. Its user-guide chapter, the isosurface tutorial,
the two cross-package examples and the rendering benchmarks moved with it. -
Breaking: the dataset package is now
tack.dataset, replacing
tack.data. Useimport tack.dataset as td; submodules move with it
(for example,tack.dataset.algorithms; the implicit arrays have since
moved on totack.arrays). The dataset model and algorithm signatures
are unchanged. -
Breaking: devices are values, spelled as the array API spells them,
andtack.initis gone with thetack.cpu/metal/cuda/hip/
level_zeroconstants.tack.device("cuda")(or"cuda:0","cpu",
"metal","hip","level_zero") is atack.Device, the same one
every time; options (num_threads,external_context) make a new one.
tack.set_default_device(...)chooses the default,get_default_device()
reads it, andwith tack.device(...):sets it in a block, per thread.
tack.set_debug()replacesinit(debug=...);TACK_DEBUGis read at
import. Arrays know their device (a.device,a.to_device(...), and
device=on every constructor), and a kernel runs where its arrays are,
so changing the default no longer strands arrays made before it; arrays
on two devices are refused, bytack.algorithms,copytoandconcat
under their own names.tack.algorithmsrun on their inputs' device,
andtack.sync()andtack.sync_async()wait for every device.
"cuda:N","hip:N"and"level_zero:N"reach every GPU, and
tack.device_count(type)counts them; a bare"cuda"or"hip"is the
device the thread already uses (a framework's current CUDA context, HIP's
current device), else 0. With a second device in use, every CUDA or HIP
operation makes its own context or device current and restores the
thread's. DLPack carries the device number both ways.
tack.from_dlpack(x)keeps memory on its own device when the default
cannot wrap it, as the array API's does: CUDA memory with the CPU as
default is a CUDA array, host memory with Metal as default a CPU array;
device=still refuses what it cannot wrap.Backend.init_options
isBackend.device_options. A warm dispatch costs about 0.4 µs more
(6.7 to 7.1 µs on an M1 Max) for reading its arrays' devices. -
Breaking: kernel values and loops are spelled as NumPy and GLSL
spell them, and Taichi's names are gone. Vectors aretack.vec2,
vec3,vec4(N scalars, one scalar for every component, or one
N-vector); a list of scalars is still a vector. Matrices aretack.mat2
tomat4(rows, or N*N row-major scalars),tack.mat(row, ...)for any
shape up to 4x4, andtack.identity(n); on the host the same names are
element dtypes. A zero-dimensional array's element isa[()], in kernels
and on the host;a[None]is refused.tack.ndrangeistack.ndindex.
Removed:tack.Vector,tack.Matrix,tack.template()(an annotation
nothing read) anddata_oriented. -
Breaking for code that reaches inside Tack: storage is "array"
throughout the core too. The module istack.lang.array; the backend
contract's hooks areallocate_array,fill_arrayandreduce_array;
the IR's nodes areIRArrayLoad,IRArrayStoreandIRArrayExtent;
messages, docstrings, the language contract and the design pages say
"array" where they said "field". The User's Guide chapter is
02-arrays-and-types.md. -
Breaking: the old storage API is gone, without deprecation:
tack.field(usetack.empty(shape, dtype)),field_from_numpyand
field_like(tack.array),field_from_ptr(array_from_ptr(ptr, shape, dtype)),Vector.fieldandMatrix.field(tack.empty(shape, tack.vec(n, dtype)),tack.mat(...)),a.to_numpy()(a.numpy()),
a.from_numpy(x)(tack.copyto(a, x)) andto_numpy_async
(numpy_async).zeros,ones,fullandarangetake NumPy's
argument order. The flat host layout ofVector.fieldandMatrix.field
went with them: a vector array'sshapecounts vectors and its values
download and upload as rows, andcopytorefuses a flat array.
tack.interop.vtk'svtk_to_fieldandfield_to_vtkare
vtk_to_arrayandarray_to_vtk(array, ...).
local_array_likeandshared_likeremain allocation-only helpers. -
A scan's small levels are one launch: a level of at most 4096 elements
on the CPU, or one tile on a GPU backend, is scanned in order by one
thread, and the total is read as one element instead of copied by a
kernel. A million elements take three launches on the CPU instead of
eight; a contour at 1M cells makes 26 launches instead of 40 and a
threshold 18 instead of 33. Floating sums now matchnp.cumsumbit
for bit through 4096 elements on the CPU and 2048 on GPUs (512 and 8
before). -
A warm dispatch costs less host time: the fast path keeps each
array's signature and each buffer's address and byte range once
computed, holds the variants it resolved instead of looking them up,
learns each template class's attribute layout once, checks array
overlap in one walk of the ranges, packs the pool's arguments with one
struct.pack_into, and skips the template scope and the texture
walks when a call has none. A serial dispatch of a kernel with eight
array arguments went from 66 to 34 µs on a 2 GHz Xeon, and inside a
dataset filter the host time per launch from 149 to 130 µs. -
A CPU launch wakes only the pool workers it uses: each worker waits on
its own mailbox, a launch ofkthreads posts tok - 1of them, and
the rest sleep on, so thekof every launch are the samek.
A hot fan-out of two threads on a pool of sixteen cost 11 µs waking
every worker and costs 4.4. -
tack.emptyreturns uninitialized storage on every backend;tack.zeros
is the call that pays for zeros. The CPU backend used to fill every new
array on the calling thread, which at 5M cells on eight threads of a
2 GHz Xeon was half of threshold's and cell-to-point's time and grew
with the thread count. An array is now first touched by the kernel that
writes it, and a CPU fill of 256 KiB or more (sozeros,ones,
full) runs as a kernel through the dispatch, so the threads share it
and the pages land where they will be used; the executor's threads are
made under the NUMA interleave policy as the pool's are. The dataset
filters' fully written flag and offset arrays take plain arrays.
Backend.fill_arrayis the hook. On Linux,TACK_CPU_MALLOC=1also
tells glibc to keep freed pages (mallopt: the mmap threshold at its
32 MiB cap, no trim under 4 GiB of free heap, the heap grown 256 MiB
at a time), since a filter reallocates the same temporaries on every
call and takes their page faults every time: threshold at 5M on 8
threads of one NUMA node 126 → 104 ms, slice 76 → 65. Off by default:
it changesmallocfor the whole process, and unbound on a 28-core
EPYC it did not pay. -
The CPU backend fans a range out through a thread pool JIT-compiled from
LLVM IR, with one ctypes call per launch and no Python on the workers'
path, instead of oneThreadPoolExecutortask per worker. A fan-out that
cost 60 µs per worker on a 2 GHz Xeon (1.2 ms for eight after an idle
gap) costs a few microseconds, so short launches thread too: the dataset
filters at a million cells went from 1.05× to 1.9× on eight threads
there. Workers claim chunks from a counter rather than taking one equal
share each, so one slowed by a sibling hyperthread or an uneven range
takes fewer. Dispatches from several
Python threads take turns at the pool, and a pool whose workers cannot
all be started is dismantled before the executor takes over.
TACK_CPU_POOL=pythonkeeps the executor, which remains the fallback
on Windows. -
A dispatch whose argument signature was seen before resolves its
variant from that signature instead of rebuilding the key, and the
CPU backend passes array addresses rather than typed pointer objects:
a warm dispatch costs 40 µs instead of 70 on a 2 GHz Xeon, on every
backend, which for a filter of forty launches is a few milliseconds. -
NUMA interleave no longer replaces a bound thread's memory policy: a
process started undernumactl --membindkeeps its binding, and the
probe at the CPU backend's start puts back the policy it found instead of the
default. -
CUDA and HIP launches are queued on a stream and return at once; the
host waits where it reads an array (numpy(), indexing, reductions,
DLPack export) or callstack.sync(). Fills and host writes queue in order
with the launches, and an array dropped while a queued launch still uses
it is freed after that launch (stream-ordered memory). A contour of a
million cells on an RTX 4060 Ti went from 9.6 to 7.1 ms, now the cost
of its 31 launches' host side alone; on an MI210, from 6.3 to 4.8 ms.
Errors of a launch surface at the next wait rather than at its call, as
on Metal. -
Level Zero launches are queued the same way, on one asynchronous
immediate command list with a barrier after each command; fills and
host writes queue in order with them (from a private copy of the host
array, so it may change at once), and a dropped array is freed after the
work queued before it (the driver's deferred free). On an Intel Max
1100, 100 small launches went from 8.7 to 2.6 ms, and a contour of a
million hexahedra from about 24 to 18 ms. Ordering by barriers rather
than an in-order list: Intel's in-order lists cost about 100 µs of device
time per kernel on driver 25.05. Copies to the device up to 16 MiB and
from it up to 64 KiB go through pooled USM host memory: from pageable
memory the driver does not return from appending such a copy until the
queue has drained, so a launch whose scalars were uploaded behind a
680 ms kernel waited 682 ms, now under 1 ms, and 100 small launches with
a changing scalar take 5.4 ms rather than 8.7. -
A CPU array of 1 MiB or more takes the NUMA interleave policy for its
range when it is allocated (mbind), so its pages spread over the
memory nodes whichever thread touches them first, a serial launch,
from_numpyor a NumPy temporary included, and keep spreading when
glibc hands the block out again. Pages already placed on a reused block
are moved once (move_pages, in 2 MiB steps, so no huge page is split).
A thread bound withnumactlkeeps its binding. On a two-node EPYC at
28 threads, tet contour's and slice's reused blocks had sat 77–89% on
one node, and those filters ran 10–20% slower. -
Allocating a vector or matrix array costs a third of what it did:
shape products usemath.prod, wherenp.prodmade a NumPy array of
each small shape tuple, six times per vector allocation (10 µs each on
a 2 GHz Xeon). The small point filters on CUDA (cylindrical and
spherical coordinates, warp, point transform, point elevation) lost
80 µs a call at 10k–100k points against 0.4.0, and are now faster than
it.
Fixed
-
CUDA on a GPU without memory pools, such as a Data Center GPU in TCC mode
on Windows: every allocation failed, since the backend always used
cuMemAllocAsync. Such a device allocates withcuMemAlloc, and a
dropped array is freed once the stream is idle, at the next allocation
or sync, becausecuMemFreewaits for the whole device (1.26 s behind
an unrelated kernel on a T4). Exporting memory from such a device, which
has no virtual memory management either, now says so. -
The disk cache stopped storing for the rest of the process on Windows
when another process had an entry open: Windows refuses to replace an
open file, and the cache took that for an unwritable directory. It now
keeps the entry already there, since entries are named by their content. -
On Intel GPUs with IGC 2.7.11 (compute runtime 25.05), a vector or matrix
component selected at a runtime index defined by a conditional
expression in a sequential loop could read the wrong component: IGC
miscompiles a chain of 64-bit compares. The selector is compared as an
i32 (recorded in the vendor workarounds). -
The nearest point of a cell, outside a quad, hexahedron, wedge or pyramid,
was its position at clamped parametric coordinates, exact only for an
axis-aligned box or a rectangle (TA-39). It is now the nearest point of a
solid's faces, or of the quad itself, a quad taken as two triangles (exact
when planar), as VTK finds it for a hexahedron since 2026-07.CellLocator,
probeand advection accept a point within a tolerance of it, so a point
just outside a skewed cell is found where it can be. -
A parallel loop bounded by a local,
n = x.shape[0]; for i in range(n),
failed at dispatch ("Cannot resolve loop range expression"), and so did
len(obj)for an indexable object whose__len__returns an array's
shape[0]. Such a bound is now read from the arguments, and a new
length reuses the compiled kernel. -
A device-class instance attribute that shadows a class constant with
something other than a number (obj.SCALE = [1, 2]) made every call
fail with "unhashable type: 'list'". Such an attribute now drops the
constant, as a subclass attribute does; a method that reads it gets the
error that names the attribute. -
HIP works with hip-python 10, the newest on PyPI and what
tack-core[hip]installs. Tack importedhip.LONG_VERSION, which 10 does
not have, so HIP read as unavailable and its tests skipped; it also lacks
hip.chip, and returns the output structs ofhipPointerGetAttributes
andhipGetDevicePropertiesinstead of filling them, and gives the device
name asstr. 7.x keeps working. -
Grids with a size of 1 before another axis --
uniform_grid((1, 3)), a
VTK image of dimensions(1, m, n)-- were refused; so were grids of one
point or none ((1, 1, 1),(0,),wavelet(extent=0)). A size of 1 now
adds no cells in any position, and a grid with no axis of two points has
none. -
Cells of no volume and faces of no area (coincident points, a grid of
spacing 0) have finite geometry: measure 0, the centroid at their points'
mean and zero normals, so the flux through them is 0. Their gradients,
flow quantities and Perot reconstruction are NaN, as before, and now
documented. -
A contour or clip crossing beside an infinite or NaN value lies at the
finite end, where the crossing and the fields carried to it were NaN. -
algorithms.histogramandentropyrefuse a range that is not finite
(asnumpy.histogramdoes), a reversed range and fewer than one bin;
entropyof no values says so, and of one value is0.0, not-0.0. -
A mesh of line cells (a 1D grid, VTK lines) derived no faces, so its
external_faceswere empty andface_geometry,upwind_flux,
divergenceandperotfailed with an internal error. Faces of lines
are not derived yet, and asking now raisesNotImplementedError. -
extract_cellstakes a cellSet, or its name indata.sets. -
dataset_to_vtkwrites a grid of one point or none as a grid. -
On HIP, a variable could hold two values: hipRTC fused a product into one
read of it while another read it rounded, sox - xwas the product's
rounding error rather than zero. A contour of a computed field (such as
Function(ramp, n)) then put some crossings at an edge's end. HIP now
fuses multiply and add only inside one expression, as the language
contract says. -
extract_surfacechecked neither face ids nor a faceSet's topology:
an id past the face count, or negative, was read out of bounds and gave
wrong cells silently, and another topology's set was used as this one's.
Both are refused now, asextract_cellsrefuses them; out-of-range ids
raiseIndexError, counted on the ids' device. -
tack.algorithms.norm,var,std,absmax,count_nonzero,dot
andhistogramread a givennas scalar components of a vector array
(norm(v, n=2)of 3-vectors took two components);nnow counts
vectors. -
Vector implicit arrays (
UniformCoordinates,CartesianProduct,
Components, a vectorConstantArray) failed to compile ingather,
unique,reduce_by_keyand the statistics; they give what the same
vectors stored give.uniquetakes vector keys, stored or implicit. -
A kernel with a
returnshared one result array across calls, so two
threads calling it at once could read each other's result. It is kept
per thread. -
vtk_to_datasetrefused a grid ofVTK_POLYGONcells, which is how
dataset_to_vtkwrites a polygonal topology (a polyhedral contour or
slice,as_polygons); it reads it back as aPolygonalTopology. A
warped or transformed structured grid, which keeps its topology over
explicit coordinates, could not be exported; it is avtkStructuredGrid,
andvtk_to_datasetreads one. -
3D
contour,gradientsandvalues_at_centersrefused a field of
values on points (such aspoint_idsor a gradient at the points), which
project,thresholdand 2D contour read as order-1H1; all of them
do now. -
Planesstored its planes in f32 whatever the data;Planes(origins, normals, dtype=tack.f64)keeps f64 data at its precision. -
tack.arrays.Stridedgiven NumPy data kept a NumPy dtype where a Tack
type belongs; it stores the data as the other implicit arrays do.
Castconverts to all ten scalar types.