Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Take the phi - 2 LLM example. Adjust train _ test _ split function to generate approximately 4 0 0 positive and 4 0 0

Take the phi-2 LLM example. Adjust train_test_split function to generate approximately 400 positive and 400 negative sentiment feature vectors. Similarly, generate 50 positive and 50 negative test samples. Using a batch-size of 4:
a) Build logistic regression classifier. Report your accuracy on train and test sets. Explain if there are any overfit or underfit observed?
b) Build a neural network with two hidden layers. Use 5 nodes in each layer. Use
RELU nonlinearity. Try three different learning rates. Explain if there are any overfit or underfit observed?
c) Build an encoder-only transformer network. Use two heads in attention. Try two
different learning rates and number of layers. Explain if there are any overfit or underfit observed?
d) Do the part-c but remove residual connections and layer normalization.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions