// Some quick parameter checking
IOUtil.assertFileIsReadable(INPUT);
IOUtil.assertFileIsWritable(OUTPUT);
log.info("Reading input file and calculating metrics.");
final SAMFileReader sam = new SAMFileReader(IOUtil.openFileForReading(INPUT));
final MetricsFile<QualityYieldMetrics,Integer> metricsFile = getMetricsFile();
final QualityYieldMetrics metrics = new QualityYieldMetrics();