错误:向量内存已耗尽(已达到限制?) [英] Error: vector memory exhausted (limit reached?)

查看:557
本文介绍了错误:向量内存已耗尽(已达到限制?)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我以前保存了一个2.8G RData文件,现在尝试加载它,以便可以再次使用它,但是很奇怪,我不能.出现错误

I previously saved a 2.8G RData file and now I'm trying to load it so I can work on it again, but weirdly, I can't. It's giving the error

错误:向量内存已耗尽(已达到极限?)

Error: vector memory exhausted (limit reached?)

这很奇怪,因为我之前一直在使用它.虽然发生了变化,但是我升级到了R 3.5.0的最新版本.我看到以前的帖子有相同的错误,例如,但当时没解决.我希望使用解决方案,该解决方案可以增加memory.limit()但不幸的是,它仅适用于Windows.

This is weird since I was working with it fine before. One thing that changed though is I upgraded to the latest version of R 3.5.0. I saw a previous post with the same error like this but it wasn't resolved. I was hopeful with this solution which increases the memory.limit() but unfortunately, it's only available for Windows.

任何人都可以帮忙吗?我真的不明白这里出了什么问题,因为我能够在更新之前使用数据集,所以它不应该抛出此错误.

Can anyone help? I don't really understand what's the problem here since I was able to work with my dataset before the update so it shouldn't be throwing this error.

此更新是否以某种方式减少了分配给R的RAM?我们可以在Mac中手动增加memory.limit()来解决此错误吗?

Did the update somehow decreased the RAM allocated to R? Can we manually increase the memory.limit() in Mac to solve this error?

推荐答案

此更改对于处理Mac OS上的操作系统内存过量使用问题是必需的.在新闻文件中:

This change was necessary to deal with operating system memory over-commit issues on Mac OS. From the NEWS file:

  \item The environment variable \env{R_MAX_VSIZE} can now be used
  to specify the maximal vector heap size. On macOS, unless specified
  by this environment variable, the maximal vector heap size is set to
  the maximum of 16GB and the available physical memory. This is to
  avoid having the \command{R} process killed when macOS over-commits
  memory.

在启动R之前,将环境变量R_MAX_VSIZE设置为适合您的系统的值,您应该能够读取文件.

Set the environment variable R_MAX_VSIZE to an appropriate value for your system before starting R and you should be able to read your file.

这篇关于错误:向量内存已耗尽(已达到限制?)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆