qcf-568 / DocTamper

[CVPR2023] Towards Robust Tampered Text Detection in Document Image: New Dataset and New Solution
122 stars 11 forks source link

replaced the jpegio package with jpeg2dct #60

Open stormcoral opened 4 months ago

stormcoral commented 4 months ago

I have replaced the jpegio package with jpeg2dct, but the training process still gets interrupted and throws the error RuntimeError: Invalid JPEG file structure: two SOI markers. I would like to know how to resolve this issue. If the training gets interrupted after only a few steps, could there also be a memory leak issue in the inference code?

qcf-568 commented 4 months ago

please also see #32

stormcoral commented 3 months ago

please also see #32

进行断点保存读取的问题是如果数据量特别大,一个epoch没有训练完就报two SOI markers的错误,这个如何解决呢

qcf-568 commented 3 months ago

please also see #32

进行断点保存读取的问题是如果数据量特别大,一个epoch没有训练完就报two SOI markers的错误,这个如何解决呢

可以改代码减小断点保存的频率,比如由 一个epoch进行断点保存及加载 改为 每1000个iterations进行断点保存及加载 ,毕竟保存权重也就用2秒钟左右的时间,对训练速度影响可以忽略不计。