class_docstr: `MNIST <http://yann.lecun.com/exdb/mnist/>`_ Dataset.
  
  Args:
      root (string): Root directory of dataset where ``MNIST/raw/train-images-idx3-ubyte``
          and  ``MNIST/raw/t10k-images-idx3-ubyte`` exist.
      train (bool, optional): If True, creates dataset from ``train-images-idx3-ubyte``,
          otherwise from ``t10k-images-idx3-ubyte``.
      download (bool, optional): If True, downloads the dataset from the internet and
          puts it in root directory. If dataset is already downloaded, it is not
          downloaded again.
      transform (callable, optional): A function/transform that  takes in a PIL image
          and returns a transformed version. E.g, ``transforms.RandomCrop``
      target_transform (callable, optional): A function/transform that takes in the
          target and transforms it.
class_docstr_tok: ["`","MNIST","<","http",":","\/\/yann.lecun.com\/exdb\/mnist\/",">","`","_","Dataset",".","Args",":","root","(","string",")",":","Root","directory","of","dataset","where","``","MNIST\/raw\/train-images-idx3-ubyte","``","and","``","MNIST\/raw\/t10k-images-idx3-ubyte","``","exist",".","train","(","bool",",","optional",")",":","If","True",",","creates","dataset","from","``","train-images-idx3-ubyte","``",",","otherwise","from","``","t10k-images-idx3-ubyte","``",".","download","(","bool",",","optional",")",":","If","True",",","downloads","the","dataset","from","the","internet","and","puts","it","in","root","directory",".","If","dataset","is","already","downloaded",",","it","is","not","downloaded","again",".","transform","(","callable",",","optional",")",":","A","function\/transform","that","takes","in","a","PIL","image","and","returns","a","transformed","version",".","E.g",",","``","transforms.RandomCrop","``","target_transform","(","callable",",","optional",")",":","A","function\/transform","that","takes","in","the","target","and","transforms","it","."]
code: def _check_legacy_exist(self):
      processed_folder_exists = os.path.exists(self.processed_folder)
      if not processed_folder_exists:
          return False
  
      return all(
          check_integrity(os.path.join(self.processed_folder, file))
          for file in (self.training_file, self.test_file)
      )
  
imports: import codecs
  import os
  import os.path
  import shutil
  import string
  import sys
  import warnings
  from typing import Any, Callable, Dict, List, Optional, Tuple
  from urllib.error import URLError
  import numpy
  import torch
  from PIL import Image
  from .utils import _flip_byte_order, check_integrity, download_and_extract_archive, extract_archive, verify_str_arg
  from .vision import VisionDataset
label_desc: Use image node_id 6 for calling the MNIST obj's underlying member method code with example usage: obj._check_legacy_exist() and returns: all, False