Skip to content

Commit

Permalink
seminar6 part1 ROI ts upd
Browse files Browse the repository at this point in the history
  • Loading branch information
PominovaMS committed Oct 2, 2020
1 parent 9b1310e commit 3cf8993
Showing 1 changed file with 15 additions and 9 deletions.
24 changes: 15 additions & 9 deletions seminar6/seminar_6_ROI_time_series.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@
"provenance": [],
"collapsed_sections": [
"hqZksnfwt34o",
"D4_cLqPStvNy",
"_Pbss93ttqMP"
"D4_cLqPStvNy"
]
},
"accelerator": "GPU"
Expand Down Expand Up @@ -1158,7 +1157,9 @@
"id": "Vlu1fvBts2fN"
},
"source": [
"## RNN for multivariate time series"
"## RNN for multivariate time series\n",
"\n",
"Since the data is essentially a multidimensional time series, it seems natural to try to analyze it with a recurrent neural network. "
]
},
{
Expand All @@ -1167,7 +1168,11 @@
"id": "_Pbss93ttqMP"
},
"source": [
"### RNN on ROI time series (with GRU units)"
"### RNN on ROI time series (with GRU units)\n",
"\n",
"Here we define a general RNN architecture that consists of **1 or more** recurrent layers with GRU units followed by **2** fully connected layers. \n",
"\n",
"Data is sequentially processed by recurrent layers. Then we take the **last** computed hidden state, **mean** of all hidden states or a vector of **concatenated hidden states**, feed them into fully connected layer and predict the ASD probability. "
]
},
{
Expand Down Expand Up @@ -1238,7 +1243,11 @@
"source": [
"### Training\n",
"\n",
"Split data into training and validation parts, and create **train and val dataloaders**. Then create **GRUModel** with parameters of your choice (don't make it too complex), optimizer and scheduler (if needed). Train the model to detect patients with ASD from healthy control and measure its **ROC AUC** on the validation set. "
"Split data into training and validation parts, and create **train and val dataloaders**. Then create **GRUModel** with parameters of your choice (don't make it too complex), optimizer and scheduler (if needed). Train the model to detect patients with ASD from healthy control and measure its **ROC AUC** on the validation set. \n",
"\n",
"You can define a model with arguments of your choice. For example, try to vary `hidden_size`, `n_layers`, `use_states` and `n_fc_units` arguments. However, remember that the training sample is still quite small for DL, and the recurrent network has many parameters, so don't make it too large. \n",
"\n",
"Also, since ovefitting is very probable, you may want to properly choose `dropout`, `weight_decay` and `n_epochs` values. "
]
},
{
Expand All @@ -1252,10 +1261,7 @@
}
},
"source": [
"# training example\n",
"\n",
"# dataset includes data from several different sources (acqusition sites)\n",
"# we will use only 2 with largest contribution - NYU and UM\n",
"# use data from all sources\n",
"dataset.use_sources = []\n",
"\n",
"# dataset have target classes 1 and 2\n",
Expand Down

0 comments on commit 3cf8993

Please sign in to comment.