Skip to content

Instantly share code, notes, and snippets.

@ericvenarusso
ericvenarusso / config.yaml
Created November 19, 2021 02:52
Example using Pydantic as Schema for YAML Files
name: 'Eric Venarusso'
age: '21'
sex: 'male'
sports:
- name: 'soccer'
team:
name: 'corinthians'
- name: 'basketball'
@MattPitlyk
MattPitlyk / fine-tuning-gpt-2-on-a-custom-dataset.ipynb
Created February 14, 2020 19:14
Fine-Tuning GPT-2 on a Custom Dataset
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
<?php
use Amp\Emitter;
use Amp\Iterator;
use Amp\Promise;
class CsvReader implements Iterator {
/** @var EventEmitter */
private $eventEmitter;
@boombatower
boombatower / download.php
Created September 27, 2015 05:15
Web scraper for vbulletin. Create pdf of pages and whole thread and downloads all attached images.
<?php
const BASE = '';
const COUNT = 1;
$pages = [];
for ($i = 1; $i <= COUNT; $i++) {
$suffix = $i > 1 ? '/page' . $i : '';
$pages[] = $page = 'page' . $i . '.pdf';
$url = BASE . $suffix;
@glombard
glombard / setup-wifi.sh
Created July 22, 2014 18:57
Install wifi drivers for Ubuntu / Lubuntu 14.04 on Acer Aspire 5755G (Broadcom BCM43227 network controller)
# Determine wireless device model (manufacturer 14e4 for Broadcom):
lspci -vvnn | grep 14e4
# Install Broadcom STA driver for BCM43227:
sudo apt-get update
sudo apt-get install --reinstall linux-headers-generic build-essential dkms bcmwl-kernel-source
sudo modprobe -r b43 ssb wl brcmfmac brcmsmac bcma
sudo modprobe wl
# Connect (press Fn+F3 to enable wifi if necessary first):