onnx: pytest error "No Schema registered for Abs with domain_version of 6"

After successful installation from source on Windows (with pip install -e onnx), I’m trying to run the tests but getting “No Schema registered for Abs with domain_version of 6” error. Am I missing something?

(test-py36) c:\repos\onnx>pytest -x
============================= test session starts =============================
platform win32 -- Python 3.6.5, pytest-3.5.1, py-1.5.3, pluggy-0.6.0
rootdir: c:\repos\onnx, inifile: setup.cfg
plugins: cov-2.5.1, nbval-0.9.0
collected 1520 items

onnx\test\backend_shape_inference_test.py F

================================== FAILURES ===================================
____________________ OnnxBackendNodeModelTest.test_abs_cpu ____________________

test_self = <backend_shape_inference_test.OnnxBackendNodeModelTest testMethod=test_abs_cpu>
device = 'CPU'

    def run(test_self, device):
        if model_test.model_dir is None:
            model_dir = self._prepare_model_data(model_test)
        else:
            model_dir = model_test.model_dir
        model_pb_path = os.path.join(model_dir, 'model.onnx')
        model = onnx.load(model_pb_path)
        model_marker[0] = model
>       prepared_model = self.backend.prepare(model, device)

onnx\backend\test\runner\__init__.py:237:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
onnx\test\backend_shape_inference_test.py:22: in prepare
    super(DummyBackend, cls).prepare(model, device, **kwargs)
onnx\backend\base.py:55: in prepare
    onnx.checker.check_model(model)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

model = ir_version: 3
producer_name: "backend-test"
graph {
  node {
    input: "x"
    output: "y"
    op_type: "Abs"
  }
  n...    }
          dim {
            dim_value: 5
          }
        }
      }
    }
  }
}
opset_import {
  version: 6
}


    def check_model(model):
>       C.check_model(model.SerializeToString())
E       onnx.onnx_cpp2py_export.checker.ValidationError: No Schema registered for Abs with domain_version of 6
E
E       ==> Context: Bad node spec: input: "x" output: "y" op_type: "Abs"

onnx\checker.py:76: ValidationError

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Comments: 20 (20 by maintainers)

Most upvoted comments

Do you have multiple VS instance installed? e.g. VS 2015. It looks like wholearchive compile flag doesn’t take effect, that flag is only supported after VS 2015 update 2