added test module. train now writes the bias term in the output model.