address overlapping
Required prerequisites
-
Make sure you've read the documentation. Your issue may be addressed there. -
Search the issue tracker and discussions to verify that this hasn't already been reported. +1 or comment there if it has.
What commit version of aidge do you use
-
aidge
: 0.5.0 -
aidge_backend_cpu
: 0.5.0 -
aidge_backend_cuda
: 0.5.0 -
aidge_core
: 0.5.1 -
aidge_export_cpp
: 0.2.1 -
aidge_onnx
: 0.4.1 -
aidge_quantization
: 0.3.0
Problem description
I noticed an address overlap when running my yoloV3. Indeed, we see that 2 successive layers use the same output address. Extracting the schedule shows that layer 19_JAdd depends on 14_JConv and 17_Scaling. Layer 14_JConv writes its outputs to address 0x83fcf5a4. However, according to the router, the next layer to be executed is 15_Scaling, which will also use address 0x83fcf5a4. It then overwrites the data dedicated to layer 19_JAdd before it is even used! There is a memory mapping error: maybe the memory manager?
Scheduling extract of Yolo V3
print("Scheduling:")
for i, n in enumerate(scheduler.get_static_scheduling()):
print(f"\t- {i} {n.name()} [{n.type()}]")
Scheduling:
- 0 roi__105_1 [Producer]
- 1 scales__127_1 [Producer]
- 2 _93_JConv_41_shift [Producer]
- 3 _21_JConv_10_weights [Producer]
- 4 _100_JConv_46_shift [Producer]
- (...)
- 226 _12_JPad_2 [JPad]
- 227 _13_JConv_6 [JConv]
- 228 _14_JConv_7 [JConv] <=
- 229 _15_JScaling_2 [JScaling] <=
- 230 _16_JScaling_3 [JScaling]
- 231 _17_JConv_8 [JConv]
- 232 _18_JAdd_2 [JAdd]
- 233 _19_JConv_9 [JConv] <=
- 234 _20_JAdd_3 [JAdd]
Extract of execution on Hardware Plateform
inputs - 0x849df6a4
outputs - **0x83fcf5a4**
inputs_buffer - 0x64800000
weights_buffer - 0x64844441
biases_buffer - 0x6484d441
outputs_buffer - 0x6484dc41
[AIDGE COMPARE] - _14_JConv_7
[SUCCESS]
inputs - 0x83dcf5a4
outputs - **0x83fcf5a4**
inputs_buffer - 0x64800000
outputs_buffer - 0x6481fffe
[AIDGE COMPARE] - _15_JScaling_2
[SUCCESS]
inputs_buffer - 0x64800000
weights_buffer - 0x64840000
biases_buffer - 0x64842000
outputs_buffer - 0x64842400
[AIDGE COMPARE] - _16_JConv_8
[SUCCESS]
inputs - 0x83dcf5a4
outputs - 0x841cf5a4
inputs_buffer - 0x64800000
outputs_buffer - 0x6481fffe
[AIDGE COMPARE] - _17_JScaling_3
[SUCCESS]
inputs_buffer - 0x64800000
weights_buffer - 0x6482e5c1
biases_buffer - 0x648375c1
outputs_buffer - 0x64837dc1
inputs - 0x843cf5a4
weights - 0x83dacc84
biases - 0x0
outputs - 0x83dcf5a4
[AIDGE COMPARE] - _18_JConv_9
[SUCCESS]
inputs0 - 0x841cf5a4
inputs1 - **0x83fcf5a4**
outputs - 0x844d76a4
inputs_buffer0 - 0x64800000
inputs_buffer1 - 0x6481fffe
outputs_buffer - 0x6483fffc
[AIDGE COMPARE] - _19_JAdd_2
[ERROR] - First error detected at 0x0x0 (out x h x w) : aidge_out = 4 vs dev_out = 9
Abort program.