Skip to content

Commit 53b72fc

Browse files
committed
Fix jettagger XN>1 issue
1 parent 85983d7 commit 53b72fc

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

deepsocflow/py/xmodel.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@ def verify_inference(model, hw, SIM, SIM_PATH='', TRACE=False):
368368
''' Verify tiled output'''
369369
if (ib == len(BUNDLES)-1):
370370
if b.softmax:
371-
y_tiled_exp = b.out.ftensor.numpy().reshape(1,b.r.XN,1,b.r.CO)
371+
y_tiled_exp = b.out.ftensor.numpy().reshape(1,b.r.XH,1,b.r.CO)
372372
y_tiled_sim = np.loadtxt(f"{hw.DATA_DIR}/{b.ib}_y_tiled_sim.txt", np.float32).reshape(y_tiled_exp.shape)/2**17
373373
error = np.max(np.abs(y_tiled_sim-y_tiled_exp))
374374
assert np.allclose(y_tiled_sim, y_tiled_exp, atol=0.5), f"Error={error}, \nsub:\n{y_tiled_sim-y_tiled_exp} for y_tiled_sim at {b.ib=}. \n y_tiled_sim=\n{y_tiled_sim} \n y_tiled_exp=\n{y_tiled_exp}\n \npre_softmax=\n{b.pre_softmax}"

run/jettagger.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ def test_dnn_engine(PARAMS):
202202
'''
203203
VERIFY & EXPORT
204204
'''
205-
export_inference(loaded_model, hw, hw.ROWS)
205+
export_inference(loaded_model, hw, batch_size=hw.ROWS)
206206
verify_inference(loaded_model, hw, SIM=SIM)
207207

208208
d_perf = predict_model_performance(hw)

0 commit comments

Comments
 (0)