Corrections to expanded layers in nn_cost