AllennLP Coreference解决方案培训和替换模型的OOM问题

发布于 2025-01-30 02:09:32 字数 852 浏览 4 评论 0 原文

关于培训和评估AllennLP的核心分辨率模型,我有一些问题。

  1. 对哪些GPU进行培训有任何限制/规格吗?我通过24220 MIB内存进行了对Titan RTX GPU进行培训的中途问题。我可以更改可能会有所帮助的任何参数(注意:我正在使用 bert 而不是Spanbert版本)?

  2. 我注意到模型用法示例使用已经训练有素且存储的模型。我们可以从训练的模型中指定模型路径吗?

  3. 我们可以在 Bert-Base-uncased 替换 blob/main/main/triending_config/coref/coref_bert_lstm.jsonnet“ rel =“ nofollow noreferrer”> coref_bert-lstm.jsonnet mm.jsonnet 文件,还是进行此更改的其他修改?

I have a few questions about training and evaluating AllenNLP's coreference resolution model.

  1. Are there any constraints/specifications on what GPUs should be used for training? I get an OOM issue midway through training on a Titan RTX GPU with 24220 MiB memory. Are there any parameters I can change that might help (note: I am using the BERT instead of the SpanBERT version)?

  2. I noticed that the model usage examples use an already trained and stored model. Can we instead specify a model path from a model we have trained?

  3. Can we substitute roberta-base with bert-base-uncased in the coref_bert-lstm.jsonnet file, or are other modifications necessary to make this change?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

巷子口的你 2025-02-06 02:09:32
  1. 该模型需要大量内存。 max_length 参数使内存使用最大。如果您可以以比512短的最大长度逃脱,请先尝试一下。
  2. 是的,无论何时将URL到经过训练的模型,您都可以替代您训练自己的模型的当地路径。
  3. 是的,您可以,但是您必须从头开始训练模型。
  1. This model needs a lot of memory. The max_length parameter makes the biggest difference to memory usage. If you can get away with a max length that's shorter than 512, try that first.
  2. Yes, wherever it takes a URL to a trained model, you can substitute a local path to a model that you trained yourself.
  3. Yes, you can, but you'll have to train the model from scratch.
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文