How to make Tiff fast and memory efficient

조회 수: 3 (최근 30일)
Dimitri Yatsenko
Dimitri Yatsenko 2012년 9월 24일
답변: Jerome Lecoq 2014년 3월 3일
In the following code using R2012b, the Tiff object keeps allocating more internal memory with every read.
t = Tiff('file.tiff')
for i=1:n
t.nextDirectory
imagesc(t.read)
end
t.close
Closing the object frees the memory at the end. But is there a way to clear the memory for frames which have already been displayed without closing the object?

채택된 답변

Jerome Lecoq
Jerome Lecoq 2014년 3월 2일
I see the same problem in 2013b. I would think this is a bug or an undocumented buffer. At the very least we should be able to disable that buffer.

추가 답변 (1개)

Jerome Lecoq
Jerome Lecoq 2014년 3월 3일
It turns out that if you open the tiff in 'r+' mode. There is no buffering/memory leak. I am going to file a bug report on this.

카테고리

Help CenterFile Exchange에서 Image Data에 대해 자세히 알아보기

태그

제품

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by