Unable to load many files at once
Afficher commentaires plus anciens
Hi,
I've created a small video-editor using the matlab GUIDE. One of its functions is to load image files in order to convert them into a movie. Everything works fine, except that I cannot load more files than ~650 at the same time. Since I work with thousands of images, loading everything in batches of 600 is just annoying, and I figure I should be able to load all my files at once. I use the following code:
[cellFiles,pathvar] = uigetfile(...
filterSpec,...
'Pick a file','MultiSelect','on');
I guess the problem is that there is a limit to the size uigetfile can return, so I was wondering if anyone knows a way to circumvent this.
With kind regards, Jorrit Montijn
Réponses (2)
Jan
le 20 Sep 2011
0 votes
There is an undocumented function called "native_uigetfile" in Matlab 2009a under Windows. Is it available on your system and does it influence the problem?
5 commentaires
Jorrit M
le 20 Sep 2011
Jan
le 20 Sep 2011
Did you make a typo in the command window or while typing the comment? "native_uitgetfile" has one extra "t"...
I found this function by reading the source of uigetfile.m and its children. The non-native version of UIGETFILE uses a Java rouitne, whose buffers can be most likely influenced. Just ask Yair Altman.
Jorrit M
le 20 Sep 2011
Maya Aviv
le 12 Fév 2013
did you find a solution? since i have the same problem. i have to get more than 1000 files.
Jan
le 12 Fév 2013
@Maya Aviv: Which OS do you use?
Sean de Wolski
le 12 Fév 2013
Are you making sure to close the files when you are done with them? This is very important. The number of file handles is limited by the OS (i.e. not MATLAB) and if you open more than this you will see some of the most ridiculous behavior ever.
What is the output from:
hOpen = fopen('all');
This will tell you if you are not closing files when done with them. To close them use:
fclose(fid);
To close all of them:
fclose('all');
Catégories
En savoir plus sur App Building dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!