Merge branch 'metafy-social:master' into master

This commit is contained in:
Harshavardhan Bajoria 2022-10-04 14:17:42 +05:30 committed by GitHub
commit 9df64acbe1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 72 additions and 9 deletions

View File

@ -159,21 +159,28 @@ Thanks a lot for spending your time helping! Keep rocking 🍻
<sub><b>Vedant Jolly</b></sub>
</a>
</td>
<td align="center">
<a href="https://github.com/Dishant10">
<img src="https://avatars.githubusercontent.com/u/84343829?v=4" width="100;" alt="Dishant10"/>
<br />
<sub><b>Dishant Nagpal</b></sub>
</a>
</td>
<td align="center">
<a href="https://github.com/SiddheshKukade">
<img src="https://avatars.githubusercontent.com/u/65951872?v=4" width="100;" alt="SiddheshKukade"/>
<br />
<sub><b>Siddhesh Bhupendra Kuakde</b></sub>
</a>
</td>
</td></tr>
<tr>
<td align="center">
<a href="https://github.com/aswin2108">
<img src="https://avatars.githubusercontent.com/u/72661784?v=4" width="100;" alt="aswin2108"/>
<br />
<sub><b>Aswin Shailajan</b></sub>
</a>
</td></tr>
<tr>
</td>
<td align="center">
<a href="https://github.com/noobyysauraj">
<img src="https://avatars.githubusercontent.com/u/81681419?v=4" width="100;" alt="noobyysauraj"/>
@ -208,15 +215,15 @@ Thanks a lot for spending your time helping! Keep rocking 🍻
<br />
<sub><b>Sarthak Roy</b></sub>
</a>
</td>
</td></tr>
<tr>
<td align="center">
<a href="https://github.com/anjali1102">
<img src="https://avatars.githubusercontent.com/u/56559378?v=4" width="100;" alt="anjali1102"/>
<br />
<sub><b>Anjali Chauhan</b></sub>
</a>
</td></tr>
<tr>
</td>
<td align="center">
<a href="https://github.com/artemis-i-guess">
<img src="https://avatars.githubusercontent.com/u/65388018?v=4" width="100;" alt="artemis-i-guess"/>
@ -251,15 +258,15 @@ Thanks a lot for spending your time helping! Keep rocking 🍻
<br />
<sub><b>Null</b></sub>
</a>
</td>
</td></tr>
<tr>
<td align="center">
<a href="https://github.com/smit-sms">
<img src="https://avatars.githubusercontent.com/u/52400400?v=4" width="100;" alt="smit-sms"/>
<br />
<sub><b>Smit Shah</b></sub>
</a>
</td></tr>
<tr>
</td>
<td align="center">
<a href="https://github.com/SameerSahu007">
<img src="https://avatars.githubusercontent.com/u/29480670?v=4" width="100;" alt="SameerSahu007"/>

View File

@ -0,0 +1,28 @@
# Slice Audio from any mp3 file
We all want only a portion form a particular audio file. This python scrip does the same for you in few very easy steps.
Only have to enter few things to get started and the rest is magic.
What all do you have to enter?
1.) Your file Path - Where your initial audio file(mp3) is located.
2.) Your export Path - Where you want to save your resultant sliced audio file to be saved.
3.) Start Minute - From what minute into the audio you want to slice from
4.) Start Second - From what second after the start minute you want to slice from
5.) End Minute - Till what minute you want the final audio to be.
6.) End Second - Till what second of the End minute you want to final audio to be.
# Requirements
Clone Repo
You need to intall pydub library for this script to run.
You can use pip - pip install pydub
More information on pydub here - https://pypi.org/project/pydub/
Use the python script slicingAudio.py

View File

@ -0,0 +1,28 @@
from pydub import AudioSegment
#Example File path
#filePath = "/Users/dishantnagpal/Desktop/python/exampleAudio.mp3"
#Example Exoprt Path
#exportPath = "/Users/dishantnagpal/Desktop/python/newPortion-1.mp3"
filePath = input("Enter your path to the audio file") #Enter your file path
exportPath = input("Enter the path you want to save the file at") #Enter export Path
sound = AudioSegment.from_mp3(filePath) #Making an executable audio file from the given path
startMin = int(input('Enter Start Minute '))
startSecond = int(input('Enter Start Second '))
endMin = int(input('Enter End Minute '))
endSecond = int(input('Enter End Second '))
startTime = startMin*60*1000+startSecond*1000
endTime = endMin*60*1000+endSecond*1000
extract = sound[startTime:endTime] #Extracting sliced Audio
extract.export(exportPath, format="mp3") #Saving the final audio file at your export path