-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit bf7b3e7
Showing
10 changed files
with
4,500 additions
and
0 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
441 changes: 441 additions & 0 deletions
441
data/.ipynb_checkpoints/data_ADNI_preprocess-checkpoint.ipynb
Large diffs are not rendered by default.
Oops, something went wrong.
1,661 changes: 1,661 additions & 0 deletions
1,661
data/.ipynb_checkpoints/data_CF_label_test-checkpoint.ipynb
Large diffs are not rendered by default.
Oops, something went wrong.
875 changes: 875 additions & 0 deletions
875
data/.ipynb_checkpoints/data_CF_preprocess-checkpoint.ipynb
Large diffs are not rendered by default.
Oops, something went wrong.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import numpy as np | ||
|
||
|
||
def import_data(data_name = 'sample'): | ||
''' | ||
Output: | ||
- data_x: [N, max_length, 1+x_dim] tensor (where N: number of samples, max_length: max sequence length, x_dim: feature dimension) | ||
the first feature is the time difference. | ||
- data_y: [N, max_length, y_dim] tensor (where N: number of samples, max_length: max sequence length, y_dim: output dimension) | ||
''' | ||
if data_name == 'sample': | ||
npz = np.load('./data/sample/data.npz') | ||
data_x = npz['data_x'] | ||
data_y = npz['data_y'] | ||
y_type = npz['y_type'] #{'binary', 'categorical', 'continuous'} | ||
else: | ||
raise ValueError('error: data_name not defined') | ||
|
||
return data_x, data_y, y_type |
Oops, something went wrong.