Skip to content

Instantly share code, notes, and snippets.

@gsanchezd
gsanchezd / main.py
Created October 7, 2022 18:48
remove_backgrounds
#!/usr/bin/python
# -*- coding: utf-8 -*-
from rembg import remove
from PIL import Image
import sys
def main():
input_path = sys.argv[1]
output_path = sys.argv[2]
@gsanchezd
gsanchezd / gist:5a19298cff5c035a1b99c678b910e8f6
Last active November 23, 2018 21:39
Custom template for Jupyter notebooks

Custom Template for jupyter notebook

Add Logo to templates

In the file articles.tplx in ~/.jupyter/templates folder (if the file or folder doesn't exist we can create it)

% Default to the notebook output style
((* if not cell_style is defined *))
@gsanchezd
gsanchezd / fog.rb
Created February 16, 2016 21:07
Base Fog Carrierwave config
if Rails.env.test?
CarrierWave.configure do |config|
config.storage = :file
config.enable_processing = false
end
else
CarrierWave.configure do |config|
config.storage = :fog
config.fog_credentials = {
:provider => 'AWS', # required