Skip to main content

load_weights

Function load_weights 

Source
pub fn load_weights(
    model: &ModelProto,
    model_dir: &Path,
    name_map: &HashMap<String, ValueId>,
) -> Result<WeightStore, LoaderError>
Expand description

Resolve all initializers, memory-mapping external data relative to model_dir. name_map maps initializer names to the graph value ids created by the graph_builder.