xnn.ffnn.models.amoeba_cpu#

The AMOEBA and HIPPO kernels on the CPU: xnn.common.cpu_kernels.launch() runs them as C++ loops, with lane-wise twins of the helpers and kernels that reduce over a block.

Functions

gather(grid, jac, w, start, batch, mesh, ...)

The launch of amoeba_kernels.gather_cartesian() or amoeba_kernels.gather_field() on the CPU (outputs the potential, gradient and Hessian arrays it stores into): the atoms in mesh-cell order, a contiguous share of them per thread.

launch(kernel, grid, *args, **meta)

Run kernel[grid](*args, **meta) on CPU tensors, as its twin when it has one.

mutual_field(mu, packed, rows, N[, guard])

amoeba_kernels.mutual_field() on the CPU from the row-ordered pair data of pack_rows().

pack_rows(r_vec, du, rows[, count])

The pairs' vectors (M, 3) and mutual ladders (M, 2) in the order of the compressed rows rows (amoeba_kernels.pair_rows()), (2 M, 5), with zero ladders for the pairs at or beyond count: built once per solve for mutual_field(), by one kernel.

spread_cartesian(q, d, Q, jac, w, start, ...)

amoeba_kernels.spread_cartesian() on the CPU: the atoms in mesh-cell order, a contiguous share of them per thread.