Module Expr Str ImportFrom alias Import alias identifier ImportFrom alias ImportFrom alias alias ImportFrom alias ImportFrom alias Assign NameStore Dict TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str AttributeLoad NameLoad attr AttributeLoad NameLoad attr Str AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore Dict Str Str Str ListLoad Num Num Num ListLoad Num Num Num ListLoad Num Num Num ClassDef bases NameLoad body Expr Str decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr SubscriptLoad AttributeLoad NameLoad attr Index Str Assign AttributeStore NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr Assign AttributeStore NameLoad attr ListComp SubscriptLoad AttributeLoad AttributeLoad NameLoad attr attr Index NameLoad comprehension NameStore AttributeLoad NameLoad attr For NameStore AttributeLoad NameLoad attr body If CompareNotEq AttributeLoad NameLoad attr Str body Raise Call NameLoad Str Assign AttributeStore NameLoad attr ListComp NameLoad comprehension NameStore AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Str Assign AttributeStore NameLoad attr SubscriptLoad AttributeLoad AttributeLoad NameLoad attr attr Index Str Assign AttributeStore NameLoad attr SubscriptLoad AttributeLoad AttributeLoad NameLoad attr attr Index Str decorator_list FunctionDef arguments args NameParam NameParam defaults body Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr If CompareEq NameLoad Str body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr orelse If CompareEq NameLoad Str body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr orelse Assign NameStore Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str Assign NameStore SubscriptLoad NameLoad Index TupleLoad NameLoad NameLoad Return Call AttributeLoad Call AttributeLoad NameLoad attr NameLoad attr Str decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Return Call NameLoad ListComp Call NameLoad Call NameLoad AttributeLoad NameLoad attr comprehension NameStore AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr TupleLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr TupleLoad NameLoad Assign NameStore Call NameLoad AttributeLoad NameLoad attr For TupleStore NameStore NameStore Call NameLoad AttributeLoad NameLoad attr body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Call AttributeLoad NameLoad attr NameLoad TryExcept body Assign NameStore AttributeLoad NameLoad attr handlers ExceptHandler type NameLoad body Assign NameStore SubscriptLoad NameLoad Index NameLoad Assign SubscriptStore NameLoad ExtSlice Slice Index NameLoad NameLoad Assign SubscriptStore NameLoad Index NameLoad AttributeLoad NameLoad attr Assign SubscriptStore NameLoad Index NameLoad AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr BinOpAdd NameLoad Num Assign SubscriptStore NameLoad ExtSlice Slice NameLoad Slice NameLoad BinOpMult NameLoad NameLoad Assign SubscriptStore NameLoad ExtSlice Slice NameLoad Index NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr TryExcept body Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr handlers ExceptHandler type NameLoad body TryExcept body Assign NameStore ListLoad AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad AttributeLoad NameLoad attr attr handlers ExceptHandler type NameLoad body Assign NameStore ListLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr If BoolOpOr CompareLt SubscriptLoad NameLoad Index Num AttributeLoad NameLoad attr CompareGt SubscriptLoad NameLoad Index Num AttributeLoad NameLoad attr body Raise Call NameLoad Str Return Call AttributeLoad NameLoad attr NameLoad keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Return Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults TupleLoad body Expr Str Assign NameStore Call AttributeLoad NameLoad attr If CompareIn AttributeLoad NameLoad attr SubscriptLoad AttributeLoad NameLoad attr Index Str body Return NameLoad Assign NameStore AttributeLoad NameLoad attr Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad If CompareNotEq NameLoad NameLoad body Raise Call NameLoad Str Assign NameStore Call NameLoad NameLoad If CompareGt NameLoad Num body Raise Call NameLoad Str If CompareNotEq NameLoad SubscriptLoad AttributeLoad NameLoad attr Slice NameLoad body Raise Call NameLoad Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad If CompareEq NameLoad Num body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad orelse Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call NameLoad NameLoad NameLoad Assign NameStore ListComp NameLoad comprehension TupleStore NameStore NameStore Call NameLoad NameLoad CompareIsNot NameLoad NameLoad Assert CompareEq Call NameLoad NameLoad Call NameLoad NameLoad Assign NameStore SubscriptLoad NameLoad Index NameLoad Assign NameStore SubscriptLoad NameLoad Slice NameLoad Assign NameStore Call NameLoad GeneratorExp NameLoad comprehension NameStore SubscriptLoad NameLoad Slice SubscriptLoad NameLoad Index NameLoad UnaryOpNot Call NameLoad NameLoad NameLoad AugAssignAdd NameStore NameLoad Assign NameStore SubscriptLoad Call AttributeLoad NameLoad attr NameLoad Index NameLoad Assign NameStore SubscriptLoad Call AttributeLoad NameLoad attr NameLoad Index NameLoad Assign NameStore BinOpDiv BinOpSub NameLoad NameLoad BinOpSub NameLoad NameLoad Assign NameStore BinOpSub NameLoad BinOpMult NameLoad NameLoad AugAssignMult NameStore NameLoad AugAssignAdd NameStore NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults TupleLoad body Expr Str If CompareEq NameLoad TupleLoad body Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr orelse Assign NameStore SubscriptLoad AttributeLoad AttributeLoad NameLoad attr attr Index NameLoad Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr NameLoad attr NameLoad Return Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam defaults body Return NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults body Expr Str Return Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Return Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list decorator_list ClassDef bases NameLoad body Expr Str Assign NameStore Str FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad body Expr Str Raise NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Raise NameLoad decorator_list decorator_list ClassDef bases NameLoad body FunctionDef arguments args NameParam NameParam defaults body Return CompareEq SubscriptLoad NameLoad Slice Num Str decorator_list NameLoad decorator_list ClassDef bases NameLoad body Expr Str Assign NameStore NameLoad Assign NameStore Num Assign NameStore TupleLoad Str Assign NameStore TupleLoad TupleLoad Str Str Assign NameStore TupleLoad Str Str Assign NameStore NameLoad Assign NameStore NameLoad Assign NameStore NameLoad FunctionDef arguments args NameParam NameParam defaults body With Call AttributeLoad SubscriptLoad NameLoad Index Str attr NameStore body Assign NameStore Call NameLoad Call NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr If CompareNotEq AttributeLoad NameLoad attr TupleLoad Num Num body Raise Call NameLoad Str Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Return Call NameLoad NameLoad NameLoad NameLoad keyword NameLoad keyword NameLoad decorator_list NameLoad decorator_list Assign NameStore AttributeLoad NameLoad attr ClassDef bases NameLoad NameLoad body Expr Str Assign NameStore Str decorator_list ClassDef bases NameLoad NameLoad body Expr Str Assign NameStore Str decorator_list
N/A N/A  Read MINC1 format images  numbers Integral N/A numpy np externals.netcdf netcdf_file spatialimages SpatialHeader SpatialImage fileslice canonical_slicers deprecated FutureWarningMixin N/A _dt_dict N/A N/A b unsigned N/A b signed__ N/A c unsigned N/A h unsigned N/A h signed__ N/A i unsigned N/A i signed__ N/A np uint8 N/A np int8 S1 N/A np uint16 N/A np int16 N/A np uint32 N/A np int32 N/A _default_dir_cos N/A xspace yspace zspace N/A 1 0 0 N/A 0 1 0 N/A 0 0 1 MincError N/A Exception N/A N/A  Error when reading MINC files  N/A Minc1File N/A object N/A N/A  Class to wrap MINC1 format opened netcdf object

    Although it has some of the same methods as a ``Header``, we use
    this only when reading a MINC file, to pull out useful header
    information, and for the method of reading the data out
     __init__ N/A N/A self mincfile N/A N/A N/A N/A self _mincfile mincfile N/A N/A self _image N/A N/A mincfile variables N/A image N/A N/A self _dim_names N/A N/A self _image dimensions N/A N/A self _dims N/A N/A N/A N/A self _mincfile variables N/A s N/A s N/A self _dim_names N/A dim N/A self _dims N/A N/A N/A N/A dim spacing regular__ N/A N/A N/A ValueError Irregular spacing not supported N/A N/A self _spatial_dims N/A name N/A name N/A self _dim_names N/A N/A name endswith space N/A N/A self _image_max N/A N/A N/A self _mincfile variables N/A image-max N/A N/A self _image_min N/A N/A N/A self _mincfile variables N/A image-min N/A _get_dimensions N/A N/A self var N/A N/A N/A N/A var dimensions N/A get_data_dtype N/A N/A self N/A N/A N/A typecode N/A N/A N/A self _image typecode N/A N/A typecode f N/A N/A dtt N/A N/A np dtype N/A np float32 N/A N/A N/A typecode d N/A N/A dtt N/A N/A np dtype N/A np float64 N/A N/A signtype N/A N/A N/A N/A self _image signtype decode latin-1 N/A dtt N/A _dt_dict N/A N/A typecode signtype N/A N/A N/A N/A N/A np dtype dtt newbyteorder > N/A get_data_shape N/A N/A self N/A N/A N/A N/A N/A N/A self _image data shape N/A get_zooms N/A N/A self N/A N/A N/A  Get real-world sizes of voxels  N/A N/A tuple N/A N/A abs N/A float N/A dim step N/A dim N/A self _dims N/A get_affine N/A N/A self N/A N/A N/A nspatial N/A len N/A self _spatial_dims N/A rot_mat N/A N/A np eye nspatial N/A steps N/A N/A np zeros N/A nspatial N/A starts N/A N/A np zeros N/A nspatial N/A dim_names N/A list N/A self _dim_names N/A N/A i name N/A enumerate N/A self _spatial_dims N/A N/A dim N/A N/A self _dims N/A N/A N/A dim_names index name N/A N/A N/A dir_cos N/A dim direction_cosines N/A N/A N/A AttributeError N/A N/A dir_cos N/A _default_dir_cos N/A name N/A N/A rot_mat N/A N/A N/A i dir_cos N/A N/A steps N/A i N/A dim step N/A N/A starts N/A i N/A dim start N/A origin N/A N/A np dot rot_mat starts N/A aff N/A N/A np eye N/A nspatial 1 N/A N/A aff N/A N/A nspatial N/A nspatial N/A rot_mat steps N/A N/A aff N/A N/A nspatial N/A nspatial origin N/A aff N/A _get_valid_range N/A N/A self N/A N/A N/A  Return valid range for image data

        The valid range can come from the image 'valid_range' or
        image 'valid_min' and 'valid_max', or, failing that, from the
        data type range
         N/A ddt N/A N/A self get_data_dtype N/A info N/A N/A np iinfo N/A ddt type N/A N/A N/A valid_range N/A N/A self _image valid_range N/A N/A N/A AttributeError N/A N/A N/A N/A valid_range N/A N/A N/A self _image valid_min N/A N/A self _image valid_max N/A N/A N/A AttributeError N/A N/A valid_range N/A N/A info min N/A info max N/A N/A N/A N/A valid_range N/A 0 N/A info min N/A N/A valid_range N/A 1 N/A info max N/A N/A N/A ValueError Valid range outside input data type range N/A N/A N/A np asarray valid_range dtype N/A np float N/A _get_scalar N/A N/A self var N/A N/A N/A  Get scalar value from NetCDF scalar  N/A N/A N/A var getValue N/A _get_array N/A N/A self var N/A N/A N/A  Get array from NetCDF array  N/A N/A var data N/A _normalize N/A N/A self data sliceobj N/A N/A N/A N/A  Apply scaling to image data `data` already sliced with `sliceobj`

        https://en.wikibooks.org/wiki/MINC/Reference/MINC1-programmers-guide#Pixel_values_and_real_values

        MINC normalization uses "image-min" and "image-max" variables to
        map the data from the valid range of the image to the range
        specified by "image-min" and "image-max".

        The "image-max" and "image-min" are variables that describe the
        "max" and "min" of image over some dimensions of "image".

        The usual case is that "image" has dimensions ["zspace", "yspace",
        "xspace"] and "image-max" has dimensions ["zspace"], but there can be
        up to two dimensions for over which scaling is specified.

        Parameters
        ----------
        data : ndarray
            data after applying `sliceobj` slicing to full image
        sliceobj : tuple, optional
            slice definition. If not specified, assume no slicing has been
            applied to `data`
         N/A ddt N/A N/A self get_data_dtype N/A N/A N/A ddt type N/A N/A np sctypes N/A float N/A N/A data N/A image_max N/A self _image_max N/A image_min N/A self _image_min N/A mx_dims N/A N/A self _get_dimensions image_max N/A mn_dims N/A N/A self _get_dimensions image_min N/A N/A mx_dims mn_dims N/A N/A N/A MincError "image-max" and "image-min" do not have the samedimensions N/A nscales N/A len mx_dims N/A N/A nscales 2 N/A N/A N/A MincError More than two scaling dimensions N/A N/A mx_dims N/A N/A self _dim_names N/A nscales N/A N/A N/A MincError image-max and image dimensions do not match N/A N/A dmin dmax N/A N/A self _get_valid_range N/A out_data N/A N/A np clip data dmin dmax N/A N/A nscales 0 N/A N/A imax N/A N/A self _get_scalar image_max N/A imin N/A N/A self _get_scalar image_min N/A N/A shape N/A N/A self get_data_shape N/A sliceobj N/A canonical_slicers sliceobj shape N/A ax_inds N/A i N/A N/A i obj N/A enumerate sliceobj N/A obj None N/A N/A N/A len ax_inds N/A len shape N/A nscales_ax N/A ax_inds N/A nscales N/A i_slicer N/A sliceobj N/A nscales_ax N/A broad_part N/A tuple N/A None N/A s N/A sliceobj N/A N/A ax_inds N/A nscales N/A N/A isinstance s Integral N/A i_slicer broad_part N/A imax N/A N/A N/A self _get_array image_max N/A i_slicer N/A imin N/A N/A N/A self _get_array image_min N/A i_slicer N/A slope N/A N/A imax imin N/A dmax dmin N/A inter N/A imin N/A dmin slope N/A out_data slope N/A out_data inter N/A out_data N/A get_scaled_data N/A N/A self sliceobj N/A N/A N/A N/A  Return scaled data for slice definition `sliceobj`

        Parameters
        ----------
        sliceobj : tuple, optional
            slice definition. If not specified, return whole array

        Returns
        -------
        scaled_arr : array
            array from minc file with scaling applied
         N/A N/A sliceobj N/A N/A N/A raw_data N/A N/A self _image data N/A N/A raw_data N/A N/A N/A self _image data N/A sliceobj N/A dtype N/A N/A self get_data_dtype N/A data N/A N/A N/A N/A np asarray raw_data view dtype N/A N/A N/A self _normalize data sliceobj N/A N/A MincImageArrayProxy N/A object N/A N/A  MINC implementation of array proxy protocol

    The array proxy allows us to freeze the passed fileobj and
    header such that it returns the expected data array.
     __init__ N/A N/A self minc_file N/A N/A N/A N/A self minc_file minc_file N/A N/A self _shape N/A N/A minc_file get_data_shape N/A shape N/A N/A self N/A N/A N/A N/A self _shape N/A property is_proxy N/A N/A self N/A N/A N/A True N/A property __array__ N/A N/A self N/A N/A N/A  Read of data from file  N/A N/A N/A N/A self minc_file get_scaled_data N/A __getitem__ N/A N/A self sliceobj N/A N/A N/A  Read slice `sliceobj` of data from file  N/A N/A N/A N/A self minc_file get_scaled_data sliceobj N/A N/A MincHeader N/A SpatialHeader N/A N/A  Class to contain header for MINC formats
     N/A data_layout C data_to_fileobj N/A N/A self data fileobj rescale N/A True N/A N/A  See Header class for an implementation we can't use  N/A NotImplementedError N/A data_from_fileobj N/A N/A self fileobj N/A N/A N/A  See Header class for an implementation we can't use  N/A NotImplementedError N/A N/A Minc1Header N/A MincHeader N/A may_contain_header N/A N/A klass binaryblock N/A N/A N/A N/A N/A binaryblock N/A 4 CDF N/A classmethod N/A Minc1Image N/A SpatialImage N/A N/A  Class for MINC1 format images

    The MINC1 image class uses the default header type, rather than a specific
    MINC header type - and reads the relevant information from the MINC file on
    load.
     N/A header_class Minc1Header N/A _meta_sniff_len 4 N/A valid_exts N/A .mnc N/A files_types N/A N/A image .mnc N/A _compressed_suffixes N/A .gz .bz2 N/A makeable True N/A rw False N/A ImageArrayProxy MincImageArrayProxy from_file_map N/A N/A klass file_map N/A N/A N/A N/A N/A N/A file_map N/A image get_prepare_fileobj fobj N/A N/A minc_file N/A Minc1File N/A netcdf_file fobj N/A affine N/A N/A minc_file get_affine N/A N/A N/A affine shape N/A 4 4 N/A N/A N/A MincError Image does not have 3 spatial dimensions N/A data_dtype N/A N/A minc_file get_data_dtype N/A shape N/A N/A minc_file get_data_shape N/A zooms N/A N/A minc_file get_zooms N/A header N/A N/A klass header_class data_dtype shape zooms N/A data N/A N/A klass ImageArrayProxy minc_file N/A N/A klass data affine header extra None file_map file_map N/A classmethod N/A N/A load N/A Minc1Image load MincFile N/A FutureWarningMixin Minc1File N/A N/A  Deprecated alternative name for Minc1File
     N/A warn_message MincFile is deprecated; please use Minc1File instead N/A MincImage N/A FutureWarningMixin Minc1Image N/A N/A  Deprecated alternative name for Minc1Image
     N/A warn_message MincImage is deprecated; please use Minc1Image instead N/A