QuantumKitHub/MatrixAlgebraKit.jl#86 for a reproducer
From within my augmented_primal function, right before it returns:
size.(primal) = ((19, 17), (17, 17), (17, 17), (1,))
From within test_reverse, after the forward from autodiff_thunk is run:
size.(y_ad) = ((19, 17), (1, 1), (17, 4818589264), (17,))
IDK what happened here but it looks like very bad things are happening to memory layout