背面有误(无 PDF)

背面有误(无 PDF)

我的文档出现了相当严重的问题。我收到以下错误:

    This compile didn’t produce a PDF. This can happen if:
There is an unrecoverable LaTeX error. If there are LaTeX errors shown below or in the raw logs, please try to fix them and compile again.
The document environment contains no content. If it’s empty, please add some content and compile again.
This project contains a file called output.pdf. If that file exists, please rename it and compile again.

但是,当我将以前的版本下载为 zip 文件并尝试将其上传回 overleaf 时,它说文件太大,无法上传!

我尝试将各个部分从上一个工作版本复制到新项目中,但无济于事(仍然出现错误)。

您以前遇到过这种情况吗?您有什么解决方法吗?

日志中第一个已知错误是:

<to be read again> 
                   \protect 
l.2741 ...yHist\\}}\relax }{figure.caption.725}{}}
                                                  
The control sequence marked <to be read again> should
not appear between \csname and \endcsname.

答案1

该错误是由于目录的辅助文件中的标题格式错误所致。

您可以从问题下的评论中显示的错误片段中看到这一点

l.2741 ...yHist\\}}\relax }{figure.caption.725}{}}

因此,在某个文件的第 2741 行,您可能会识别出确定哪个文件的语法,或者完整日志会显示文件名,将日志向上移动到第一个(没有匹配项的文件),这可能是

(./output.aux

output.aux此时正在读取显示内容。

错误上下文是

<to be read again> 
                   \protect 
l.2741 ...yHist\\}}\relax }{figure.caption.725}{}}
                                                  
The control sequence marked <to be read again> should
not appear between \csname and \endcsname.

您从中认出了原始来源

\foreach \x[count=\z] in \histogramImages {
\begin{figure}[H]
\centering
\includegraphics[max size={\textwidth}{\textheight}]{figures/Histograms/\x.png}
\caption{Greyscale Histogram for \x{\label{fig:greyHist\z}}}
\end{figure}
} 

\label{fig:greyHist\z}看起来可疑,可以删除。由于损坏的文件在每次运行开始时都会被读入,因此您需要删除它们,以便写入干净的文件。背面是:

在此处输入图片描述

您可能不需要标签,但如果需要,可以将它们放回原处,但细节取决于未显示的代码。

相关内容