I've used subfloat to include subfigures, with their relevant labels but with empty captions. what I'm going to do is to reference these figures with \subref in the main caption of the figure. But what I get is only ?? signs in the caption [main caption]. I can't figure out what's the problem. this is what I have:
\begin{figure}
\centering
\subfloat[][]
{
\includegraphics[scale=0.55]{signal}
\label{signal_model}
}
\subfloat[][]
{
\includegraphics[scale=0.55]{amplitude}
\label{amplitude_mod}
}
\caption{phase noise variability: \subref{signal model} some text \subref{amplitude_mod} some other text}
\end{figure}

"The subcaption package was updated to version 1.1. It got a new option for selecting a format used by \subref, and a new command called \phantomsubcaption for referencing a sub-figure without caption. Furthermore the subcaption package documentation was enhanced regarding references."
– pasha Jul 08 '12 at 17:49subcaptionpackage (and not thesubfigone) please use\subcaptionboxinstead of\subfloatand put the\labelinside the caption text, not inside the sub-figure body. – Jul 09 '12 at 06:45refcheckcan also mess with\subref. Was getting??sub@<ref>instead of(a), and it showed properly as(a)when I turned off refcheck. Note that\protect\subrefwhilerefcheckwas on didn't fix it. – Sterling Mar 15 '22 at 07:04showkeysinstead ofrefcheck: including\protectdoes not help, but turning offshowkeysmakes the subrefs appear properly. – Saibot May 21 '22 at 11:58