Skip to content

Commit 9e7642c

Browse files
mariomario
authored andcommitted
new & updated readmes
1 parent 99619fc commit 9e7642c

File tree

3 files changed

+24
-158
lines changed

3 files changed

+24
-158
lines changed

README.md

Lines changed: 9 additions & 158 deletions
Original file line numberDiff line numberDiff line change
@@ -1,178 +1,29 @@
11
# Computational Neuroimaging Toolbox
22

3-
![](https://img.shields.io/badge/release-v1.2.0-blueviolet.svg?style=flat)
43
![](https://img.shields.io/github/license/ccnmaastricht/CNI_toolbox)
54
![](https://img.shields.io/github/issues/ccnmaastricht/CNI_toolbox)
65
![](https://img.shields.io/github/forks/ccnmaastricht/CNI_toolbox)
76
![](https://img.shields.io/github/stars/ccnmaastricht/CNI_toolbox)
87

9-
The Computational Neuroimaging Toolbox is a MATLAB toolbox for estimating input-referred models. Specifically, the toolbox contains tools for Fourier analyses of phase-encoded stimuli, population receptive field mapping, estimating parameters of generic (user-defined) input-referred models as well as performing ridge regression.
8+
The Computational Neuroimaging Toolbox contains tools for estimating input-referred models. Specifically, it includes tools for Fourier analyses of phase-encoded stimuli, population receptive field (pRF) mapping, fast (real-time) pRF mapping and for estimating parameters of generic (user-defined) input-referred models.
109

1110
This code is hosted at https://github.com/ccnmaastricht/CNI_toolbox
1211
The latest version may always be found here.
1312

13+
## Matlab implementation ![](https://img.shields.io/badge/release-v2.0.0-blueviolet.svg?style=flat)
14+
1415
This software was developed with MATLAB R2017a and access to the full suite of MATLAB add-on packages. Some of these packages may be required to run the software.
1516

16-
## Installation
17-
There are two options for installing the toolbox. Either download the toolbox file [Computational Neuroimaging Toolbox.mltbx](https://github.com/ccnmaastricht/CNI_toolbox/raw/master/Computational%20Neuroimaging%20Toolbox.mltbx), navigate to the downloaded file within MATLAB and then execute the following command:
17+
### Installation
18+
Download the toolbox file [Computational Neuroimaging Toolbox.mltbx](https://github.com/ccnmaastricht/CNI_toolbox/raw/master/Computational%20Neuroimaging%20Toolbox.mltbx), navigate to the downloaded file within MATLAB and then execute the following command:
1819

1920
```MATLAB
2021
matlab.addons.toolbox.installToolbox('Computational Neuroimaging Toolbox.mltbx');
2122
```
23+
## Python implementation ![](https://img.shields.io/badge/release-v1.0.0-blueviolet.svg?style=flat)
2224

23-
Alternatively, download the compressed toolbox [Computational Neuroimaging Toolbox.zip](https://github.com/ccnmaastricht/CNI_toolbox/raw/master/Computational%20Neuroimaging%20Toolbox.zip) and extract it into Documents/MATLAB/Add-Ons/Toolboxes.
24-
25-
## Files
26-
This repository contains four files.
27-
1. `PEA.m` - MATLAB class implementation of Fourier analysis of phase-encoded stimuli.
28-
2. `pRF.m` - MATLAB class implementation of population receptive field mapping.
29-
3. `IRM.m` - MATLAB class implementation of input-referred model estimation.
30-
4. `RRT.m` - MATLAB class implementation of voxel-wise ridge regression.
31-
32-
33-
### Phase-encoding analysis tool.
34-
`pea = PEA(parameters)` creates an instance of the PEA class.
35-
parameters is a structure with 7 required fields
36-
- f_sampling: sampling frequency (1/TR)
37-
- f_stim : stimulation frequency
38-
- n_samples : number of samples (volumes)
39-
- n_rows : number of rows (in-plane resolution)
40-
- n_cols : number of columns (in-plance resolution)
41-
- n_slices : number of slices
25+
### Installation
4226

43-
This class has the following functions
44-
45-
- `delay = PEA.get_delay();`
46-
- `direction = PEA.get_direction();`
47-
- `PEA.set_delay(delay);`
48-
- `PEA.set_direction(direction);`
49-
- `results = PEA.fitting(data);`
50-
51-
Use `help PEA.function` to get more detailed help on any specific
52-
function (e.g. `help PEA.fitting`)
53-
54-
typical workflow:
55-
```Matlab
56-
pea = PEA(parameters);
57-
pea.set_delay(delay);
58-
pea.set_direction(direction);
59-
results = pea.fitting(data);
27+
```Python
28+
pip install cni-tlbx
6029
```
61-
62-
### Population receptive field (pRF) mapping tool.
63-
`prf = pRF(parameters)` creates an instance of the pRF class.
64-
parameters is a structure with 7 required fields
65-
- f_sampling: sampling frequency (1/TR)
66-
- n_samples : number of samples (volumes)
67-
- n_rows : number of rows (in-plane resolution)
68-
- n_cols : number of columns (in-plance resolution)
69-
- n_slices : number of slices
70-
- w_stimulus: width of stimulus images in pixels
71-
- h_stimulus: height of stimulus images in pixels
72-
73-
optional inputs are
74-
- hrf : either a column vector containing a single hemodynamic
75-
response used for every voxel;
76-
or a matrix with a unique hemodynamic response along
77-
its columns for each voxel.
78-
By default the canonical two-gamma hemodynamic response
79-
function is generated internally based on the scan parameters.
80-
81-
This class has the following functions
82-
83-
- `hrf = pRF.get_hrf();`
84-
- `stimulus = pRF.get_stimulus();`
85-
- `tc = pRF.get_timecourses();`
86-
- `pRF.set_hrf(hrf);`
87-
- `pRF.set_stimulus(stimulus);`
88-
- `pRF.import_stimulus();`
89-
- `pRF.create_timecourses();`
90-
- `results = pRF.mapping(data);`
91-
92-
Use `help pRF.function` to get more detailed help on any specific function
93-
(e.g. `help pRF.mapping`)
94-
95-
typical workflow:
96-
```Matlab
97-
prf = pRF(parameters);
98-
prf.import_stimulus();
99-
prf.create_timecourses();
100-
results = prf.mapping(data);
101-
```
102-
103-
### Input-referred model (IRM) mapping tool.
104-
105-
`irm = IRM(parameters)` creates an instance of the IRM class.
106-
parameters is a structure with 5 required fields
107-
- f_sampling: sampling frequency (1/TR)
108-
- n_samples : number of samples (volumes)
109-
- n_rows : number of rows (in-plane resolution)
110-
- n_cols : number of columns (in-plance resolution)
111-
- n_slices : number of slices
112-
113-
optional inputs are
114-
- hrf : either a column vector containing a single hemodynamic
115-
response used for every voxel;
116-
or a matrix with a unique hemodynamic response along
117-
its columns for each voxel.
118-
By default the canonical two-gamma hemodynamic response
119-
function is generated internally based on the scan parameters.
120-
121-
This class has the following functions
122-
123-
- `hrf = IRM.get_hrf();`
124-
- `stimulus = IRM.get_stimulus();`
125-
- `tc = IRM.get_timecourses();`
126-
- `IRM.set_hrf(hrf);`
127-
- `IRM.set_stimulus(stimulus);`
128-
- `IRM.create_timecourses();`
129-
- `results = IRM.mapping(data);`
130-
131-
Use `help IRM.function` to get more detailed help on any specific function
132-
(e.g. `help IRM.mapping`)
133-
134-
typical workflow:
135-
```Matlab
136-
irm = IRM(parameters);
137-
irm.set_stimulus();
138-
irm.create_timecourse(FUN,xdata);
139-
results = irm.mapping(data);
140-
```
141-
142-
### Ridge-based analysis tool.
143-
144-
`rrt = RRT(parameters)` creates an instance of the RRT class.
145-
parameters is a structure with 5 required fields
146-
- f_sampling: sampling frequency (1/TR)
147-
- n_samples : number of samples (volumes)
148-
- n_rows : number of rows (in-plane resolution)
149-
- n_cols : number of columns (in-plance resolution)
150-
- n_slices : number of slices
151-
152-
optional inputs are
153-
- hrf : either a column vector containing a single hemodynamic
154-
response used for every voxel;
155-
or a matrix with a unique hemodynamic response along
156-
its columns for each voxel.
157-
By default the canonical two-gamma hemodynamic response
158-
function is generated internally based on the scan parameters.
159-
160-
This class has the following functions
161-
162-
- `hrf = RRT.get_hrf();`
163-
- `X = RRT.get_design();`
164-
- `RRT.set_hrf(hrf);`
165-
- `RRT.set_design(X);`
166-
- `RRT.optimize_lambda(data,range);`
167-
- `results = RRT.perform_ridge(data);`
168-
169-
Use `help RRT.function` to get more detailed help on any specific
170-
function (e.g. `help RRT.perform_ridge`)
171-
172-
typical workflow:
173-
```Matlab
174-
rrt = RRT(parameters);
175-
rrt.set_design(X);
176-
rrt.optimize_lambda(data,range);
177-
results = rrt.perform_ridge(data);
178-
```

code/matlab/README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
## Files
2+
This repository contains four files.
3+
1. `PEA.m` - class implementation of Fourier analysis of phase-encoded stimuli.
4+
4. `HGR.m` - class implementation of linear RF model based on hashed Gaussians.
5+
3. `pRF.m` - class implementation of population receptive field mapping.
6+
4. `IRM.m` - class implementation of input-referred model estimation.
7+
4. `online_processor.m` - class implementation of real-time data processing.
8+
5. `progress.m` - progress bar function used by main tools.

code/python/README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
## Files
2+
This repository contains four files.
3+
1. `PEA.py` - class implementation of Fourier analysis of phase-encoded stimuli.
4+
4. `HGR.py` - class implementation of linear RF model based on hashed Gaussians.
5+
3. `pRF.py` - class implementation of population receptive field mapping.
6+
4. `IRM.py` - class implementation of input-referred model estimation.
7+
5. `gadgets.py` - collection of auxiliary tools (used by main tools).

0 commit comments

Comments
 (0)