File tree 1 file changed +12
-4
lines changed
1 file changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -612,13 +612,21 @@ impl Model {
612
612
graph. add_constant ( name, const_data)
613
613
}
614
614
Some ( sg:: ConstantDataType :: Int8 ) => {
615
- let const_data =
616
- constant_data_from_storage_offset :: < i8 > ( storage, & shape, data_offset) ?;
615
+ let const_data = constant_data_from_storage_offset :: < i8 > (
616
+ storage,
617
+ & shape,
618
+ strides. as_deref ( ) ,
619
+ data_offset,
620
+ ) ?;
617
621
graph. add_constant ( name, const_data)
618
622
}
619
623
Some ( sg:: ConstantDataType :: UInt8 ) => {
620
- let const_data =
621
- constant_data_from_storage_offset :: < u8 > ( storage, & shape, data_offset) ?;
624
+ let const_data = constant_data_from_storage_offset :: < u8 > (
625
+ storage,
626
+ & shape,
627
+ strides. as_deref ( ) ,
628
+ data_offset,
629
+ ) ?;
622
630
graph. add_constant ( name, const_data)
623
631
}
624
632
_ => {
You can’t perform that action at this time.
0 commit comments