Ushma30 / MobileNet-V1

Apache License 2.0
3 stars 4 forks source link

sw-emu error , ERROR: std::bad_alloc #1

Closed sinaasadiyan closed 5 years ago

sinaasadiyan commented 5 years ago

Hey,

I tested your implementation in SDaccel, and i got ERROR: std::bad_alloc error during sw-emu, seems somehow the problem is using deprecated APIs or bad allocating arrays in host side. Xilinx recommends using align allocator but i dont know if that is the problem or not. As you have also uploaded sdaccel report i think the problem is with my environment, do you know any solution with that?

i am using SDx 2018.3 and xilinx_aws-vu9p-f1-04261818_dynamic_5_0

and in line 259 in MobileNet.c file, the offset value seems to be 80, and is typed 0

kmhatre14 commented 5 years ago

Hi @sinatv52 we are also using sdx 2018.3 and xilinx_aws-vu9p-f1-04261818_dynamic_5_0

Are you able to run the helloworld_ocl example with sw_emu We have used the same make file used in that.

Check this out this might help,

line 259 is fixed.

Thank you

sinaasadiyan commented 5 years ago

This problem was solved. SDaccel couldnt find the xclbin. with absolute path of xclbin file i don't get this error anymore.

but still has errors and does not run completely. The new error is about not releasing Opencl objects. I thought the problem is with my environment but my friend also gets the same error. I checked main objects like program, contex, commandqueue and... i did not find any not released. some of them like avgPool kernel seems to be in a region that does not need to be released and you have not used clReleasekernel(avgPool) with other kernel release which is true. Still i don't know what is the problem, maybe sth has not released or freed.

The Error:

WARNING: Profiling may contain incomplete information. Please ensure all OpenCL objects are released by your host code (e.g., clReleaseProgram()). terminate called without an active exception.