code: def init(self):
      if self.initialized:
          return
  
      if self.fixed is None:
          self.fixed = np.zeros(self.pos.shape[0], dtype=bool)
      if self.push is None:
          self.push = np.ones(self.links.shape[0], dtype=bool)
      if self.pull is None:
          self.pull = np.ones(self.links.shape[0], dtype=bool)
  
      # precompute relative masses across links
      l1 = self.links[:, 0]
      l2 = self.links[:, 1]
      m1 = self.mass[l1]
      m2 = self.mass[l2]
      self.mrel1 = (m1 / (m1 + m2))[:, np.newaxis]
      self.mrel1[self.fixed[l1]] = 1  # fixed point constraint
      self.mrel1[self.fixed[l2]] = 0
      self.mrel2 = 1.0 - self.mrel1
  
      for i in range(10):
          self.relax(n=10)
  
      self.initialized = True
  
file_path: pyqtgraph/pyqtgraph/examples/verlet_chain/chain.py
imports: import time
  import numpy
  import pyqtgraph
  from .None import relax
label_desc: Use image node_id 2 for calling the ChainSim obj's underlying member method code with example usage: obj.init() without return types