Skip to content

Instantly share code, notes, and snippets.

View ibaaj's full-sized avatar

Ismaïl Baaj ibaaj

  • Paris, France
View GitHub Profile
@ibaaj
ibaaj / arxiv-preparation.md
Created January 27, 2023 15:05 — forked from xiaohk/arxiv-preparation.md
Prepare for an arXiv submission

Submission Steps

  1. Download source code from Overleaf if you use it: menu -> download -> source.

  2. Strip comments and combine all tex files (f01-main.tex, f02-intro.tex, etc.) into one file arxiv_main.tex.

# Replace f01-main.tex with the main tex file in your overleaf project
latexpand --empty-comments f01-main.tex > arxiv_main.tex
@ibaaj
ibaaj / parsing.py
Created December 3, 2022 12:44
parsing mathgenealogy
import pprint
import re
import requests
from bs4 import BeautifulSoup, SoupStrainer
import time
import json
ALLAUTHORS = {}
@ibaaj
ibaaj / fan.py
Created November 8, 2018 22:56
fan.py
import numpy as np
import skfuzzy as fuzz
import matplotlib.pyplot as plt
import sys
import matplotlib
matplotlib.rc('font', **{'sans-serif' : 'Arial',
'family' : 'sans-serif'})
@ibaaj
ibaaj / pasta
Created September 17, 2018 14:40
'Nom','Diametre','Largeur','Longueur','Epaisseur','Profondeur','Bords','Surface','CoupeTransversale','ProfilLongitudinal','TempsDeCuisson'
Acini di pepe,2,-,3,-,-,lisse,lisse,solide,droit,9
Agnolotti,-,30,45,-,-,crénelé,lisse,creux,pincé,10
Anellini,6,-,-,1,-,lisse,lisse,creux,droit,6
Bucatini,3,-,237,-,-,lisse,lisse,creux,droit,11
Buccoli,8,-,30,-,-,lisse,lisse,creux,helicoïdal,8
Calamaretti,25,-,14,-,-,lisse,lisse,creux,droit,14
Cannelloni,23,-,100,-,-,lisse,lisse,creux,droit,20
Cannolicchi rigati,8,-,41,-,-,lisse,strié,creux,droit,11
Capellini,1,-,260,-,-,lisse,lisse,solide,droit,2
@ibaaj
ibaaj / blocktoimg.py
Created August 13, 2018 09:58 — forked from laanwj/blocktoimg.py
tools to write (block) data to png files and vice versa
#!/usr/bin/env python3
# Distributed under the MIT software license
import binascii, struct, sys, io, argparse
from PIL import Image
IMG_WIDTH = 512 # could be made adaptive...
MIN_HEIGHT = 4 # minimum height of image; twitter won't let us upload anything smaller
BYTES_PER_PIXEL = 4 # RGBA, 8 bit
def div_roundup(x,y):
\documentclass[a4paper, 12pt]{article}
\usepackage{amsmath,amsthm,amssymb}
%\usepackage{diagrams}
\usepackage[french]{babel}
\usepackage[latin1]{inputenc}
\usepackage{hyperref}
\input xy
@ibaaj
ibaaj / 360TimelapseTutorial.md
Created October 13, 2017 18:51 — forked from Tomasvrba/360TimelapseTutorial.md
HD 360° Timelapse and FFmpeg tutorial

How to capture, stitch and publish a 360° timelapse

Consumer ready 360° cameras are becoming ever more accessible and many people are experimenting with a variety of 360° content. Out of the many cameras on the market the Ricoh Theta S is one of the most user-friendly, turn-key solutions with lots of built-in features. However, the camera's videos are limited 1920x960 resolution and the Theta+ app only lets you create a timelapse with up to 300 or 400 images. The workaround is to use interval shooting to capture as many images as you'd like at the 5376x2688 to full resolution and then stitch them together manually into an HD video. There are few GUI solutions (especially open-source/free) which let you do this with ease. Here's how you do it:

Set up interval shooting on your Ricoh Theta S

#!/bin/zsh
rm -rf ./frames ./ftop ./fbottom ./final;
mkdir -p {frames,ftop,fbottom,final};
ffmpeg -i IMG_6501.MOV -r 25 -qscale:v 2 frames/%05d.jpg ;
framesNumber=$(ls ./frames/*.jpg |wc -l|tr -d ' ');
C_H=540
digraph mainmap {
resolution = 72;
node [fontsize = 10];
edge [fontsize = 9];
overlap = false;
sep=0.4
splines=true;xSatisfiability [label= "SATISFIABILITY" URL= "http://en.wikipedia.org/wiki/Satisfiability"style="bold", shape="ellipse", peripheries="2", fontsize ="14"];
xCircuitSatisfiability [label= "CIRCUIT SATISFIABILITY" URL= "" style ="filled", fillcolor ="#eeeeee" style="bold", shape="ellipse", peripheries="2", fontsize ="14"];
xMaxCut [label= "MAX CUT" URL= "http://en.wikipedia.org/wiki/Cut_(graph_theory)#Minimal_and_maximal_cuts"];
xJobSequencing [label= "JOB SEQUENCING" URL= "" style ="filled", fillcolor ="#eeeeee" ];
@ibaaj
ibaaj / get.py
Created May 9, 2017 00:37
09/05 bot
import json
import csv
thuneEUR = 100
thuneETH = 0
paramChange = 1
s = 0 # 0 = faire rien, -{paramChange} vendre, +{paramChange} acheter