I hereby claim:
- I am berpj on github.
- I am berpj (https://keybase.io/berpj) on keybase.
- I have a public key ASCfuc2xEtlc92znUEcJYFv7EVWJU5oEAyxkSHUHmMyDugo
To claim this, I am signing this object:
link = object.url_for(:get, { expires: Time.now + (60 * 5), secure: true, response_content_disposition: "attachment; filename=#{filename}" }).to_s |
# "Colorizing B/W Movies with Neural Nets", | |
# Network/Code Created by Ryan Dahl, hacked by samim.io to work with movies | |
# BACKGROUND: http://tinyclouds.org/colorize/ | |
# DEMO: https://www.youtube.com/watch?v=_MJU8VK2PI4 | |
# USAGE: | |
# 1. Download TensorFlow model from: http://tinyclouds.org/colorize/ | |
# 2. Use FFMPEG or such to extract frames from video. | |
# 3. Make sure your images are 224x224 pixels dimension. You can use imagemagicks "mogrify", here some useful commands: | |
# mogrify -resize 224x224 *.jpg | |
# mogrify -gravity center -background black -extent 224x224 *.jpg |
t = gets.strip.to_i | |
t.times do | |
count = 0 | |
x = gets.strip.split.map(&:to_i) | |
y = Math.sqrt(x[0]).floor | |
z = Math.sqrt(x[1]).floor | |
count += 1 if y**2 == x[0] | |
y += 1 | |
while (y**2 <= x[1]) do | |
count += 1 |
I hereby claim:
To claim this, I am signing this object:
# lib/tasks/db_clean.rake | |
# Homemade rake task to clean DB for Rails 5 | |
namespace :db do | |
desc "Reset and seed DB" | |
task :clean => :environment do | |
# Empty tables and reset primary id autoincrement | |
ApplicationRecord.connection.tables.each do |table| | |
next if table.match(/\Aschema_migrations\Z/) || table.match(/\Aar_internal_metadata\Z/) | |
ApplicationRecord.connection.execute("TRUNCATE TABLE #{table} RESTART IDENTITY CASCADE") |
$(function() { | |
/* | |
// TABS | |
*/ | |
$('body').on('click', '.w-tab-link', function(e) { | |
// Set to active the selected tab link | |
var selected = $(this).attr('data-w-tab') | |
$(this).closest('.w-tab-menu').find('.w-tab-link').removeClass('w--current') | |
$(this).addClass('w--current') |
response = OPENAI_CLIENT.chat( | |
parameters: { | |
model: "gpt-4-0613", # Required. | |
messages: [ | |
{ role: "system", content: "Tu es un expert en aviation et OSINT. Je vais te donner des données ADS-B que tu vas interpréter afin de déterminer le type de vol ou de mission dont il s'agit. Utilise uniquement la fonction sortie."}, | |
{ role: "user", content: self.traces.last.to_json } | |
], | |
functions: [ | |
{ | |
name: "sortie", |
#!/bin/bash | |
# This file will be sourced in init.sh | |
# https://raw.githubusercontent.com/ai-dock/comfyui/main/config/provisioning/default.sh | |
# Packages are installed after nodes so we can fix them... | |
#DEFAULT_WORKFLOW="https://..." |
#!/bin/bash | |
# This file will be sourced in init.sh | |
# Namespace functions with provisioning_ | |
# https://raw.githubusercontent.com/ai-dock/stable-diffusion-webui/main/config/provisioning/default.sh | |
### Edit the following arrays to suit your workflow - values must be quoted and separated by newlines or spaces. | |
### If you specify gated models you'll need to set environment variables HF_TOKEN and/orf CIVITAI_TOKEN | |
DISK_GB_REQUIRED=30 |