setup:
-using PYNQ-Z2 board with V2.7 image
-powered with adapter with jumper to REG
issue:
while running test_benchmark_topi_conv2d.py I am getting RPCError in both with local as well as downloaded bit stream file. pl help in rootcausing.
log:
xilinx@pynq:~/tvm$ python ./vta/tests/python/integration/test_benchmark_topi_conv2d.py
URLError(ConnectionResetError(104, ‘Connection reset by peer’))
Download attempt 0/3 failed, retrying.
URLError(ConnectionResetError(104, ‘Connection reset by peer’))
Download attempt 1/3 failed, retrying.
Conv2DWorkload(batch=1, height=56, width=56, in_filter=64, out_filter=64, hkernel=3, wkernel=3, hpad=1, wpad=1, hstride=1, wstride=1)
CPU CONV2D TEST PASSED: Time cost = 0.143871 sec/op, 1.60708 GOPS
Conv2DWorkload(batch=1, height=56, width=56, in_filter=64, out_filter=128, hkernel=3, wkernel=3, hpad=1, wpad=1, hstride=2, wstride=2)
CPU CONV2D TEST PASSED: Time cost = 0.0770264 sec/op, 1.50086 GOPS
Conv2DWorkload(batch=1, height=56, width=56, in_filter=64, out_filter=128, hkernel=1, wkernel=1, hpad=0, wpad=0, hstride=2, wstride=2)
CPU CONV2D TEST PASSED: Time cost = 0.01033 sec/op, 1.24347 GOPS
Conv2DWorkload(batch=1, height=28, width=28, in_filter=128, out_filter=128, hkernel=3, wkernel=3, hpad=1, wpad=1, hstride=1, wstride=1)
CPU CONV2D TEST PASSED: Time cost = 0.162596 sec/op, 1.422 GOPS
Conv2DWorkload(batch=1, height=28, width=28, in_filter=128, out_filter=256, hkernel=3, wkernel=3, hpad=1, wpad=1, hstride=2, wstride=2)
CPU CONV2D TEST PASSED: Time cost = 0.0778063 sec/op, 1.48581 GOPS
Conv2DWorkload(batch=1, height=28, width=28, in_filter=128, out_filter=256, hkernel=1, wkernel=1, hpad=0, wpad=0, hstride=2, wstride=2)
CPU CONV2D TEST PASSED: Time cost = 0.0098826 sec/op, 1.29976 GOPS
Conv2DWorkload(batch=1, height=14, width=14, in_filter=256, out_filter=256, hkernel=3, wkernel=3, hpad=1, wpad=1, hstride=1, wstride=1)
CPU CONV2D TEST PASSED: Time cost = 0.171096 sec/op, 1.35135 GOPS
Conv2DWorkload(batch=1, height=14, width=14, in_filter=256, out_filter=512, hkernel=3, wkernel=3, hpad=1, wpad=1, hstride=2, wstride=2)
CPU CONV2D TEST PASSED: Time cost = 0.105497 sec/op, 1.09582 GOPS
Conv2DWorkload(batch=1, height=14, width=14, in_filter=256, out_filter=512, hkernel=1, wkernel=1, hpad=0, wpad=0, hstride=2, wstride=2)
CPU CONV2D TEST PASSED: Time cost = 0.0126969 sec/op, 1.01167 GOPS
Conv2DWorkload(batch=1, height=7, width=7, in_filter=512, out_filter=512, hkernel=3, wkernel=3, hpad=1, wpad=1, hstride=1, wstride=1)
CPU CONV2D TEST PASSED: Time cost = 0.202319 sec/op, 1.14281 GOPS
Traceback (most recent call last):
File “./vta/tests/python/integration/test_benchmark_topi_conv2d.py”, line 318, in
test_conv2d(device=“vta”)
File “./vta/tests/python/integration/test_benchmark_topi_conv2d.py”, line 313, in test_conv2d
vta.testing.run(_run)
File “/home/xilinx/tvm/vta/python/vta/testing/utils.py”, line 74, in run
run_func(env, remote)
File “./vta/tests/python/integration/test_benchmark_topi_conv2d.py”, line 304, in _run
program_fpga(remote, bitstream=None)
File “/home/xilinx/tvm/vta/python/vta/rpc_client.py”, line 68, in program_fpga
fprogram(os.path.basename(bitstream))
File “/home/xilinx/tvm/python/tvm/_ffi/_ctypes/packed_func.py”, line 239, in call
raise_last_ffi_error()
File “/home/xilinx/tvm/python/tvm/_ffi/base.py”, line 476, in raise_last_ffi_error
raise py_err
tvm.error.RPCError: Traceback (most recent call last):
3: tvm::runtime::RPCWrappedFunc::operator()(tvm::runtime::TVMArgs, tvm::runtime::TVMRetValue*) const
2: tvm::runtime::RPCClientSession::CallFunc(void*, TVMValue const*, int const*, int, std::function<void (tvm::runtime::TVMArgs)> const&)
1: tvm::runtime::RPCEndpoint::CallFunc(void*, TVMValue const*, int const*, int, std::function<void (tvm::runtime::TVMArgs)>)
0: tvm::runtime::RPCEndpoint::HandleUntilReturnEvent(bool, std::function<void (tvm::runtime::TVMArgs)>)
File “/home/xilinx/tvm/src/runtime/rpc/rpc_endpoint.cc”, line 390
RPCError: Error caught from RPC call:
xilinx@pynq:~/tvm$ ls -l /home/xilinx/.vta_cache/pynq/0_0_2/1x16_i8w8a32_15_15_18_17.bit
-rw-rw-r-- 1 xilinx xilinx 4045671 Nov 4 02:30 /home/xilinx/.vta_cache/pynq/0_0_2/1x16_i8w8a32_15_15_18_17.bit
xilinx@pynq:~/tvm$ date
Sat 04 Nov 2023 02:50:33 AM UTC
xilinx@pynq:~/tvm$ ls -l /home/xilinx/bitstreams/pynq/0.0.2/1x16_i8w8a32_15_15_18_17.bit
-rwxrwxrwx 1 xilinx xilinx 4045671 Nov 2 14:02 /home/xilinx/bitstreams/pynq/0.0.2/1x16_i8w8a32_15_15_18_17.bit
xilinx@pynq:~/tvm$
server side log:
xilinx@pynq:~/tvm$ sudo ./apps/vta_rpc/start_rpc_server.sh
[sudo] password for xilinx:
INFO:numexpr.utils:NumExpr defaulting to 2 threads.
2023-11-04 02:19:13.925 INFO bind to 0.0.0.0:9091
2023-11-04 02:20:26.364 INFO connected from (‘192.168.2.99’, 48604)
2023-11-04 02:20:26.434 INFO start serving at /tmp/tmpr15zipi2
INFO:root:Loading VTA library: /home/xilinx/tvm/vta/python/vta/…/…/…/build/libvta.so
2023-11-04 02:20:59.721 INFO load_module /tmp/tmpr15zipi2/conv2d.o
INFO:root:Loading VTA library: /home/xilinx/tvm/vta/python/vta/…/…/…/build/libvta.so
2023-11-04 02:21:27.994 INFO load_module /tmp/tmpr15zipi2/conv2d.o
INFO:root:Loading VTA library: /home/xilinx/tvm/vta/python/vta/…/…/…/build/libvta.so
2023-11-04 02:21:43.721 INFO load_module /tmp/tmpr15zipi2/conv2d.o
INFO:root:Loading VTA library: /home/xilinx/tvm/vta/python/vta/…/…/…/build/libvta.so
2023-11-04 02:22:11.356 INFO load_module /tmp/tmpr15zipi2/conv2d.o
INFO:root:Loading VTA library: /home/xilinx/tvm/vta/python/vta/…/…/…/build/libvta.so
2023-11-04 02:22:53.086 INFO load_module /tmp/tmpr15zipi2/conv2d.o
INFO:root:Loading VTA library: /home/xilinx/tvm/vta/python/vta/…/…/…/build/libvta.so
2023-11-04 02:23:20.331 INFO load_module /tmp/tmpr15zipi2/conv2d.o
INFO:root:Loading VTA library: /home/xilinx/tvm/vta/python/vta/…/…/…/build/libvta.so
2023-11-04 02:24:14.126 INFO load_module /tmp/tmpr15zipi2/conv2d.o
INFO:root:Loading VTA library: /home/xilinx/tvm/vta/python/vta/…/…/…/build/libvta.so
2023-11-04 02:25:52.478 INFO load_module /tmp/tmpr15zipi2/conv2d.o
INFO:root:Loading VTA library: /home/xilinx/tvm/vta/python/vta/…/…/…/build/libvta.so
2023-11-04 02:27:07.138 INFO load_module /tmp/tmpr15zipi2/conv2d.o
INFO:root:Loading VTA library: /home/xilinx/tvm/vta/python/vta/…/…/…/build/libvta.so
2023-11-04 02:29:54.947 INFO load_module /tmp/tmpr15zipi2/conv2d.o
2023-11-04 02:29:57.461 INFO finish serving (‘192.168.2.99’, 48604)
2023-11-04 02:29:57.468 INFO connected from (‘192.168.2.99’, 48612)
2023-11-04 02:29:57.471 INFO start serving at /tmp/tmpqvkk1t9r
INFO:root:Generating grammar tables from /usr/lib/python3.8/lib2to3/Grammar.txt
INFO:root:Generating grammar tables from /usr/lib/python3.8/lib2to3/PatternGrammar.txt
2023-11-04 02:30:20.159 INFO finish serving (‘192.168.2.99’, 48612)