当前位置:网站首页>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
边栏推荐
- CVPR 2022 | querydet: use cascaded sparse query to accelerate small target detection under high resolution
- 【PTA】整除光棍
- 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
- Some basic configurations in interlij idea
- selenium. common. exceptions. WebDriverException: Message: ‘chromedriver‘ executable needs to be in PAT
- Mysql database and table building: the difference between utf8 and utf8mb4
- JDBC tool class jdbcconutil gets the connection to the database
- [graph theory brush question-4] force deduction 778 Swimming in a rising pool
- Plato Farm元宇宙IEO上线四大,链上交易颇高
- AQS learning
猜你喜欢
LeetCode动态规划训练营(1~5天)
ArcGIS JS version military landmark drawing (dovetail arrow, pincer arrow, assembly area) fan and other custom graphics
SIGIR'22「微软」CTR估计:利用上下文信息促进特征表征学习
堡垒机、跳板机JumpServer的搭建,以及使用,图文详细
16MySQL之DCL 中 COMMIT和ROllBACK
Matlab analytic hierarchy process to quickly calculate the weight
Servlet learning notes
What is the difference between a host and a server?
[target tracking] pedestrian attitude recognition based on frame difference method combined with Kalman filter, with matlab code
Numpy - creation of data type and array
随机推荐
nc基础用法1
WordPress插件:WP-China-Yes解决国内访问官网慢的方法
Es index (document name) fuzzy query method (database name fuzzy query method)
Operation of numpy array
R语言使用econocharts包创建微观经济或宏观经济图、indifference函数可视化无差异曲线、自定义计算交叉点、自定义配置indifference函数的参数丰富可视化效果
What is the difference between a host and a server?
JDBC tool class jdbcfiledateutil uploads files and date format conversion, including the latest, simplest and easiest way to upload single files and multiple files
SQL Server Connectors By Thread Pool | DTSQLServerTP 插件使用说明
Markdown < a > tag new page open link
Browser - learning notes
SIGIR'22 "Microsoft" CTR estimation: using context information to promote feature representation learning
WordPress plug-in: WP CHINA Yes solution to slow domestic access to the official website
R language uses timeroc package to calculate the multi time AUC value of survival data under competitive risk, uses Cox model and adds covariates, and R language uses the plotauccurve function of time
Mathematical modeling column | Part 5: MATLAB optimization model solving method (Part I): Standard Model
nc基础用法2
ArcGIS JS version military landmark drawing (dovetail arrow, pincer arrow, assembly area) fan and other custom graphics
Openharmony open source developer growth plan, looking for new open source forces that change the world!
Remote code execution in Win 11 using wpad / PAC and JScript
Redis的安装(CentOS7命令行安装)
JDBC database addition, deletion, query and modification tool class