code: def specific_gravity(self, value):
          
          value = clean_float(value)
          if value is None:
              return
          specific_gravity = self._calc_specific_gravity()
          if specific_gravity is not None and not ct.isclose(specific_gravity, value, rel_tol=self._tolerance):
              raise ModelError("specific gravity is inconsistent with set unit_dry_weight and void_ratio")
  
          self._specific_gravity = float(value)
          self.stack.append(("specific_gravity", float(value)))
          self.recompute_all_weights_and_void()
docs: Set the relative weight of the solid