code: public static Problem readProblem(File file, double bias) throws IOException, InvalidInputDataException {
          try (InputStream inputStream = new FileInputStream(file)) {
              return readProblem(inputStream, bias);
          }
      }
docs: reads a problem from LibSVM format
  @param file the SVM file
  @throws IOException obviously in case of any I/O exception ;)
  @throws InvalidInputDataException if the input file is not correctly formatted