Skip to content

Instantly share code, notes, and snippets.

View userr2232's full-sized avatar
🌴
On vacation

Reynaldo RZ userr2232

🌴
On vacation
  • Vancouver, Canada
View GitHub Profile
@userr2232
userr2232 / multiprocess_selenium.py
Created December 24, 2023 00:34 — forked from wooddar/multiprocess_selenium.py
Easy Python script to run selenium web workers/browsers in parallel
"""
This is an adaptable example script for using selenium across multiple webbrowsers simultaneously. This makes use of
two queues - one to store idle webworkers and another to store data to pass to any idle webworkers in a selenium function
"""
from multiprocessing import Queue, cpu_count
from threading import Thread
from selenium import webdriver
from time import sleep
from numpy.random import randint
@userr2232
userr2232 / OneDriveError.cs
Created March 9, 2023 06:18
OneDrive Error Code Handling
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Newtonsoft.Json;
namespace Microsoft.OneDrive
{
public class OneDriveError
@userr2232
userr2232 / build.sh
Created July 10, 2021 06:15 — forked from lucasea777/build.sh
Python C Extension Hello World
gcc -fpic --shared $(python3-config --includes) greetmodule.c -o greet.abi3.so
# can also use $(pkg-config --cflags python-3.5)
# or
# python3 setup.py install --record files.txt --user
@userr2232
userr2232 / brats_challenge_starterkit.py
Created October 18, 2020 21:39 — forked from faustomilletari/brats_challenge_starterkit.py
BraTS 2020 challenge Eisen starter kit
"""
Eisen BraTS2020 challenge starter kit
NOTE: you need to register to the challenge, download and unpack the data in
order to be able to run the following example.
Find more info here: https://www.med.upenn.edu/cbica/brats2020/data.html
Information about Eisen can be found at http://eisen.ai -- Join the community on Slack https://bit.ly/2L7i6OL

Typing vagrant from the command line will display a list of all available commands.

Be sure that you are in the same directory as the Vagrantfile when running these commands!

Creating a VM

  • vagrant init -- Initialize Vagrant with a Vagrantfile and ./.vagrant directory, using no specified base image. Before you can do vagrant up, you'll need to specify a base image in the Vagrantfile.
  • vagrant init <boxpath> -- Initialize Vagrant with a specific box. To find a box, go to the public Vagrant box catalog. When you find one you like, just replace it's name with boxpath. For example, vagrant init ubuntu/trusty64.

Starting a VM

  • vagrant up -- starts vagrant environment (also provisions only on the FIRST vagrant up)

1. Clone your fork:

git clone [email protected]:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream