NervanaSystems / ngraph-mxnet

MXNet - nGraph integration

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Mutli-nGraph Backend Unit tests

mbrookhart opened this issue · comments

Acceptance Criteria:

  1. NGraph unit tests run the standard operator unit tests with the new context from #289
  2. MXNet test files are not modified.
  3. tests nGraph needs to skip are handled in the nGraph test files.
  4. CI is updated to use new context tests.

A few (mutually exclusive) ideas for how to solve this:

  • Add a feature to MXNet itself in which the default context can be overridden via an environment variable.
  • Modify the test scripts so that CMake's "configure" system tweaks which particular hardcoded context is used.

Haven't gotten to fleshing this one out yet, mxnet.test_utils.set_default_context can do this. The basic idea is, say, make a test_ngraph_cpu.py file, have a mxnet.test_utils.set_default_context(mx.ngraph("CPU")), a from test_operator import *, and an if __name__=='__main__': import nose nose.runmodule()