Source:
<code>private void getMetadata() { if (title == null) { title = tag.getFirst(FieldKey.TITLE); } if (artist == null) { artist = tag.getFirst(FieldKey.ARTIST); } if (album == null) { album = tag.getFirst(FieldKey.ALBUM); } if (duration < 1) { try { AudioFile audioFile = AudioFileIO.read(new File(absolutePath)); duration = ((MP3AudioHeader) audioFile.getAudioHeader()).getPreciseTrackLength(); } catch (Exception e) { log.error("Input was not correct: " + absolutePath); log.trace(StackTrace.stackTrace(e)); } } if (bpm == 0) { try { bpm = Double.parseDouble(tag.getFirst(FieldKey.BPM)); } catch (NumberFormatException e) { if (isWindows) { analyzeTrack(); } try { bpm = Double.parseDouble(tag.getFirst(FieldKey.BPM)); log.info("BPM for: " + title + " is: " + bpm); } catch (NumberFormatException f) { log.error("There was no bpm information in file: " + absolutePath); log.trace(StackTrace.stackTrace(f)); } } } try { key = new MusicalKey(tag.getFirst(FieldKey.KEY)); } catch (IllegalArgumentException e) { if (isWindows) { analyzeTrack(); } try { key = new MusicalKey(tag.getFirst(FieldKey.KEY)); log.info("Key for: " + title + " is: " + key); } catch (IllegalArgumentException f) { log.error("There was no key information in file: " + absolutePath); log.trace(StackTrace.stackTrace(f)); } } try { id3EnergyParser(); } catch (NumberFormatException | NullPointerException e) { energyLevels(); if (this.getBpm() > 0.0) { calculateDifferences(); } } calculateTransitions(); System.out.println(this.getTitle()); System.out.println(averageEnergy); System.out.println(differences); System.out.println(outTransitionTimes + " OTT"); <START> System.out.println(inTransitionTimes + " ITT\n"); <END> }</code><technical_language>If print lines needed, please add logger</technical_language>

Target:
private void getMetadata() { if (title == null) { title = tag.getFirst(FieldKey.TITLE); } if (artist == null) { artist = tag.getFirst(FieldKey.ARTIST); } if (album == null) { album = tag.getFirst(FieldKey.ALBUM); } if (duration < 1) { try { AudioFile audioFile = AudioFileIO.read(new File(absolutePath)); duration = ((MP3AudioHeader) audioFile.getAudioHeader()).getPreciseTrackLength(); } catch (Exception e) { log.error("Input was not correct: " + absolutePath); log.trace(StackTrace.stackTrace(e)); } } if (bpm == 0) { try { bpm = Double.parseDouble(tag.getFirst(FieldKey.BPM)); } catch (NumberFormatException e) { if (isWindows) { analyzeTrack(); } try { bpm = Double.parseDouble(tag.getFirst(FieldKey.BPM)); log.info("BPM for: " + title + " is: " + bpm); } catch (NumberFormatException f) { log.error("There was no bpm information in file: " + absolutePath); log.trace(StackTrace.stackTrace(f)); } } } try { key = new MusicalKey(tag.getFirst(FieldKey.KEY)); } catch (IllegalArgumentException e) { if (isWindows) { analyzeTrack(); } try { key = new MusicalKey(tag.getFirst(FieldKey.KEY)); log.info("Key for: " + title + " is: " + key); } catch (IllegalArgumentException f) { log.error("There was no key information in file: " + absolutePath); log.trace(StackTrace.stackTrace(f)); } } try { id3EnergyParser(); } catch (NumberFormatException | NullPointerException e) { energyLevels(); if (this.getBpm() > 0.0) { calculateDifferences(); } } calculateTransitions(); }