Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/python3
"""OCR with PDF/TIFF as source files on GCS"""
#Source: https://towardsdatascience.com/how-to-extract-the-text-from-pdfs-using-python-and-the-google-cloud-vision-api-7a0a798adc13
#https://github.com/szeamer/google-cloud-vision-script/blob/main/script.py
#Requirements:
#pip3 install google-cloud-vision
#pip3 install google-cloud-storage
@zorbaproject
zorbaproject / transcribe.py
Last active December 21, 2020 05:21
Transcribe long audio files with Google Speech API
# Original source: https://towardsdatascience.com/how-to-use-google-speech-to-text-api-to-transcribe-long-audio-files-1c886f4eb3e9
#Requirements
#sudo pip3 install google-cloud-storage
#sudo pip3 install google-cloud-speech
#sudo pip3 install pydub
#sudo apt install ffmpeg
#Create a project on https://console.cloud.google.com/
#Enable Storage Transfer API
@zorbaproject
zorbaproject / scrapefb.py
Last active April 2, 2022 08:41
Download all posts from a Facebook page, in txt or csv
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
#Written by Luca Tringali
# The code is described here:
# https://www.codice-sorgente.it/2018/08/facebook-scraping-scaricare-tutti-i-post-delle-pagine-facebook/
#Released under GNU GPL3
#USAGE: python3 ./scrapefb.py https://facebookpageurl/ ./ CSV
#The second argument is the output folder, the third one (in caps) is the format TXT or CSV