{"id":221,"date":"2008-07-30T14:02:02","date_gmt":"2008-07-30T18:02:02","guid":{"rendered":"https:\/\/blogs.mathworks.com\/steve\/2008\/07\/30\/tiff-update\/"},"modified":"2019-10-28T09:38:13","modified_gmt":"2019-10-28T13:38:13","slug":"tiff-update","status":"publish","type":"post","link":"https:\/\/blogs.mathworks.com\/steve\/2008\/07\/30\/tiff-update\/","title":{"rendered":"Reading Massively Multipage TIFFs: An Update"},"content":{"rendered":"<p>\r\nLast fall I wrote about a complaint some MATLAB users had about reading certain kinds of TIFF files.  Specifically, some users have TIFF files that each contain tens of thousands of images&mdash;or more! One user sent us a single TIFF file containing almost 130,000 individual images. My tongue-in-cheek name for these files is \"Massively Multipage TIFF\" (MMT).\r\n<\/p>\r\n\r\n<p>\r\nThe problem is that the syntax for reading the k-th image from a TIFF file:\r\n<\/p>\r\n\r\n<pre>\r\n  >> I = imread(filename, k);\r\n<\/pre>\r\n\r\n<p>\r\ntakes significantly longer for images at the end of the file.  As a result, reading all of the images in such a file takes way too long. I discussed the technical issues in the post <a href=\"https:\/\/blogs.mathworks.com\/steve\/2007\/09\/16\/multipage-tiffs\/\">\"How many images can fit in a TIFF file\"<\/a> last September.\r\n<\/p>\r\n\r\n<p>\r\nWe now have updated files you can use to improve import performance on these TIFF files. The patch is only for the most recent MATLAB release, R2008a. Please do not try to apply the patch to earlier releases.\r\n<\/p>\r\n\r\n<p>\r\n<em>[Update - August 11, 2008 - The download link above now points to an official MathWorks technical support solution page.<\/em>\r\n<\/p>\r\n\r\n<p>\r\nWith the updated files, images at the end of a TIFF file can be read in the same amount of time as images at the beginning of the file. Note that a different syntax is necessary, so please read the instructions in the download carefully.\r\n<\/p>\r\n\r\n<p>\r\nYou should be aware that these updates will <strong>NOT<\/strong> be included in the upcoming R2008b release.  These changes were implemented very recently, and the relevant development deadline for R2008b changes was a couple of months ago.\r\n<\/p>\r\n\r\n<p>\r\nAlso, we don't have any updates available yet for improving the performance of creating such TIFF files using <tt>imwrite<\/tt>.\r\n<\/p>","protected":false},"excerpt":{"rendered":"<p>\r\nLast fall I wrote about a complaint some MATLAB users had about reading certain kinds of TIFF files.  Specifically, some users have TIFF files that each contain tens of thousands of images&mdash;or... <a class=\"read-more\" href=\"https:\/\/blogs.mathworks.com\/steve\/2008\/07\/30\/tiff-update\/\">read more >><\/a><\/p>","protected":false},"author":42,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[76],"_links":{"self":[{"href":"https:\/\/blogs.mathworks.com\/steve\/wp-json\/wp\/v2\/posts\/221"}],"collection":[{"href":"https:\/\/blogs.mathworks.com\/steve\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.mathworks.com\/steve\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.mathworks.com\/steve\/wp-json\/wp\/v2\/users\/42"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.mathworks.com\/steve\/wp-json\/wp\/v2\/comments?post=221"}],"version-history":[{"count":1,"href":"https:\/\/blogs.mathworks.com\/steve\/wp-json\/wp\/v2\/posts\/221\/revisions"}],"predecessor-version":[{"id":2268,"href":"https:\/\/blogs.mathworks.com\/steve\/wp-json\/wp\/v2\/posts\/221\/revisions\/2268"}],"wp:attachment":[{"href":"https:\/\/blogs.mathworks.com\/steve\/wp-json\/wp\/v2\/media?parent=221"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.mathworks.com\/steve\/wp-json\/wp\/v2\/categories?post=221"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.mathworks.com\/steve\/wp-json\/wp\/v2\/tags?post=221"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}