MCPcopy Create free account
hub / github.com/0xShug0/audio.cpp / validate_expected_shape

Function validate_expected_shape

src/framework/assets/tensor_source.cpp:37–44  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

35 case 1:
36 return core::TensorShape::from_dims({dims[0]});
37 case 2:
38 return core::TensorShape::from_dims({dims[0], dims[1]});
39 case 3:
40 return core::TensorShape::from_dims({dims[0], dims[1], dims[2]});
41 case 4:
42 return core::TensorShape::from_dims({dims[0], dims[1], dims[2], dims[3]});
43 default:
44 throw std::runtime_error("unsupported tensor rank");
45 }
46}
47

Callers 4

set_backend_tensorMethod · 0.85
require_f32Method · 0.85
require_tensorMethod · 0.85

Calls 1

stringFunction · 0.50

Tested by

no test coverage detected