TrackerCSRT not included in the wasm bundle
this is my dockerfile
FROM emscripten/emsdk:3.1.46
WORKDIR /src
RUN git clone --depth 1 https://github.com/opencv/opencv.git && \
git clone --depth 1 https://github.com/opencv/opencv_contrib.git
WORKDIR /src/opencv
RUN emcmake python3 ./platforms/js/build_js.py build_wasm \
--build_wasm \
--disable_single_file \
--cmake_option="-DOPENCV_EXTRA_MODULES_PATH=/src/opencv_contrib/modules" \
--cmake_option="-DBUILD_opencv_tracking=ON"
# Copy build artifacts to the same paths expected by the release workflow
FROM alpine:3.20
WORKDIR /src/opencv/build_wasm/bin
COPY --from=0 /src/opencv/build_wasm/bin/opencv.js ./opencv.js
COPY --from=0 /src/opencv/build_wasm/bin/opencv_js.wasm ./opencv_js.wasm
These are the only trackers included:
Am I doing something wrong? I tested a few trackers in python but TrackerCSRT is the best one for my situation, so I'd like to use that in the WASM build as well. Thanks!
OpenCV JS bundle doesn't bring all public OpenCV functions.
- Bundle size may be very big.
- Not all modules/functions are well supported. There are still some corner cases.
TrackerMIL is described here: https://github.com/opencv/opencv/blob/4.x/modules/video/misc/js/gen_dict.json
This contrib module (tracking) is not adopted for JS, and doesn't have JS binding configuration here: https://github.com/opencv/opencv_contrib/tree/4.x/modules/tracking/misc
Ref: https://github.com/opencv/opencv/pull/25986
@opencv-alalek thanks for the reply. Is there a way to include another module? Can I override that whitelist and add TrackerCSRT to it?