Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
Strange behavior: file doesn't exist error even if the file does exist

Subject: Strange behavior: file doesn't exist error even if the file does exist

From: Louis

Date: 10 Nov, 2010 15:04:04

Message: 1 of 2

I am doing the following simple loop:

I have (.pgm) images with names range from 0:1000, I am loading the images (using imread) on one-by-one basis using for-loop, I do some manipulation then save them back.

Everything is okay for the first 491 images; afterwards matlab gives me the error
“ File does not exist”
Well the file “does” exist. Also now if let’s say I try to “imread”some previously read files for example file number 490 or even file number 1, which the code already read ithem and did the manipulation. It still gives me the error “File does not exist” :S.

Well okay, afterwards I try to debug my matlab, now it doesn’t even allow me to run or debug (by putting the break points) on the .m file. I have to close matlab and open it again to work :S

Can you please advise if you faced such a thing

Regards

Louis

Subject: Strange behavior: file doesn't exist error even if the file does exist

From: Louis

Date: 10 Nov, 2010 15:13:04

Message: 2 of 2

Resolved :) I forgot to ‘fclose’ the files I am opening..

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us