docstr: Calculates the return to origin probability from the propagator, which is
  the propagator evaluated at zero (see Descoteaux et Al. [1]_,
  Tuch [2]_, Wu et al. [3]_)
  rtop = P(0)
  
  Parameters
  ----------
  normalized : boolean, optional
      Whether to normalize the propagator by its sum in order to obtain a
      pdf. Default: True.
  
  Returns
  -------
  rtop : float
      the return to origin probability
  
  References
  ----------
  .. [1] Descoteaux M. et al., "Multiple q-shell diffusion propagator
  imaging", Medical Image Analysis, vol 15, No. 4, p. 603-621, 2011.
  
  .. [2] Tuch D.S., "Diffusion MRI of Complex Tissue Structure",
   PhD Thesis, 2002.
  
  .. [3] Wu Y. et al., "Computation of Diffusion Function Measures
  in q -Space Using Magnetic Resonance Hybrid Diffusion Imaging",
  IEEE TRANSACTIONS ON MEDICAL IMAGING, vol. 27, No. 6, p. 858-865, 2008
docstr_tok: ["Calculates","the","return","to","origin","probability","from","the","propagator",",","which","is","the","propagator","evaluated","at","zero","(","see","Descoteaux","et","Al",".","[","1","]","_",",","Tuch","[","2","]","_",",","Wu","et","al",".","[","3","]","_",")","rtop","=","P","(","0",")","Parameters","--","--","--","--","--","normalized",":","boolean",",","optional","Whether","to","normalize","the","propagator","by","its","sum","in","order","to","obtain","a","pdf",".","Default",":","True",".","Returns","--","--","--","-","rtop",":","float","the","return","to","origin","probability","References","--","--","--","--","--","..","[","1","]","Descoteaux","M.","et","al.",",","``","Multiple","q-shell","diffusion","propagator","imaging","''",",","Medical","Image","Analysis",",","vol","15",",","No",".","4",",","p.","603-621",",","2011",".","..","[","2","]","Tuch","D.S.",",","``","Diffusion","MRI","of","Complex","Tissue","Structure","''",",","PhD","Thesis",",","2002",".","..","[","3","]","Wu","Y.","et","al.",",","``","Computation","of","Diffusion","Function","Measures","in","q","-Space","Using","Magnetic","Resonance","Hybrid","Diffusion","Imaging","''",",","IEEE","TRANSACTIONS","ON","MEDICAL","IMAGING",",","vol",".","27",",","No",".","6",",","p.","858-865",",","2008"]
code: def rtop_pdf(self, normalized=True):
      r"""Calculates the return to origin probability from the propagator, which is
      the propagator evaluated at zero (see Descoteaux et Al. [1]_,
      Tuch [2]_, Wu et al. [3]_)
      rtop = P(0)
  
      Parameters
      ----------
      normalized : boolean, optional
          Whether to normalize the propagator by its sum in order to obtain a
          pdf. Default: True.
  
      Returns
      -------
      rtop : float
          the return to origin probability
  
      References
      ----------
      .. [1] Descoteaux M. et al., "Multiple q-shell diffusion propagator
      imaging", Medical Image Analysis, vol 15, No. 4, p. 603-621, 2011.
  
      .. [2] Tuch D.S., "Diffusion MRI of Complex Tissue Structure",
       PhD Thesis, 2002.
  
      .. [3] Wu Y. et al., "Computation of Diffusion Function Measures
      in q -Space Using Magnetic Resonance Hybrid Diffusion Imaging",
      IEEE TRANSACTIONS ON MEDICAL IMAGING, vol. 27, No. 6, p. 858-865, 2008
  
      """
  
      Pr = self.pdf(normalized=normalized)
  
      center = self.qgrid_sz // 2
  
      rtop = Pr[center, center, center]
      return rtop
  
imports: import numpy
  from scipy.ndimage import map_coordinates
  from scipy.fftpack import fftn, fftshift, ifftshift
  from dipy.reconst.odf import OdfModel, OdfFit
  from dipy.reconst.cache import Cache
  from dipy.reconst.multi_voxel import multi_voxel_fit
label_desc: Use image node_id 4 for calling the DiffusionSpectrumFit obj's underlying member method code with example usage: obj.rtop_pdf(normalized) and returns: rtop