Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
fdt
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
FSL
fdt
Commits
d39dd0d3
Commit
d39dd0d3
authored
18 years ago
by
Saad Jbabdi
Browse files
Options
Downloads
Patches
Plain Diff
added an option --pd to probtrackx for balancing the probability w.r.t distance
parent
e9766ad5
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
probtrackxOptions.h
+14
-10
14 additions, 10 deletions
probtrackxOptions.h
streamlines.cc
+17
-5
17 additions, 5 deletions
streamlines.cc
with
31 additions
and
15 deletions
probtrackxOptions.h
+
14
−
10
View file @
d39dd0d3
...
@@ -35,6 +35,7 @@ class probtrackxOptions {
...
@@ -35,6 +35,7 @@ class probtrackxOptions {
Option
<
string
>
mode
;
Option
<
string
>
mode
;
Option
<
string
>
targetfile
;
Option
<
string
>
targetfile
;
Option
<
bool
>
simpleout
;
Option
<
bool
>
simpleout
;
Option
<
int
>
pathdist
;
Option
<
bool
>
s2tout
;
Option
<
bool
>
s2tout
;
FmribOption
<
bool
>
matrix1out
;
FmribOption
<
bool
>
matrix1out
;
FmribOption
<
bool
>
matrix2out
;
FmribOption
<
bool
>
matrix2out
;
...
@@ -109,6 +110,9 @@ class probtrackxOptions {
...
@@ -109,6 +110,9 @@ class probtrackxOptions {
simpleout
(
string
(
"--opd"
),
false
,
simpleout
(
string
(
"--opd"
),
false
,
string
(
"output path distribution"
),
string
(
"output path distribution"
),
false
,
no_argument
),
false
,
no_argument
),
pathdist
(
string
(
"--pd"
),
1
,
string
(
"path distribution, 1:probability,2:distance corrected value"
),
false
,
requires_argument
),
s2tout
(
string
(
"--os2t"
),
false
,
s2tout
(
string
(
"--os2t"
),
false
,
string
(
"output seeds to targets"
),
string
(
"output seeds to targets"
),
false
,
no_argument
),
false
,
no_argument
),
...
@@ -119,18 +123,17 @@ class probtrackxOptions {
...
@@ -119,18 +123,17 @@ class probtrackxOptions {
string
(
"output matrix2"
),
string
(
"output matrix2"
),
false
,
no_argument
),
false
,
no_argument
),
maskmatrixout
(
string
(
"--omaskmatrix"
),
false
,
maskmatrixout
(
string
(
"--omaskmatrix"
),
false
,
string
(
"output maskmatrix"
),
string
(
"output maskmatrix"
),
false
,
no_argument
),
false
,
no_argument
),
outfile
(
string
(
"-o,--out"
),
string
(
""
),
outfile
(
string
(
"-o,--out"
),
string
(
""
),
string
(
"Output file (only for single seed voxel mode)"
),
string
(
"Output file (only for single seed voxel mode)"
),
false
,
requires_argument
),
false
,
requires_argument
),
rubbishfile
(
string
(
"--rubbish"
),
string
(
""
),
rubbishfile
(
string
(
"--rubbish"
),
string
(
""
),
string
(
"Rubbish file"
),
string
(
"Rubbish file"
),
false
,
requires_argument
),
false
,
requires_argument
),
seeds_to_dti
(
string
(
"--xfm"
),
string
(
""
),
seeds_to_dti
(
string
(
"--xfm"
),
string
(
""
),
string
(
"Transform Matrix taking seed space to DTI space default is to use the identity"
),
false
,
requires_argument
),
string
(
"Transform Matrix taking seed space to DTI space default is to use the identity"
),
false
,
requires_argument
),
skipmask
(
string
(
"--no_integrity"
),
string
(
""
),
skipmask
(
string
(
"--no_integrity"
),
string
(
""
),
string
(
"no explanation needed"
),
string
(
"no explanation needed"
),
false
,
requires_argument
),
false
,
requires_argument
),
seedref
(
string
(
"--seedref"
),
string
(
""
),
seedref
(
string
(
"--seedref"
),
string
(
""
),
...
@@ -205,6 +208,7 @@ class probtrackxOptions {
...
@@ -205,6 +208,7 @@ class probtrackxOptions {
options
.
add
(
logdir
);
options
.
add
(
logdir
);
options
.
add
(
forcedir
);
options
.
add
(
forcedir
);
options
.
add
(
simpleout
);
options
.
add
(
simpleout
);
options
.
add
(
pathdist
);
options
.
add
(
s2tout
);
options
.
add
(
s2tout
);
options
.
add
(
matrix1out
);
options
.
add
(
matrix1out
);
options
.
add
(
matrix2out
);
options
.
add
(
matrix2out
);
...
...
This diff is collapsed.
Click to expand it.
streamlines.cc
+
17
−
5
View file @
d39dd0d3
...
@@ -363,11 +363,23 @@ namespace TRACT{
...
@@ -363,11 +363,23 @@ namespace TRACT{
void
Counter
::
update_pathdist
(){
void
Counter
::
update_pathdist
(){
const
vector
<
ColumnVector
>&
path
=
m_stline
.
get_path_ref
();
const
vector
<
ColumnVector
>&
path
=
m_stline
.
get_path_ref
();
for
(
unsigned
int
i
=
0
;
i
<
path
.
size
();
i
++
){
if
(
opts
.
pathdist
.
value
()
==
1
){
int
x_s
=
int
(
round
(
float
(
path
[
i
](
1
)))),
y_s
=
int
(
round
(
float
(
path
[
i
](
2
)))),
z_s
=
int
(
round
(
float
(
path
[
i
](
3
))));
for
(
unsigned
int
i
=
0
;
i
<
path
.
size
();
i
++
){
if
(
m_beenhere
(
x_s
,
y_s
,
z_s
)
==
0
){
int
x_s
=
int
(
round
(
float
(
path
[
i
](
1
)))),
y_s
=
int
(
round
(
float
(
path
[
i
](
2
)))),
z_s
=
int
(
round
(
float
(
path
[
i
](
3
))));
m_prob
(
x_s
,
y_s
,
z_s
)
+=
1
;
if
(
m_beenhere
(
x_s
,
y_s
,
z_s
)
==
0
){
m_beenhere
(
x_s
,
y_s
,
z_s
)
=
1
;
m_prob
(
x_s
,
y_s
,
z_s
)
+=
1
;
m_beenhere
(
x_s
,
y_s
,
z_s
)
=
1
;
}
}
}
else
{
int
d
=
1
;
for
(
unsigned
int
i
=
0
;
i
<
path
.
size
();
i
++
){
int
x_s
=
int
(
round
(
float
(
path
[
i
](
1
)))),
y_s
=
int
(
round
(
float
(
path
[
i
](
2
)))),
z_s
=
int
(
round
(
float
(
path
[
i
](
3
))));
if
(
m_beenhere
(
x_s
,
y_s
,
z_s
)
==
0
){
m_prob
(
x_s
,
y_s
,
z_s
)
+=
d
;
d
++
;
m_beenhere
(
x_s
,
y_s
,
z_s
)
=
1
;
}
}
}
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment