-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathsetup.tex
More file actions
141 lines (114 loc) · 6.05 KB
/
setup.tex
File metadata and controls
141 lines (114 loc) · 6.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
%------------------------------------------------------------------------------
% package includes
%------------------------------------------------------------------------------
% font encoding is set up for pdflatex, for other environments see
% http://tex.stackexchange.com/questions/44694/fontenc-vs-inputenc
\usepackage[T1]{fontenc} % 8-bit fonts, improves handling of hyphenations
% provides `old' commands for table of contents. Eases the ability to switch
% between book and scrbook
\usepackage{scrhack}
% ------------------- layout, default -------------------
% adjust the style of float's captions, separated from text to improve readabilty
\usepackage[labelfont=bf, labelsep=colon, format=hang, textfont=singlespacing]{caption}
% With format = hang your caption will look like this:
% Figure 1: Lorem ipsum dolor sit amet,
% consectetuer adipiscing elit.
% Ut purus elit, vestibulum
% If you instead want
% Figure 1: Lorem ipsum dolor sit amet,
% consectetuer adipiscing elit. Ut purus
% elit, vestibulum
% change to format=plain
\usepackage{chngcntr} % continuous numbering of figures/tables over chapters
\counterwithout{equation}{chapter}
\counterwithout{figure}{chapter}
\counterwithout{table}{chapter}
% Uncomment the following line if you switch from scrbook to book
% and comment the setkomafont line
\usepackage{titlesec} % remove "Chapter" from the chapter title
\titleformat{\chapter}[hang]{\bfseries\huge}{\thechapter}{2pc}{\huge}
% \setkomafont{chapter}{\normalfont\bfseries\huge}
\usepackage{setspace} % Line spacing
\onehalfspacing
% \doublespacing % uncomment for double spacing, e.g. for annotations in correction
% ------------------- functional, default-------------------
\usepackage{natbib}
\usepackage[dvipsnames]{xcolor} % more colors
\usepackage{array} % custom format per column in table - needed on the title page
\usepackage{graphicx} % include graphics
\usepackage{subfig} % divide figure, e.g. 1(a), 1(b)...
\usepackage{amsmath} % |
\usepackage{amsthm} % | math, bmatrix etc
\usepackage{amsfonts} % |
\usepackage{calc} % calculate within LaTeX
\usepackage[unicode=true,bookmarks=true,bookmarksnumbered=true,
bookmarksopen=true,bookmarksopenlevel=1,breaklinks=false,
pdfborder={0 0 0},backref=false,colorlinks=false]{hyperref}
%==========================================
% You might not need the following packages, I only included them as they
% are needed for the example floats
% ------------------- functional, custom -------------------
\usepackage{algorithm,algpseudocode}
\usepackage{bm} % bold greek variables (boldmath)
\usepackage{tikz}
\usetikzlibrary{positioning} % use: above left of, etc
% Improves general appearance of the text
\usepackage[protrusion=true,expansion=true, kerning]{microtype}
\usepackage{enumitem}
% usually you don't need this, just for demonstration of a longer caption
\usepackage{lipsum}
%------------------------------------------------------------------------------
% (re)new commands / settings
%------------------------------------------------------------------------------
% ----------------- referencing ----------------
\newcommand{\secref}[1]{Section~\ref{#1}}
\newcommand{\chapref}[1]{Chapter~\ref{#1}}
\renewcommand{\eqref}[1]{Equation~(\ref{#1})}
\newcommand{\figref}[1]{Figure~\ref{#1}}
\newcommand{\tabref}[1]{Table~\ref{#1}}
% ------------------- colors -------------------
\definecolor{darkgreen}{rgb}{0.0, 0.5, 0.0}
% Colors of the Albert Ludwigs University as in
% https://www.zuv.uni-freiburg.de/service/cd/cd-manual/farbwelt
\definecolor{UniBlue}{RGB}{0, 74, 153}
\definecolor{UniRed}{RGB}{193, 0, 42}
\definecolor{UniGrey}{RGB}{154, 155, 156}
% ------------------- layout -------------------
% prevents floating objects from being placed ahead of their section
\let\mySection\section\renewcommand{\section}{\suppressfloats[t]\mySection}
\let\mySubSection\subsection\renewcommand{\subsection}{\suppressfloats[t]\mySubSection}
% ------------------- marker commands -------------------
% ToDo command
\newcommand{\todo}[1]{\textbf{\textcolor{red}{(TODO: #1)}}}
\newcommand{\extend}[1]{\textbf{\textcolor{darkgreen}{(EXTEND: #1)}}}
% Lighter color to note down quick drafts
\newcommand{\draft}[1]{\textbf{\textcolor{NavyBlue}{(DRAFT: #1)}}}
% ------------------- math formatting commands -------------------
% define vectors to be bold instead of using an arrow
\renewcommand{\vec}[1]{\mathbf{#1}}
\newcommand{\mat}[1]{\mathbf{#1}}
% tag equation with name
\newcommand{\eqname}[1]{\tag*{#1}}
% ------------------- pdf settings -------------------
% ADAPT THIS
\hypersetup{pdftitle={\thetitle},
pdfauthor={\theauthor},
pdfsubject={Undergraduate thesis at the Albert Ludwig University of Freiburg},
pdfkeywords={deep learning, awesome algorithm, undergraduate thesis},
pdfpagelayout=OneColumn, pdfnewwindow=true, pdfstartview=XYZ, plainpages=false}
%==========================================
% You might not need the following commands, I only included them as they
% are needed for the example floats
% ------------------- Tikz styles -------------------
\tikzset{>=latex} % arrow style
% ------------------- algorithm ---------------------
% Command to align comments in algorithm
\newcommand{\alignedComment}[1]{\Comment{\parbox[t]{.35\linewidth}{#1}}}
% define a foreach command in algorithms
\algnewcommand\algorithmicforeach{\textbf{foreach}}
\algdef{S}[FOR]{ForEach}[1]{\algorithmicforeach\ #1\ \algorithmicdo}
% line spacing should be 1.5
\renewcommand{\baselinestretch}{1.5}
% set distance between items in a list, for more details see the
% enumitem package: https://www.ctan.org/pkg/enumitem
\setlist{itemsep=.5em}