Changed nn_cost parameter vector remapping to remap to the cell array instead.