code: def _get_mean(self, imt, mag, hypo_depth, rrup, d):
          
          # clip magnitude at 8.3 as per note at page 3-36 in table Table 3.3.2-6
          # in "Technical Reports on National Seismic Hazard Maps for Japan"
          mag = min(mag, 8.3)
          if imt.name == 'PGV':
              mean = (
                  0.58 * mag +
                  0.0038 * hypo_depth +
                  d -
                  1.29 -
                  np.log10(rrup + 0.0028 * 10 ** (0.5 * mag)) -
                  0.002 * rrup
              )
          else:
              mean = (
                  0.50 * mag +
                  0.0043 * hypo_depth +
                  d +
                  0.61 -
                  np.log10(rrup + 0.0055 * 10 ** (0.5 * mag)) -
                  0.003 * rrup
              )
              mean = np.log10(10**(mean)/(g*100))
  
          return mean
docs: Return mean value as defined in equation 3.5.1-1 page 148