Lee-zix / RE-GCN

This is the official code release of the following paper: Zixuan Li, Xiaolong Jin, Wei Li, Saiping Guan, Jiafeng Guo, Huawei Shen, Yuanzhuo Wang and Xueqi Cheng. Temporal Knowledge Graph Reasoning Based on Evolutional Representation Learning
129 stars 25 forks source link

cuda out of memory #14

Open Wjt0403 opened 1 year ago

Wjt0403 commented 1 year ago

I tried to train a model on my own dataset, but I came with the problem "cuda out of memory", is there any good way to solve that problem?

Lee-zix commented 1 year ago

The memory cost is influenced by many factors. The most important factor is the number of historical facts. If your dataset has so many facts at one timestamp and you use a long history. The "cuda out of memory" problem may appear. The simplest way to this problem is to decrease the length of history snapshots you modeling. And maybe adding a negative sampling strategy to RE-GCN is also a common solution.