Ältere Kommentare anzeigen
ライブ映像から連続的に予測をしたいと思っております。事前に作成した回帰を使いたいのですが、初心者で何から手をつけて行けばいいのかわからないです。やり方や、その参考となる資料をご教授していただけないでしょうか?よろしくお願いします!
Antworten (1)
Kojiro Saito
am 25 Sep. 2022
回帰モデルをnetという変数でnet.matファイルに保存し、webcamで1秒ごとに撮影した画像を回帰に掛けるダミーコードは以下のとおりです。while 文にしているので、Ctrl+C で中止されるまで実行される例です。
load('net.mat')
cam = webcam('xxx');
while true
img = snapshot(cam);
pred = predict(net, img);
% 1秒後に次のループを実行
pause(1)
end
Kategorien
Mehr zu Image Acquisition Support Packages for Hardware Adaptors (Generic Video Interface) finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!