Issue#4: Updating slicer.py for customize start and end time input params #37
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Below improvements added to slicer.py:
Mins and secs Example: python interviewkit/slicer.py data/Martine+Barrat_FINAL.mp3 105:40 107:40 (audio will be sliced from 105mins 40secs to 107mins and 40secs)
Mins Example: python interviewkit/slicer.py data/Martine+Barrat_FINAL.mp3 2 4 (audio will be sliced from 2mins to 4mins)
@audreyfeldroy Issue No. 4 mentions audio slice from 105:40 to 107:40 of MartineBarrat_FINAL.mp3. I am afraid that the downloaded MartineBarrat_FINAL audio only contains ~90mins of sound, so I was not able to create the sliced audio file from 105:40 to 107:40 as required.
For creating sliced audio from any file, just mention the mins and seconds for start and end time and the script will generate the sliced audio file.
Example: If we need sliced audio from 10mins 20secs to 20mins 40 secs, it can be done as shown below:
python interviewkit/slicer.py data/Martine+Barrat_FINAL.mp3 10:20 20:40
Also, The Script currently doesn't support input in hours format, so hours will need to converted to mins:secs format. I am planning to add hours support to the script in coming days. For now, the start and end time needs to be converted to mins:secs format.
Eg: If we want audio from 1hr 20mins 30 secs to 1hr 30mins 40secs, it can be done as shown below:
1hr 20mins 30 secs = 80mins 30secs
1hr 30mins 40sec = 90mins 40secs
python interviewkit/slicer.py data/Martine+Barrat_FINAL.mp3 80:30 90:40
For Issue#35 regarding slicer support for m4a files, I tested the current slicer script on SusanYung_FINAL.m4a file and it worked perfectly fine without issues. So I guess that issue can be closed if it works on your side too without issues.