docs: def setup(self):
          """
          Performs initial setup for VaspJob, including overriding any settings
          and backing up.
          """
          decompress_dir('.')
  
          if self.backup:
              for f in VASP_INPUT_FILES:
                  shutil.copy(f, "{}.orig".format(f))
  
          if self.auto_npar:
              try:
                  incar = Incar.from_file("INCAR")
                  # Only optimized NPAR for non-HF and non-RPA calculations.
                  if not (incar.get("LHFCALC") or incar.get("LRPA") or
                          incar.get("LEPSILON")):
                      if incar.get("IBRION") in [5, 6, 7, 8]:
                          # NPAR should not be set for Hessian matrix
                          # calculations, whether in DFPT or otherwise.
                          del incar["NPAR"]
                      else:
                          import multiprocessing
                          # try sge environment variable first
                          # (since multiprocessing counts cores on the current
                          # machine only)
                          ncores = os.environ.get('NSLOTS') or \
                              multiprocessing.cpu_count()
                          ncores = int(ncores)
                          for npar in range(int(math.sqrt(ncores)),
                                            ncores):
                              if ncores % npar == 0:
                                  incar["NPAR"] = npar
                                  break
                      incar.write_file("INCAR")
              except:
                  pass
  
          if self.auto_continue:
              if os.path.exists("continue.json"):
                  actions = loadfn("continue.json").get("actions")
                  logger.info("Continuing previous VaspJob. Actions: {}".format(actions))
                  backup(VASP_BACKUP_FILES, prefix="prev_run")
                  VaspModder().apply_actions(actions)
  
              else:
                  # Default functionality is to copy CONTCAR to POSCAR and set
                  # ISTART to 1 in the INCAR, but other actions can be specified
                  if self.auto_continue is True:
                      actions = [{"file": "CONTCAR",
                                  "action": {"_file_copy": {"dest": "POSCAR"}}},
                                 {"dict": "INCAR",
                                  "action": {"_set": {"ISTART": 1}}}]
                  else:
                      actions = self.auto_continue
                  dumpfn({"actions": actions}, "continue.json")
  
          if self.settings_override is not None:
              VaspModder().apply_actions(self.settings_override)