File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -44,13 +44,14 @@ bool upyOpenCVBoot() {
44
44
45
45
// Initializes `StdMatAllocator` on the C heap, see:
46
46
// https://github.com/sparkfun/micropython-opencv/issues/17
47
+ //
47
48
// Alternatively, we could set the NumpyAllocator as the default Mat
48
- // allocator with Mat::setDefaultAllocator(&GetNumpyAllocator()),
49
+ // allocator with ` Mat::setDefaultAllocator(&GetNumpyAllocator())` ,
49
50
// however that actually causes some issues. For example, Canny()
50
- // creates an temporary 64-bit float Mat, which is not supported by
51
- // ulab NumPy and therefore fails if we use the NumpyAllocator. The
52
- // StdMatAllocator is fine , because it calls `malloc()`, which we catch
53
- // with `__wrap_malloc()` to ensure the data is allocated on the GC heap
51
+ // creates a temporary 64-bit float Mat, which is not supported by ulab
52
+ // NumPy and therefore fails with the NumpyAllocator. StdMatAllocator is
53
+ // fine to use , because it calls `malloc()`, which we catch with
54
+ // `__wrap_malloc()` to ensure the data is allocated on the GC heap
54
55
Mat::getDefaultAllocator ();
55
56
56
57
return true ;
You can’t perform that action at this time.
0 commit comments