フィルターのクリア

How to convert FLIR .seq file to .mat matlab format?

43 ビュー (過去 30 日間)
Anju Narendran
Anju Narendran 2023 年 11 月 21 日
コメント済み: Anju Narendran 2023 年 11 月 29 日
I am reaching out to seek guidance on the process of reading a FLIR recording in .SEQ format using MATLAB. Additionally, I would like to inquire if there exists a method to convert the .SEQ file to a .MAT file ?

採用された回答

Simar
Simar 2023 年 11 月 28 日
Hi Anju,
I understand that you are facing issues in reading a FLIR recording in SEQ format using MATLAB and looking to convert SEQ file to a MAT file.
Reading a SEQ file from a FLIR camera and converting it to a MAT file in MATLAB can be a bit complex because SEQ is a proprietary format used by FLIR for storing sequences of thermal images. However, FLIR provides a software development kit (SDK) called FLIR Atlas SDK for .NET that can be used to read SEQ files. Use this SDK in combination with MATLAB's .NET interoperability features to read the SEQ file and then save the data to a MAT file. Below are the steps to follow:
  • Ensure that you have installed the FLIR Atlas SDK on the system. This SDK is provided by FLIR Systems and is necessary for reading SEQ files produced by FLIR thermal cameras. Download the SDK from FLIR Systems' official website and follow their installation instructions.
  • MATLAB has the capability to interact with .NET assemblies. Load the FLIR Atlas SDK assembly into MATLAB and use it to read the SEQ file.
  • Use the functions provided by the FLIR Atlas SDK to open and read frames from the SEQ file.
  • Once have the image data in MATLAB, save it to a MAT file using the save function.
Here is a sample code to get started. Please note that this code assumes to have the FLIR Atlas SDK installed, and a Windows machine is being used, as the SDK is for the .NET framework:
% Add the FLIR Atlas SDK .NET assembly
% Make sure to provide the correct path to the DLL file
dllPath = 'C:\Path\To\FLIR\SDK\YourSDK.dll';
NET.addAssembly(dllPath);
% Create an object to handle the SEQ file
seqReader = Flir.Atlas.Image.ThermalImageSequence();
% Open the SEQ file
seqFilePath = 'C:\Path\To\Your\File.seq';
seqReader.Open(seqFilePath);
% Preallocate a cell array to hold the thermal images
numFrames = seqReader.Count;
thermalImages = cell(1, numFrames);
% Read each frame and store it in the cell array
for i = 1:numFrames
% Move to the i-th frame
seqReader.GoTo(i-1); % Indices are zero-based in .NET
% Get the thermal image
thermalImage = seqReader.ThermalImage;
% Retrieve the image data (temperature values, for example)
imageData = thermalImage.ImageProcessing.GetPixelsArray;
% Store the image data
thermalImages{i} = imageData;
end
% Close the SEQ reader
seqReader.Close();
% Save the thermal images to a MAT file
save('ThermalImages.mat', 'thermalImages');
Please note that the Code provided is a general example, and it may require modification or added adjustments to work properly in a specific context or environment. One would need to replace the DLL path and SEQ file path with their actual paths and may also need to adjust the code to match the specific classes and methods provided by the FLIR Atlas SDK that one is using.
If not familiar with .NET interoperability in MATLAB or the FLIR Atlas SDK, or if encountering any issues, please refer to the following documentation links:
Hope it helps!
Best Regards,
Simar
  1 件のコメント
Anju Narendran
Anju Narendran 2023 年 11 月 29 日
Thank you very much for your reply

サインインしてコメントする。

その他の回答 (0 件)

タグ

製品


リリース

R2023b

Community Treasure Hunt

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

Start Hunting!

Translated by