IndexMaps with dim > 2 and the GPU

(Greg Cotten) #1

Hi all, directly implementing IndexMaps with a dim > 2 (with the exception of HalfDomain) is an optimization problem on the GPU. You basically have two options:

  1. Directly implement IndexMaps on the GPU with a for loop (bad)
  2. Convert the IndexMap to effectively be a 1D LUT - this will potentially cause imprecision unless the 1D LUT generated is insanely precise. I think @nick mentioned a 20-bit sized 1D LUT would be fine for Linear to ACEScc.

My question is - should we forgo IndexMaps with dim > 2 except for HalfDomain? I’ve implemented a HalfDomain index map on the GPU and it was pretty straightforward.