Skip to content

Commit ea30b03

Browse files
committed
Merge pull request #3 from bcipolli/satra/enh/cifti2
Base CiftiImage on the xml.expat framework
2 parents 5f2afe2 + 8b5ac2e commit ea30b03

File tree

157 files changed

+3963
-3879
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

157 files changed

+3963
-3879
lines changed

.mailmap

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,5 @@ Basile Pinsard <[email protected]> bpinsard <[email protected]>
2929
3030
Ben Cipollini <[email protected]> Ben Cipollini <[email protected]>
3131
Chris Markiewicz <[email protected]> Christopher J. Markiewicz <[email protected]>
32+
Chris Markiewicz <[email protected]> Christopher J. Markiewicz <[email protected]>
33+
Chris Markiewicz <[email protected]> Chris Johnson <[email protected]>

.travis.yml

Lines changed: 30 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ env:
2424
- INSTALL_TYPE="setup"
2525
python:
2626
- 2.6
27-
- 3.2
2827
- 3.3
2928
- 3.4
3029
- 3.5
@@ -58,13 +57,19 @@ matrix:
5857
- python: 2.7
5958
env:
6059
- INSTALL_TYPE=requirements
60+
- python: 2.7
61+
env:
62+
- STYLE=1
63+
- python: 3.5
64+
env:
65+
- STYLE=1
6166
before_install:
6267
- source tools/travis_tools.sh
6368
- virtualenv --python=python venv
6469
- source venv/bin/activate
6570
- python --version # just to check
66-
- pip install -U pip # upgrade to latest pip to find 3.5 wheels
67-
- retry pip install nose # always
71+
- pip install -U pip wheel # upgrade to latest pip find 3.5 wheels; wheel to avoid errors
72+
- retry pip install nose flake8 # always
6873
- wheelhouse_pip_install $DEPENDS
6974
# pydicom <= 0.9.8 doesn't install on python 3
7075
- if [ "${TRAVIS_PYTHON_VERSION:0:1}" == "2" ]; then
@@ -99,20 +104,29 @@ install:
99104
- export NIBABEL_DATA_DIR="$PWD/nibabel-data"
100105
# command to run tests, e.g. python setup.py test
101106
script:
102-
# Change into an innocuous directory and find tests from installation
103-
- mkdir for_testing
104-
- cd for_testing
105-
- if [ "${COVERAGE}" == "1" ]; then
106-
cp ../.coveragerc .;
107-
COVER_ARGS="--with-coverage --cover-package nibabel";
108-
fi
109-
- if [ "$DOC_DOC_TEST" == "1" ]; then
110-
pip install sphinx;
111-
cd ../doc;
112-
make html;
113-
make doctest;
107+
- |
108+
if [ "${STYLE}" == "1" ]; then
109+
# Run styles only on core nibabel code.
110+
flake8 nibabel
114111
else
115-
nosetests --with-doctest $COVER_ARGS nibabel;
112+
# Change into an innocuous directory and find tests from installation
113+
mkdir for_testing
114+
cd for_testing
115+
if [ "${COVERAGE}" == "1" ]; then
116+
cp ../.coveragerc .;
117+
COVER_ARGS="--with-coverage --cover-package nibabel";
118+
fi
119+
if [ "$DOC_DOC_TEST" == "1" ]; then
120+
pip install sphinx numpydoc texext;
121+
cd ../doc;
122+
make html;
123+
make doctest;
124+
else
125+
nosetests --with-doctest $COVER_ARGS nibabel;
126+
fi
116127
fi
117128
after_success:
118129
- if [ "${COVERAGE}" == "1" ]; then coveralls; fi
130+
131+
notifications:
132+
webhooks: http://nipy.bic.berkeley.edu:54856/travis

Changelog

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,19 @@ References like "pr/298" refer to github pull request numbers.
3434
are raising a DataError if the track is truncated when ``strict=True``
3535
(the default), rather than a TypeError when trying to create the points
3636
array.
37+
38+
* 2.0.2 (Monday 23 November 2015)
39+
40+
* Fix for integer overflow on large images (pr/325) (MB);
41+
* Fix for Freesurfer nifti files with unusual dimensions (pr/332) (Chris
42+
Markiewicz);
43+
* Fix typos on benchmarks and tests (pr/336, pr/340, pr/347) (Chris
44+
Markiewicz);
45+
* Fix Windows install script (pr/339) (MB);
46+
* Support for Python 3.5 (pr/363) (MB) and numpy 1.10 (pr/358) (Chris
47+
Markiewicz);
48+
* Update pydicom imports to permit version 1.0 (pr/379) (Chris Markiewicz);
49+
* Workaround for Python 3.5.0 gzip regression (pr/383) (Ben Cipollini).
3750
* tripwire.TripWire object now raises subclass of AttributeError when trying
3851
to get an attribute, rather than a direct subclass of Exception. This
3952
prevents Python 3.5 triggering the tripwire when doing inspection prior to

doc/source/conf.py

Lines changed: 27 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -11,45 +11,55 @@
1111
# nipype documentation build configuration file, created by
1212
# sphinx-quickstart on Mon Jul 20 12:30:18 2009.
1313
#
14-
# This file is execfile()d with the current directory set to its containing dir.
14+
# This file is exec()d with the current directory set to its containing dir.
1515
#
1616
# Note that not all possible configuration values are present in this
1717
# autogenerated file.
1818
#
1919
# All configuration values have a default; values that are commented out
2020
# serve to show the default.
2121

22-
import sys, os
22+
import sys
23+
import os
2324

2425
import nibabel
2526

27+
# Check for external Sphinx extensions we depend on
28+
try:
29+
import numpydoc
30+
except ImportError:
31+
raise RuntimeError('Need to install "numpydoc" package for doc build')
32+
try:
33+
import texext
34+
except ImportError:
35+
raise RuntimeError('Need to install "texext" package for doc build')
36+
2637
# If extensions (or modules to document with autodoc) are in another directory,
2738
# add these directories to sys.path here. If the directory is relative to the
2839
# documentation root, use os.path.abspath to make it absolute, like shown here.
2940
sys.path.append(os.path.abspath('../sphinxext'))
3041

31-
# -- General configuration -----------------------------------------------------
42+
# -- General configuration ----------------------------------------------------
3243

3344
# We load the nibabel release info into a dict by explicit execution
3445
rel = {}
35-
execfile('../../nibabel/info.py', rel)
46+
with open(os.path.join('..', '..', 'nibabel', 'info.py'), 'r') as fobj:
47+
exec(fobj.read(), rel)
3648

3749
# Write long description from info
3850
with open('_long_description.inc', 'wt') as fobj:
3951
fobj.write(rel['LONG_DESCRIPTION'])
4052

41-
# Add any Sphinx extension module names here, as strings. They can be extensions
42-
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
53+
# Add any Sphinx extension module names here, as strings. They can be
54+
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
4355
extensions = ['sphinx.ext.autodoc',
4456
'sphinx.ext.doctest',
4557
#'sphinx.ext.intersphinx',
4658
'sphinx.ext.todo',
4759
'sphinx.ext.mathjax',
4860
'sphinx.ext.inheritance_diagram',
4961
'sphinx.ext.autosummary',
50-
'math_dollar', # has to go before numpydoc
51-
# we have a local copy of the extension, imported from NumPy 1.3
52-
# this also includes the docscrape* extensions
62+
'texext.math_dollar', # has to go before numpydoc
5363
'numpydoc',
5464
'only_directives',
5565
'plot_directive',
@@ -104,7 +114,7 @@
104114
# for source files.
105115
exclude_trees = ['_build']
106116

107-
# The reST default role (used for this markup: `text`) to use for all documents.
117+
# The reST default role (used for this markup: `text`) to use for all documents
108118
#default_role = None
109119

110120
# If true, '()' will be appended to :func: etc. cross-reference text.
@@ -124,7 +134,7 @@
124134
# A list of ignored prefixes for module index sorting.
125135
#modindex_common_prefix = []
126136

127-
# -- Sphinxext configuration ---------------------------------------------------
137+
# -- Sphinxext configuration --------------------------------------------------
128138

129139
# Set attributes for layout of inheritance diagrams
130140
inheritance_graph_attrs = dict(rankdir="LR", size='"6.0, 8.0"', fontsize=14,
@@ -135,7 +145,7 @@
135145
# Flag to show todo items in rendered output
136146
todo_include_todos = True
137147

138-
# -- Options for HTML output ---------------------------------------------------
148+
# -- Options for HTML output --------------------------------------------------
139149

140150
# The theme to use for HTML and HTML Help pages. Major themes that come with
141151
# Sphinx are currently 'default' and 'sphinxdoc'.
@@ -218,7 +228,7 @@
218228

219229
mathjax_path = 'https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML'
220230

221-
# -- Options for LaTeX output --------------------------------------------------
231+
# -- Options for LaTeX output -------------------------------------------------
222232

223233
# The paper size ('letter' or 'a4').
224234
#latex_paper_size = 'letter'
@@ -227,11 +237,11 @@
227237
#latex_font_size = '10pt'
228238

229239
# Grouping the document tree into LaTeX files. List of tuples
230-
# (source start file, target name, title, author, documentclass [howto/manual]).
240+
# (source start file, target name, title, author,
241+
# documentclass [howto/manual]).
231242
latex_documents = [
232-
('index', 'nibabel.tex', u'NiBabel Documentation',
233-
u'NiBabel Authors', 'manual'),
234-
]
243+
('index', 'nibabel.tex', u'NiBabel Documentation', u'NiBabel Authors',
244+
'manual')]
235245

236246
# The name of an image file (relative to this directory) to place at the top of
237247
# the title page.

doc/source/devel/advanced_testing.rst

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
.. -*- mode: rst -*-
2+
.. ex: set sts=4 ts=4 sw=4 et tw=79:
3+
### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ###
4+
#
5+
# See COPYING file distributed along with the NiBabel package for the
6+
# copyright and license terms.
7+
#
8+
### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ###
9+
10+
.. _advanced_testing:
11+
12+
************
13+
Advanced Testing
14+
************
15+
16+
Setup
17+
-----
18+
19+
Before running advanced tests, please update all submodules of nibabel, by running ``git submodule update --init``
20+
21+
22+
Long-running tests
23+
------------------
24+
25+
Long-running tests are not enabled by default, and can be resource-intensive. To run these tests:
26+
27+
* Set environment variable ``NIPY_EXTRA_TESTS=slow``
28+
* Run ``nosetests``.
29+
30+
Note that some tests may require a machine with >4GB of RAM.
31+
32+
.. include:: ../links_names.txt

doc/source/devel/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,4 @@ Developer documentation page
1414
add_image_format
1515
devdiscuss
1616
make_release
17+
advanced_testing

0 commit comments

Comments
 (0)