SlideShare a Scribd company logo
CSCE 509 – Spring 2019
Assignment 3 // updated 01May19
DUE: May 11, 2019 at 5 p.m.
• Two data sets available on Moodle
o {concaveData.npy, concaveTarget.npy}
o {testData.npy, testTarget.npy}
• Write TensorFlow code to perform DNN
classification with three(3) classes
• Use concave*.npy for training
• Use test*.npy for test
• Data is the data matrix; Target is the labeled
targets from {0, 1, 2}
• Do each of the following steps. For each step: Note
the accuracy of the classification using
the test data set. Discuss the results.
1. Write TensorFlow code to perform DNN
classification using default settings. Define
your
own architecture with two hidden layers. Calculate
the number of parameters in your
network. Do not let the number of parameters
exceed the number of inputsamples in
concave*.npy
2. Use one or two additional layers compared to
(1) but be sure that the number of
parameters do not exceed the number of input
samples. Which has better accuracy
performance? Or are they about the same?
3. Write Python code to read in the data sets. Add a
largeconstant (such as “509” or “5090”)
to each inputfeature. Write the data sets as files,to
be read in as inputsets. Repeat the
classification using the new inputfiles with the
architecture that has better performance
in (1) or (2). What is the accuracy performance
for the same number of epochs? If the
accuracy performance is about the same, does it
converge faster or slower or about the
same?
4. Use the given data sets as used in (1) and
(2). Use either of the two architectures. Change
the tf.layers.dense() function initlialization to He
initialization by using the
variance_scaling_initializer() function:
he_init =
tf.contrib.layers.variance_scaling_initializer(factor=2.0)
hidden1 = tf.layers.dense(X, n_hidden1, activation=tf.nn.relu,
kernel_initializer=he_init, name=”hidden1”)
# do the same for other hidden layers
What is the accuracy performance? Compare to
either (1) or (2).
5. Take the architecture from either (1) or (2).
Replace the relu activation function by the
exponential linear unit (ELU). In the
tf.layers.dense function, use
activation=tf.nn.elu
What is the accuracy performance? Compare to
either (1) or (2) and to (4).
6. Perform batch normalization on either (1) or
(2) as follows. We want to zero-center and
normalize the inputs to the activation function of
each layerby learning the mean and
scales of the inputs for each layer. Modify
the Python code as follows:
X = tf.placeholder(tf.float32, shape=(None, n_inputs),
name=”X”)
training = tf.placeholder_with_default(False, shape=(),
name=”training”)
Then in defining the hidden layers:
hidden1 = tf.layers.dense(X, n_hidden1, name=”hidden1”)
batchnorm1 = tf.layers.batch_normalization(hidden1,
training=training,
momentum=0.9)
bn1_act = tf.nn.elu(batchnorm1)
hidden2 = tf.layers.dense(bn1_act, n_hidden2, name=”hidden2”)
batchnorm2 = tf.layers.batch_normalization(hidden2,
training=training,
momentum=0.9)
bn2_act = tf.nn.elu(batchnorm2)
# other hidden layers as needed
logits_bf_bn = tf.layers.dense(bn2_act, n_outputs,
name=”outputs”)
logits = tf.layers.batch_normalization(logits_bf_bn,
training=training,
momentum=0.9)
At the end of the construction phase, add this
line:
extra_update_steps =
tf.get_collection(tf.GraphKeys.UPDATE_OPS)
In the execution phase; add the extraupdate steps
and set training to True during the
session.run:
session.run([training_step, extra_update_steps],
feed_dict={training: True,
X:X_batch, y:y_batch})
Does the performance change?
CHAPTER 26 LAB HOMEWORK
NAME: ____________________________ LAB SECTION:
_______
following molecules
normally found?
(Either circle where
they are found, or
erase where they
wouldn’t be found)
or mechanism that
prevents certain
molecules…
into filtrate?
filtrate to become
urine?
B
a
rr
ie
r:
M
e
ch
a
n
is
m
:
1
C
h
a
p
te
r 2
6
L
a
b
H
o
m
e
w
o
rk
Found in
blood?
RBC
Albumin
Glucose
Urea
Found in
filtrate?
RBC
Albumin
Glucose
Urea
Found in
urine?
RBC
Albumin
Glucose
Urea
6
/2
6
/2
0
1
8
P
le
a
s
e
s
ta
p
le
h
e
re
ABNORMAL COMPONENTS OF A URINALYSIS TEST
STRIP
What would cause the following
to appear in the bloodstream?
Bilirubins
Urobilinogins
Ketones
Nitrites
Hemoglobin
Kidney damage
Liver damage
Bacterial infection
Diabetes
2
C
h
a
p
te
r 2
6
L
a
b
H
o
m
e
w
o
rk
URINALYSIS: FILL IN THE FOLLOWING CHART
Substance Normally
found in
blood?
Normally
found in
filtrate?
Normally
found in
urine?
Significance
(brief)?
Leukocytes
Nitrites
Protein
Glucose
Ketone bodies
Urobilinogen
Bilirubin
Erythrocytes
Hemoglobin
3
C
h
a
p
te
r 6
L
a
b
H
o
m
e
w
o
rk

More Related Content

PDF
OpenPOWER Workshop in Silicon Valley
PDF
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
PDF
Neural Networks in the Wild: Handwriting Recognition
PPTX
Deep Learning, Keras, and TensorFlow
PDF
Neural networks using tensor flow in amazon deep learning server
PPTX
Deep Learning, Scala, and Spark
PPTX
TensorFlow for IITians
PPTX
H2 o berkeleydltf
OpenPOWER Workshop in Silicon Valley
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
Neural Networks in the Wild: Handwriting Recognition
Deep Learning, Keras, and TensorFlow
Neural networks using tensor flow in amazon deep learning server
Deep Learning, Scala, and Spark
TensorFlow for IITians
H2 o berkeleydltf

Similar to CSCE509–Spring2019Assignment3updated01May19DU.docx (20)

PPTX
Deep Learning in your Browser: powered by WebGL
PDF
Deep Learning, Microsoft Cognitive Toolkit (CNTK) and Azure Machine Learning ...
PDF
IRJET - Implementation of Neural Network on FPGA
PPTX
Digit recognizer by convolutional neural network
PPTX
Introduction to Deep Learning, Keras, and Tensorflow
PDF
Introduction to Deep Learning, Keras, and TensorFlow
PPTX
Introduction to Deep Learning and Tensorflow
PPTX
Machine Learning Essentials Demystified part2 | Big Data Demystified
PPTX
Deep Learning and TensorFlow
PPTX
C++ and Deep Learning
PPTX
Deep Learning and TensorFlow
PDF
Icpp power ai-workshop 2018
PPTX
Deep learning with TensorFlow
DOCX
Need help filling out the missing sections of this code- the sections.docx
PDF
Neural Networks from Scratch - TensorFlow 101
PDF
Keras and TensorFlow
PDF
Hardware Acceleration for Machine Learning
PPTX
How to Build a Neural Network and Make Predictions
PPTX
Artificial Intelligence, Machine Learning and Deep Learning
PDF
Power ai tensorflowworkloadtutorial-20171117
Deep Learning in your Browser: powered by WebGL
Deep Learning, Microsoft Cognitive Toolkit (CNTK) and Azure Machine Learning ...
IRJET - Implementation of Neural Network on FPGA
Digit recognizer by convolutional neural network
Introduction to Deep Learning, Keras, and Tensorflow
Introduction to Deep Learning, Keras, and TensorFlow
Introduction to Deep Learning and Tensorflow
Machine Learning Essentials Demystified part2 | Big Data Demystified
Deep Learning and TensorFlow
C++ and Deep Learning
Deep Learning and TensorFlow
Icpp power ai-workshop 2018
Deep learning with TensorFlow
Need help filling out the missing sections of this code- the sections.docx
Neural Networks from Scratch - TensorFlow 101
Keras and TensorFlow
Hardware Acceleration for Machine Learning
How to Build a Neural Network and Make Predictions
Artificial Intelligence, Machine Learning and Deep Learning
Power ai tensorflowworkloadtutorial-20171117
Ad

More from mydrynan (20)

DOCX
CSIA 413 Cybersecurity Policy, Plans, and Programs.docx
DOCX
CSIS 100CSIS 100 - Discussion Board Topic #1One of the object.docx
DOCX
CSI Paper Grading Rubric- (worth a possible 100 points) .docx
DOCX
CSIA 413 Cybersecurity Policy, Plans, and ProgramsProject #4 IT .docx
DOCX
CSI 170 Week 3 AssingmentAssignment 1 Cyber Computer CrimeAss.docx
DOCX
CSE422 Section 002 – Computer Networking Fall 2018 Ho.docx
DOCX
CSCI  132  Practical  Unix  and  Programming   .docx
DOCX
CSCI 714 Software Project Planning and EstimationLec.docx
DOCX
CSCI 561Research Paper Topic Proposal and Outline Instructions.docx
DOCX
CSCI 561 DB Standardized Rubric50 PointsCriteriaLevels of .docx
DOCX
CryptographyLesson 10© Copyright 2012-2013 (ISC)², Inc. Al.docx
DOCX
CSCI 352 - Digital Forensics Assignment #1 Spring 2020 .docx
DOCX
CSCE 1040 Homework 2 For this assignment we are going to .docx
DOCX
CSCI 2033 Elementary Computational Linear Algebra(Spring 20.docx
DOCX
CSCE 3110 Data Structures & Algorithms Summer 2019 1 of .docx
DOCX
CSCI 340 Final Group ProjectNatalie Warden, Arturo Gonzalez, R.docx
DOCX
CSC-321 Final Writing Assignment In this assignment, you .docx
DOCX
Cryptography is the application of algorithms to ensure the confiden.docx
DOCX
CSc3320 Assignment 6 Due on 24th April, 2013 Socket programming .docx
DOCX
Cryptography KeysCryptography provides confidentiality, inte.docx
CSIA 413 Cybersecurity Policy, Plans, and Programs.docx
CSIS 100CSIS 100 - Discussion Board Topic #1One of the object.docx
CSI Paper Grading Rubric- (worth a possible 100 points) .docx
CSIA 413 Cybersecurity Policy, Plans, and ProgramsProject #4 IT .docx
CSI 170 Week 3 AssingmentAssignment 1 Cyber Computer CrimeAss.docx
CSE422 Section 002 – Computer Networking Fall 2018 Ho.docx
CSCI  132  Practical  Unix  and  Programming   .docx
CSCI 714 Software Project Planning and EstimationLec.docx
CSCI 561Research Paper Topic Proposal and Outline Instructions.docx
CSCI 561 DB Standardized Rubric50 PointsCriteriaLevels of .docx
CryptographyLesson 10© Copyright 2012-2013 (ISC)², Inc. Al.docx
CSCI 352 - Digital Forensics Assignment #1 Spring 2020 .docx
CSCE 1040 Homework 2 For this assignment we are going to .docx
CSCI 2033 Elementary Computational Linear Algebra(Spring 20.docx
CSCE 3110 Data Structures & Algorithms Summer 2019 1 of .docx
CSCI 340 Final Group ProjectNatalie Warden, Arturo Gonzalez, R.docx
CSC-321 Final Writing Assignment In this assignment, you .docx
Cryptography is the application of algorithms to ensure the confiden.docx
CSc3320 Assignment 6 Due on 24th April, 2013 Socket programming .docx
Cryptography KeysCryptography provides confidentiality, inte.docx
Ad

Recently uploaded (20)

PDF
RMMM.pdf make it easy to upload and study
PPTX
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
PDF
O7-L3 Supply Chain Operations - ICLT Program
PDF
Computing-Curriculum for Schools in Ghana
PDF
TR - Agricultural Crops Production NC III.pdf
PDF
102 student loan defaulters named and shamed – Is someone you know on the list?
PPTX
1st Inaugural Professorial Lecture held on 19th February 2020 (Governance and...
PPTX
Cell Structure & Organelles in detailed.
PDF
Module 4: Burden of Disease Tutorial Slides S2 2025
PDF
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
PPTX
master seminar digital applications in india
PPTX
PPT- ENG7_QUARTER1_LESSON1_WEEK1. IMAGERY -DESCRIPTIONS pptx.pptx
PDF
Abdominal Access Techniques with Prof. Dr. R K Mishra
PPTX
Renaissance Architecture: A Journey from Faith to Humanism
PPTX
Institutional Correction lecture only . . .
PPTX
Pharma ospi slides which help in ospi learning
PDF
01-Introduction-to-Information-Management.pdf
PDF
Physiotherapy_for_Respiratory_and_Cardiac_Problems WEBBER.pdf
PPTX
Introduction_to_Human_Anatomy_and_Physiology_for_B.Pharm.pptx
PDF
O5-L3 Freight Transport Ops (International) V1.pdf
RMMM.pdf make it easy to upload and study
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
O7-L3 Supply Chain Operations - ICLT Program
Computing-Curriculum for Schools in Ghana
TR - Agricultural Crops Production NC III.pdf
102 student loan defaulters named and shamed – Is someone you know on the list?
1st Inaugural Professorial Lecture held on 19th February 2020 (Governance and...
Cell Structure & Organelles in detailed.
Module 4: Burden of Disease Tutorial Slides S2 2025
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
master seminar digital applications in india
PPT- ENG7_QUARTER1_LESSON1_WEEK1. IMAGERY -DESCRIPTIONS pptx.pptx
Abdominal Access Techniques with Prof. Dr. R K Mishra
Renaissance Architecture: A Journey from Faith to Humanism
Institutional Correction lecture only . . .
Pharma ospi slides which help in ospi learning
01-Introduction-to-Information-Management.pdf
Physiotherapy_for_Respiratory_and_Cardiac_Problems WEBBER.pdf
Introduction_to_Human_Anatomy_and_Physiology_for_B.Pharm.pptx
O5-L3 Freight Transport Ops (International) V1.pdf

CSCE509–Spring2019Assignment3updated01May19DU.docx

  • 1. CSCE 509 – Spring 2019 Assignment 3 // updated 01May19 DUE: May 11, 2019 at 5 p.m. • Two data sets available on Moodle o {concaveData.npy, concaveTarget.npy} o {testData.npy, testTarget.npy} • Write TensorFlow code to perform DNN classification with three(3) classes • Use concave*.npy for training • Use test*.npy for test • Data is the data matrix; Target is the labeled targets from {0, 1, 2} • Do each of the following steps. For each step: Note the accuracy of the classification using the test data set. Discuss the results. 1. Write TensorFlow code to perform DNN classification using default settings. Define your own architecture with two hidden layers. Calculate the number of parameters in your network. Do not let the number of parameters exceed the number of inputsamples in concave*.npy 2. Use one or two additional layers compared to
  • 2. (1) but be sure that the number of parameters do not exceed the number of input samples. Which has better accuracy performance? Or are they about the same? 3. Write Python code to read in the data sets. Add a largeconstant (such as “509” or “5090”) to each inputfeature. Write the data sets as files,to be read in as inputsets. Repeat the classification using the new inputfiles with the architecture that has better performance in (1) or (2). What is the accuracy performance for the same number of epochs? If the accuracy performance is about the same, does it converge faster or slower or about the same? 4. Use the given data sets as used in (1) and (2). Use either of the two architectures. Change the tf.layers.dense() function initlialization to He initialization by using the variance_scaling_initializer() function: he_init = tf.contrib.layers.variance_scaling_initializer(factor=2.0) hidden1 = tf.layers.dense(X, n_hidden1, activation=tf.nn.relu, kernel_initializer=he_init, name=”hidden1”) # do the same for other hidden layers What is the accuracy performance? Compare to either (1) or (2). 5. Take the architecture from either (1) or (2). Replace the relu activation function by the
  • 3. exponential linear unit (ELU). In the tf.layers.dense function, use activation=tf.nn.elu What is the accuracy performance? Compare to either (1) or (2) and to (4). 6. Perform batch normalization on either (1) or (2) as follows. We want to zero-center and normalize the inputs to the activation function of each layerby learning the mean and scales of the inputs for each layer. Modify the Python code as follows: X = tf.placeholder(tf.float32, shape=(None, n_inputs), name=”X”) training = tf.placeholder_with_default(False, shape=(), name=”training”) Then in defining the hidden layers: hidden1 = tf.layers.dense(X, n_hidden1, name=”hidden1”) batchnorm1 = tf.layers.batch_normalization(hidden1, training=training, momentum=0.9) bn1_act = tf.nn.elu(batchnorm1) hidden2 = tf.layers.dense(bn1_act, n_hidden2, name=”hidden2”) batchnorm2 = tf.layers.batch_normalization(hidden2, training=training, momentum=0.9) bn2_act = tf.nn.elu(batchnorm2) # other hidden layers as needed logits_bf_bn = tf.layers.dense(bn2_act, n_outputs, name=”outputs”)
  • 4. logits = tf.layers.batch_normalization(logits_bf_bn, training=training, momentum=0.9) At the end of the construction phase, add this line: extra_update_steps = tf.get_collection(tf.GraphKeys.UPDATE_OPS) In the execution phase; add the extraupdate steps and set training to True during the session.run: session.run([training_step, extra_update_steps], feed_dict={training: True, X:X_batch, y:y_batch}) Does the performance change? CHAPTER 26 LAB HOMEWORK NAME: ____________________________ LAB SECTION: _______ following molecules normally found? (Either circle where they are found, or
  • 5. erase where they wouldn’t be found) or mechanism that prevents certain molecules… into filtrate? filtrate to become urine? B a rr ie r: M e ch a
  • 8. 6 /2 0 1 8 P le a s e s ta p le h e re ABNORMAL COMPONENTS OF A URINALYSIS TEST STRIP What would cause the following to appear in the bloodstream?
  • 10. H o m e w o rk URINALYSIS: FILL IN THE FOLLOWING CHART Substance Normally found in blood? Normally found in filtrate? Normally found in urine? Significance (brief)?