Get the value of property from bagOfWords
1 次查看(过去 30 天)
显示 更早的评论
Hi,
I have got following bagOfWords and need to extract the number of words into an arrary. How is that possible?
bagOfWords with properties:
Counts: [1×68 double]
Vocabulary: [1×68 string]
NumWords: 68
NumDocuments: 1
Thanks in advance
采纳的回答
Walter Roberson
2020-7-15
bag.NumWords
2 个评论
Walter Roberson
2020-7-15
data = cat(1, image_patches,labels);
That code is overwriting all of data each iteration.
It looks to me as if data will not be a vector, but I do not seem to be able to locate any hellopatches() function so I cannot tell what shape it will be. As you are not doing imresize() I also cannot be sure that all of the images are the same size, so I cannot be sure that data will be the same size for each iteration. Under the circumstances you should be considering saving into a cell array.
Note: please do not post the same query multiple times. I found at least 3 copies of your query :(
更多回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!