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. oracle触发器如何使用2

    触发器 是特定事件出现的时候,自动执行的代码块.类似于存储过程,但是用户不能直接调用他们.触发器是许多关系数据库系统都提供的一项技术.在ORACLE系统里,触发器类似过程和函数,都有声明,执行和异常处 ...

  2. (转)如何在Windows上安装多个MySQL

    原文:http://www.blogjava.net/hongjunli/archive/2009/03/01/257216.html 如何在Windows上安装多个MySQL 本文以免安装版的mys ...

  3. 12、SQL基础整理(运算符与优先级)

    运算符 + - * / %(取余),赋值运算符 = declare @jia int set @jia = 1+1 print @jia declare @jia int set @jia = 10% ...

  4. HDU 5823 (状压dp)

    Problem color II 题目大意 定义一个无向图的价值为给每个节点染色使得每条边连接的两个节点颜色不同的最少颜色数. 对于给定的一张由n个点组成的无向图,求该图的2^n-1张非空子图的价值. ...

  5. Unity3D ShaderLab 漫反射卷积光照模型

    Unity3D ShaderLab 漫反射卷积光照模型 漫反射卷积[Diffuse convolution]是一个模糊立方体的过程,它保留了立方图的整体光照强度,只模糊了细节. 这种效果在我们要活得一 ...

  6. jQuery ajax传多个参数

    ajax可以传送一个或多个参数到后台php中 <script> $(function(){ $("#sub_btn").click(function(){ var em ...

  7. [转Go-简洁的并发 ]

    http://www.yankay.com/go-clear-concurreny/ Posted on 2012-11-28by yankay 多核处理器越来越普及.有没有一种简单的办法,能够让我们 ...

  8. linux服务器并发与tcmalloc

    前一天使用pmap查看服务器中自己开发的游戏服务的内存使用情况,发现其中数据存储服务的内存占用率非常高,截图如下. 从截图中可以看出来,分配了大量的64MB左右的内存空间,因为对自己的服务比较了解,知 ...

  9. Java字符串null相加

    Java字符串null相加 最近和同事讨论了下面的一段代码: String a = null; a += a; System.out.println(a); 运行结果: nullnull 本着学习的态 ...

  10. 万恶的VS2010 快捷键

    此随笔用来记录VS的快捷键: 1.ctrl + U :将选定行中的大写置换为小写: 2.ctrl + K,ctrl + C :注释选定行: 3.ctrl + K,ctrl + U :取消注释选定行: