Browse Source

feat(externcopr/nvidaopticalflow): fix output and fix cu context issue on

diff thread,  nvof loader outptr share with mgb ptr, upgrade lastest nvof sdk

GitOrigin-RevId: 6e003c6428
release-0.6
Megvii Engine Team 5 years ago
parent
commit
a808f807c6
2 changed files with 5 additions and 0 deletions
  1. +4
    -0
      src/serialization/impl/extern_c_opr.cpp
  2. +1
    -0
      src/serialization/include/megbrain/serialization/extern_c_opr.h

+ 4
- 0
src/serialization/impl/extern_c_opr.cpp View File

@@ -59,6 +59,8 @@ MGBDType dtype_cpp2c(DType dtype) {
return MGB_DTYPE_FLOAT32;
case DTypeEnum::Int32:
return MGB_DTYPE_INT32;
case DTypeEnum::Int16:
return MGB_DTYPE_INT16;
case DTypeEnum::Uint8:
return MGB_DTYPE_UINT8;
#if !MEGDNN_DISABLE_FLOAT16
@@ -75,6 +77,8 @@ DType dtype_c2cpp(MGBDType dtype) {
switch (dtype) {
case MGB_DTYPE_UINT8:
return dtype::Uint8{};
case MGB_DTYPE_INT16:
return dtype::Int16{};
case MGB_DTYPE_INT32:
return dtype::Int32{};
case MGB_DTYPE_FLOAT32:


+ 1
- 0
src/serialization/include/megbrain/serialization/extern_c_opr.h View File

@@ -36,6 +36,7 @@ typedef enum MGBDType {
MGB_DTYPE_UINT8,
//! IEEE 754-based half-precision floating
MGB_DTYPE_FLOAT16,
MGB_DTYPE_INT16,
} MGBDType;

typedef struct MGBTensorShape {


Loading…
Cancel
Save