def validate_parameters(params, shape):
 validator = ParamValidator()
 report = validator.validate(params, shape)
 if report.has_errors():
  raise ParamValidationError(report=report.generate_report())

def validate_parameters ( params , shape ) : validator = ParamValidator ( ) report = validator . validate ( params , shape ) if report . has_errors ( ) : raise ParamValidationError ( report = report . generate_report ( ) )
validates input parameters against a schema .