From 65b3544126231e3177a0b3b9896b525f539747e9 Mon Sep 17 00:00:00 2001 From: Dimitri Papadopoulos <3234522+DimitriPapadopoulos@users.noreply.github.com> Date: Sun, 20 Nov 2022 21:24:26 +0100 Subject: [PATCH] DOC: fix typos found by codespell --- doc/source/devel/data_pkg_discuss.rst | 8 ++++---- doc/source/devel/spm_use.rst | 2 +- doc/source/dicom/dcm2nii_algorithms.rst | 2 +- doc/source/dicom/spm_dicom.rst | 4 ++-- doc/source/installation.rst | 2 +- doc/source/old/examples.txt | 2 +- nibabel/data.py | 2 +- nibabel/pkg_info.py | 2 +- nibabel/tests/test_analyze.py | 2 +- nibabel/tests/test_api_validators.py | 2 +- nibabel/tests/test_fileslice.py | 2 +- nibabel/tests/test_processing.py | 2 +- nibabel/tests/test_wrapstruct.py | 2 +- 13 files changed, 17 insertions(+), 17 deletions(-) diff --git a/doc/source/devel/data_pkg_discuss.rst b/doc/source/devel/data_pkg_discuss.rst index dbd8cca88a..f983351925 100644 --- a/doc/source/devel/data_pkg_discuss.rst +++ b/doc/source/devel/data_pkg_discuss.rst @@ -367,14 +367,14 @@ Discovery .. [#tag-sources] - Revsion ids could for example be hashes of the package instantiation + Revision ids could for example be hashes of the package instantiation (package contents), so they could be globally unique to the contents, wherever the contents was when the identifier was made. However, *tags* - are just names that someone has attached to a particular revsion id. If + are just names that someone has attached to a particular revision id. If there is more than one person providing versions of a particular package, - there may not be agreement on the revsion that a particular tag is attached + there may not be agreement on the revision that a particular tag is attached to. For example, I might think that ``release-0.3`` of ``some-package`` - refers to package state identified by revsion id ``af5bd6``, but you might + refers to package state identified by revision id ``af5bd6``, but you might think that ``release-0.3`` of ``some-package`` refers to some other package state. In this case you and are are both a *tag sources* for the package. The state that particular tag refers to can depend then on the source from diff --git a/doc/source/devel/spm_use.rst b/doc/source/devel/spm_use.rst index a4e6d8dbfd..56c7051696 100644 --- a/doc/source/devel/spm_use.rst +++ b/doc/source/devel/spm_use.rst @@ -291,7 +291,7 @@ from volumes, as long as the transform is an affine. Miscellaneous functions operating on vol structs: -* ``spm_conv_vol`` - convolves volume with seperable functions in x, y, z +* ``spm_conv_vol`` - convolves volume with separable functions in x, y, z * ``spm_render_vol`` - does a projection of a volume onto a surface * ``spm_vol_check`` - takes array of vol structs and checks for sameness of image dimensions and ``mat`` (affines) across the list. diff --git a/doc/source/dicom/dcm2nii_algorithms.rst b/doc/source/dicom/dcm2nii_algorithms.rst index ac4ab3e4da..809ac51c51 100644 --- a/doc/source/dicom/dcm2nii_algorithms.rst +++ b/doc/source/dicom/dcm2nii_algorithms.rst @@ -18,7 +18,7 @@ Compiling dcm2nii ================= Follow the download / install instructions at the -http://www.lazarus.freepascal.org/ site. I was on a Mac, and folowed the +http://www.lazarus.freepascal.org/ site. I was on a Mac, and followed the instructions here: http://wiki.lazarus.freepascal.org/Installing_Lazarus_on_MacOS_X . Default build with version 0.9.28.2 gave an error linking against Carbon, so I needed to diff --git a/doc/source/dicom/spm_dicom.rst b/doc/source/dicom/spm_dicom.rst index 8c89e0ecda..67b6bcf0ca 100644 --- a/doc/source/dicom/spm_dicom.rst +++ b/doc/source/dicom/spm_dicom.rst @@ -80,8 +80,8 @@ There's a check for not-even tag length. If not even: #. 13 appears to mean 10 and is reset to be 10 #. Any other odd number is not valid and gives a tag length of 0 -``SQ`` VR type (Sequnce of items type) --------------------------------------- +``SQ`` VR type (Sequence of items type) +--------------------------------------- tag length of 13 set to tag length 10. diff --git a/doc/source/installation.rst b/doc/source/installation.rst index ffc5f7f47c..5e6009f7ae 100644 --- a/doc/source/installation.rst +++ b/doc/source/installation.rst @@ -43,7 +43,7 @@ Windows), and type:: This will download and install NiBabel. -If you really like doing stuff manually, you can install NiBabel by downoading +If you really like doing stuff manually, you can install NiBabel by downloading the source from `NiBabel pypi`_ . Go to the pypi page and select the source distribution you want. Download the distribution, unpack it, and then, from the unpacked directory, run:: diff --git a/doc/source/old/examples.txt b/doc/source/old/examples.txt index 19a44d9cb0..dfbc2b4d9e 100644 --- a/doc/source/old/examples.txt +++ b/doc/source/old/examples.txt @@ -80,7 +80,7 @@ the desired values: >>> print nim.header['dim'] [ 4 32 32 16 100 1 1 1] -First value shows the number of dimensions in the datset: 4 (good, that's what +First value shows the number of dimensions in the dataset: 4 (good, that's what we wanted). The following numbers are dataset size on the x, y, z, t, u, v, w axis (NIfTI files can handle up to 7 dimensions). diff --git a/nibabel/data.py b/nibabel/data.py index 438cd2aa58..52be86fd43 100644 --- a/nibabel/data.py +++ b/nibabel/data.py @@ -76,7 +76,7 @@ def list_files(self, relative=True): Parameters ---------- relative: bool, optional - If True, path returned are relative to the base paht of + If True, path returned are relative to the base path of the data source. Returns diff --git a/nibabel/pkg_info.py b/nibabel/pkg_info.py index 43b39f4e89..e28cc6e28d 100644 --- a/nibabel/pkg_info.py +++ b/nibabel/pkg_info.py @@ -32,7 +32,7 @@ def cmp_pkg_version(version_str, pkg_version_str=__version__): version_str : str Version string to compare to current package version pkg_version_str : str, optional - Version of our package. Optional, set fom ``__version__`` by default. + Version of our package. Optional, set from ``__version__`` by default. Returns ------- diff --git a/nibabel/tests/test_analyze.py b/nibabel/tests/test_analyze.py index bbcdfbeefc..28aebd35a1 100644 --- a/nibabel/tests/test_analyze.py +++ b/nibabel/tests/test_analyze.py @@ -656,7 +656,7 @@ def as_analyze_map(self): exp_hdr['cal_min'] = -100 exp_hdr['cal_max'] = 100 assert klass.from_header(H5()) == exp_hdr - # set_* methods override fields fron header + # set_* methods override fields from header class H6(H5): diff --git a/nibabel/tests/test_api_validators.py b/nibabel/tests/test_api_validators.py index 76043348c9..782a7915fc 100644 --- a/nibabel/tests/test_api_validators.py +++ b/nibabel/tests/test_api_validators.py @@ -34,7 +34,7 @@ class ValidateAPI(metaclass=validator2test): Your job is twofold: - * define an ``obj_params`` iteratable, where the iterator returns (``obj``, + * define an ``obj_params`` iterable, where the iterator returns (``obj``, ``params``) pairs. ``obj`` is something that you want to validate against an API. ``params`` is a mapping giving parameters for this object to test against. diff --git a/nibabel/tests/test_fileslice.py b/nibabel/tests/test_fileslice.py index e33c1f6814..35c61e149b 100644 --- a/nibabel/tests/test_fileslice.py +++ b/nibabel/tests/test_fileslice.py @@ -298,7 +298,7 @@ def test_optimize_slicer(): # be 'full' assert optimize_slicer(slice(9), 10, False, False, 4, _always) == (slice(0, 9, 1), slice(None)) assert optimize_slicer(slice(9), 10, True, False, 4, _always) == (slice(None), slice(0, 9, 1)) - # Unless this is the slowest dimenion, and all_true is True, in which case + # Unless this is the slowest dimension, and all_true is True, in which case # we don't update to full assert optimize_slicer(slice(9), 10, True, True, 4, _always) == (slice(0, 9, 1), slice(None)) # Nor if the heuristic won't update diff --git a/nibabel/tests/test_processing.py b/nibabel/tests/test_processing.py index 401966faa9..3c2a70a8c4 100644 --- a/nibabel/tests/test_processing.py +++ b/nibabel/tests/test_processing.py @@ -83,7 +83,7 @@ def test_adapt_affine(): [ 3, 4, 12], [ 6, 7, 13], [ 0, 0, 1]]) - # For 4x4 affine, 1D image, 2 dropped columnn + # For 4x4 affine, 1D image, 2 dropped columns assert_array_equal(adapt_affine(aff_3d, 1), [[ 0, 11], [ 3, 12], diff --git a/nibabel/tests/test_wrapstruct.py b/nibabel/tests/test_wrapstruct.py index 011e16d47d..a360804f5a 100644 --- a/nibabel/tests/test_wrapstruct.py +++ b/nibabel/tests/test_wrapstruct.py @@ -213,7 +213,7 @@ def test_endian_guess(self): assert eh_swapped.endianness == swapped_code def test_binblock_is_file(self): - # Checks that the binary string respresentation is the whole of the + # Checks that the binary string representation is the whole of the # header file. This is true for Analyze types, but not true Nifti # single file headers, for example, because they will have extension # strings following. More generally, there may be other perhaps