Skip to content

Instantly share code, notes, and snippets.

View abcsds's full-sized avatar

Alberto Barradas abcsds

View GitHub Profile
@abcsds
abcsds / pdc_dtf.py
Created September 28, 2023 09:03 — forked from agramfort/pdc_dtf.py
Partial Directed Coherence and Direct Transfer Function using MVAR processes
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Implements Partial Directed Coherence and Direct Transfer Function
using MVAR processes.
Reference
---------
Luiz A. Baccala and Koichi Sameshima. Partial directed coherence:
a new concept in neural structure determination.
@abcsds
abcsds / vidstab_ffmpeg.md
Created July 6, 2023 06:46 — forked from hlorand/vidstab_ffmpeg.md
Video stabilization using VidStab and FFMPEG

Video stabilization using VidStab and FFMPEG

** Step 1 **

Install ffmpeg with the vidstab plugin.

@abcsds
abcsds / Latex in Markdown.md
Created February 3, 2022 16:45
A quick way to render latex in markdown
@abcsds
abcsds / lucasKanade.jl
Created October 10, 2018 09:28
Lucas-Kanade method on julia
using Images
# FFTW.set_num_threads(2)
"""
opticalFlow(im1::Array, im2::Array, kps::Array{CartesianIndex{2},1}; windowSize=15)
Parameters:
- im1: An Image array, the first frame in time.
- im2: The second frame in time, must be the same size as im1
- kps: Key points, or points of interest within the image where the optical flow is expected.
- windowSize: Window size for solving the flow equations. Default 15.
"""
@abcsds
abcsds / main.jl
Created August 2, 2018 04:59
[LSTM language Model] a simple example that creates a character-based language model with LSTMs in Julia with the help of Flux
using Flux
using Flux: onehot, argmax, chunk, batchseq, throttle, crossentropy
using StatsBase: wsample
using Base.Iterators: partition
cd(@__DIR__)
text = collect(repeat(readstring("prince_eo.txt"), 20))
alphabet = [unique(text)..., '_']
text = map(ch -> onehot(ch, alphabet), text)
@abcsds
abcsds / infb.py
Created November 14, 2017 06:46 — forked from meznak/infb.py
A script to scrape information from your facebook friends.
#!/usr/bin/python
'''
InFB - Information Facebook
Usage: infb.py user@domain.tld password
infb.py
http://ruel.me
@abcsds
abcsds / .juliarc.jl
Created September 22, 2017 14:54 — forked from Ismael-VC/.juliarc.jl
~/.juliarc.jl
using Compat
# using Suppressor
using OhMyREPL
const SEPARATOR = "\n\n" * "#"^80 * "\n\n"
ENV["PYTHON"] = ""
ENV["JULIA_WARN_COLOR"] = :yellow
ENV["JULIA_INFO_COLOR"] = :cyan
# ENV["LISP_PROMPT_TEXT"] = "λ ↦ "
@abcsds
abcsds / GIF-Screencast-OSX.md
Created August 15, 2017 16:53 — forked from dergachev/GIF-Screencast-OSX.md
OS X Screencast to animated GIF

OS X Screencast to animated GIF

This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.

Screencapture GIF

Instructions

To capture the video (filesize: 19MB), using the free "QuickTime Player" application:

@abcsds
abcsds / osx-for-hackers.sh
Created August 15, 2017 16:52 — forked from brandonb927/osx-for-hackers.sh
OSX for Hackers: Yosemite/El Capitan Edition. This script tries not to be *too* opinionated and any major changes to your system require a prompt. You've been warned.
#!/bin/sh
###
# SOME COMMANDS WILL NOT WORK ON macOS (Sierra or newer)
# For Sierra or newer, see https://github.com/mathiasbynens/dotfiles/blob/master/.macos
###
# Alot of these configs have been taken from the various places
# on the web, most from here
# https://github.com/mathiasbynens/dotfiles/blob/5b3c8418ed42d93af2e647dc9d122f25cc034871/.osx
@abcsds
abcsds / tmux-cheatsheet.markdown
Created August 15, 2017 16:48 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname