code: def pg_backup(self, pg_dump_exe='pg_dump', exclude_schema=None):
          
  
          command = [
              pg_dump_exe, '-Fc', '-f', self.file,
              'service={}'.format(self.pg_service)
              ]
          if exclude_schema:
              command.append(' '.join("--exclude-schema={}".format(schema) for schema in exclude_schema))
  
          subprocess.check_output(command, stderr=subprocess.STDOUT)
docs: Call the pg_dump command to create a db backup
  
          Parameters
          ----------
          pg_dump_exe: str
              the pg_dump command path
          exclude_schema: str[]
              list of schemas to be skipped