def _to_input_sig(inputs): if isinstance(inputs, rules.TypeSignature): return inputs else: in_type = [validate_type(x) for x in inputs] return rules.TypeSignature([rules.value_typed_as(x) for x in in_type])
def _operation_type_conversion(inputs, output): in_type = [validate_type(x) for x in inputs] in_values = [rules.value_typed_as(_convert_types(x)) for x in in_type] out_type = validate_type(output) out_value = rules.shape_like_flatargs(out_type) return (in_values, out_value)
def _operation_type_conversion(inputs, output): in_type = [ir._validate_type(x) for x in inputs] in_values = [rules.value_typed_as(_convert_types(x)) for x in in_type] out_type = ir._validate_type(output) out_value = rules.shape_like_flatargs(out_type) return (in_values, out_value)