code: def absolute_magnitude(self, richness=1, steps=1e4):
          
          # Using the SDSS g,r -> V from Jester 2005 [astro-ph/0506022]
          # for stars with R-I < 1.15
          # V = g_sdss - 0.59*(g_sdss - r_sdss) - 0.01
  
          # Create a copy of the isochrone in the SDSS system
          params = {k:v.value for k,v in self._params.items()}
          params.update(band_1='g',band_2='r',survey='sdss')
          iso = self.__class__(**params)
  
          # g, r are absolute magnitude
          mass_init, mass_pdf, mass_act, sdss_g, sdss_r = iso.sample(mass_steps=steps)
          V = jester_mag_v(sdss_g,sdss_r)
  
          # Sum the V-band absolute magnitudes
          return sum_mags(V,weights=mass_pdf*richness)
docs: Calculate the absolute visual magnitude (Mv) from the richness
          by transforming the isochrone in the SDSS system and using the
          g,r -> V transform equations from Jester 2005
          [astro-ph/0506022].
  
  
          Parameters:
          -----------
          richness : isochrone normalization parameter
          steps    : number of isochrone sampling steps
  
          Returns:
          --------
          abs_mag : Absolute magnitude (Mv)