From c2f2af39d2f33e2b5f9aacb48b08ec9eb2f13a76 Mon Sep 17 00:00:00 2001
From: Yaman Umuroglu <yamanu@xilinx.com>
Date: Tue, 3 Sep 2019 15:43:28 +0100
Subject: [PATCH] move up brevitas import to top of file

---
 tests/test_brevitas_export.py | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/tests/test_brevitas_export.py b/tests/test_brevitas_export.py
index d7e1c5e73..d0df91f74 100644
--- a/tests/test_brevitas_export.py
+++ b/tests/test_brevitas_export.py
@@ -2,6 +2,7 @@ import os
 from functools import reduce
 from operator import mul
 
+import brevitas.onnx as bo
 import onnx
 import onnx.numpy_helper as nph
 import torch
@@ -73,8 +74,6 @@ def test_brevitas_to_onnx_export():
     export_onnx_path = "test_output_lfc.onnx"
     with torch.no_grad():
         lfc = LFC(weight_bit_width=1, act_bit_width=1, in_bit_width=1)
-        import brevitas.onnx as bo
-
         bo.prepare_for_onnx_export(lfc, True)
         torch.onnx.export(
             lfc, torch.empty(784, dtype=torch.float), export_onnx_path, verbose=True
-- 
GitLab