Skip to content

Instantly share code, notes, and snippets.

View slitayem's full-sized avatar
๐Ÿ“ˆ

Saloua Litayem slitayem

๐Ÿ“ˆ
View GitHub Profile
@slitayem
slitayem / PyGameMP3Player.py
Created January 13, 2018 13:18 — forked from juehan/PyGameMP3Player.py
MP3Player Using PyGame
'''
Created on 2012. 2. 19.
This module is for playing mp3 (limited) and wav formatted audio file
@author: John
'''
import pygame
def playsound(soundfile):
"""Play sound through default mixer channel in blocking manner.
This will load the whole sound into memory before playback
@slitayem
slitayem / README.md
Created December 14, 2017 15:12 — forked from hofmannsven/README.md
My simply Git Cheatsheet
@slitayem
slitayem / spark2.2_hadoop2.7.4.md
Last active January 30, 2021 07:36
Install Spark 2.2 and Hadoop 2.7.4 with Jupyter and zeppelin on macOS Sierra
  • Install Homebrew if you don't have it yet
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

The script will explain what changes it will make and prompt you before the installation begins. Once youโ€™ve installed Homebrew, insert the Homebrew directory at the top of your PATH environment variable. You can do this by adding the following line at the bottom of your ~/.bash_profile file

export PATH=/usr/local/bin:/usr/local/sbin:$PATH
  • Install Python 3:
@slitayem
slitayem / pickle_vs_joblib_vs__pickle.py
Last active October 25, 2017 08:18
Comparison between pickle, _pickle and joblib
#!/usr/bin/env python3
from sklearn.externals import joblib
import numpy
import pickle
import _pickle
import timeit
def wrapper(func, *args, **kwargs):
@slitayem
slitayem / pylint.sh
Last active October 19, 2017 09:38
pylint all folder python files except virtualenv folder (venv) located in the project directory.
#!/usr/bin/env bash
# Author Saloua Litayem
# For more details about pylint check https://docs.pylint.org/en/1.6.0/index.html
if [ "$#" -lt 1 ]
then
echo "Usage: $0 folder_path [pylintrc file] [venv_folder(default: venv)]"
exit 1
fi
CMD="find $1 -name '*.py'"
# Install R + RStudio on Ubuntu 16.04
sudo apt-key adv โ€“keyserver keyserver.ubuntu.com โ€“recv-keys E084DAB9
# Ubuntu 12.04: precise
# Ubuntu 14.04: trusty
# Ubuntu 16.04: xenial
# Basic format of next line deb https://<my.favorite.cran.mirror>/bin/linux/ubuntu <enter your ubuntu version>/
sudo add-apt-repository 'deb https://ftp.ussg.iu.edu/CRAN/bin/linux/ubuntu xenial/'
sudo apt-get update
@slitayem
slitayem / s3gzip.py
Created September 26, 2017 14:23 — forked from veselosky/s3gzip.py
How to store and retrieve gzip-compressed objects in AWS S3
# vim: set fileencoding=utf-8 :
#
# How to store and retrieve gzip-compressed objects in AWS S3
###########################################################################
#
# Copyright 2015 Vince Veselosky and contributors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
@slitayem
slitayem / happy_git_on_osx.md
Created August 23, 2017 09:24 — forked from trey/happy_git_on_osx.md
Creating a Happy Git Environment on OS X

Creating a Happy Git Environment on OS X

Step 1: Install Git

brew install git bash-completion

Configure things:

git config --global user.name "Your Name"

git config --global user.email "[email protected]"

@slitayem
slitayem / SeleniumGridTutorial.md
Created June 14, 2017 11:32 — forked from dzitkowskik/SeleniumGridTutorial.md
A simple tutorial of using selenium grid in python unittests

Prepare files & libraries

  1. Download selenium standalone server from: http://goo.gl/rQhaxb, Create local folder at ~/selenium and copy or move jar to that path:
$ mkdir ~/selenium
$ cd ~/selenium
$ wget http://goo.gl/rQhaxb
$ mv selenium-server-standalone-2.49.1.jar ~/selenium/
@slitayem
slitayem / gist:008e803204f1f6219e4183ede6c974fe
Created June 8, 2017 12:34 — forked from rxaviers/gist:7360908
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: ๐Ÿ˜„ :smile: ๐Ÿ˜† :laughing:
๐Ÿ˜Š :blush: ๐Ÿ˜ƒ :smiley: โ˜บ๏ธ :relaxed:
๐Ÿ˜ :smirk: ๐Ÿ˜ :heart_eyes: ๐Ÿ˜˜ :kissing_heart:
๐Ÿ˜š :kissing_closed_eyes: ๐Ÿ˜ณ :flushed: ๐Ÿ˜Œ :relieved:
๐Ÿ˜† :satisfied: ๐Ÿ˜ :grin: ๐Ÿ˜‰ :wink:
๐Ÿ˜œ :stuck_out_tongue_winking_eye: ๐Ÿ˜ :stuck_out_tongue_closed_eyes: ๐Ÿ˜€ :grinning:
๐Ÿ˜— :kissing: ๐Ÿ˜™ :kissing_smiling_eyes: ๐Ÿ˜› :stuck_out_tongue: