Binary SVM Cascade Classifier

조회 수: 1 (최근 30일)
Andrés Vacas
Andrés Vacas 2017년 6월 24일
댓글: Andrés Vacas 2017년 6월 27일
I am trying to train a SVM with data that I have extracted from movie scenes. This data comes in .xml files and contains information about both audio and video of the scene. Now I am having problems in finding how to train a SVM in Matlab. First of all it is not clear how to get the data from the files that I have generated and get them to be correctly operated by Matlab.
Just to give more info, the classification has to be in cascade because I have got 4 movie genres. So my question is:
How can I get the data from my .xml files and train them with a SVM using Matlab?
Thank you for your time.
  댓글 수: 1
Andrés Vacas
Andrés Vacas 2017년 6월 26일
I already got the info out of the xml files. Now I would like to know what file extension or format(.txt, .csv, .xls...) is best supported by the training commands and what command is best.
Thank you for your help

댓글을 달려면 로그인하십시오.

채택된 답변

Mudambi Srivatsa
Mudambi Srivatsa 2017년 6월 26일
You can import data from a variety of file formats (.txt, .csv, .xls and so on) into MATLAB table format using "readtable" function.
Refer to the following link for more information:
https://www.mathworks.com/help/matlab/ref/readtable.html
Once you import the table data, you can use it in "fitcsvm" to train or cross-validate SVM as follows:
Mdl = fitcsvm(Tbl,ResponseVarName)
  댓글 수: 1
Andrés Vacas
Andrés Vacas 2017년 6월 27일
Thank you Mudambi!! That solved my doubt.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Statistics and Machine Learning Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by