Questions tagged [mat]

Use this tag for questions dealing with opencv cv::Mat (or cvMat) data structure. Use [mat-file] tag for Matlab binary file format. Use [matrix] tag for other types of 2D numeric data structures.

cv::Mat (or cvMat) is a basic data structure defined by to handle tabular (2D or 3D) numeric data.

DO NOT CONFUSE THIS TAG WITH
for general data structures for tabular numeric data.
for Matlab's binary file format.

941 questions
-1
votes
1 answer

Extract values from a fig file?

Given the fig file ( for example https://file.io/6Ud5sALJHi6e) how can I turn it into a ".mat" file ?
MementoMori
  • 283
  • 4
  • 10
-1
votes
1 answer

Dynamical adding checkbox to each row in table angular

In the above image i want to add checkbox and its label dynamical to each row when click on 'Add New checkbox' button. so when i click on it button will visible a input box and type the checkbox name and submit the new checkbox will visible only…
Abru007
  • 435
  • 4
  • 12
-1
votes
1 answer

Add decimal value formate for fild in angulare

I Want To Set Number Format Decimal Like 0.00 In Material Filed My Code Is This
-1
votes
2 answers

OpenCV - Accessing Mat data using for loop

I'm trying to create a convolution function but I'm having trouble during the access to the kernel data (cv::Mat). I create the 3x3 kernel: cv::Mat krn(3, 3, CV_32FC1); krn.setTo(1); krn = krn/9; And I try to loop over it. Next the image Mat…
l000000l
  • 330
  • 1
  • 3
  • 14
-1
votes
1 answer

Discount rates, Formulas

for example, I have 1 computer with a discount, the price of this computer is $ 450 with a 10% discount, I want to know the real price of it, I want to learn this both over 10% and as 10% money. Computer 10% off Price = 450$ Computer $10 off Price =…
lidersin
  • 51
  • 7
-1
votes
1 answer

OpenCV cv::Mat size limit

When I setting a cv::Mat object with large width and height, the code would run exception... or print "bgModel.size != tsize." And when I lower width or height, print "bgModel.size == tsize." It seems that cv::Mat has a size limitation. Is there any…
-1
votes
1 answer

How to convert .mat files into csv and save them with the same names?

I have a folder of .mat files (thousands of files) with specific names such as FD800-000-M300.mat MD500-234-K400.mat ... and I would like to convert them into csv files and save them with same name they had as .mat files…
user12035904
-1
votes
1 answer

is there a limit on how many times I can use .read on the same file?

VideoCapture capVideo; capVideo.read(imgFrame2); is there a limit on how many times I can use .read on the same file?
-1
votes
1 answer

How to copy a rectangular area of a Mat a new Mat of the same size?

How can I save an area of one image in a new image with the same size as the first image? For example if I had an image like this: I want to create another image like this: This is what I tried: #include #include…
Hadi GhahremanNezhad
  • 2,377
  • 5
  • 29
  • 58
-1
votes
1 answer

How to convert Opencv Mat to JPEG char data

Recently, i am having trouble with converting a Mat frame captured from my webcam by OpenCV to a normal JPEG unsigned char array. I've tried one or two way on Google but the result seems not the correct jpeg uchar array. Here is a piece of my code: …
hoango27
  • 89
  • 3
  • 11
-1
votes
1 answer

Create a mat file

I saw the next tutorial: https://www.mathworks.com/videos/object-recognition-deep-learning-and-machine-learning-for-computer-vision-121144.html. At the Demo 2 was doing with deep learning a food detection. For this was use a .mat file. I want to…
-1
votes
1 answer

How to convert Matrix to a type Mat?

I am using EmguCV to do simple image processing. I want to remove small contours from my thresholded image so I used connectedcomponentswithstats. Below is my code where I convert any pixel smaller than the minimum size into black - essentially…
jodumagpi
  • 55
  • 1
  • 12
-1
votes
1 answer

how to store 1D vector in Mat and how to access those points in Mat?

I have a 1D vector of point2f. I am storing those points in 2D Mat of size 6x6. How to access these points now?
van
  • 15
  • 9
-1
votes
2 answers

Loop through captured images vector

I have strange problem. I am taking a set of photos of a sequential event via webcam and OpenCV. Storing them in a vector variable. At the end of the capture function, all I got is the last capture. I think I have a fundamental problem with vectors.…
meakcey
  • 83
  • 1
  • 10
-1
votes
1 answer

Opencv Mat efficiency linearized by right triangle

How to efficiency linearized Mat (symmetric matrix) to one row by right triangle. For example, when I have: 0aabbb b0aaaa ba0bba bac0aa aaaa0c abcab0 and then from that I get: aabbbaaaabbaaac Something like this: ... template Mat…
gulliver
  • 86
  • 2
  • 9