bug fixed for mlp