Reconstruction of the diffusion signal with the kurtosis tensor model

The diffusion kurtosis model is an expansion of the diffusion tensor model (see example_reconst_dti). In addition to the diffusion tensor (DT), the diffusion kurtosis model quantifies the degree to which water diffusion in biological tissues is non-Gaussian using the kurtosis tensor (KT) [Jensen2005].

Measurements of non-Gaussian diffusion from the diffusion kurtosis model are of interest because they can be used to characterize tissue microstructural heterogeneity [Jensen2010]. Moreover, DKI can be used to: 1) derive concrete biophysical parameters, such as the density of axonal fibers and diffusion tortuosity [Fierem2011] (see example_reconst_dki_micro); and 2) resolve crossing fibers in tractography and to obtain invariant rotational measures not limited to well-aligned fiber populations [NetoHe2015].

The diffusion kurtosis model expresses the diffusion-weighted signal as:

\[S(n,b)=S_{0}e^{-bD(n)+\]

rac{1}{6}b^{2}D(n)^{2}K(n)}

where \(\mathbf{b}\) is the applied diffusion weighting (which is dependent on the measurement parameters), \(S_0\) is the signal in the absence of diffusion gradient sensitization, \(\mathbf{D(n)}\) is the value of diffusion along direction \(\mathbf{n}\), and \(\mathbf{K(n)}\) is the value of kurtosis along direction \(\mathbf{n}\). The directional diffusion \(\mathbf{D(n)}\) and kurtosis \(\mathbf{K(n)}\) can be related to the diffusion tensor (DT) and kurtosis tensor (KT) using the following equations:

\[D(n)=\sum_{i=1}^{3}\sum_{j=1}^{3}n_{i}n_{j}D_{ij}\]

and

\[K(n)=\]
rac{MD^{2}}{D(n)^{2}}sum_{i=1}^{3}sum_{j=1}^{3}sum_{k=1}^{3}

sum_{l=1}^{3}n_{i}n_{j}n_{k}n_{l}W_{ijkl}

where \(D_{ij}\) are the elements of the second-order DT, and \(W_{ijkl}\) the elements of the fourth-order KT and \(MD\) is the mean diffusivity. As the DT, KT has antipodal symmetry and thus only 15 Wijkl elements are needed to fully characterize the KT:

\[egin{matrix} ( & W_{xxxx} & W_{yyyy} & W_{zzzz} & W_{xxxy} & W_{xxxz} & ... \ & W_{xyyy} & W_{yyyz} & W_{xzzz} & W_{yzzz} & W_{xxyy} & ... \ & W_{xxzz} & W_{yyzz} & W_{xxyz} & W_{xyyz} & W_{xyzz} & & )\end{matrix}\]

In the following example we show how to fit the diffusion kurtosis model on diffusion-weighted multi-shell datasets and how to estimate diffusion kurtosis based statistics.

First, we import all relevant modules:

import numpy as np
import dipy.reconst.dki as dki
import dipy.reconst.dti as dti
from dipy.core.gradients import gradient_table
from dipy.data import get_fnames
from dipy.io.gradients import read_bvals_bvecs
from dipy.io.image import load_nifti
from dipy.segment.mask import median_otsu
from dipy.viz.plotting import compare_maps
from scipy.ndimage import gaussian_filter

DKI requires multi-shell data, i.e. data acquired from more than one non-zero b-value. Here, we use fetch to download a multi-shell dataset which was kindly provided by Hansen and Jespersen (more details about the data are provided in their paper [Hansen2016]). The total size of the downloaded data is 192 MBytes, however you only need to fetch it once.

fraw, fbval, fbvec, t1_fname = get_fnames('cfin_multib')

data, affine = load_nifti(fraw)
bvals, bvecs = read_bvals_bvecs(fbval, fbvec)
gtab = gradient_table(bvals, bvecs)

Function get_fnames downloads and outputs the paths of the data, load_nifti returns the data as a nibabel Nifti1Image object, and read_bvals_bvecs loads the arrays containing the information about the b-values and b-vectors. These later arrays are converted to the GradientTable object required for Dipy_’s data reconstruction.

Before fitting the data, we perform some data pre-processing. We first compute a brain mask to avoid unnecessary calculations on the background of the image.

maskdata, mask = median_otsu(data, vol_idx=[0, 1], median_radius=4, numpass=2,
                             autocrop=False, dilate=1)

Since the diffusion kurtosis models involves the estimation of a large number of parameters [TaxCMW2015] and since the non-Gaussian components of the diffusion signal are more sensitive to artefacts [NetoHe2012], it might be favorable to suppress the effects of noise and artefacts before diffusion kurtosis fitting. In this example the effects of noise and artefacts are suppress by using 3D Gaussian smoothing (with a Gaussian kernel with fwhm=1.25) as suggested by pioneer DKI studies (e.g. [Jensen2005], [NetoHe2012]). Although here the Gaussian smoothing is used so that results are comparable to these studies, it is important to note that more advanced noise and artifact suppression algorithms are available in DIPY_, e.g. the Marcenko-Pastur PCA denoising algorithm (example-denoise-mppca) and the Gibbs artefact suppression algorithm (example-denoise-gibbs).

fwhm = 1.25
gauss_std = fwhm / np.sqrt(8 * np.log(2))  # converting fwhm to Gaussian std
data_smooth = np.zeros(data.shape)
for v in range(data.shape[-1]):
    data_smooth[..., v] = gaussian_filter(data[..., v], sigma=gauss_std)

Now that we have loaded and pre-processed the data we can go forward with DKI fitting. For this, the DKI model is first defined for the data’s GradientTable object by instantiating the DiffusionKurtosisModel object in the following way:

dkimodel = dki.DiffusionKurtosisModel(gtab)

To fit the data using the defined model object, we call the fit function of this object. For the purpose of this example, we will only fit a single slice of the data:

data_smooth = data_smooth[:, :, 9:10]
mask = mask[:, :, 9:10]
dkifit = dkimodel.fit(data_smooth, mask=mask)
  0%|          | 0/3121 [00:00<?, ?it/s]
  1%|1         | 35/3121 [00:00<00:09, 338.80it/s]
  2%|2         | 69/3121 [00:00<00:09, 337.16it/s]
  3%|3         | 109/3121 [00:00<00:08, 365.11it/s]
  5%|4         | 151/3121 [00:00<00:07, 386.19it/s]
  6%|6         | 190/3121 [00:00<00:07, 379.52it/s]
  7%|7         | 228/3121 [00:00<00:07, 368.94it/s]
  8%|8         | 265/3121 [00:00<00:07, 363.36it/s]
 10%|9         | 302/3121 [00:00<00:07, 358.74it/s]
 11%|#         | 340/3121 [00:00<00:07, 364.56it/s]
 12%|#2        | 377/3121 [00:01<00:07, 350.38it/s]
 13%|#3        | 415/3121 [00:01<00:07, 358.87it/s]
 14%|#4        | 452/3121 [00:01<00:07, 361.69it/s]
 16%|#5        | 489/3121 [00:01<00:07, 362.89it/s]
 17%|#6        | 526/3121 [00:01<00:07, 330.84it/s]
 18%|#7        | 560/3121 [00:01<00:09, 267.31it/s]
 19%|#9        | 601/3121 [00:01<00:08, 300.29it/s]
 20%|##        | 636/3121 [00:01<00:08, 309.60it/s]
 22%|##1       | 676/3121 [00:01<00:07, 332.99it/s]
 23%|##2       | 713/3121 [00:02<00:07, 341.84it/s]
 24%|##3       | 749/3121 [00:02<00:06, 343.40it/s]
 25%|##5       | 785/3121 [00:02<00:06, 336.37it/s]
 26%|##6       | 823/3121 [00:02<00:06, 348.14it/s]
 28%|##7       | 859/3121 [00:02<00:06, 336.10it/s]
 29%|##8       | 894/3121 [00:02<00:06, 338.18it/s]
 30%|##9       | 935/3121 [00:02<00:06, 357.54it/s]
 31%|###1      | 972/3121 [00:02<00:06, 355.00it/s]
 32%|###2      | 1008/3121 [00:02<00:06, 334.73it/s]
 33%|###3      | 1042/3121 [00:03<00:06, 325.84it/s]
 35%|###4      | 1079/3121 [00:03<00:06, 337.09it/s]
 36%|###5      | 1120/3121 [00:03<00:05, 353.87it/s]
 37%|###7      | 1158/3121 [00:03<00:05, 360.81it/s]
 38%|###8      | 1195/3121 [00:03<00:05, 344.88it/s]
 39%|###9      | 1231/3121 [00:03<00:05, 348.21it/s]
 41%|####      | 1267/3121 [00:03<00:05, 349.29it/s]
 42%|####1     | 1303/3121 [00:03<00:05, 352.31it/s]
 43%|####2     | 1340/3121 [00:03<00:04, 357.18it/s]
 44%|####4     | 1376/3121 [00:03<00:05, 343.80it/s]
 45%|####5     | 1420/3121 [00:04<00:04, 370.73it/s]
 47%|####6     | 1458/3121 [00:04<00:04, 368.19it/s]
 48%|####7     | 1495/3121 [00:04<00:04, 361.86it/s]
 49%|####9     | 1533/3121 [00:04<00:04, 363.12it/s]
 50%|#####     | 1572/3121 [00:04<00:04, 370.76it/s]
 52%|#####1    | 1610/3121 [00:04<00:04, 357.42it/s]
 53%|#####2    | 1646/3121 [00:04<00:04, 358.14it/s]
 54%|#####3    | 1682/3121 [00:04<00:04, 354.82it/s]
 55%|#####5    | 1718/3121 [00:04<00:03, 352.59it/s]
 56%|#####6    | 1754/3121 [00:05<00:03, 352.71it/s]
 57%|#####7    | 1792/3121 [00:05<00:03, 358.87it/s]
 59%|#####8    | 1835/3121 [00:05<00:03, 375.04it/s]
 60%|######    | 1877/3121 [00:05<00:03, 387.78it/s]
 62%|######1   | 1929/3121 [00:05<00:02, 426.42it/s]
 63%|######3   | 1977/3121 [00:05<00:02, 441.15it/s]
 65%|######4   | 2022/3121 [00:05<00:02, 412.38it/s]
 66%|######6   | 2064/3121 [00:05<00:02, 402.07it/s]
 67%|######7   | 2105/3121 [00:05<00:02, 400.89it/s]
 69%|######8   | 2146/3121 [00:05<00:02, 397.00it/s]
 70%|#######   | 2186/3121 [00:06<00:02, 391.12it/s]
 71%|#######1  | 2226/3121 [00:06<00:02, 384.75it/s]
 73%|#######2  | 2266/3121 [00:06<00:02, 387.98it/s]
 74%|#######3  | 2305/3121 [00:06<00:02, 363.14it/s]
 75%|#######5  | 2349/3121 [00:06<00:02, 384.32it/s]
 77%|#######6  | 2388/3121 [00:06<00:01, 380.29it/s]
 78%|#######7  | 2427/3121 [00:06<00:01, 363.19it/s]
 79%|#######8  | 2464/3121 [00:06<00:01, 364.09it/s]
 80%|########  | 2501/3121 [00:06<00:01, 340.54it/s]
 81%|########1 | 2536/3121 [00:07<00:01, 302.84it/s]
 83%|########2 | 2579/3121 [00:07<00:01, 335.19it/s]
 84%|########4 | 2622/3121 [00:07<00:01, 360.61it/s]
 85%|########5 | 2660/3121 [00:07<00:01, 357.81it/s]
 87%|########6 | 2700/3121 [00:07<00:01, 368.44it/s]
 88%|########7 | 2738/3121 [00:07<00:01, 355.93it/s]
 89%|########8 | 2776/3121 [00:07<00:00, 360.93it/s]
 90%|######### | 2813/3121 [00:07<00:00, 357.49it/s]
 91%|#########1| 2851/3121 [00:07<00:00, 363.49it/s]
 93%|#########2| 2888/3121 [00:08<00:00, 364.11it/s]
 94%|#########3| 2925/3121 [00:08<00:00, 360.26it/s]
 95%|#########4| 2962/3121 [00:08<00:00, 360.02it/s]
 96%|#########6| 3000/3121 [00:08<00:00, 364.95it/s]
 97%|#########7| 3038/3121 [00:08<00:00, 367.62it/s]
 99%|#########8| 3086/3121 [00:08<00:00, 396.72it/s]
100%|##########| 3121/3121 [00:08<00:00, 359.85it/s]

The fit method creates a DiffusionKurtosisFit object, which contains all the diffusion and kurtosis fitting parameters and other DKI attributes. For instance, since the diffusion kurtosis model estimates the diffusion tensor, all standard diffusion tensor statistics can be computed from the DiffusionKurtosisFit instance. For example, we can extract the fractional anisotropy (FA), the mean diffusivity (MD), the axial diffusivity (AD) and the radial diffusivity (RD) from the DiffusionKurtosisiFit instance. Of course, these measures can also be computed from DIPY’s TensorModel fit, and should be analogous; however, theoretically, the diffusion statistics from the kurtosis model are expected to have better accuracy, since DKI’s diffusion tensor are decoupled from higher order terms effects [Veraar2011], [NetoHe2012]. Below we compare the FA, MD, AD, and RD, computed from both DTI and DKI.

tenmodel = dti.TensorModel(gtab)
tenfit = tenmodel.fit(data_smooth, mask=mask)

fits = [tenfit, dkifit]
maps = ['fa', 'md', 'ad', 'rd']
fit_labels = ['DTI', 'DKI']
map_kwargs = [{'vmax': 0.7}, {'vmax': 2e-3}, {'vmax': 2e-3}, {'vmax': 2e-3}]
compare_maps(fits, maps, fit_labels=fit_labels, map_kwargs=map_kwargs,
             filename='Diffusion_tensor_measures_from_DTI_and_DKI.png')
reconst dki
examples_built/07_reconstruction/Diffusion_tensor_measures_from_DTI_and_DKI.png

Diffusion tensor measures obtained from the diffusion tensor estimated from DKI (upper panels) and DTI (lower panels).

DTI’s diffusion estimates present lower values than DKI’s estimates, showing that DTI’s diffusion measurements are underestimated by higher order effects.

In addition to the standard diffusion statistics, the DiffusionKurtosisFit instance can be used to estimate the non-Gaussian measures of mean kurtosis (MK), the axial kurtosis (AK) and the radial kurtosis (RK).

maps = ['mk', 'ak', 'rk']
compare_maps([dkifit], maps, fit_labels=['DKI'],
             map_kwargs={'vmin': 0, 'vmax': 1.5},
             filename='Kurtosis_tensor_standard_measures.png')
reconst dki
examples_built/07_reconstruction/Kurtosis_tensor_standard_measures.png

DKI standard kurtosis measures.

The non-Gaussian behaviour of the diffusion signal is expected to be higher when tissue water is confined by multiple compartments. MK is, therefore, higher in white matter since it is highly compartmentalized by myelin sheaths. These water diffusion compartmentalization is expected to be more pronounced perpendicularly to white matter fibers and thus the RK map presents higher amplitudes than the AK map.

It is important to note that kurtosis estimates might present negative estimates in deep white matter regions (e.g. the band of dark voxels in the RK map above). These negative kurtosis values are artefactual and might be induced by: 1) low radial diffusivities of aligned white matter - since it is very hard to capture non-Gaussian information in radial direction due to it’s low diffusion decays, radial kurtosis estimates (and consequently the mean kurtosis estimates) might have low robustness and tendency to exhibit negative values [NetoHe2012]; 2) Gibbs artefacts - MRI images might be corrupted by signal oscillation artefact between tissue’s edges if an inadequate number of high frequencies of the k-space is sampled. These oscillations might have different signs on images acquired with different diffusion-weighted and inducing negative biases in kurtosis parametric maps [Perron2015], [NetoHe2018].

One can try to suppress this issue by using the more advance noise and artefact suppression algorithms, e.g., as mentioned above, the MP-PCA denoising (example-denoise-mppca) and Gibbs Unringing (example-denoise-gibbs) algorithms. Alternatively, one can overcome this artefact by computing the kurtosis values from powder-averaged diffusion-weighted signals. The details on how to compute the kurtosis from powder-average signals in dipy are described in follow the tutorial (example-reconst-msdki). Finally, one can use constrained optimization to ensure that the fitted parameters are physically plausible [DelaHa2020], as we will illustrate in the next section. Ideally though, artefacts such as Gibbs ringing should be corrected for as well as possible before using constrained optimization.

Constrained optimization for DKI

When instantiating the DiffusionKurtosisModel, the model can be set up to use constraints with the option fit_method=’CLS’ (for ordinary least squares) or with fit_method=’CWLS’ (for weighted least squares). Constrained fitting takes more time than unconstrained fitting, but is generally recommended to prevent physically unplausible parameter estimates [DelaHa2020]. For performance purposes it is recommended to use the MOSEK solver (https://www.mosek.com/) by setting cvxpy_solver='MOSEK'. Different solvers can differ greatly in terms of runtime and solution accuracy, and in some cases solvers may show warnings about convergence or recommended option settings.

Note

In certain atypical scenarios, the DKI+ constraints could potentially be too restrictive. Always check the results of a constrained fit with their unconstrained counterpart to verify that there are no unexpected qualitative differences.

dkimodel_plus = dki.DiffusionKurtosisModel(gtab, fit_method='CLS')
dkifit_plus = dkimodel_plus.fit(data_smooth, mask=mask)
  0%|          | 0/3121 [00:00<?, ?it/s]
  0%|          | 4/3121 [00:00<01:23, 37.43it/s]
  0%|          | 10/3121 [00:00<01:02, 50.15it/s]
  1%|          | 17/3121 [00:00<00:55, 55.77it/s]
  1%|          | 24/3121 [00:00<00:53, 57.50it/s]
  1%|          | 31/3121 [00:00<00:52, 58.59it/s]
  1%|1         | 38/3121 [00:00<00:51, 59.46it/s]
  1%|1         | 44/3121 [00:00<00:52, 59.04it/s]
  2%|1         | 51/3121 [00:00<00:51, 60.15it/s]
  2%|1         | 58/3121 [00:01<00:51, 59.95it/s]
  2%|2         | 64/3121 [00:01<00:51, 59.09it/s]
  2%|2         | 71/3121 [00:01<00:50, 59.93it/s]
  2%|2         | 77/3121 [00:01<00:51, 59.38it/s]
  3%|2         | 83/3121 [00:01<00:51, 59.46it/s]
  3%|2         | 89/3121 [00:01<00:57, 52.82it/s]
  3%|3         | 95/3121 [00:01<00:58, 51.32it/s]
  3%|3         | 101/3121 [00:01<00:58, 51.97it/s]
  3%|3         | 108/3121 [00:01<00:54, 54.90it/s]
  4%|3         | 114/3121 [00:02<00:53, 56.24it/s]
  4%|3         | 120/3121 [00:02<00:52, 56.88it/s]
  4%|4         | 127/3121 [00:02<00:51, 57.97it/s]
  4%|4         | 134/3121 [00:02<00:50, 59.01it/s]
  4%|4         | 140/3121 [00:02<00:50, 59.16it/s]
  5%|4         | 147/3121 [00:02<00:49, 59.62it/s]
  5%|4         | 153/3121 [00:02<00:50, 59.16it/s]
  5%|5         | 160/3121 [00:02<00:49, 59.68it/s]
  5%|5         | 167/3121 [00:02<00:49, 59.68it/s]
  6%|5         | 173/3121 [00:03<00:49, 59.21it/s]
  6%|5         | 180/3121 [00:03<00:48, 60.36it/s]
  6%|5         | 187/3121 [00:03<00:49, 59.32it/s]
  6%|6         | 194/3121 [00:03<00:48, 60.29it/s]
  6%|6         | 201/3121 [00:03<00:48, 59.69it/s]
  7%|6         | 207/3121 [00:03<00:48, 59.67it/s]
  7%|6         | 213/3121 [00:03<00:48, 59.76it/s]
  7%|7         | 220/3121 [00:03<00:47, 61.27it/s]
  7%|7         | 227/3121 [00:03<00:48, 60.02it/s]
  7%|7         | 234/3121 [00:04<00:48, 59.88it/s]
  8%|7         | 241/3121 [00:04<00:48, 59.60it/s]
  8%|7         | 248/3121 [00:04<00:47, 60.22it/s]
  8%|8         | 255/3121 [00:04<00:47, 59.96it/s]
  8%|8         | 262/3121 [00:04<00:47, 59.83it/s]
  9%|8         | 268/3121 [00:04<00:47, 59.66it/s]
  9%|8         | 275/3121 [00:04<00:46, 60.70it/s]
  9%|9         | 282/3121 [00:04<00:47, 59.67it/s]
  9%|9         | 288/3121 [00:04<00:49, 57.47it/s]
  9%|9         | 294/3121 [00:05<00:48, 58.11it/s]
 10%|9         | 300/3121 [00:05<00:48, 58.51it/s]
 10%|9         | 306/3121 [00:05<00:50, 55.61it/s]
 10%|#         | 313/3121 [00:05<00:48, 58.43it/s]
 10%|#         | 319/3121 [00:05<00:47, 58.57it/s]
 10%|#         | 325/3121 [00:05<00:48, 58.14it/s]
 11%|#         | 331/3121 [00:05<00:47, 58.64it/s]
 11%|#         | 338/3121 [00:05<00:46, 60.08it/s]
 11%|#1        | 345/3121 [00:05<00:46, 59.60it/s]
 11%|#1        | 351/3121 [00:06<00:46, 59.29it/s]
 11%|#1        | 358/3121 [00:06<00:46, 59.45it/s]
 12%|#1        | 365/3121 [00:06<00:45, 60.56it/s]
 12%|#1        | 372/3121 [00:06<00:46, 59.69it/s]
 12%|#2        | 379/3121 [00:06<00:45, 59.79it/s]
 12%|#2        | 386/3121 [00:06<00:45, 60.17it/s]
 13%|#2        | 393/3121 [00:06<00:45, 60.28it/s]
 13%|#2        | 400/3121 [00:06<00:45, 60.13it/s]
 13%|#3        | 407/3121 [00:06<00:45, 60.06it/s]
 13%|#3        | 414/3121 [00:07<00:45, 59.72it/s]
 13%|#3        | 421/3121 [00:07<00:45, 59.50it/s]
 14%|#3        | 427/3121 [00:07<00:48, 56.06it/s]
 14%|#3        | 433/3121 [00:07<00:50, 53.72it/s]
 14%|#4        | 439/3121 [00:07<00:50, 52.87it/s]
 14%|#4        | 445/3121 [00:07<00:50, 52.80it/s]
 14%|#4        | 451/3121 [00:07<00:51, 52.31it/s]
 15%|#4        | 457/3121 [00:07<00:52, 50.99it/s]
 15%|#4        | 463/3121 [00:08<00:51, 51.26it/s]
 15%|#5        | 469/3121 [00:08<00:51, 51.59it/s]
 15%|#5        | 475/3121 [00:08<00:50, 52.25it/s]
 15%|#5        | 482/3121 [00:08<00:48, 54.81it/s]
 16%|#5        | 488/3121 [00:08<00:46, 56.10it/s]
 16%|#5        | 495/3121 [00:08<00:45, 57.20it/s]
 16%|#6        | 501/3121 [00:08<00:47, 55.68it/s]
 16%|#6        | 507/3121 [00:08<00:46, 56.56it/s]
 16%|#6        | 514/3121 [00:08<00:45, 57.77it/s]
 17%|#6        | 520/3121 [00:09<00:44, 58.30it/s]
 17%|#6        | 526/3121 [00:09<00:44, 58.66it/s]
 17%|#7        | 533/3121 [00:09<00:43, 59.29it/s]
 17%|#7        | 540/3121 [00:09<00:43, 59.62it/s]
 17%|#7        | 546/3121 [00:09<00:43, 59.52it/s]
 18%|#7        | 552/3121 [00:09<00:43, 59.32it/s]
 18%|#7        | 559/3121 [00:09<00:42, 59.88it/s]
 18%|#8        | 566/3121 [00:09<00:42, 59.80it/s]
 18%|#8        | 572/3121 [00:09<00:42, 59.44it/s]
 19%|#8        | 579/3121 [00:09<00:42, 59.95it/s]
 19%|#8        | 585/3121 [00:10<00:44, 57.52it/s]
 19%|#8        | 591/3121 [00:10<00:43, 58.12it/s]
 19%|#9        | 597/3121 [00:10<00:43, 58.46it/s]
 19%|#9        | 604/3121 [00:10<00:42, 59.18it/s]
 20%|#9        | 611/3121 [00:10<00:42, 58.75it/s]
 20%|#9        | 617/3121 [00:10<00:43, 57.03it/s]
 20%|#9        | 623/3121 [00:10<00:43, 57.84it/s]
 20%|##        | 629/3121 [00:10<00:42, 58.24it/s]
 20%|##        | 636/3121 [00:10<00:42, 59.16it/s]
 21%|##        | 642/3121 [00:11<00:41, 59.28it/s]
 21%|##        | 649/3121 [00:11<00:41, 59.54it/s]
 21%|##        | 655/3121 [00:11<00:41, 59.60it/s]
 21%|##1       | 661/3121 [00:11<00:41, 59.31it/s]
 21%|##1       | 668/3121 [00:11<00:40, 60.00it/s]
 22%|##1       | 674/3121 [00:11<00:40, 59.83it/s]
 22%|##1       | 681/3121 [00:11<00:40, 59.99it/s]
 22%|##2       | 687/3121 [00:11<00:40, 59.84it/s]
 22%|##2       | 693/3121 [00:11<00:40, 59.82it/s]
 22%|##2       | 700/3121 [00:12<00:40, 60.05it/s]
 23%|##2       | 707/3121 [00:12<00:40, 59.86it/s]
 23%|##2       | 713/3121 [00:12<00:41, 57.69it/s]
 23%|##3       | 719/3121 [00:12<00:41, 57.91it/s]
 23%|##3       | 726/3121 [00:12<00:40, 58.67it/s]
 23%|##3       | 733/3121 [00:12<00:40, 59.14it/s]
 24%|##3       | 739/3121 [00:12<00:40, 59.23it/s]
 24%|##3       | 745/3121 [00:12<00:42, 56.57it/s]
 24%|##4       | 752/3121 [00:12<00:40, 58.04it/s]
 24%|##4       | 759/3121 [00:13<00:40, 58.41it/s]
 25%|##4       | 766/3121 [00:13<00:39, 59.14it/s]
 25%|##4       | 772/3121 [00:13<00:39, 59.14it/s]
 25%|##4       | 779/3121 [00:13<00:39, 59.49it/s]
 25%|##5       | 785/3121 [00:13<00:39, 59.57it/s]
 25%|##5       | 791/3121 [00:13<00:39, 59.25it/s]
 26%|##5       | 797/3121 [00:13<00:39, 58.52it/s]
 26%|##5       | 803/3121 [00:13<00:40, 57.71it/s]
 26%|##5       | 809/3121 [00:13<00:40, 56.67it/s]
 26%|##6       | 815/3121 [00:14<00:40, 57.32it/s]
 26%|##6       | 821/3121 [00:14<00:40, 56.72it/s]
 27%|##6       | 828/3121 [00:14<00:39, 58.38it/s]
 27%|##6       | 834/3121 [00:14<00:39, 58.64it/s]
 27%|##6       | 840/3121 [00:14<00:38, 58.95it/s]
 27%|##7       | 847/3121 [00:14<00:38, 59.43it/s]
 27%|##7       | 853/3121 [00:14<00:38, 59.34it/s]
 28%|##7       | 859/3121 [00:14<00:38, 59.26it/s]
 28%|##7       | 865/3121 [00:14<00:38, 58.32it/s]
 28%|##7       | 871/3121 [00:14<00:39, 57.60it/s]
 28%|##8       | 878/3121 [00:15<00:38, 58.50it/s]
 28%|##8       | 884/3121 [00:15<00:38, 58.53it/s]
 29%|##8       | 891/3121 [00:15<00:37, 59.41it/s]
 29%|##8       | 897/3121 [00:15<00:37, 59.47it/s]
 29%|##8       | 903/3121 [00:15<00:38, 57.91it/s]
 29%|##9       | 909/3121 [00:15<00:40, 54.90it/s]
 29%|##9       | 916/3121 [00:15<00:38, 56.54it/s]
 30%|##9       | 922/3121 [00:15<00:40, 54.90it/s]
 30%|##9       | 928/3121 [00:15<00:39, 55.18it/s]
 30%|##9       | 934/3121 [00:16<00:39, 55.06it/s]
 30%|###       | 940/3121 [00:16<00:38, 56.28it/s]
 30%|###       | 946/3121 [00:16<00:37, 57.32it/s]
 31%|###       | 953/3121 [00:16<00:37, 58.56it/s]
 31%|###       | 960/3121 [00:16<00:36, 59.38it/s]
 31%|###       | 966/3121 [00:16<00:36, 58.90it/s]
 31%|###1      | 972/3121 [00:16<00:36, 59.08it/s]
 31%|###1      | 978/3121 [00:16<00:36, 59.14it/s]
 32%|###1      | 984/3121 [00:16<00:36, 57.88it/s]
 32%|###1      | 990/3121 [00:17<00:36, 57.81it/s]
 32%|###1      | 996/3121 [00:17<00:36, 58.18it/s]
 32%|###2      | 1002/3121 [00:17<00:36, 58.61it/s]
 32%|###2      | 1008/3121 [00:17<00:36, 57.89it/s]
 32%|###2      | 1014/3121 [00:17<00:36, 58.45it/s]
 33%|###2      | 1020/3121 [00:17<00:37, 56.70it/s]
 33%|###2      | 1026/3121 [00:17<00:36, 57.14it/s]
 33%|###3      | 1032/3121 [00:17<00:36, 57.79it/s]
 33%|###3      | 1039/3121 [00:17<00:35, 58.68it/s]
 33%|###3      | 1045/3121 [00:17<00:35, 58.89it/s]
 34%|###3      | 1052/3121 [00:18<00:35, 58.78it/s]
 34%|###3      | 1058/3121 [00:18<00:36, 56.62it/s]
 34%|###4      | 1065/3121 [00:18<00:35, 58.30it/s]
 34%|###4      | 1071/3121 [00:18<00:35, 58.54it/s]
 35%|###4      | 1078/3121 [00:18<00:34, 58.97it/s]
 35%|###4      | 1085/3121 [00:18<00:34, 59.53it/s]
 35%|###4      | 1091/3121 [00:18<00:34, 59.27it/s]
 35%|###5      | 1097/3121 [00:18<00:36, 55.21it/s]
 35%|###5      | 1103/3121 [00:18<00:36, 56.02it/s]
 36%|###5      | 1109/3121 [00:19<00:35, 56.96it/s]
 36%|###5      | 1116/3121 [00:19<00:34, 58.58it/s]
 36%|###5      | 1122/3121 [00:19<00:34, 58.47it/s]
 36%|###6      | 1128/3121 [00:19<00:34, 58.56it/s]
 36%|###6      | 1134/3121 [00:19<00:33, 58.92it/s]
 37%|###6      | 1141/3121 [00:19<00:33, 59.73it/s]
 37%|###6      | 1147/3121 [00:19<00:33, 59.10it/s]
 37%|###6      | 1153/3121 [00:19<00:34, 57.15it/s]
 37%|###7      | 1159/3121 [00:19<00:34, 57.67it/s]
 37%|###7      | 1166/3121 [00:20<00:33, 58.57it/s]
 38%|###7      | 1173/3121 [00:20<00:33, 58.83it/s]
 38%|###7      | 1180/3121 [00:20<00:32, 59.31it/s]
 38%|###8      | 1186/3121 [00:20<00:32, 59.29it/s]
 38%|###8      | 1193/3121 [00:20<00:32, 59.41it/s]
 38%|###8      | 1200/3121 [00:20<00:32, 59.98it/s]
 39%|###8      | 1206/3121 [00:20<00:32, 59.69it/s]
 39%|###8      | 1213/3121 [00:20<00:31, 59.98it/s]
 39%|###9      | 1219/3121 [00:20<00:31, 59.76it/s]
 39%|###9      | 1225/3121 [00:21<00:32, 58.55it/s]
 39%|###9      | 1231/3121 [00:21<00:32, 57.85it/s]
 40%|###9      | 1237/3121 [00:21<00:32, 58.42it/s]
 40%|###9      | 1243/3121 [00:21<00:31, 58.86it/s]
 40%|####      | 1250/3121 [00:21<00:31, 59.32it/s]
 40%|####      | 1257/3121 [00:21<00:31, 59.64it/s]
 40%|####      | 1263/3121 [00:21<00:31, 59.38it/s]
 41%|####      | 1269/3121 [00:21<00:31, 59.13it/s]
 41%|####      | 1276/3121 [00:21<00:30, 60.35it/s]
 41%|####1     | 1283/3121 [00:22<00:30, 59.40it/s]
 41%|####1     | 1290/3121 [00:22<00:30, 59.96it/s]
 42%|####1     | 1296/3121 [00:22<00:30, 59.67it/s]
 42%|####1     | 1302/3121 [00:22<00:33, 54.77it/s]
 42%|####1     | 1308/3121 [00:22<00:33, 54.31it/s]
 42%|####2     | 1314/3121 [00:22<00:32, 55.34it/s]
 42%|####2     | 1320/3121 [00:22<00:31, 56.41it/s]
 42%|####2     | 1326/3121 [00:22<00:31, 56.98it/s]
 43%|####2     | 1333/3121 [00:22<00:30, 58.34it/s]
 43%|####2     | 1339/3121 [00:23<00:30, 58.78it/s]
 43%|####3     | 1346/3121 [00:23<00:29, 59.57it/s]
 43%|####3     | 1352/3121 [00:23<00:29, 59.47it/s]
 44%|####3     | 1358/3121 [00:23<00:29, 59.48it/s]
 44%|####3     | 1365/3121 [00:23<00:29, 59.82it/s]
 44%|####3     | 1371/3121 [00:23<00:29, 59.51it/s]
 44%|####4     | 1378/3121 [00:23<00:28, 60.23it/s]
 44%|####4     | 1385/3121 [00:23<00:29, 59.81it/s]
 45%|####4     | 1392/3121 [00:23<00:28, 60.14it/s]
 45%|####4     | 1399/3121 [00:24<00:31, 55.10it/s]
 45%|####5     | 1405/3121 [00:24<00:30, 56.30it/s]
 45%|####5     | 1411/3121 [00:24<00:29, 57.05it/s]
 45%|####5     | 1418/3121 [00:24<00:29, 58.41it/s]
 46%|####5     | 1424/3121 [00:24<00:28, 58.69it/s]
 46%|####5     | 1430/3121 [00:24<00:28, 58.40it/s]
 46%|####6     | 1437/3121 [00:24<00:28, 59.49it/s]
 46%|####6     | 1444/3121 [00:24<00:27, 59.91it/s]
 46%|####6     | 1450/3121 [00:24<00:28, 59.64it/s]
 47%|####6     | 1457/3121 [00:25<00:27, 59.78it/s]
 47%|####6     | 1464/3121 [00:25<00:27, 60.06it/s]
 47%|####7     | 1471/3121 [00:25<00:27, 60.10it/s]
 47%|####7     | 1478/3121 [00:25<00:27, 59.84it/s]
 48%|####7     | 1484/3121 [00:25<00:27, 59.80it/s]
 48%|####7     | 1490/3121 [00:25<00:27, 58.86it/s]
 48%|####7     | 1497/3121 [00:25<00:26, 60.25it/s]
 48%|####8     | 1504/3121 [00:25<00:26, 60.08it/s]
 48%|####8     | 1511/3121 [00:25<00:26, 59.87it/s]
 49%|####8     | 1518/3121 [00:26<00:26, 60.36it/s]
 49%|####8     | 1525/3121 [00:26<00:26, 59.69it/s]
 49%|####9     | 1532/3121 [00:26<00:26, 60.26it/s]
 49%|####9     | 1539/3121 [00:26<00:26, 60.37it/s]
 50%|####9     | 1546/3121 [00:26<00:26, 59.35it/s]
 50%|####9     | 1553/3121 [00:26<00:25, 60.32it/s]
 50%|####9     | 1560/3121 [00:26<00:25, 60.07it/s]
 50%|#####     | 1567/3121 [00:26<00:26, 59.04it/s]
 50%|#####     | 1573/3121 [00:26<00:26, 57.69it/s]
 51%|#####     | 1579/3121 [00:27<00:26, 57.87it/s]
 51%|#####     | 1586/3121 [00:27<00:25, 59.22it/s]
 51%|#####1    | 1592/3121 [00:27<00:25, 59.04it/s]
 51%|#####1    | 1599/3121 [00:27<00:25, 59.98it/s]
 51%|#####1    | 1605/3121 [00:27<00:25, 59.72it/s]
 52%|#####1    | 1611/3121 [00:27<00:26, 56.96it/s]
 52%|#####1    | 1618/3121 [00:27<00:25, 57.96it/s]
 52%|#####2    | 1624/3121 [00:27<00:25, 58.45it/s]
 52%|#####2    | 1631/3121 [00:27<00:25, 58.91it/s]
 52%|#####2    | 1637/3121 [00:28<00:25, 58.33it/s]
 53%|#####2    | 1644/3121 [00:28<00:24, 59.74it/s]
 53%|#####2    | 1651/3121 [00:28<00:24, 60.04it/s]
 53%|#####3    | 1658/3121 [00:28<00:24, 60.02it/s]
 53%|#####3    | 1665/3121 [00:28<00:24, 59.91it/s]
 54%|#####3    | 1672/3121 [00:28<00:24, 60.12it/s]
 54%|#####3    | 1679/3121 [00:28<00:23, 60.13it/s]
 54%|#####4    | 1686/3121 [00:28<00:24, 59.72it/s]
 54%|#####4    | 1693/3121 [00:28<00:23, 60.11it/s]
 54%|#####4    | 1700/3121 [00:29<00:23, 59.76it/s]
 55%|#####4    | 1706/3121 [00:29<00:23, 59.79it/s]
 55%|#####4    | 1713/3121 [00:29<00:23, 60.03it/s]
 55%|#####5    | 1720/3121 [00:29<00:23, 60.18it/s]
 55%|#####5    | 1727/3121 [00:29<00:23, 59.71it/s]
 56%|#####5    | 1734/3121 [00:29<00:23, 60.16it/s]
 56%|#####5    | 1741/3121 [00:29<00:23, 59.96it/s]
 56%|#####5    | 1747/3121 [00:29<00:23, 59.52it/s]
 56%|#####6    | 1754/3121 [00:29<00:22, 60.30it/s]
 56%|#####6    | 1761/3121 [00:30<00:23, 57.48it/s]
 57%|#####6    | 1767/3121 [00:30<00:24, 55.77it/s]
 57%|#####6    | 1773/3121 [00:30<00:23, 56.72it/s]
 57%|#####7    | 1780/3121 [00:30<00:23, 57.96it/s]
 57%|#####7    | 1786/3121 [00:30<00:22, 58.36it/s]
 57%|#####7    | 1793/3121 [00:30<00:22, 58.80it/s]
 58%|#####7    | 1800/3121 [00:30<00:22, 59.15it/s]
 58%|#####7    | 1807/3121 [00:30<00:22, 59.52it/s]
 58%|#####8    | 1813/3121 [00:31<00:22, 59.41it/s]
 58%|#####8    | 1820/3121 [00:31<00:21, 60.04it/s]
 59%|#####8    | 1827/3121 [00:31<00:21, 59.79it/s]
 59%|#####8    | 1834/3121 [00:31<00:21, 59.63it/s]
 59%|#####8    | 1840/3121 [00:31<00:21, 59.62it/s]
 59%|#####9    | 1847/3121 [00:31<00:21, 60.18it/s]
 59%|#####9    | 1854/3121 [00:31<00:21, 60.08it/s]
 60%|#####9    | 1861/3121 [00:31<00:21, 59.98it/s]
 60%|#####9    | 1868/3121 [00:31<00:20, 60.00it/s]
 60%|######    | 1875/3121 [00:32<00:20, 60.13it/s]
 60%|######    | 1882/3121 [00:32<00:20, 60.16it/s]
 61%|######    | 1889/3121 [00:32<00:20, 59.80it/s]
 61%|######    | 1895/3121 [00:32<00:20, 59.54it/s]
 61%|######    | 1901/3121 [00:32<00:20, 59.50it/s]
 61%|######1   | 1907/3121 [00:32<00:20, 59.54it/s]
 61%|######1   | 1914/3121 [00:32<00:20, 60.22it/s]
 62%|######1   | 1921/3121 [00:32<00:19, 60.14it/s]
 62%|######1   | 1928/3121 [00:32<00:20, 58.23it/s]
 62%|######1   | 1934/3121 [00:33<00:20, 57.81it/s]
 62%|######2   | 1940/3121 [00:33<00:20, 58.29it/s]
 62%|######2   | 1946/3121 [00:33<00:20, 58.53it/s]
 63%|######2   | 1953/3121 [00:33<00:19, 59.43it/s]
 63%|######2   | 1959/3121 [00:33<00:21, 54.02it/s]
 63%|######2   | 1965/3121 [00:33<00:20, 55.25it/s]
 63%|######3   | 1972/3121 [00:33<00:19, 57.50it/s]
 63%|######3   | 1979/3121 [00:33<00:19, 58.43it/s]
 64%|######3   | 1986/3121 [00:33<00:19, 59.11it/s]
 64%|######3   | 1992/3121 [00:34<00:19, 58.99it/s]
 64%|######4   | 1998/3121 [00:34<00:18, 59.22it/s]
 64%|######4   | 2005/3121 [00:34<00:18, 59.40it/s]
 64%|######4   | 2012/3121 [00:34<00:18, 59.57it/s]
 65%|######4   | 2018/3121 [00:34<00:18, 59.49it/s]
 65%|######4   | 2025/3121 [00:34<00:18, 60.04it/s]
 65%|######5   | 2032/3121 [00:34<00:18, 60.07it/s]
 65%|######5   | 2039/3121 [00:34<00:18, 59.94it/s]
 66%|######5   | 2046/3121 [00:34<00:17, 60.24it/s]
 66%|######5   | 2053/3121 [00:35<00:17, 59.92it/s]
 66%|######6   | 2060/3121 [00:35<00:17, 60.33it/s]
 66%|######6   | 2067/3121 [00:35<00:17, 59.59it/s]
 66%|######6   | 2074/3121 [00:35<00:17, 60.31it/s]
 67%|######6   | 2081/3121 [00:35<00:17, 59.81it/s]
 67%|######6   | 2087/3121 [00:35<00:17, 59.76it/s]
 67%|######7   | 2094/3121 [00:35<00:17, 59.77it/s]
 67%|######7   | 2101/3121 [00:35<00:16, 60.17it/s]
 68%|######7   | 2108/3121 [00:35<00:16, 59.91it/s]
 68%|######7   | 2115/3121 [00:36<00:16, 60.49it/s]
 68%|######7   | 2122/3121 [00:36<00:16, 59.69it/s]
 68%|######8   | 2129/3121 [00:36<00:16, 59.89it/s]
 68%|######8   | 2135/3121 [00:36<00:16, 59.65it/s]
 69%|######8   | 2142/3121 [00:36<00:16, 60.09it/s]
 69%|######8   | 2149/3121 [00:36<00:16, 60.16it/s]
 69%|######9   | 2156/3121 [00:36<00:16, 60.27it/s]
 69%|######9   | 2163/3121 [00:36<00:16, 59.51it/s]
 70%|######9   | 2170/3121 [00:37<00:15, 60.03it/s]
 70%|######9   | 2177/3121 [00:37<00:15, 60.04it/s]
 70%|######9   | 2184/3121 [00:37<00:15, 60.27it/s]
 70%|#######   | 2191/3121 [00:37<00:15, 59.50it/s]
 70%|#######   | 2198/3121 [00:37<00:15, 60.05it/s]
 71%|#######   | 2205/3121 [00:37<00:15, 59.69it/s]
 71%|#######   | 2212/3121 [00:37<00:15, 59.96it/s]
 71%|#######1  | 2219/3121 [00:37<00:14, 60.50it/s]
 71%|#######1  | 2226/3121 [00:37<00:14, 60.37it/s]
 72%|#######1  | 2233/3121 [00:38<00:14, 60.21it/s]
 72%|#######1  | 2240/3121 [00:38<00:14, 60.08it/s]
 72%|#######1  | 2247/3121 [00:38<00:14, 60.14it/s]
 72%|#######2  | 2254/3121 [00:38<00:14, 59.80it/s]
 72%|#######2  | 2260/3121 [00:38<00:14, 59.46it/s]
 73%|#######2  | 2267/3121 [00:38<00:14, 59.69it/s]
 73%|#######2  | 2274/3121 [00:38<00:13, 60.61it/s]
 73%|#######3  | 2281/3121 [00:38<00:14, 59.38it/s]
 73%|#######3  | 2288/3121 [00:38<00:13, 60.23it/s]
 74%|#######3  | 2295/3121 [00:39<00:13, 60.46it/s]
 74%|#######3  | 2302/3121 [00:39<00:13, 59.73it/s]
 74%|#######3  | 2308/3121 [00:39<00:13, 59.42it/s]
 74%|#######4  | 2315/3121 [00:39<00:13, 60.54it/s]
 74%|#######4  | 2322/3121 [00:39<00:13, 60.13it/s]
 75%|#######4  | 2329/3121 [00:39<00:13, 60.02it/s]
 75%|#######4  | 2336/3121 [00:39<00:13, 59.78it/s]
 75%|#######5  | 2342/3121 [00:39<00:13, 59.41it/s]
 75%|#######5  | 2348/3121 [00:39<00:12, 59.53it/s]
 75%|#######5  | 2355/3121 [00:40<00:12, 60.17it/s]
 76%|#######5  | 2362/3121 [00:40<00:12, 60.71it/s]
 76%|#######5  | 2369/3121 [00:40<00:12, 59.96it/s]
 76%|#######6  | 2376/3121 [00:40<00:12, 60.24it/s]
 76%|#######6  | 2383/3121 [00:40<00:12, 59.91it/s]
 77%|#######6  | 2390/3121 [00:40<00:12, 60.27it/s]
 77%|#######6  | 2397/3121 [00:40<00:12, 60.16it/s]
 77%|#######7  | 2404/3121 [00:40<00:11, 59.83it/s]
 77%|#######7  | 2410/3121 [00:41<00:11, 59.84it/s]
 77%|#######7  | 2417/3121 [00:41<00:11, 60.06it/s]
 78%|#######7  | 2424/3121 [00:41<00:11, 60.05it/s]
 78%|#######7  | 2431/3121 [00:41<00:11, 59.96it/s]
 78%|#######8  | 2438/3121 [00:41<00:11, 60.26it/s]
 78%|#######8  | 2445/3121 [00:41<00:11, 59.67it/s]
 79%|#######8  | 2452/3121 [00:41<00:11, 60.32it/s]
 79%|#######8  | 2459/3121 [00:41<00:11, 56.97it/s]
 79%|#######8  | 2465/3121 [00:41<00:11, 55.39it/s]
 79%|#######9  | 2472/3121 [00:42<00:11, 57.32it/s]
 79%|#######9  | 2478/3121 [00:42<00:11, 56.31it/s]
 80%|#######9  | 2484/3121 [00:42<00:11, 55.33it/s]
 80%|#######9  | 2491/3121 [00:42<00:10, 57.64it/s]
 80%|########  | 2498/3121 [00:42<00:10, 57.96it/s]
 80%|########  | 2505/3121 [00:42<00:10, 59.29it/s]
 80%|########  | 2511/3121 [00:42<00:10, 59.22it/s]
 81%|########  | 2518/3121 [00:42<00:10, 60.22it/s]
 81%|########  | 2525/3121 [00:42<00:10, 59.57it/s]
 81%|########1 | 2531/3121 [00:43<00:10, 58.79it/s]
 81%|########1 | 2538/3121 [00:43<00:09, 60.09it/s]
 82%|########1 | 2545/3121 [00:43<00:09, 59.81it/s]
 82%|########1 | 2552/3121 [00:43<00:09, 60.12it/s]
 82%|########1 | 2559/3121 [00:43<00:09, 58.84it/s]
 82%|########2 | 2565/3121 [00:43<00:09, 57.67it/s]
 82%|########2 | 2571/3121 [00:43<00:09, 58.21it/s]
 83%|########2 | 2577/3121 [00:43<00:09, 56.63it/s]
 83%|########2 | 2583/3121 [00:43<00:09, 56.92it/s]
 83%|########2 | 2589/3121 [00:44<00:09, 56.98it/s]
 83%|########3 | 2595/3121 [00:44<00:09, 56.66it/s]
 83%|########3 | 2601/3121 [00:44<00:09, 57.02it/s]
 84%|########3 | 2607/3121 [00:44<00:08, 57.59it/s]
 84%|########3 | 2614/3121 [00:44<00:08, 58.71it/s]
 84%|########3 | 2620/3121 [00:44<00:08, 58.84it/s]
 84%|########4 | 2627/3121 [00:44<00:08, 59.52it/s]
 84%|########4 | 2633/3121 [00:44<00:08, 59.40it/s]
 85%|########4 | 2640/3121 [00:44<00:08, 59.78it/s]
 85%|########4 | 2646/3121 [00:45<00:07, 59.73it/s]
 85%|########5 | 2653/3121 [00:45<00:07, 60.01it/s]
 85%|########5 | 2660/3121 [00:45<00:07, 59.85it/s]
 85%|########5 | 2667/3121 [00:45<00:07, 60.14it/s]
 86%|########5 | 2674/3121 [00:45<00:07, 59.94it/s]
 86%|########5 | 2680/3121 [00:45<00:07, 59.86it/s]
 86%|########6 | 2686/3121 [00:45<00:07, 59.36it/s]
 86%|########6 | 2693/3121 [00:45<00:07, 60.35it/s]
 87%|########6 | 2700/3121 [00:45<00:07, 60.00it/s]
 87%|########6 | 2706/3121 [00:46<00:06, 59.58it/s]
 87%|########6 | 2712/3121 [00:46<00:06, 59.67it/s]
 87%|########7 | 2719/3121 [00:46<00:06, 60.24it/s]
 87%|########7 | 2726/3121 [00:46<00:06, 59.74it/s]
 88%|########7 | 2732/3121 [00:46<00:06, 59.55it/s]
 88%|########7 | 2739/3121 [00:46<00:06, 60.61it/s]
 88%|########7 | 2746/3121 [00:46<00:06, 59.64it/s]
 88%|########8 | 2753/3121 [00:46<00:06, 59.90it/s]
 88%|########8 | 2760/3121 [00:46<00:05, 60.21it/s]
 89%|########8 | 2767/3121 [00:47<00:05, 60.40it/s]
 89%|########8 | 2774/3121 [00:47<00:05, 59.52it/s]
 89%|########9 | 2780/3121 [00:47<00:05, 57.41it/s]
 89%|########9 | 2786/3121 [00:47<00:06, 55.35it/s]
 89%|########9 | 2792/3121 [00:47<00:06, 53.42it/s]
 90%|########9 | 2799/3121 [00:47<00:05, 55.68it/s]
 90%|########9 | 2805/3121 [00:47<00:05, 56.32it/s]
 90%|######### | 2811/3121 [00:47<00:05, 57.25it/s]
 90%|######### | 2817/3121 [00:47<00:05, 56.67it/s]
 90%|######### | 2824/3121 [00:48<00:05, 57.90it/s]
 91%|######### | 2830/3121 [00:48<00:04, 58.22it/s]
 91%|######### | 2837/3121 [00:48<00:04, 59.23it/s]
 91%|#########1| 2843/3121 [00:48<00:04, 56.48it/s]
 91%|#########1| 2850/3121 [00:48<00:04, 57.89it/s]
 92%|#########1| 2856/3121 [00:48<00:04, 58.20it/s]
 92%|#########1| 2863/3121 [00:48<00:04, 58.88it/s]
 92%|#########1| 2869/3121 [00:48<00:04, 56.50it/s]
 92%|#########2| 2876/3121 [00:48<00:04, 57.59it/s]
 92%|#########2| 2882/3121 [00:49<00:04, 58.02it/s]
 93%|#########2| 2889/3121 [00:49<00:03, 58.99it/s]
 93%|#########2| 2896/3121 [00:49<00:03, 59.22it/s]
 93%|#########3| 2903/3121 [00:49<00:03, 59.57it/s]
 93%|#########3| 2909/3121 [00:49<00:03, 55.76it/s]
 93%|#########3| 2915/3121 [00:49<00:05, 38.68it/s]
 94%|#########3| 2921/3121 [00:49<00:04, 41.81it/s]
 94%|#########3| 2927/3121 [00:50<00:04, 45.67it/s]
 94%|#########4| 2934/3121 [00:50<00:03, 49.31it/s]
 94%|#########4| 2940/3121 [00:50<00:03, 50.29it/s]
 94%|#########4| 2946/3121 [00:50<00:03, 51.85it/s]
 95%|#########4| 2952/3121 [00:50<00:03, 53.99it/s]
 95%|#########4| 2959/3121 [00:50<00:02, 56.15it/s]
 95%|#########5| 2965/3121 [00:50<00:02, 56.74it/s]
 95%|#########5| 2971/3121 [00:50<00:02, 57.59it/s]
 95%|#########5| 2977/3121 [00:50<00:02, 58.06it/s]
 96%|#########5| 2983/3121 [00:51<00:02, 56.54it/s]
 96%|#########5| 2989/3121 [00:51<00:02, 57.25it/s]
 96%|#########5| 2996/3121 [00:51<00:02, 58.17it/s]
 96%|#########6| 3002/3121 [00:51<00:02, 58.45it/s]
 96%|#########6| 3009/3121 [00:51<00:01, 59.19it/s]
 97%|#########6| 3016/3121 [00:51<00:01, 59.07it/s]
 97%|#########6| 3023/3121 [00:51<00:01, 59.90it/s]
 97%|#########7| 3029/3121 [00:51<00:01, 59.27it/s]
 97%|#########7| 3036/3121 [00:51<00:01, 60.03it/s]
 98%|#########7| 3043/3121 [00:52<00:01, 59.94it/s]
 98%|#########7| 3050/3121 [00:52<00:01, 60.19it/s]
 98%|#########7| 3057/3121 [00:52<00:01, 59.38it/s]
 98%|#########8| 3064/3121 [00:52<00:00, 60.27it/s]
 98%|#########8| 3071/3121 [00:52<00:00, 59.76it/s]
 99%|#########8| 3077/3121 [00:52<00:00, 59.81it/s]
 99%|#########8| 3084/3121 [00:52<00:00, 59.53it/s]
 99%|#########9| 3090/3121 [00:52<00:00, 59.63it/s]
 99%|#########9| 3097/3121 [00:52<00:00, 59.98it/s]
 99%|#########9| 3103/3121 [00:53<00:00, 59.86it/s]
100%|#########9| 3110/3121 [00:53<00:00, 60.07it/s]
100%|#########9| 3117/3121 [00:53<00:00, 58.77it/s]
100%|##########| 3121/3121 [00:53<00:00, 58.52it/s]

We can now compare the kurtosis measures obtained with the constrained fit to the measures obtained before, where we see that many of the artefactual voxels have now been corrected. In particular outliers caused by pure noise – instead of for example acquisition artefacts – can be corrected with this method.

compare_maps([dkifit_plus], ['mk', 'ak', 'rk'], fit_labels=['DKI+'],
             filename='Kurtosis_tensor_standard_measures_plus.png')
reconst dki
examples_built/07_reconstruction/Kurtosis_tensor_standard_measures_plus.png

DKI standard kurtosis measures obtained with constrained optimization.

When using constrained optimization, the expected range of the kurtosis measures is also naturally constrained, and so does not typically require additional clipping.

Finally, constrained optimization obviates the need for smoothing in many cases:

dkifit_noisy = dkimodel.fit(data[:, :, 9:10], mask=mask)
dkifit_noisy_plus = dkimodel_plus.fit(data[:, :, 9:10], mask=mask)

compare_maps([dkifit_noisy, dkifit_noisy_plus], ['mk', 'ak', 'rk'],
             fit_labels=['DKI', 'DKI+'], map_kwargs={'vmin': 0, 'vmax': 1.5},
             filename='Kurtosis_tensor_standard_measures_noisy.png')
reconst dki
  0%|          | 0/3121 [00:00<?, ?it/s]
  1%|1         | 39/3121 [00:00<00:08, 380.26it/s]
  2%|2         | 78/3121 [00:00<00:08, 374.55it/s]
  4%|3         | 117/3121 [00:00<00:07, 376.04it/s]
  5%|4         | 155/3121 [00:00<00:07, 376.54it/s]
  6%|6         | 193/3121 [00:00<00:07, 373.81it/s]
  7%|7         | 233/3121 [00:00<00:07, 381.15it/s]
  9%|8         | 273/3121 [00:00<00:07, 379.81it/s]
 10%|9         | 311/3121 [00:00<00:07, 378.77it/s]
 11%|#1        | 351/3121 [00:00<00:07, 375.52it/s]
 12%|#2        | 389/3121 [00:01<00:07, 368.90it/s]
 14%|#3        | 432/3121 [00:01<00:06, 384.55it/s]
 15%|#5        | 471/3121 [00:01<00:06, 382.03it/s]
 16%|#6        | 513/3121 [00:01<00:06, 392.37it/s]
 18%|#7        | 556/3121 [00:01<00:06, 401.17it/s]
 19%|#9        | 601/3121 [00:01<00:06, 415.36it/s]
 21%|##        | 643/3121 [00:01<00:06, 404.38it/s]
 22%|##1       | 684/3121 [00:01<00:06, 397.76it/s]
 23%|##3       | 724/3121 [00:01<00:07, 321.39it/s]
 24%|##4       | 761/3121 [00:02<00:07, 333.11it/s]
 26%|##6       | 812/3121 [00:02<00:06, 378.40it/s]
 27%|##7       | 852/3121 [00:02<00:06, 375.75it/s]
 29%|##8       | 891/3121 [00:02<00:05, 377.38it/s]
 30%|##9       | 930/3121 [00:02<00:05, 378.30it/s]
 31%|###1      | 970/3121 [00:02<00:05, 382.41it/s]
 32%|###2      | 1010/3121 [00:02<00:05, 385.68it/s]
 34%|###3      | 1049/3121 [00:02<00:05, 378.20it/s]
 35%|###4      | 1090/3121 [00:02<00:05, 386.69it/s]
 36%|###6      | 1129/3121 [00:02<00:05, 380.11it/s]
 37%|###7      | 1168/3121 [00:03<00:05, 371.11it/s]
 39%|###8      | 1209/3121 [00:03<00:05, 380.50it/s]
 40%|###9      | 1248/3121 [00:03<00:05, 364.36it/s]
 41%|####1     | 1285/3121 [00:03<00:05, 361.50it/s]
 42%|####2     | 1325/3121 [00:03<00:04, 366.84it/s]
 44%|####3     | 1369/3121 [00:03<00:04, 386.18it/s]
 45%|####5     | 1412/3121 [00:03<00:04, 397.72it/s]
 47%|####6     | 1452/3121 [00:03<00:04, 396.49it/s]
 48%|####7     | 1492/3121 [00:03<00:04, 390.89it/s]
 49%|####9     | 1532/3121 [00:04<00:04, 384.16it/s]
 50%|#####     | 1571/3121 [00:04<00:04, 385.34it/s]
 52%|#####1    | 1610/3121 [00:04<00:03, 386.50it/s]
 53%|#####2    | 1649/3121 [00:04<00:03, 386.69it/s]
 54%|#####4    | 1688/3121 [00:04<00:03, 378.06it/s]
 55%|#####5    | 1726/3121 [00:04<00:03, 368.38it/s]
 57%|#####6    | 1766/3121 [00:04<00:03, 377.45it/s]
 58%|#####7    | 1804/3121 [00:04<00:03, 354.78it/s]
 59%|#####8    | 1840/3121 [00:04<00:03, 334.03it/s]
 60%|######    | 1874/3121 [00:05<00:03, 327.09it/s]
 61%|######1   | 1917/3121 [00:05<00:03, 353.93it/s]
 63%|######2   | 1958/3121 [00:05<00:03, 368.99it/s]
 64%|######4   | 2001/3121 [00:05<00:02, 381.66it/s]
 65%|######5   | 2040/3121 [00:05<00:02, 375.67it/s]
 67%|######6   | 2081/3121 [00:05<00:02, 384.38it/s]
 68%|######8   | 2126/3121 [00:05<00:02, 402.77it/s]
 70%|######9   | 2178/3121 [00:05<00:02, 436.32it/s]
 71%|#######1  | 2226/3121 [00:05<00:02, 447.16it/s]
 73%|#######2  | 2271/3121 [00:05<00:02, 409.15it/s]
 74%|#######4  | 2313/3121 [00:06<00:02, 400.57it/s]
 75%|#######5  | 2354/3121 [00:06<00:01, 397.19it/s]
 77%|#######6  | 2395/3121 [00:06<00:01, 390.86it/s]
 78%|#######8  | 2435/3121 [00:06<00:01, 385.99it/s]
 79%|#######9  | 2474/3121 [00:06<00:01, 384.22it/s]
 81%|########  | 2514/3121 [00:06<00:01, 388.26it/s]
 82%|########1 | 2554/3121 [00:06<00:01, 387.00it/s]
 83%|########3 | 2593/3121 [00:06<00:01, 385.99it/s]
 84%|########4 | 2633/3121 [00:06<00:01, 386.49it/s]
 86%|########5 | 2672/3121 [00:07<00:01, 365.34it/s]
 87%|########6 | 2711/3121 [00:07<00:01, 371.83it/s]
 88%|########8 | 2750/3121 [00:07<00:00, 376.78it/s]
 89%|########9 | 2788/3121 [00:07<00:00, 371.13it/s]
 91%|######### | 2826/3121 [00:07<00:00, 368.05it/s]
 92%|#########1| 2870/3121 [00:07<00:00, 388.20it/s]
 93%|#########3| 2910/3121 [00:07<00:00, 391.13it/s]
 95%|#########4| 2951/3121 [00:07<00:00, 395.28it/s]
 96%|#########5| 2993/3121 [00:07<00:00, 400.97it/s]
 97%|#########7| 3034/3121 [00:07<00:00, 401.64it/s]
 99%|#########8| 3075/3121 [00:08<00:00, 385.28it/s]
100%|##########| 3121/3121 [00:08<00:00, 404.47it/s]
100%|##########| 3121/3121 [00:08<00:00, 382.17it/s]

  0%|          | 0/3121 [00:00<?, ?it/s]
  0%|          | 6/3121 [00:00<00:53, 58.12it/s]
  0%|          | 9/3121 [00:11<00:53, 58.12it/s]/opt/homebrew/Caskroom/miniforge/base/envs/dipy-39-x86/lib/python3.9/site-packages/cvxpy/problems/problem.py:1385: UserWarning: Solution may be inaccurate. Try another solver, adjusting the solver settings, or solve with verbose=True for more information.
  warnings.warn(
/Users/skoudoro/devel/dipy/dipy/core/optimize.py:527: UserWarning: Solver failed to produce an optimum: optimal_inaccurate.
  warnings.warn(msg)

  0%|          | 10/3121 [00:30<3:10:20,  3.67s/it]
  0%|          | 11/3121 [00:59<6:30:23,  7.53s/it]
  1%|          | 17/3121 [00:59<2:52:01,  3.33s/it]
  1%|          | 23/3121 [01:00<1:35:46,  1.86s/it]
  1%|          | 29/3121 [01:00<58:51,  1.14s/it]
  1%|          | 29/3121 [01:12<58:51,  1.14s/it]
  1%|          | 30/3121 [01:29<3:03:38,  3.56s/it]
  1%|1         | 32/3121 [02:01<5:05:27,  5.93s/it]
  1%|1         | 37/3121 [02:01<3:00:20,  3.51s/it]
  1%|1         | 43/3121 [02:01<1:46:02,  2.07s/it]
  2%|1         | 47/3121 [02:12<1:45:54,  2.07s/it]
  2%|1         | 48/3121 [02:33<2:57:32,  3.47s/it]
  2%|1         | 53/3121 [03:05<3:46:59,  4.44s/it]
  2%|1         | 58/3121 [03:38<4:21:51,  5.13s/it]
  2%|2         | 64/3121 [03:38<2:50:15,  3.34s/it]
  2%|2         | 70/3121 [03:39<1:53:37,  2.23s/it]
  2%|2         | 77/3121 [03:39<1:13:11,  1.44s/it]
  3%|2         | 84/3121 [03:39<48:38,  1.04it/s]
  3%|2         | 88/3121 [03:52<48:34,  1.04it/s]
  3%|2         | 89/3121 [04:10<1:56:13,  2.30s/it]
  3%|2         | 90/3121 [04:41<3:36:34,  4.29s/it]
  3%|2         | 91/3121 [05:12<5:36:23,  6.66s/it]
  3%|3         | 97/3121 [05:12<3:11:01,  3.79s/it]
  3%|3         | 103/3121 [05:12<1:58:13,  2.35s/it]
  3%|3         | 109/3121 [05:13<1:16:39,  1.53s/it]
  4%|3         | 115/3121 [05:13<51:18,  1.02s/it]
  4%|3         | 121/3121 [05:13<35:00,  1.43it/s]
  4%|4         | 126/3121 [05:13<25:33,  1.95it/s]
  4%|4         | 131/3121 [05:13<18:35,  2.68it/s]
  4%|4         | 136/3121 [05:13<13:31,  3.68it/s]
  5%|4         | 142/3121 [05:13<09:18,  5.33it/s]
  5%|4         | 148/3121 [05:13<06:36,  7.50it/s]
  5%|4         | 154/3121 [05:14<04:48, 10.27it/s]
  5%|5         | 161/3121 [05:14<03:25, 14.38it/s]
  5%|5         | 167/3121 [05:14<02:39, 18.54it/s]
  6%|5         | 173/3121 [05:14<02:07, 23.19it/s]
  6%|5         | 180/3121 [05:14<01:41, 29.07it/s]
  6%|5         | 187/3121 [05:14<01:24, 34.86it/s]
  6%|6         | 193/3121 [05:14<01:14, 39.32it/s]
  6%|6         | 199/3121 [05:14<01:09, 42.13it/s]
  7%|6         | 206/3121 [05:14<01:01, 47.08it/s]
  7%|6         | 212/3121 [05:14<00:58, 50.13it/s]
  7%|6         | 218/3121 [05:15<00:55, 52.60it/s]
  7%|7         | 224/3121 [05:15<00:54, 53.10it/s]
  7%|7         | 231/3121 [05:15<00:52, 55.09it/s]
  8%|7         | 237/3121 [05:15<00:52, 54.72it/s]
  8%|7         | 243/3121 [05:15<00:52, 54.86it/s]
  8%|8         | 250/3121 [05:15<00:50, 56.51it/s]
  8%|8         | 256/3121 [05:15<00:50, 56.52it/s]
  8%|8         | 262/3121 [05:15<00:50, 56.61it/s]
  9%|8         | 268/3121 [05:15<00:50, 56.99it/s]
  9%|8         | 275/3121 [05:16<00:51, 54.79it/s]
  9%|9         | 281/3121 [05:16<00:51, 55.28it/s]
  9%|9         | 287/3121 [05:16<00:51, 55.44it/s]
  9%|9         | 293/3121 [05:16<00:52, 53.46it/s]
 10%|9         | 299/3121 [05:16<00:52, 53.74it/s]
 10%|9         | 305/3121 [05:16<01:00, 46.43it/s]
 10%|9         | 310/3121 [05:16<01:00, 46.46it/s]
 10%|#         | 315/3121 [05:16<01:00, 46.66it/s]
 10%|#         | 321/3121 [05:17<00:58, 47.99it/s]
 10%|#         | 326/3121 [05:17<00:58, 48.13it/s]
 11%|#         | 332/3121 [05:17<00:55, 50.58it/s]
 11%|#         | 338/3121 [05:17<00:55, 50.19it/s]
 11%|#1        | 344/3121 [05:17<00:53, 51.99it/s]
 11%|#1        | 351/3121 [05:17<00:50, 55.16it/s]
 11%|#1        | 357/3121 [05:17<00:49, 56.12it/s]
 12%|#1        | 363/3121 [05:17<00:48, 56.57it/s]
 12%|#1        | 370/3121 [05:17<00:47, 58.47it/s]
 12%|#2        | 376/3121 [05:18<00:48, 56.76it/s]
 12%|#2        | 382/3121 [05:18<00:47, 57.12it/s]
 12%|#2        | 388/3121 [05:18<00:49, 55.18it/s]
 13%|#2        | 395/3121 [05:18<00:47, 57.01it/s]
 13%|#2        | 401/3121 [05:18<00:47, 57.36it/s]
 13%|#3        | 407/3121 [05:18<00:47, 57.25it/s]
 13%|#3        | 414/3121 [05:18<00:45, 59.21it/s]
 13%|#3        | 421/3121 [05:18<00:46, 58.22it/s]
 14%|#3        | 427/3121 [05:18<00:47, 57.06it/s]
 14%|#3        | 434/3121 [05:19<00:46, 57.97it/s]
 14%|#4        | 440/3121 [05:19<00:46, 57.92it/s]
 14%|#4        | 446/3121 [05:19<00:45, 58.26it/s]
 14%|#4        | 452/3121 [05:19<00:45, 58.61it/s]
 15%|#4        | 458/3121 [05:19<00:46, 57.46it/s]
 15%|#4        | 465/3121 [05:19<00:45, 58.44it/s]
 15%|#5        | 472/3121 [05:19<00:45, 58.73it/s]
 15%|#5        | 478/3121 [05:19<00:44, 58.93it/s]
 16%|#5        | 485/3121 [05:19<00:44, 59.45it/s]
 16%|#5        | 491/3121 [05:20<00:44, 59.47it/s]
 16%|#5        | 497/3121 [05:20<00:44, 59.61it/s]
 16%|#6        | 503/3121 [05:20<00:44, 59.22it/s]
 16%|#6        | 509/3121 [05:20<00:44, 58.44it/s]
 17%|#6        | 515/3121 [05:20<00:45, 57.77it/s]
 17%|#6        | 521/3121 [05:20<00:47, 54.81it/s]
 17%|#6        | 528/3121 [05:20<00:45, 57.19it/s]
 17%|#7        | 534/3121 [05:20<00:44, 57.66it/s]
 17%|#7        | 540/3121 [05:20<00:46, 56.07it/s]
 17%|#7        | 546/3121 [05:20<00:45, 57.14it/s]
 18%|#7        | 552/3121 [05:21<00:45, 56.61it/s]
 18%|#7        | 558/3121 [05:21<00:46, 54.69it/s]
 18%|#8        | 564/3121 [05:21<00:46, 54.82it/s]
 18%|#8        | 571/3121 [05:21<00:44, 56.71it/s]
 19%|#8        | 578/3121 [05:21<00:44, 57.16it/s]
 19%|#8        | 585/3121 [05:21<00:43, 58.67it/s]
 19%|#8        | 592/3121 [05:21<00:42, 58.82it/s]
 19%|#9        | 598/3121 [05:21<00:42, 58.68it/s]
 19%|#9        | 605/3121 [05:21<00:42, 59.42it/s]
 20%|#9        | 611/3121 [05:22<00:42, 59.38it/s]
 20%|#9        | 618/3121 [05:22<00:41, 60.08it/s]
 20%|##        | 625/3121 [05:22<00:41, 60.00it/s]
 20%|##        | 631/3121 [05:22<00:41, 59.51it/s]
 20%|##        | 638/3121 [05:22<00:49, 50.63it/s]
 21%|##        | 645/3121 [05:22<00:46, 53.65it/s]
 21%|##        | 651/3121 [05:22<00:44, 54.93it/s]
 21%|##1       | 658/3121 [05:22<00:43, 56.78it/s]
 21%|##1       | 664/3121 [05:23<00:42, 57.49it/s]
 21%|##1       | 671/3121 [05:23<00:42, 57.56it/s]
 22%|##1       | 678/3121 [05:23<00:41, 58.99it/s]
 22%|##1       | 684/3121 [05:23<00:41, 58.39it/s]
 22%|##2       | 690/3121 [05:23<00:41, 58.51it/s]
 22%|##2       | 696/3121 [05:23<00:42, 57.46it/s]
 22%|##2       | 702/3121 [05:23<00:41, 58.10it/s]
 23%|##2       | 708/3121 [05:23<00:41, 57.67it/s]
 23%|##2       | 714/3121 [05:23<00:42, 56.57it/s]
 23%|##3       | 720/3121 [05:24<00:43, 55.20it/s]
 23%|##3       | 726/3121 [05:24<00:42, 55.90it/s]
 23%|##3       | 733/3121 [05:24<00:41, 56.92it/s]
 24%|##3       | 740/3121 [05:24<00:41, 57.77it/s]
 24%|##3       | 747/3121 [05:24<00:40, 58.65it/s]
 24%|##4       | 754/3121 [05:24<00:39, 59.23it/s]
 24%|##4       | 761/3121 [05:24<00:39, 59.84it/s]
 25%|##4       | 767/3121 [05:24<00:39, 59.72it/s]
 25%|##4       | 773/3121 [05:24<00:42, 54.89it/s]
 25%|##4       | 779/3121 [05:25<00:48, 48.49it/s]
 25%|##5       | 785/3121 [05:25<00:51, 45.10it/s]
 25%|##5       | 790/3121 [05:25<00:50, 45.74it/s]
 26%|##5       | 796/3121 [05:25<00:47, 48.96it/s]
 26%|##5       | 803/3121 [05:25<00:43, 52.97it/s]
 26%|##5       | 809/3121 [05:25<00:42, 54.67it/s]
 26%|##6       | 815/3121 [05:25<00:41, 56.06it/s]
 26%|##6       | 822/3121 [05:25<00:40, 57.22it/s]
 27%|##6       | 828/3121 [05:25<00:39, 57.59it/s]
 27%|##6       | 835/3121 [05:26<00:38, 58.83it/s]
 27%|##6       | 841/3121 [05:26<00:38, 59.05it/s]
 27%|##7       | 848/3121 [05:26<00:38, 59.56it/s]
 27%|##7       | 854/3121 [05:26<00:39, 56.89it/s]
 28%|##7       | 860/3121 [05:26<00:40, 55.27it/s]
 28%|##7       | 867/3121 [05:26<00:39, 56.67it/s]
 28%|##7       | 873/3121 [05:26<00:40, 55.64it/s]
 28%|##8       | 879/3121 [05:26<00:44, 50.66it/s]
 28%|##8       | 885/3121 [05:27<00:45, 49.18it/s]
 29%|##8       | 891/3121 [05:27<00:44, 50.36it/s]
 29%|##8       | 897/3121 [05:27<00:44, 50.43it/s]
 29%|##8       | 904/3121 [05:27<00:41, 53.65it/s]
 29%|##9       | 910/3121 [05:27<00:40, 54.67it/s]
 29%|##9       | 916/3121 [05:27<00:40, 53.81it/s]
 30%|##9       | 922/3121 [05:27<00:42, 51.95it/s]
 30%|##9       | 928/3121 [05:27<00:43, 50.70it/s]
 30%|##9       | 934/3121 [05:28<00:46, 47.46it/s]
 30%|###       | 939/3121 [05:28<00:46, 46.43it/s]
 30%|###       | 944/3121 [05:28<00:49, 44.37it/s]
 30%|###       | 949/3121 [05:28<00:53, 40.54it/s]
 31%|###       | 954/3121 [05:28<00:58, 36.93it/s]
 31%|###       | 958/3121 [05:28<00:58, 36.92it/s]
 31%|###       | 963/3121 [05:28<00:55, 39.16it/s]
 31%|###1      | 968/3121 [05:28<00:53, 40.22it/s]
 31%|###1      | 973/3121 [05:29<00:52, 41.12it/s]
 31%|###1      | 978/3121 [05:29<00:49, 43.09it/s]
 32%|###1      | 984/3121 [05:29<00:46, 46.26it/s]
 32%|###1      | 989/3121 [05:29<00:45, 46.55it/s]
 32%|###1      | 994/3121 [05:29<00:46, 46.03it/s]
 32%|###2      | 999/3121 [05:29<00:46, 45.55it/s]
 32%|###2      | 1004/3121 [05:29<00:46, 45.42it/s]
 32%|###2      | 1009/3121 [05:29<00:45, 46.06it/s]
 33%|###2      | 1015/3121 [05:29<00:42, 49.04it/s]
 33%|###2      | 1021/3121 [05:30<00:41, 50.49it/s]
 33%|###2      | 1027/3121 [05:30<00:39, 52.92it/s]
 33%|###3      | 1034/3121 [05:30<00:37, 55.50it/s]
 33%|###3      | 1040/3121 [05:30<00:36, 56.69it/s]
 34%|###3      | 1047/3121 [05:30<00:35, 57.62it/s]
 34%|###3      | 1053/3121 [05:30<00:35, 57.73it/s]
 34%|###3      | 1060/3121 [05:30<00:34, 59.26it/s]
 34%|###4      | 1066/3121 [05:30<00:34, 59.30it/s]
 34%|###4      | 1072/3121 [05:30<00:36, 56.33it/s]
 35%|###4      | 1079/3121 [05:30<00:35, 57.62it/s]
 35%|###4      | 1086/3121 [05:31<00:34, 58.77it/s]
 35%|###5      | 1093/3121 [05:31<00:34, 58.93it/s]
 35%|###5      | 1099/3121 [05:31<00:34, 59.08it/s]
 35%|###5      | 1105/3121 [05:31<00:34, 58.45it/s]
 36%|###5      | 1111/3121 [05:31<00:35, 55.98it/s]
 36%|###5      | 1117/3121 [05:31<00:37, 52.99it/s]
 36%|###5      | 1123/3121 [05:31<00:40, 48.92it/s]
 36%|###6      | 1128/3121 [05:31<00:45, 43.46it/s]
 36%|###6      | 1133/3121 [05:32<00:44, 44.73it/s]
 36%|###6      | 1138/3121 [05:32<00:44, 44.67it/s]
 37%|###6      | 1143/3121 [05:32<00:43, 45.38it/s]
 37%|###6      | 1149/3121 [05:32<00:41, 47.83it/s]
 37%|###7      | 1156/3121 [05:32<00:38, 51.48it/s]
 37%|###7      | 1163/3121 [05:32<00:36, 54.29it/s]
 37%|###7      | 1169/3121 [05:32<00:35, 55.52it/s]
 38%|###7      | 1175/3121 [05:32<00:37, 52.30it/s]
 38%|###7      | 1181/3121 [05:33<00:37, 51.07it/s]
 38%|###8      | 1187/3121 [05:33<00:36, 53.35it/s]
 38%|###8      | 1193/3121 [05:33<00:36, 53.25it/s]
 38%|###8      | 1199/3121 [05:33<00:35, 54.87it/s]
 39%|###8      | 1206/3121 [05:33<00:33, 57.10it/s]
 39%|###8      | 1212/3121 [05:33<00:33, 57.68it/s]
 39%|###9      | 1218/3121 [05:33<00:32, 57.73it/s]
 39%|###9      | 1225/3121 [05:33<00:33, 55.80it/s]
 39%|###9      | 1231/3121 [05:33<00:34, 55.29it/s]
 40%|###9      | 1237/3121 [05:33<00:34, 54.90it/s]
 40%|###9      | 1243/3121 [05:34<00:33, 55.71it/s]
 40%|####      | 1249/3121 [05:34<00:36, 51.39it/s]
 40%|####      | 1256/3121 [05:34<00:34, 54.17it/s]
 40%|####      | 1262/3121 [05:34<00:35, 52.51it/s]
 41%|####      | 1268/3121 [05:34<00:34, 54.25it/s]
 41%|####      | 1274/3121 [05:34<00:33, 54.54it/s]
 41%|####1     | 1280/3121 [05:34<00:33, 54.97it/s]
 41%|####1     | 1286/3121 [05:34<00:33, 54.58it/s]
 41%|####1     | 1292/3121 [05:35<00:32, 55.71it/s]
 42%|####1     | 1298/3121 [05:35<00:33, 54.40it/s]
 42%|####1     | 1304/3121 [05:35<00:33, 53.60it/s]
 42%|####2     | 1311/3121 [05:35<00:32, 55.92it/s]
 42%|####2     | 1317/3121 [05:35<00:33, 53.69it/s]
 42%|####2     | 1323/3121 [05:35<00:33, 54.27it/s]
 43%|####2     | 1329/3121 [05:35<00:32, 55.12it/s]
 43%|####2     | 1336/3121 [05:35<00:31, 57.20it/s]
 43%|####2     | 1342/3121 [05:35<00:31, 56.25it/s]
 43%|####3     | 1348/3121 [05:36<00:32, 53.84it/s]
 43%|####3     | 1354/3121 [05:36<00:33, 52.70it/s]
 44%|####3     | 1360/3121 [05:36<00:34, 51.37it/s]
 44%|####3     | 1366/3121 [05:36<00:36, 48.43it/s]
 44%|####3     | 1371/3121 [05:36<00:37, 46.74it/s]
 44%|####4     | 1376/3121 [05:36<00:37, 46.18it/s]
 44%|####4     | 1381/3121 [05:36<00:38, 44.68it/s]
 44%|####4     | 1386/3121 [05:36<00:38, 44.51it/s]
 45%|####4     | 1391/3121 [05:36<00:37, 45.87it/s]
 45%|####4     | 1398/3121 [05:37<00:34, 50.31it/s]
 45%|####4     | 1398/3121 [05:52<00:34, 50.31it/s]
 45%|####4     | 1399/3121 [06:09<1:05:41,  2.29s/it]
 45%|####5     | 1405/3121 [06:09<41:10,  1.44s/it]
 45%|####5     | 1412/3121 [06:09<25:26,  1.12it/s]
 45%|####5     | 1418/3121 [06:10<17:23,  1.63it/s]
 46%|####5     | 1425/3121 [06:10<11:28,  2.47it/s]
 46%|####5     | 1431/3121 [06:10<08:10,  3.44it/s]
 46%|####6     | 1437/3121 [06:10<05:51,  4.79it/s]
 46%|####6     | 1444/3121 [06:10<04:02,  6.92it/s]
 46%|####6     | 1450/3121 [06:10<02:59,  9.29it/s]
 47%|####6     | 1457/3121 [06:10<02:09, 12.84it/s]
 47%|####6     | 1463/3121 [06:10<01:40, 16.46it/s]
 47%|####7     | 1469/3121 [06:10<01:19, 20.78it/s]
 47%|####7     | 1476/3121 [06:10<01:01, 26.63it/s]
 48%|####7     | 1483/3121 [06:11<00:50, 32.35it/s]
 48%|####7     | 1490/3121 [06:11<00:43, 37.78it/s]
 48%|####7     | 1497/3121 [06:11<00:38, 42.70it/s]
 48%|####8     | 1504/3121 [06:11<00:34, 46.51it/s]
 48%|####8     | 1511/3121 [06:11<00:32, 50.23it/s]
 49%|####8     | 1518/3121 [06:11<00:30, 52.72it/s]
 49%|####8     | 1524/3121 [06:11<00:29, 54.36it/s]
 49%|####9     | 1531/3121 [06:11<00:28, 56.15it/s]
 49%|####9     | 1538/3121 [06:12<00:27, 57.36it/s]
 49%|####9     | 1540/3121 [06:22<00:27, 57.36it/s]
 49%|####9     | 1541/3121 [06:44<45:09,  1.71s/it]
 50%|####9     | 1546/3121 [06:44<32:50,  1.25s/it]
 50%|####9     | 1552/3121 [06:44<22:27,  1.16it/s]
 50%|####9     | 1558/3121 [06:44<15:36,  1.67it/s]
 50%|#####     | 1563/3121 [06:44<11:29,  2.26it/s]
 50%|#####     | 1568/3121 [06:44<08:25,  3.07it/s]
 50%|#####     | 1573/3121 [06:45<06:10,  4.18it/s]
 51%|#####     | 1578/3121 [06:45<04:32,  5.66it/s]
 51%|#####     | 1583/3121 [06:45<03:21,  7.63it/s]
 51%|#####     | 1583/3121 [07:02<03:21,  7.63it/s]
 51%|#####     | 1584/3121 [07:17<1:06:05,  2.58s/it]
 51%|#####     | 1589/3121 [07:17<42:40,  1.67s/it]
 51%|#####1    | 1594/3121 [07:17<28:23,  1.12s/it]
 51%|#####1    | 1599/3121 [07:17<19:17,  1.32it/s]
 51%|#####1    | 1604/3121 [07:17<13:19,  1.90it/s]
 52%|#####1    | 1608/3121 [07:32<13:17,  1.90it/s]
 52%|#####1    | 1609/3121 [07:49<59:50,  2.37s/it]
 52%|#####1    | 1610/3121 [08:23<2:03:21,  4.90s/it]
 52%|#####1    | 1616/3121 [08:23<1:12:25,  2.89s/it]
 52%|#####1    | 1622/3121 [08:23<45:33,  1.82s/it]
 52%|#####2    | 1628/3121 [08:23<29:48,  1.20s/it]
 52%|#####2    | 1635/3121 [08:23<18:58,  1.31it/s]
 53%|#####2    | 1641/3121 [08:23<13:10,  1.87it/s]
 53%|#####2    | 1648/3121 [08:23<08:47,  2.79it/s]
 53%|#####2    | 1654/3121 [08:23<06:19,  3.87it/s]
 53%|#####3    | 1661/3121 [08:23<04:21,  5.59it/s]
 53%|#####3    | 1667/3121 [08:24<03:12,  7.55it/s]
 54%|#####3    | 1673/3121 [08:24<02:23, 10.11it/s]
 54%|#####3    | 1679/3121 [08:24<01:48, 13.32it/s]
 54%|#####3    | 1685/3121 [08:24<01:23, 17.24it/s]
 54%|#####4    | 1691/3121 [08:24<01:06, 21.41it/s]
 54%|#####4    | 1697/3121 [08:24<00:55, 25.76it/s]
 55%|#####4    | 1703/3121 [08:24<00:45, 31.05it/s]
 55%|#####4    | 1709/3121 [08:24<00:39, 35.42it/s]
 55%|#####4    | 1716/3121 [08:24<00:34, 41.13it/s]
 55%|#####5    | 1723/3121 [08:25<00:30, 45.89it/s]
 55%|#####5    | 1729/3121 [08:25<00:28, 49.03it/s]
 56%|#####5    | 1735/3121 [08:25<00:26, 51.62it/s]
 56%|#####5    | 1742/3121 [08:25<00:25, 54.23it/s]
 56%|#####6    | 1749/3121 [08:25<00:24, 56.10it/s]
 56%|#####6    | 1756/3121 [08:25<00:23, 57.44it/s]
 56%|#####6    | 1762/3121 [08:25<00:25, 54.03it/s]
 57%|#####6    | 1768/3121 [08:25<00:24, 54.26it/s]
 57%|#####6    | 1775/3121 [08:25<00:23, 56.67it/s]
 57%|#####7    | 1781/3121 [08:26<00:23, 56.34it/s]
 57%|#####7    | 1787/3121 [08:26<00:23, 55.92it/s]
 57%|#####7    | 1793/3121 [08:26<00:25, 52.55it/s]
 58%|#####7    | 1799/3121 [08:26<00:24, 54.04it/s]
 58%|#####7    | 1805/3121 [08:26<00:24, 52.79it/s]
 58%|#####8    | 1811/3121 [08:26<00:26, 50.38it/s]
 58%|#####8    | 1818/3121 [08:26<00:24, 53.34it/s]
 58%|#####8    | 1824/3121 [08:26<00:24, 52.54it/s]
 59%|#####8    | 1830/3121 [08:26<00:25, 51.54it/s]
 59%|#####8    | 1836/3121 [08:27<00:26, 48.61it/s]
 59%|#####8    | 1841/3121 [08:27<00:27, 46.95it/s]
 59%|#####9    | 1846/3121 [08:27<00:26, 47.23it/s]
 59%|#####9    | 1852/3121 [08:27<00:25, 49.08it/s]
 60%|#####9    | 1858/3121 [08:27<00:25, 50.27it/s]
 60%|#####9    | 1864/3121 [08:27<00:25, 48.75it/s]
 60%|#####9    | 1869/3121 [08:27<00:26, 47.67it/s]
 60%|######    | 1875/3121 [08:27<00:25, 48.87it/s]
 60%|######    | 1882/3121 [08:28<00:23, 52.84it/s]
 60%|######    | 1888/3121 [08:28<00:22, 54.07it/s]
 61%|######    | 1894/3121 [08:28<00:22, 53.46it/s]
 61%|######    | 1900/3121 [08:28<00:23, 52.85it/s]
 61%|######1   | 1906/3121 [08:28<00:23, 51.54it/s]
 61%|######1   | 1912/3121 [08:28<00:23, 52.01it/s]
 61%|######1   | 1918/3121 [08:28<00:24, 49.94it/s]
 62%|######1   | 1924/3121 [08:28<00:24, 49.67it/s]
 62%|######1   | 1929/3121 [08:28<00:25, 47.65it/s]
 62%|######1   | 1934/3121 [08:29<00:25, 46.75it/s]
 62%|######2   | 1939/3121 [08:29<00:25, 46.55it/s]
 62%|######2   | 1945/3121 [08:29<00:23, 49.86it/s]
 63%|######2   | 1951/3121 [08:29<00:22, 52.10it/s]
 63%|######2   | 1957/3121 [08:29<00:22, 51.97it/s]
 63%|######2   | 1964/3121 [08:29<00:21, 54.93it/s]
 63%|######3   | 1970/3121 [08:29<00:22, 52.27it/s]
 63%|######3   | 1976/3121 [08:29<00:22, 51.00it/s]
 64%|######3   | 1982/3121 [08:29<00:21, 53.13it/s]
 64%|######3   | 1988/3121 [08:30<00:21, 53.83it/s]
 64%|######3   | 1994/3121 [08:30<00:20, 54.55it/s]
 64%|######4   | 2001/3121 [08:30<00:19, 56.50it/s]
 64%|######4   | 2007/3121 [08:30<00:19, 56.12it/s]
 65%|######4   | 2014/3121 [08:30<00:18, 58.84it/s]
 65%|######4   | 2020/3121 [08:30<00:18, 58.90it/s]
 65%|######4   | 2026/3121 [08:30<00:18, 59.15it/s]
 65%|######5   | 2033/3121 [08:30<00:18, 59.59it/s]
 65%|######5   | 2039/3121 [08:30<00:18, 59.39it/s]
 66%|######5   | 2046/3121 [08:31<00:17, 59.95it/s]
 66%|######5   | 2052/3121 [08:31<00:17, 59.71it/s]
 66%|######5   | 2058/3121 [08:31<00:17, 59.67it/s]
 66%|######6   | 2065/3121 [08:31<00:17, 59.26it/s]
 66%|######6   | 2072/3121 [08:31<00:17, 60.12it/s]
 67%|######6   | 2079/3121 [08:31<00:18, 57.85it/s]
 67%|######6   | 2085/3121 [08:31<00:18, 55.38it/s]
 67%|######6   | 2091/3121 [08:31<00:19, 53.57it/s]
 67%|######7   | 2097/3121 [08:32<00:19, 52.84it/s]
 67%|######7   | 2103/3121 [08:32<00:19, 50.93it/s]
 68%|######7   | 2109/3121 [08:32<00:20, 50.34it/s]
 68%|######7   | 2115/3121 [08:32<00:20, 48.84it/s]
 68%|######7   | 2120/3121 [08:32<00:21, 47.65it/s]
 68%|######8   | 2125/3121 [08:32<00:21, 46.01it/s]
 68%|######8   | 2130/3121 [08:32<00:22, 44.19it/s]
 68%|######8   | 2135/3121 [08:32<00:21, 45.07it/s]
 69%|######8   | 2140/3121 [08:32<00:21, 44.93it/s]
 69%|######8   | 2145/3121 [08:33<00:22, 43.61it/s]
 69%|######8   | 2150/3121 [08:33<00:22, 42.29it/s]
 69%|######9   | 2155/3121 [08:33<00:22, 42.76it/s]
 69%|######9   | 2160/3121 [08:33<00:23, 41.76it/s]
 69%|######9   | 2165/3121 [08:33<00:22, 42.86it/s]
 70%|######9   | 2170/3121 [08:33<00:21, 44.15it/s]
 70%|######9   | 2176/3121 [08:33<00:19, 47.34it/s]
 70%|######9   | 2182/3121 [08:33<00:19, 48.30it/s]
 70%|#######   | 2187/3121 [08:34<00:20, 44.86it/s]
 70%|#######   | 2192/3121 [08:34<00:21, 43.12it/s]
 70%|#######   | 2197/3121 [08:34<00:21, 42.01it/s]
 71%|#######   | 2203/3121 [08:34<00:20, 44.84it/s]
 71%|#######   | 2208/3121 [08:34<00:19, 45.92it/s]
 71%|#######   | 2213/3121 [08:34<00:19, 46.78it/s]
 71%|#######1  | 2219/3121 [08:34<00:18, 49.15it/s]
 71%|#######1  | 2225/3121 [08:34<00:17, 50.54it/s]
 71%|#######1  | 2231/3121 [08:34<00:16, 52.63it/s]
 72%|#######1  | 2237/3121 [08:35<00:17, 50.72it/s]
 72%|#######1  | 2243/3121 [08:35<00:18, 48.38it/s]
 72%|#######2  | 2249/3121 [08:35<00:17, 51.05it/s]
 72%|#######2  | 2256/3121 [08:35<00:15, 54.32it/s]
 73%|#######2  | 2263/3121 [08:35<00:15, 56.46it/s]
 73%|#######2  | 2269/3121 [08:35<00:14, 56.96it/s]
 73%|#######2  | 2276/3121 [08:35<00:14, 58.37it/s]
 73%|#######3  | 2282/3121 [08:35<00:14, 58.79it/s]
 73%|#######3  | 2288/3121 [08:35<00:14, 59.04it/s]
 74%|#######3  | 2294/3121 [08:36<00:13, 59.29it/s]
 74%|#######3  | 2300/3121 [08:36<00:13, 58.84it/s]
 74%|#######3  | 2307/3121 [08:36<00:13, 60.13it/s]
 74%|#######4  | 2314/3121 [08:36<00:13, 59.19it/s]
 74%|#######4  | 2320/3121 [08:36<00:13, 57.71it/s]
 75%|#######4  | 2326/3121 [08:36<00:13, 57.92it/s]
 75%|#######4  | 2332/3121 [08:36<00:13, 58.18it/s]
 75%|#######4  | 2339/3121 [08:36<00:13, 59.28it/s]
 75%|#######5  | 2345/3121 [08:36<00:13, 58.60it/s]
 75%|#######5  | 2351/3121 [08:37<00:13, 58.88it/s]
 76%|#######5  | 2357/3121 [08:37<00:14, 51.10it/s]
 76%|#######5  | 2363/3121 [08:37<00:14, 51.60it/s]
 76%|#######5  | 2369/3121 [08:37<00:14, 51.29it/s]
 76%|#######6  | 2375/3121 [08:37<00:14, 52.37it/s]
 76%|#######6  | 2381/3121 [08:37<00:13, 54.03it/s]
 76%|#######6  | 2387/3121 [08:37<00:13, 55.41it/s]
 77%|#######6  | 2394/3121 [08:37<00:12, 57.56it/s]
 77%|#######6  | 2401/3121 [08:37<00:12, 58.43it/s]
 77%|#######7  | 2407/3121 [08:38<00:12, 58.14it/s]
 77%|#######7  | 2413/3121 [08:38<00:12, 58.55it/s]
 78%|#######7  | 2419/3121 [08:38<00:11, 58.83it/s]
 78%|#######7  | 2425/3121 [08:38<00:11, 59.03it/s]
 78%|#######7  | 2431/3121 [08:38<00:11, 57.84it/s]
 78%|#######8  | 2437/3121 [08:38<00:11, 58.03it/s]
 78%|#######8  | 2444/3121 [08:38<00:11, 58.94it/s]
 79%|#######8  | 2450/3121 [08:38<00:11, 58.17it/s]
 79%|#######8  | 2457/3121 [08:38<00:11, 58.91it/s]
 79%|#######8  | 2463/3121 [08:38<00:11, 59.05it/s]
 79%|#######9  | 2470/3121 [08:39<00:10, 60.59it/s]
 79%|#######9  | 2477/3121 [08:39<00:10, 58.65it/s]
 80%|#######9  | 2484/3121 [08:39<00:10, 59.84it/s]
 80%|#######9  | 2490/3121 [08:39<00:10, 59.72it/s]
 80%|#######9  | 2496/3121 [08:39<00:10, 59.58it/s]
 80%|########  | 2502/3121 [08:39<00:10, 57.42it/s]
 80%|########  | 2508/3121 [08:39<00:11, 54.24it/s]
 81%|########  | 2514/3121 [08:39<00:11, 51.81it/s]
 81%|########  | 2520/3121 [08:40<00:12, 47.18it/s]
 81%|########  | 2525/3121 [08:40<00:12, 46.02it/s]
 81%|########1 | 2530/3121 [08:40<00:13, 42.65it/s]
 81%|########1 | 2535/3121 [08:40<00:13, 43.42it/s]
 81%|########1 | 2540/3121 [08:40<00:13, 44.37it/s]
 82%|########1 | 2545/3121 [08:40<00:12, 44.76it/s]
 82%|########1 | 2550/3121 [08:40<00:12, 43.93it/s]
 82%|########1 | 2555/3121 [08:40<00:12, 43.90it/s]
 82%|########2 | 2560/3121 [08:40<00:12, 44.06it/s]
 82%|########2 | 2565/3121 [08:41<00:12, 43.56it/s]
 82%|########2 | 2570/3121 [08:41<00:12, 43.25it/s]
 83%|########2 | 2575/3121 [08:41<00:12, 42.80it/s]
 83%|########2 | 2580/3121 [08:41<00:12, 42.74it/s]
 83%|########2 | 2585/3121 [08:41<00:12, 43.33it/s]
 83%|########2 | 2590/3121 [08:41<00:11, 44.48it/s]
 83%|########3 | 2595/3121 [08:41<00:11, 44.85it/s]
 83%|########3 | 2601/3121 [08:41<00:10, 48.18it/s]
 83%|########3 | 2606/3121 [08:42<00:11, 46.72it/s]
 84%|########3 | 2611/3121 [08:42<00:11, 45.22it/s]
 84%|########3 | 2616/3121 [08:42<00:11, 44.42it/s]
 84%|########3 | 2621/3121 [08:42<00:11, 43.62it/s]
 84%|########4 | 2626/3121 [08:42<00:11, 43.72it/s]
 84%|########4 | 2632/3121 [08:42<00:10, 46.54it/s]
 85%|########4 | 2638/3121 [08:42<00:09, 48.97it/s]
 85%|########4 | 2644/3121 [08:42<00:09, 51.60it/s]
 85%|########4 | 2650/3121 [08:42<00:08, 52.78it/s]
 85%|########5 | 2656/3121 [08:43<00:08, 52.52it/s]
 85%|########5 | 2663/3121 [08:43<00:08, 54.15it/s]
 86%|########5 | 2669/3121 [08:43<00:08, 53.23it/s]
 86%|########5 | 2675/3121 [08:43<00:08, 53.85it/s]
 86%|########5 | 2681/3121 [08:43<00:08, 54.84it/s]
 86%|########6 | 2687/3121 [08:43<00:07, 54.30it/s]
 86%|########6 | 2693/3121 [08:43<00:07, 54.03it/s]
 86%|########6 | 2699/3121 [08:43<00:07, 55.66it/s]
 87%|########6 | 2705/3121 [08:43<00:07, 55.52it/s]
 87%|########6 | 2711/3121 [08:44<00:07, 55.27it/s]
 87%|########7 | 2718/3121 [08:44<00:07, 57.10it/s]
 87%|########7 | 2724/3121 [08:44<00:06, 57.48it/s]
 87%|########7 | 2730/3121 [08:44<00:06, 57.68it/s]
 88%|########7 | 2736/3121 [08:44<00:06, 55.61it/s]
 88%|########7 | 2743/3121 [08:44<00:06, 56.64it/s]
 88%|########8 | 2749/3121 [08:44<00:06, 55.58it/s]
 88%|########8 | 2755/3121 [08:44<00:06, 54.85it/s]
 88%|########8 | 2761/3121 [08:44<00:06, 55.88it/s]
 89%|########8 | 2767/3121 [08:45<00:06, 56.67it/s]
 89%|########8 | 2773/3121 [08:45<00:06, 55.40it/s]
 89%|########9 | 2779/3121 [08:45<00:06, 55.58it/s]
 89%|########9 | 2785/3121 [08:45<00:06, 55.70it/s]
 89%|########9 | 2792/3121 [08:45<00:05, 56.78it/s]
 90%|########9 | 2798/3121 [08:45<00:05, 54.98it/s]
 90%|########9 | 2804/3121 [08:45<00:05, 53.62it/s]
 90%|######### | 2810/3121 [08:45<00:05, 52.17it/s]
 90%|######### | 2816/3121 [08:45<00:05, 53.22it/s]
 90%|######### | 2822/3121 [08:46<00:05, 52.12it/s]
 91%|######### | 2828/3121 [08:46<00:05, 50.53it/s]
 91%|######### | 2834/3121 [08:46<00:06, 47.66it/s]
 91%|######### | 2839/3121 [08:46<00:06, 45.78it/s]
 91%|#########1| 2844/3121 [08:46<00:06, 44.32it/s]
 91%|#########1| 2849/3121 [08:46<00:06, 43.27it/s]
 91%|#########1| 2854/3121 [08:46<00:06, 43.26it/s]
 92%|#########1| 2859/3121 [08:46<00:06, 42.79it/s]
 92%|#########1| 2864/3121 [08:47<00:06, 42.27it/s]
 92%|#########1| 2869/3121 [08:47<00:06, 41.73it/s]
 92%|#########2| 2874/3121 [08:47<00:06, 40.29it/s]
 92%|#########2| 2879/3121 [08:47<00:05, 41.48it/s]
 92%|#########2| 2884/3121 [08:47<00:05, 41.25it/s]
 93%|#########2| 2889/3121 [08:47<00:05, 42.06it/s]
 93%|#########2| 2894/3121 [08:47<00:05, 41.93it/s]
 93%|#########2| 2899/3121 [08:47<00:05, 42.02it/s]
 93%|#########3| 2904/3121 [08:47<00:05, 42.99it/s]
 93%|#########3| 2910/3121 [08:48<00:04, 45.22it/s]
 93%|#########3| 2916/3121 [08:48<00:04, 47.70it/s]
 94%|#########3| 2922/3121 [08:48<00:03, 49.81it/s]
 94%|#########3| 2928/3121 [08:48<00:03, 50.45it/s]
 94%|#########4| 2934/3121 [08:48<00:03, 51.32it/s]
 94%|#########4| 2940/3121 [08:48<00:03, 51.75it/s]
 94%|#########4| 2946/3121 [08:48<00:03, 53.32it/s]
 95%|#########4| 2952/3121 [08:48<00:03, 55.15it/s]
 95%|#########4| 2958/3121 [08:48<00:02, 54.75it/s]
 95%|#########4| 2964/3121 [08:49<00:02, 55.27it/s]
 95%|#########5| 2970/3121 [08:49<00:02, 54.55it/s]
 95%|#########5| 2976/3121 [08:49<00:02, 55.20it/s]
 96%|#########5| 2982/3121 [08:49<00:02, 54.86it/s]
 96%|#########5| 2988/3121 [08:49<00:02, 56.19it/s]
 96%|#########5| 2994/3121 [08:49<00:02, 55.54it/s]
 96%|#########6| 3000/3121 [08:49<00:02, 53.36it/s]
 96%|#########6| 3006/3121 [08:49<00:02, 53.89it/s]
 97%|#########6| 3012/3121 [08:49<00:01, 54.66it/s]
 97%|#########6| 3018/3121 [08:50<00:02, 50.51it/s]
 97%|#########6| 3024/3121 [08:50<00:01, 51.41it/s]
 97%|#########7| 3030/3121 [08:50<00:01, 51.86it/s]
 97%|#########7| 3036/3121 [08:50<00:01, 51.48it/s]
 97%|#########7| 3042/3121 [08:50<00:01, 53.63it/s]
 98%|#########7| 3048/3121 [08:50<00:01, 55.35it/s]
 98%|#########7| 3054/3121 [08:50<00:01, 56.12it/s]
 98%|#########7| 3056/3121 [09:02<00:01, 56.12it/s]
 98%|#########7| 3057/3121 [09:25<02:10,  2.04s/it]
 98%|#########8| 3063/3121 [09:25<01:18,  1.36s/it]
 98%|#########8| 3069/3121 [09:25<00:48,  1.08it/s]
 99%|#########8| 3075/3121 [09:25<00:29,  1.56it/s]
 99%|#########8| 3082/3121 [09:25<00:16,  2.35it/s]
 99%|#########8| 3085/3121 [09:42<00:15,  2.35it/s]
 99%|#########8| 3086/3121 [09:56<01:11,  2.04s/it]
 99%|#########9| 3092/3121 [09:56<00:40,  1.40s/it]
 99%|#########9| 3099/3121 [09:57<00:20,  1.09it/s]
 99%|#########9| 3105/3121 [09:57<00:10,  1.55it/s]
 99%|#########9| 3105/3121 [10:12<00:10,  1.55it/s]
100%|#########9| 3106/3121 [10:30<00:41,  2.80s/it]
100%|#########9| 3108/3121 [11:02<01:04,  4.96s/it]
100%|#########9| 3112/3121 [11:02<00:30,  3.42s/it]
100%|#########9| 3114/3121 [11:22<00:23,  3.42s/it]
100%|#########9| 3115/3121 [11:36<00:31,  5.32s/it]
100%|#########9| 3116/3121 [12:07<00:40,  8.08s/it]
100%|#########9| 3118/3121 [12:38<00:29,  9.81s/it]
100%|##########| 3121/3121 [13:09<00:00,  9.98s/it]
100%|##########| 3121/3121 [13:09<00:00,  3.96it/s]
examples_built/07_reconstruction/Kurtosis_tensor_standard_measures_noisy.png

DKI standard kurtosis measures obtained on unsmoothed data with constrained optimization.

Mean kurtosis tensor and kurtosis fractional anisotropy

As pointed by previous studies [Hansen2013], axial, radial and mean kurtosis depends on the information of both diffusion and kurtosis tensor. DKI measures that only depend on the kurtosis tensor include the mean of the kurtosis tensor [Hansen2013], and the kurtosis fractional anisotropy [GlennR2015]. These measures are computed and illustrated below:

compare_maps([dkifit_plus], ['mkt', 'kfa'], fit_labels=['DKI+'],
             map_kwargs=[{'vmin': 0, 'vmax': 1.5}, {'vmin': 0, 'vmax': 1}],
             filename='Measures_from_kurtosis_tensor_only.png')
reconst dki
examples_built/07_reconstruction/Measures_from_kurtosis_tensor_only.png

DKI measures obtained from the kurtosis tensor only.

As reported by [Hansen2013], the mean of the kurtosis tensor (MKT) produces similar maps than the standard mean kurtosis (MK). On the other hand, the kurtosis fractional anisotropy (KFA) maps shows that the kurtosis tensor have different degrees of anisotropy than the FA measures from the diffusion tensor.

References

[Jensen2005] (1,2)

Jensen JH, Helpern JA, Ramani A, Lu H, Kaczynski K (2005). Diffusional Kurtosis Imaging: The Quantification of Non_Gaussian Water Diffusion by Means of Magnetic Resonance Imaging. Magnetic Resonance in Medicine 53: 1432-1440

[Jensen2010]

Jensen JH, Helpern JA (2010). MRI quantification of non-Gaussian water diffusion by kurtosis analysis. NMR in Biomedicine 23(7): 698-710

[Fierem2011]

Fieremans E, Jensen JH, Helpern JA (2011). White matter characterization with diffusion kurtosis imaging. NeuroImage 58: 177-188

[Veraar2011]

Veraart J, Poot DH, Van Hecke W, Blockx I, Van der Linden A, Verhoye M, Sijbers J (2011). More Accurate Estimation of Diffusion Tensor Parameters Using Diffusion Kurtosis Imaging. Magnetic Resonance in Medicine 65(1): 138-145

[NetoHe2012] (1,2,3,4)

Neto Henriques R, Ferreira H, Correia M, (2012). Diffusion kurtosis imaging of the healthy human brain. Master Dissertation Bachelor and Master Programin Biomedical Engineering and Biophysics, Faculty of Sciences. http://repositorio.ul.pt/bitstream/10451/8511/1/ulfc104137_tm_Rafael_Henriques.pdf

[Hansen2013] (1,2,3)

Hansen B, Lund TE, Sangill R, and Jespersen SN (2013). Experimentally and computationally393fast method for estimation of a mean kurtosis. Magnetic Resonance in Medicine 69, 1754–1760.394doi:10.1002/mrm.24743

[GlennR2015]

Glenn GR, Helpern JA, Tabesh A, Jensen JH (2015). Quantitative assessment of diffusional387kurtosis anisotropy. NMR in Biomedicine28, 448–459. doi:10.1002/nbm.3271

[NetoHe2015]

Neto Henriques R, Correia MM, Nunes RG, Ferreira HA (2015). Exploring the 3D geometry of the diffusion kurtosis tensor - Impact on the development of robust tractography procedures and novel biomarkers, NeuroImage 111: 85-99

[Perron2015]

Perrone D, Aelterman J, Pižurica A, Jeurissen B, Philips W, Leemans A, (2015). The effect of Gibbs ringing artifacts on measures derived from diffusion MRI. Neuroimage 120, 441-455. https://doi.org/10.1016/j.neuroimage.2015.06.068.

[TaxCMW2015]

Tax CMW, Otte WM, Viergever MA, Dijkhuizen RM, Leemans A (2014). REKINDLE: Robust extraction of kurtosis INDices with linear estimation. Magnetic Resonance in Medicine 73(2): 794-808.

[Hansen2016]

Hansen, B, Jespersen, SN (2016). Data for evaluation of fast kurtosis strategies, b-value optimization and exploration of diffusion MRI contrast. Scientific Data 3: 160072 doi:10.1038/sdata.2016.72

[NetoHe2018]

Neto Henriques R (2018). Advanced Methods for Diffusion MRI Data Analysis and their Application to the Healthy Ageing Brain (Doctoral thesis). https://doi.org/10.17863/CAM.29356

[DelaHa2020] (1,2)

Dela Haije et al. “Enforcing necessary non-negativity constraints for common diffusion MRI models using sum of squares programming”. NeuroImage 209, 2020, 116405.

Total running time of the script: ( 15 minutes 19.446 seconds)

Gallery generated by Sphinx-Gallery