@Override
  protected void onPreExecute() {
    super.onPreExecute();
    dialog.setTitle("Please wait");
    dialog.setMessage("Checking for data installation...");
    dialog.setIndeterminate(false);
    dialog.setProgressStyle(ProgressDialog.STYLE_HORIZONTAL);
    dialog.setCancelable(false);
    dialog.show();
    activity.setButtonVisibility(false);
  }
AsyncTask to asynchronously download data and initialize Tesseract.

@param activity
         The calling activity
@param baseApi
         API to the OCR engine
@param dialog
         Dialog box with thermometer progress indicator
@param indeterminateDialog
         Dialog box with indeterminate progress indicator
@param languageCode
         ISO 639-2 OCR language code
@param languageName
         Name of the OCR language, for example, "English"
@param ocrEngineMode
         Whether to use Tesseract, Cube, or both
OCRTest/src/main/java/edu/sfsu/cs/orange/ocr/OcrInitAsyncTask.java