Dan Tenenbaum
2011-Mar-30 01:10 UTC
[Rd] problem with png() and large dimensions on some 32-bit Windows machines
Hello, I encountered this:> png(file=tempfile(), width=1165, height=12983)Error in png(file = tempfile(), width = 1165, height = 12983) : unable to start png() device In addition: Warning messages: 1: In png(file = tempfile(), width = 1165, height = 12983) : Unable to allocate bitmap 2: In png(file = tempfile(), width = 1165, height = 12983) : opening device failed>On the following system:> sessionInfo()R version 2.13.0 alpha (2011-03-18 r54865) Platform: i386-pc-mingw32/i386 (32-bit) locale: [1] LC_COLLATE=English_United States.1252 [2] LC_CTYPE=English_United States.1252 [3] LC_MONETARY=English_United States.1252 [4] LC_NUMERIC=C [5] LC_TIME=English_United States.1252 attached base packages: [1] stats graphics grDevices utils datasets methods base This is a Windows Server 2003 R2 Enterprise Edition Service Pack 2 system with 3GB of RAM. On another system, the command works fine. Info from that system:> sessionInfo()R version 2.13.0 alpha (2011-03-27 r55091) Platform: i386-pc-mingw32/i386 (32-bit) locale: [1] LC_COLLATE=English_United States.1252 [2] LC_CTYPE=English_United States.1252 [3] LC_MONETARY=English_United States.1252 [4] LC_NUMERIC=C [5] LC_TIME=English_United States.1252 attached base packages: [1] stats graphics grDevices utils datasets methods base Windows Server 2008 R2 Enterprise with 4GB of RAM. The command also worked fine on a system with only 2GB of RAM, but I don't have further information about that system at the moment. It suggests though that the amount of RAM is not the sole factor involved. Sorry this may not be the most reproducible problem, but I hope this is useful nonetheless. Dan [[alternative HTML version deleted]]
Dan Tenenbaum
2011-Mar-30 01:58 UTC
[Rd] problem with png() and large dimensions on some 32-bit Windows machines
I forgot to mention, on the machine where the png() command below does not work, the output of capabilities() is:> capabilities()jpeg png tiff tcltk X11 aqua http/ftp sockets TRUE TRUE TRUE TRUE FALSE FALSE TRUE TRUE libxml fifo cledit iconv NLS profmem cairo TRUE FALSE TRUE TRUE TRUE TRUE FALSE Also, I checked to make sure that tempfile() returns something writable, and that does not seem to be the issue.> t <- tempfile() > png(file=t) > png(file=t, width=1165, height=12983)Error in png(file = t, width = 1165, height = 12983) : unable to start png() device In addition: Warning messages: 1: In png(file = t, width = 1165, height = 12983) : Unable to allocate bitmap 2: In png(file = t, width = 1165, height = 12983) : opening device failed In fact, to narrow it down some more, it works if I specify either height or width but not both. Thanks Dan On Tue, Mar 29, 2011 at 6:10 PM, Dan Tenenbaum <dtenenba@fhcrc.org> wrote:> Hello, > > I encountered this: > > > png(file=tempfile(), width=1165, height=12983) > Error in png(file = tempfile(), width = 1165, height = 12983) : > unable to start png() device > In addition: Warning messages: > 1: In png(file = tempfile(), width = 1165, height = 12983) : > Unable to allocate bitmap > 2: In png(file = tempfile(), width = 1165, height = 12983) : > opening device failed > > > > On the following system: > > sessionInfo() > R version 2.13.0 alpha (2011-03-18 r54865) > Platform: i386-pc-mingw32/i386 (32-bit) > > locale: > [1] LC_COLLATE=English_United States.1252 > [2] LC_CTYPE=English_United States.1252 > [3] LC_MONETARY=English_United States.1252 > [4] LC_NUMERIC=C > [5] LC_TIME=English_United States.1252 > > attached base packages: > [1] stats graphics grDevices utils datasets methods base > > This is a Windows Server 2003 R2 Enterprise Edition Service Pack 2 system > with 3GB of RAM. > > On another system, the command works fine. Info from that system: > > > sessionInfo() > R version 2.13.0 alpha (2011-03-27 r55091) > Platform: i386-pc-mingw32/i386 (32-bit) > > locale: > [1] LC_COLLATE=English_United States.1252 > [2] LC_CTYPE=English_United States.1252 > [3] LC_MONETARY=English_United States.1252 > [4] LC_NUMERIC=C > [5] LC_TIME=English_United States.1252 > > attached base packages: > [1] stats graphics grDevices utils datasets methods base > Windows Server 2008 R2 Enterprise with 4GB of RAM. > > The command also worked fine on a system with only 2GB of RAM, but I don't > have further information about that system at the moment. It suggests though > that the amount of RAM is not the sole factor involved. > > Sorry this may not be the most reproducible problem, but I hope this is > useful nonetheless. > Dan > > > >[[alternative HTML version deleted]]
Simon Urbanek
2011-Mar-30 02:03 UTC
[Rd] problem with png() and large dimensions on some 32-bit Windows machines
Dan, the Windows build of R has no back-end choices, so the error essentially comes from a system call which means that Windows simply cannot provide the resources. Have you tried let's say Cairo alternative on the same machine? [If you want to test it, please use install.packages("Cairo",,"http://rforge.net") ] That doesn't depend on the OS resources, only on RAM so it may be in theory more scalable. Cheers, Simon On Mar 29, 2011, at 9:10 PM, Dan Tenenbaum wrote:> Hello, > > I encountered this: > >> png(file=tempfile(), width=1165, height=12983) > Error in png(file = tempfile(), width = 1165, height = 12983) : > unable to start png() device > In addition: Warning messages: > 1: In png(file = tempfile(), width = 1165, height = 12983) : > Unable to allocate bitmap > 2: In png(file = tempfile(), width = 1165, height = 12983) : > opening device failed >> > > On the following system: >> sessionInfo() > R version 2.13.0 alpha (2011-03-18 r54865) > Platform: i386-pc-mingw32/i386 (32-bit) > > locale: > [1] LC_COLLATE=English_United States.1252 > [2] LC_CTYPE=English_United States.1252 > [3] LC_MONETARY=English_United States.1252 > [4] LC_NUMERIC=C > [5] LC_TIME=English_United States.1252 > > attached base packages: > [1] stats graphics grDevices utils datasets methods base > > This is a Windows Server 2003 R2 Enterprise Edition Service Pack 2 system > with 3GB of RAM. > > On another system, the command works fine. Info from that system: > >> sessionInfo() > R version 2.13.0 alpha (2011-03-27 r55091) > Platform: i386-pc-mingw32/i386 (32-bit) > > locale: > [1] LC_COLLATE=English_United States.1252 > [2] LC_CTYPE=English_United States.1252 > [3] LC_MONETARY=English_United States.1252 > [4] LC_NUMERIC=C > [5] LC_TIME=English_United States.1252 > > attached base packages: > [1] stats graphics grDevices utils datasets methods base > Windows Server 2008 R2 Enterprise with 4GB of RAM. > > The command also worked fine on a system with only 2GB of RAM, but I don't > have further information about that system at the moment. It suggests though > that the amount of RAM is not the sole factor involved. > > Sorry this may not be the most reproducible problem, but I hope this is > useful nonetheless. > Dan > > [[alternative HTML version deleted]] > > ______________________________________________ > R-devel at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-devel > >
Possibly Parallel Threads
- R_HOME path getting munged in inst/doc/Makefile on Windows
- download.file() on ftp URL fails in windows with default download method
- download.file() on ftp URL fails in windows with default download method
- R CMD build processes inst/doc/Makefile only if there are vignette files?
- download.file() on ftp URL fails in windows with default download method