Created
December 7, 2021 10:09
-
-
Save wonrax/0745222db5475de002595c3abe79c80c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\newcommand{\image}[4][1]{ | |
\begin{figure}[ht!] | |
\includegraphics[trim=0 0 0 -2cm,width=#1\textwidth,keepaspectratio]{#2} | |
\centering | |
\caption{#3} | |
\label{#4} | |
\end{figure} | |
} | |
% Example usage | |
% \image[0.7]{img/Skein_permutation.png}{Hoán vị Skein \ | |
% \citep{wiki:skein_permutation}}{fig:skein} | |
\newcommand{\doubleimage}[7][0.4]{ | |
\begin{figure}[ht!] | |
\centering | |
\begin{subfigure}{.5\textwidth} | |
\centering | |
\includegraphics[width=#1\linewidth]{#2} | |
\caption{#3} | |
\end{subfigure}% | |
\begin{subfigure}{.5\textwidth} | |
\centering | |
\includegraphics[width=#1\linewidth]{#4} | |
\caption{#5} | |
\end{subfigure} | |
\caption{#6} | |
\label{#7} | |
\end{figure} | |
} | |
% Example usage | |
% \doubleimage[0.7]{img/code/naiveHashing/circle.jpg}{Hình \ | |
% tròn}{img/code/naiveHashing/circle-1p.jpg}{Hình tròn bị thay đổi 1 điểm \ | |
% ảnh}{Hai hình ảnh chỉ khác nhau một điểm ảnh}{fig:doubleimage} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment