\documentclass[answers]{exam}1\newif\ifanswers2\answerstrue % comment out to hide answers34\usepackage{lastpage} % Required to determine the last page for the footer5\usepackage{extramarks} % Required for headers and footers6\usepackage[usenames,dvipsnames]{color} % Required for custom colors7\usepackage{graphicx} % Required to insert images8\usepackage{listings} % Required for insertion of code9\usepackage{courier} % Required for the courier font10\usepackage{lipsum} % Used for inserting dummy 'Lorem ipsum' text into the template11\usepackage{enumerate}12\usepackage{subfigure}13\usepackage{booktabs}14\usepackage{amsmath, amsthm, amssymb}15\usepackage{hyperref}16\usepackage{datetime}17\usepackage{minted}18\settimeformat{ampmtime}19\usepackage{algpseudocode}20\usepackage{algorithmicx}21\usepackage[ruled]{algorithm}22\usepackage{tikz-dependency}2324\usepackage{tikz}25\usetikzlibrary{positioning,patterns,fit,calc}26% Margins27\topmargin=-0.45in28\evensidemargin=0in29\oddsidemargin=0in30\textwidth=6.5in31\textheight=9.0in32\headsep=0.25in3334\linespread{1.1} % Line spacing3536% Set up the header and footer37%\pagestyle{fancy}38%\rhead{\hmwkAuthorName} % Top left header39%\lhead{\hmwkClass: \hmwkTitle} % Top center head40%\lfoot{\lastxmark} % Bottom left footer41%\cfoot{} % Bottom center footer42%\rfoot{Page\ \thepage\ of\ \protect\pageref{LastPage}} % Bottom right footer43%\renewcommand\headrulewidth{0.4pt} % Size of the header rule44%\renewcommand\footrulewidth{0.4pt} % Size of the footer rule4546\pagestyle{headandfoot}47\runningheadrule{}48\firstpageheader{CS 224n}{Assignment 3}{}49\runningheader{CS 224n} {Assignment 3} {Page \thepage\ of \numpages}50\firstpagefooter{}{}{} \runningfooter{}{}{}5152\setlength\parindent{0pt} % Removes all indentation from paragraphs5354%----------------------------------------------------------------------------------------55% CODE INCLUSION CONFIGURATION56%----------------------------------------------------------------------------------------5758\definecolor{MyDarkGreen}{rgb}{0.0,0.4,0.0} % This is the color used for comments59\lstloadlanguages{Python} % Load Perl syntax for listings, for a list of other languages supported see: ftp://ftp.tex.ac.uk/tex-archive/macros/latex/contrib/listings/listings.pdf60\lstset{language=Python, % Use Perl in this example61frame=single, % Single frame around code62basicstyle=\footnotesize\ttfamily, % Use small true type font63keywordstyle=[1]\color{Blue}\bf, % Perl functions bold and blue64keywordstyle=[2]\color{Purple}, % Perl function arguments purple65keywordstyle=[3]\color{Blue}\underbar, % Custom functions underlined and blue66identifierstyle=, % Nothing special about identifiers67commentstyle=\usefont{T1}{pcr}{m}{sl}\color{MyDarkGreen}\small, % Comments small dark green courier font68stringstyle=\color{Purple}, % Strings are purple69showstringspaces=false, % Don't put marks in string spaces70tabsize=5, % 5 spaces per tab71%72% Put standard Perl functions not included in the default language here73morekeywords={rand},74%75% Put Perl function parameters here76morekeywords=[2]{on, off, interp},77%78% Put user defined functions here79morekeywords=[3]{test},80%81morecomment=[l][\color{Blue}]{...}, % Line continuation (...) like blue comment82numbers=left, % Line numbers on left83firstnumber=1, % Line numbers start with line 184numberstyle=\tiny\color{Blue}, % Line numbers are blue and small85stepnumber=5 % Line numbers go in steps of 586}8788%----------------------------------------------------------------------------------------89% NAME AND CLASS SECTION90%----------------------------------------------------------------------------------------9192\newcommand{\hmwkTitle}{Dependency Parsing} % Assignment title93\newcommand{\hmwkClass}{CS\ 224n Assignment \#3} % Course/class94\newcommand{\ifans}[1]{\ifanswers \color{red} \textbf{Solution: } #1 \color{black} \fi}9596% \newcommand{\ifans}[1]{}9798\input macros.tex99\input std_macros.tex100101%----------------------------------------------------------------------------------------102% TITLE PAGE103%----------------------------------------------------------------------------------------104\qformat{\Large\bfseries\thequestion{}. \thequestiontitle{} (\thepoints{})\hfill}105106\title{107\vspace{-1in}108\textmd{\textbf{\hmwkClass:\ \hmwkTitle}}109}110\author{}111%\date{\textit{\small Updated \today\ at \currenttime}} % Insert date here if you want it to appear below your name112\date{}113114\setcounter{section}{0} % one-indexing115\begin{document}116117\maketitle118% \vspace{-10pt}119120In this assignment, you will build a neural dependency parser using PyTorch. For a review of the fundamentals of PyTorch, please check out the PyTorch review session on Canvas. In Part 1, you will learn about two general neural network techniques (Adam Optimization and Dropout). In Part 2, you will implement and train a dependency parser using the techniques from Part 1, before analyzing a few erroneous dependency parses.121122Please tag the questions correctly on Gradescope, the TAs will take points off if you don't tag questions.123\begin{questions}124\input{q1.tex}125\newpage126\input{q2.tex}127\end{questions}128129\input{submission.tex}130\end{document}131132