code: def get_forces(self, a=None):
          
          if a is None:
              a = self.a
          forces = np.zeros([len(a), 3], dtype=float)
          if self.mask is None:
              forces[self.mask] = self.force
          else:
              forces[:] = self.force
          return forces
docs: Calculate atomic forces.