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

Method require_f32

src/framework/assets/tensor_source.cpp:371–378  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

369 throw std::runtime_error("missing tensor: " + std::string(name));
370 }
371 const auto [data, byte_size] = require_data_range(*info);
372 RawTensorData tensor;
373 tensor.metadata = TensorMetadata{info->name, info->dtype, info->shape};
374 tensor.bytes.resize(byte_size);
375 std::memcpy(tensor.bytes.data(), data, byte_size);
376 discard_data_range(*info);
377 return tensor;
378 }
379
380 void set_backend_tensor(
381 ggml_tensor * tensor,

Callers 12

load_weight_norm_conv1dFunction · 0.45
load_activationFunction · 0.45
load_from_safetensorsMethod · 0.45
load_conv1dFunction · 0.45
load_conv_transpose1dFunction · 0.45
load_linearFunction · 0.45
load_snakeFunction · 0.45
read_f32_tensorFunction · 0.45
load_conv1dFunction · 0.45

Calls 5

validate_expected_shapeFunction · 0.85
decode_tensor_data_f32Function · 0.85
shape_from_dimsFunction · 0.85

Tested by

no test coverage detected