clc; clear all;  close all;
image_path = '/media/wangxiao/Elements/image_segment_backup/';
savePath = '/media/wangxiao/Seagate/wangxiao/additional_data/'; threshold = ; first_files = dir(image_path); for i = :length(first_files)
sec_file_name = first_files(i).name;
sec_path = [image_path, sec_file_name, '/'];
sec_files = dir(sec_path);
disp(['process the: ', sec_file_name, '---', num2str(i-), '/', num2str(length(first_files)-),' waiting . . . ']); for j = :length(sec_files)
third_file_name = sec_files(j).name;
third_path = [sec_path, third_file_name, '/'];
third_files = dir(third_path);
disp([' process the: ', third_file_name, '---', num2str(j-), '/', num2str(length(sec_files)-),' . . . ']); for k = :length(third_files)
fourth_files_name = third_files(k).name;
fourth_path = [third_path, fourth_files_name, '/'];
fourth_files = dir(fourth_path);
disp([' process the: ', fourth_files_name, '---', num2str(k-), '/', num2str(length(third_files)-),' . . . ']); for ii = :length(fourth_files)
fifth_file_name = fourth_files(ii).name;
fifth_path = [fourth_path, fifth_file_name, '/'];
fifth_files = dir(fifth_path);
disp([' process the: ', fifth_file_name, '---', num2str(ii-), '/', num2str(length(fourth_files)-),' . . . ']); for jj = :length(fifth_files)
six_file_name = fifth_files(jj).name;
six_path = [fifth_path, six_file_name, '/'];
six_files = dir([six_path, '*.jpg']);
% disp([' process the: ', six_file_name, '---', num2str(jj-), '/', num2str(length(fifth_files)-), ' . . . ']); for kk = :length(six_files)
seven_file_name = six_files(kk).name;
image = imread([six_path, seven_file_name]); imshow(image); [width, length, channel] = size(image);
% disp(sec_file_name);
% disp(third_file_name);
% disp(fourth_files_name);
% disp(fifth_file_name);
% disp(six_file_name);
% disp(seven_file_name);
resolution = width * length ; if (resolution > threshold)
imwrite(image, [savePath, seven_file_name]);
end end end end end end end

Error using subsindex
Function 'subsindex' is not defined for values of class 'struct'.

Error in pre_deal_additional_data (line 39)
                    for kk = 1:length(six_files)

----------------------------------------------------------------------

----------------------------------------------------------------------

fuck the error and  the answer is :

 clc; clear all;  close all;
image_path = '/media/wangxiao/Elements/image_segment_backup/';
savePath = '/media/wangxiao/Seagate/wangxiao/additional_data/'; threshold_self = ; first_files = dir(image_path); for i = :size(first_files, )
sec_file_name = first_files(i).name;
sec_path = [image_path, sec_file_name, '/'];
sec_files = dir(sec_path);
disp(['process the: ', sec_file_name, '---', num2str(i-), '/', num2str(length(first_files)-),' waiting . . . ']); for j = : size(sec_files, )
third_file_name = sec_files(j).name;
third_path = [sec_path, third_file_name, '/'];
third_files = dir(third_path);
% disp([' process the: ', third_file_name, '---', num2str(j-), '/', num2str(length(sec_files)-),' . . . ']); for k = : size(third_files, )
fourth_files_name = third_files(k).name;
fourth_path = [third_path, fourth_files_name, '/'];
fourth_files = dir(fourth_path);
% disp([' process the: ', fourth_files_name, '---', num2str(k-), '/', num2str(length(third_files)-),' . . . ']); for ii = : size(fourth_files, )
fifth_file_name = fourth_files(ii).name;
fifth_path = [fourth_path, fifth_file_name, '/'];
fifth_files = dir(fifth_path);
% disp([' process the: ', fifth_file_name, '---', num2str(ii-), '/', num2str(length(fourth_files)-),' . . . ']); for jj = : size(fifth_files, )
six_file_name = fifth_files(jj).name;
six_path = [fifth_path, six_file_name, '/'];
six_files = dir([six_path, '*.jpg']);
% disp([' process the: ', six_file_name, '---', num2str(jj-), '/', num2str(length(fifth_files)-), ' . . . ']); for kk = : size(six_files, )
seven_file_name = six_files(kk).name;
image = imread([six_path, seven_file_name]); % imshow(image); [width, length, channel] = size(image); resolution_self = width * length ; if (resolution_self > threshold_self)
imwrite(image, [savePath, seven_file_name]);
end end end end end end end

Error using subsindex Function 'subsindex' is not defined for values of class 'struct'.的更多相关文章

  1. Mysql drop function xxxx ERROR 1305 (42000): FUNCTION (UDF) xxxx does not exist

    mysql> drop function GetEmployeeInformationByID;ERROR 1305 (42000): FUNCTION (UDF) GetEmployeeInf ...

  2. JS function document.onclick(){}报错Syntax error on token "function", delete this token

    JS function document.onclick(){}报错Syntax error on token "function", delete this token func ...

  3. Apache Error: Invalid command ‘Allow’, perhaps misspelled or defined by a module not included in the server configuration

    在一个Window Server 2008R2系统上使用Apache架设了一个PHP的网站项目 在配置Apache的过程中出现了以下问题   根据上面的提示说是没有相应的权限,那就在虚拟主机里进行了配 ...

  4. Error Code: 1305. FUNCTION student.rand_string does not exist

    1.错误描述 13:52:42 call new_procedure Error Code: 1305. FUNCTION student.rand_string does not exist 0.0 ...

  5. Error Code: 1630. FUNCTION rand.string does not exist

    1.错误描述 13:50:13 call new_procedure Error Code: 1630. FUNCTION rand.string does not exist. Check the ...

  6. error: no matching function for call to 'std::exception:exception(const char[16])'

    环境:codeblocks 语言:C++ 在执行:throw new exception("queue is empty.");时 遇到问题:error: no matching ...

  7. OpenCV 学习笔记 06 SIFT使用中出现版权问题error: (-213:The function/feature is not implemented)

    1 错误原因 1.1 报错全部信息: cv2.error: OpenCV(4.0.1) D:\Build\OpenCV\opencv_contrib-4.0.1\modules\xfeatures2d ...

  8. 【Loadrunner】Error -26601: Decompression function 错误解决、27728报错解决方案

       一. Error -26601: Decompression function 错误解决 Action2.c(30): Error -26601: Decompression function ...

  9. Error no matching function for call to 'std::exception::exception(const char [15])'

    Error no matching function for call to 'std::exception::exception(const char [15])' Error 'logic_err ...

随机推荐

  1. iOS开发XCODE5 SVN配置 使用办法

    第一次弄svn版本控制,折腾了好久一直都出错!无意间看到一篇文章!貌似解决了,很感谢“代码妖娆” 的详细流程(http://blog.sina.com.cn/s/blog_68661bd80101ph ...

  2. poj1276 多重背包

    //Accepted 1100 KB 47 ms //多重背包 #include <cstdio> #include <cstring> #include <iostre ...

  3. hdu2196 树的直径 + bfs

    //Accepted 740 KB 15 ms //树的直径 //距离一个顶点最远的点一定是树的直径的一个端点 #include <cstdio> #include <cstring ...

  4. access手工注入

    1.判断数据类型 and exists (select * from msysobjects) >0 and exists (select * from sysobjects) >0 一般 ...

  5. 用Ogre实现《天龙八部》场景中水面(TerrainLiquid)详解

    本文主要讲的是<天龙八部>游戏中水面(TerrainLiquid)的具体实现,使用C++,Ogre1.6. 天龙的水面做的比较简单,虽然没有倒影,但动态纹理+深度图做出的效果还行,看着不是 ...

  6. Oracle数据库中序列用法讲解

    序列(SEQUENCE)是序列号生成器,可以为表中的行自动生成序列号,产生一组等间隔的数值(类型为数字).其主要的用途是生成表的主键值,可以在插入语句中引用,也可以通过查询检查当前值,或使序列增至下一 ...

  7. python3爬虫初探(一)之urllib.request

    ---恢复内容开始--- #小白一个,在此写下自己的python爬虫初步的知识.如有错误,希望谅解并指出. #欢迎和大家交流python爬虫相关的问题 #2016/6/18 #----第一把武器--- ...

  8. post&get请求总结

    1.将get获取的数据,UrlDecode后返回 public static string SendGet(string url) { HttpWebRequest httpWebRequest = ...

  9. C#操作指针

    如何:递增和递减指针 使用增量和减量运算符 ++ 和 -- 可以将 pointer-type* 类型的指针的位置改变 sizeof (pointer-type). 增量和减量表达式的形式如下: ++p ...

  10. ie6下png背景显示问题?

    针对ie6下png背景显示问题,CSS中可以这样解决:_background:none;_filter:progid:DXImageTransform.Microsoft.AlphaImageLoad ...