当前位置:网站首页>How can matlab obtain the truncated image in trainingimagelabeler
How can matlab obtain the truncated image in trainingimagelabeler
2022-04-23 20:21:00 【Install a sound 77】
I use 2021b Version of matlab, The interface is as shown in the figure :
trainingImageLabeler It's a matlab Its own annotation tool , As an adaptation tool , It should have been convenient and easy to use , however trainingImageLabeler After several updates , Instead, it's more Galla cross .
The output of your image is especially good , Finally, it will only be output as mat file , Although it can also pass through readtable Read training in this way , But there is no real graph , It's still uncomfortable , How could such a function be cut off .
In fact, this acquisition method is very simple ,
l as long as load Take a look at what you saved mat file , A... Will appear in the workspace gTruth, The path information of the file and the clipped square area are inside .
load('test.mat')
So write a script , pick up information , Then use the image imcrop Function to cut and save it .
The script is as follows :
clear all
clc
load('test.mat')
P = size(gTruth.LabelData);
P_size = P(1);
%1 Is the scope of ,2 Is the image location
list1=[];
list2=[];
for i = 1:P_size
react = gTruth.LabelData{i,1}{1,1};
pic_path=gTruth.DataSource.Source(i);
pic_path_str = cell2mat(pic_path);
list1=[list1;react];
list2=[list2;pic_path_str];
end
list1;
list2;
for j =1:30
I=imread(list2(j,:));
C=imcrop(I,list1(j,:));
C_last=imresize(C,[227 227]);
num = list2(j,:);
num_str = num(25:end)
imwrite(C_last,strcat('aaa/',num_str));
end
A rough script written temporarily , Hope to solve your problem .
版权声明
本文为[Install a sound 77]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204210551491151.html
边栏推荐
- SRS deployment
- PCL点云处理之直线与平面的交点计算(五十三)
- nc基础用法3
- R语言使用caret包的preProcess函数进行数据预处理:对所有的数据列进行BoxCox变换处理(将非正态分布数据列转换为正态分布数据、不可以处理负数)、设置method参数为BoxCox
- SQL Server Connectors By Thread Pool | DTSQLServerTP plugin instructions
- Investigate why close is required after sqlsession is used in mybatties
- The R language uses the timeroc package to calculate the multi time AUC value of survival data without competitive risk, and uses the confint function to calculate the confidence interval value of mul
- The flinkcdc reports an error: but this is no longer available on the server
- NC basic usage 4
- Numpy Index & slice & iteration
猜你喜欢
Livego + ffmpeg + RTMP + flvjs to realize live video
Azkaban recompile, solve: could not connect to SMTP host: SMTP 163.com, port: 465 [January 10, 2022]
Error reported by Azkaban: Azkaban jobExecutor. utils. process. ProcessFailureException: Process exited with code 127
Commit and ROLLBACK in DCL of 16mysql
Es keyword sorting error reason = fielddata is disabled on text fields by default Set fielddata = true on keyword in order
go-zero框架数据库方面避坑指南
Building the tide, building the foundation and winning the future -- the successful holding of zdns Partner Conference
AQS learning
Es error: request contains unrecognized parameter [ignore_throttled]
16MySQL之DCL 中 COMMIT和ROllBACK
随机推荐
The flinkcdc reports an error: but this is no longer available on the server
Linux64Bit下安装MySQL5.6-不能修改root密码
Error reported by Azkaban: Azkaban jobExecutor. utils. process. ProcessFailureException: Process exited with code 127
Redis cache penetration, cache breakdown, cache avalanche
STM32 Basics
NC basic usage 4
SQL Server Connectors By Thread Pool | DTSQLServerTP plugin instructions
Numpy mathematical function & logical function
Redis的安装(CentOS7命令行安装)
SQL Server Connectors By Thread Pool | DTSQLServerTP 插件使用说明
Servlet learning notes
中金财富公司怎么样,开户安全吗
PCL点云处理之直线与平面的交点计算(五十三)
【PTA】L1-002 打印沙漏
DNS cloud school rising posture! Three advanced uses of authoritative DNS
nc基础用法1
An error is reported in the initialization metadata of the dolphin scheduler -- it turns out that there is a special symbol in the password. "$“
Modeling based on catiav6
selenium.common.exceptions.WebDriverException: Message: ‘chromedriver‘ executable needs to be in PAT
Confusion about thread blocking after calling the read () method of wrapper flow