Skip to content

ENH: Support TCK streamlines file format #486

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 32 commits into from
Apr 18, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
46b1de9
Initial support for TCK
MarcCote Feb 25, 2016
7648d3c
FIX: check for eof
MarcCote Feb 25, 2016
306dc6e
Support Python 3
MarcCote Feb 25, 2016
9c9cb5d
More Python3 supports
MarcCote Mar 31, 2016
86dc54c
Send streamlines to world space before saving in a TCK file
MarcCote Apr 1, 2016
2b87c36
Added unit test that make sure we handle affine_to_rasmm correctly in…
MarcCote Apr 1, 2016
317b1cc
RF+DOC+TEST: tck format.
MarcCote Sep 13, 2016
7a5532f
BF: Supports Python 3
MarcCote Sep 13, 2016
1df9501
PEP8
MarcCote Sep 13, 2016
893fa44
TST: added unit test for TCK files written in big-endian
MarcCote Sep 13, 2016
96d555b
BF: Python 3
MarcCote Sep 14, 2016
e9ab875
BF: fixed TCK buferring and added a unit test
MarcCote Sep 21, 2016
b4cbbcc
BF: Was saving unwanted information in a TCK's header.
MarcCote Oct 4, 2016
21158e1
Added TCK version of the standard test.
MarcCote Nov 4, 2016
de8ee31
Typos
MarcCote Nov 4, 2016
570b37d
BF: Assume identity affine when loading TCK files.
MarcCote Dec 22, 2016
0f63e7c
PEP8
MarcCote Feb 13, 2017
72d146a
DOC+PEP8: Finish addressing @matthew-brett's comments.
MarcCote Feb 28, 2017
ea84c9d
RF: refactor tck read for speed
matthew-brett Mar 27, 2017
a4bda85
MAINT: update numpy dependency to 1.7
matthew-brett Mar 27, 2017
2df7518
Merge pull request #12 from matthew-brett/refactor-tck-read
MarcCote Mar 29, 2017
029f853
PEP8 + addressed's @matthew-brett's comments
MarcCote Mar 29, 2017
9228075
Convert MagicNumber to bytes
MarcCote Mar 30, 2017
4d93676
Addressed's @jchoude's comments
MarcCote Mar 31, 2017
aacf014
Increase test coverage
MarcCote Mar 31, 2017
c6117fe
PEP8
MarcCote Mar 31, 2017
bac044b
Update docstring and addressed @Matthew-brett's last comments
MarcCote Apr 7, 2017
3dc3d71
RF: move create_empty_header logic to top level
matthew-brett Apr 13, 2017
9511327
RF: make default trk structured array a scalar
matthew-brett Apr 13, 2017
0bacbf5
BF: adapt tests to new TractogramFile interface
matthew-brett Apr 13, 2017
0d0ece1
[DOC] mentioned that the file needs to be opened in binary mode if pr…
MarcCote Apr 18, 2017
d2e08da
Merge pull request #13 from matthew-brett/refactor-create-empty-header
MarcCote Apr 18, 2017
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,19 +33,19 @@ matrix:
# Absolute minimum dependencies
- python: 2.7
env:
- DEPENDS="numpy==1.6.0" PYDICOM=0
- DEPENDS="numpy==1.7.1" PYDICOM=0
# Absolute minimum dependencies plus oldest MPL
# Check these against:
# nibabel/info.py
# doc/source/installation.rst
# requirements.txt
- python: 2.7
env:
- DEPENDS="numpy==1.6.0 matplotlib==1.3.1" PYDICOM=0
- DEPENDS="numpy==1.7.1 matplotlib==1.3.1" PYDICOM=0
# Minimum pydicom dependency
- python: 2.7
env:
- DEPENDS="numpy==1.6.0 pydicom==0.9.7 pillow==2.6"
- DEPENDS="numpy==1.7.1 pydicom==0.9.7 pillow==2.6"
# test against numpy 1.7
- python: 2.7
env:
Expand Down
2 changes: 1 addition & 1 deletion doc/source/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ Requirements
.travis.yml

* Python_ 2.7, or >= 3.4
* NumPy_ 1.6 or greater
* NumPy_ 1.7 or greater
* Six_ 1.3 or greater
* SciPy_ (optional, for full SPM-ANALYZE support)
* PyDICOM_ 0.9.7 or greater (optional, for DICOM support)
Expand Down
2 changes: 1 addition & 1 deletion nibabel/info.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ def cmp_pkg_version(version_str, pkg_version_str=__version__):
# doc/source/installation.rst
# requirements.txt
# .travis.yml
NUMPY_MIN_VERSION = '1.6.0'
NUMPY_MIN_VERSION = '1.7.1'
PYDICOM_MIN_VERSION = '0.9.7'
SIX_MIN_VERSION = '1.3'

Expand Down
5 changes: 4 additions & 1 deletion nibabel/streamlines/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,12 @@
from .tractogram_file import ExtensionWarning

from .trk import TrkFile
from .tck import TckFile

# List of all supported formats
FORMATS = {".trk": TrkFile}
FORMATS = {".trk": TrkFile,
".tck": TckFile
}


def is_supported(fileobj):
Expand Down
Loading