Numeração aleatória e espaçamento de subfiguras na saída pdf

Numeração aleatória e espaçamento de subfiguras na saída pdf

A numeração das subfiguras na minha saída em PDF é meio aleatória, mas no editor a numeração é como deveria ser.

Onde as subfiguras são numeradas corretamente de (a) a (d), mas quando exportadas para pdf, é isso que obtenho:

insira a descrição da imagem aqui

Gostaria também de perguntar por que o espaçamento horizontal na primeira linha das figuras é diferente? As configurações para cada linha são as mesmas, mas a primeira linha não segue.

Eu não sei como consertar isso. Aqui está um LaTeXcódigo da figura:

%% LyX 2.3.2-2 created this file.  For more info, see http://www.lyx.org/.
%% Do not edit unless you really know what you are doing.
\documentclass[english]{IEEEtran}
\usepackage[T1]{fontenc}
\usepackage[latin9]{inputenc}
\usepackage{graphicx}

\makeatletter
\@ifundefined{showcaptionsetup}{}{%
 \PassOptionsToPackage{caption=false}{subfig}}
\usepackage{subfig}
\makeatother

\usepackage{babel}
\begin{document}
\begin{figure*}
\subfloat[]{\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_0_ground_truth}}\enskip{}\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_1_ground_truth}}\enskip{}\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_2_ground_truth}}}

\subfloat[]{\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_0_ground_truth}}\enskip{}\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_1_ground_truth}}\enskip{}\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_2_ground_truth}}}

\subfloat[]{\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_0_ground_truth}}\enskip{}\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_1_ground_truth}}\enskip{}\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_2_ground_truth}}}

\subfloat[]{\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_0_ground_truth}}\enskip{}\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_1_ground_truth}}\enskip{}\subfloat{\includegraphics[width=0.28\paperwidth]{volume_4_2_ground_truth}}}

\caption{Comparison}
\end{figure*}

\end{document}

Responder1

Se entendi corretamente que você precisa de apenas quatro legendas (de (a) a (d), uma por linha), você pode simplesmente remover o aninhado \subfloat:

\documentclass[english]{IEEEtran}
\usepackage[T1]{fontenc}
\usepackage[latin9]{inputenc}
\usepackage{graphicx}

\makeatletter
\@ifundefined{showcaptionsetup}{}{%
 \PassOptionsToPackage{caption=false}{subfig}}
\usepackage{subfig}
\makeatother

\usepackage{babel}
\begin{document}
\begin{figure*}
\centering
\subfloat[]{%
    \includegraphics[width=0.25\paperwidth]{example-image}\enskip
    \includegraphics[width=0.25\paperwidth]{example-image}\enskip
    \includegraphics[width=0.25\paperwidth]{example-image}%
}

\subfloat[]{%
    \includegraphics[width=0.25\paperwidth]{example-image}\enskip
    \includegraphics[width=0.25\paperwidth]{example-image}\enskip
    \includegraphics[width=0.25\paperwidth]{example-image}%
}

\subfloat[]{%
    \includegraphics[width=0.25\paperwidth]{example-image}\enskip
    \includegraphics[width=0.25\paperwidth]{example-image}\enskip
    \includegraphics[width=0.25\paperwidth]{example-image}%
}

\subfloat[]{%
    \includegraphics[width=0.25\paperwidth]{example-image}\enskip
    \includegraphics[width=0.25\paperwidth]{example-image}\enskip
    \includegraphics[width=0.25\paperwidth]{example-image}%
}

\caption{Comparison}
\end{figure*}

\end{document}

insira a descrição da imagem aqui

Responder2

Use \includegraphicso comando dentro de minipáginas com a largura desejada.

\documentclass[english]{article}
\usepackage[T1]{fontenc}
\usepackage{graphicx}
\usepackage{subcaption}
\begin{document}

\begin{figure*}
\begin{minipage}{0.3\textwidth}
\includegraphics[width=\linewidth]{volume_4_0_ground_truth}
\end{minipage}\hspace*{\fill}
\begin{minipage}{0.3\textwidth}
\includegraphics[width=\linewidth]{volume_4_1_ground_truth}
\end{minipage}\hspace*{\fill}
\begin{minipage}{0.3\textwidth}
\includegraphics[width=\linewidth]{volume_4_2_ground_truth}
\end{minipage}\vspace{15pt}

\begin{minipage}{0.3\textwidth}
\includegraphics[width=\linewidth]{volume_4_0_ground_truth}
\end{minipage}\hspace*{\fill}
\begin{minipage}{0.3\textwidth}
\includegraphics[width=\linewidth]{volume_4_1_ground_truth}
\end{minipage}\hspace*{\fill}
\begin{minipage}{0.3\textwidth}
\includegraphics[width=\linewidth]{volume_4_2_ground_truth}
\end{minipage}
\caption{Comparison}
\end{figure*}

\end{document}

Uma legenda pode ser incluída se desejar usando o comando:\captionof{subfigure}{Caption (a)}

informação relacionada