Skip to content

Conversation

tanvi355
Copy link
Contributor

@tanvi355 tanvi355 commented May 31, 2021

Description

Using this script you can convert any video into a pdf file.

Fixes #1035

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)
  • This change requires a documentation update

Checklist:

  • My code follows the style guidelines(Clean Code) of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have created a helpful and easy to understand README.md
  • My documentation follows Template for README.md
  • I have added the project meta data in the PR template.

Project Metadata

If there is no-file/nothing to fill the below fields with, then type: none

Example: If no requirements.txt needed/present, then type none in Requirments.

Category:

  • Calculators
  • AI/ML
  • Scrappers
  • Social_Media
  • PDF
  • Image_Processing
  • Video_Processing
  • Games
  • Networking
  • OS_Utilities
  • Automation
  • Cryptography
  • Computer_Vision
  • Fun
  • Others

Title: Video to PDF (GUI)

Folder: Video to PDF

Requirements: requirements.txt

Script: script.py

Arguments: none

Contributor: tanvi355

Description: Using this script you can convert any video into a pdf file.

Copy link
Contributor

@kaustubhgupta kaustubhgupta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • delete my_pdf.pdf
  • Other changes:

Comment on lines 5 to 10
## Modules used :
- Tkinter
- MoviePy
- Speech Recognition
- OS
- FPDF
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As the requirement file is already there, you can delete this section

Comment on lines 1 to 4
Tkinter
FPDF
Speech Recognition
MoviePy
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mention them in the format so that one can install them using:

pip install -r requirements.txt

Check this file: https://github.com/avinashkranjan/Amazing-Python-Scripts/blob/master/Amazon-Price-Alert/requirements.txt

pdf.ln(0.5)


pdf.output("my_pdf.pdf")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add this path:

Suggested change
pdf.output("my_pdf.pdf")
pdf.output("./ Video to PDF/my_pdf.pdf")

Also, the file name needs to be the same as the video file name with added (pdf). For instance,
input: video12.mp4
output: video12 (pdf).pdf

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have added the path now...
but for name of video and pdf to be same I tried writing pdf.output(video_filepath.split('.')[0]+"(pdf)"+".pdf") but it isn't working....

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Checkout this PR implementation: #1105

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

like this?

filename = os.path.basename(video_filepath)
pdf.output("./Video to PDF/" + filename.split('.')[0] + "(pdf)" + ".pdf")

@kaustubhgupta kaustubhgupta added the minor-change-not-bug Suggested a minor change in code, not a bug label May 31, 2021
@tanvi355
Copy link
Contributor Author

Also, I have deleted my_pdf.pdf so should I remove the sample video link from README?

@kaustubhgupta
Copy link
Contributor

Also, I have deleted my_pdf.pdf so should I remove the sample video link from README?

not needed

@kaustubhgupta kaustubhgupta added next review needed Approved by some mentors, more approvals needed and removed minor-change-not-bug Suggested a minor change in code, not a bug labels May 31, 2021
Copy link

@Kushal997-das Kushal997-das left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@tanvi355
Copy link
Contributor Author

tanvi355 commented Jun 5, 2021

@avinashkranjan @antrikshmisri please review the PR.

@avinashkranjan avinashkranjan added gssoc23 Issues created for/by the GirlScript Summer of Code'23 Participants level3 New features, Major bug fixing manual-db-update-req The PR was merged but db was not updated. Need to update the database manully and removed next review needed Approved by some mentors, more approvals needed labels Jun 5, 2021
Copy link
Owner

@avinashkranjan avinashkranjan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM..🚩

@avinashkranjan avinashkranjan merged commit 71fa076 into avinashkranjan:master Jun 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
gssoc23 Issues created for/by the GirlScript Summer of Code'23 Participants level3 New features, Major bug fixing manual-db-update-req The PR was merged but db was not updated. Need to update the database manully
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Video to PDF (GUI)
5 participants