This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt update | |
sudo apt install build-essential git dkms | |
git clone https://github.com/brektrou/rtl8821CU.git | |
cd rtl8821CU | |
chmod +x dkms-install.sh | |
sudo ./dkms-install.sh | |
sudo modprobe 8821cu |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// S2 Geometry functions | |
// the regional scoreboard is based on a level 6 S2 Cell | |
// - https://docs.google.com/presentation/d/1Hl4KapfAENAOf4gv-pSngKwvS_jwNVHRPZTTDzXXn6Q/view?pli=1#slide=id.i22 | |
// at the time of writing there's no actual API for the intel map to retrieve scoreboard data, | |
// but it's still useful to plot the score cells on the intel map | |
// the S2 geometry is based on projecting the earth sphere onto a cube, with some scaling of face coordinates to | |
// keep things close to approximate equal area for adjacent cells | |
// to convert a lat,lng into a cell id: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from multiprocessing import Pool | |
import tqdm | |
def pmap(func, iterable, n_proc=8): | |
with Pool(n_proc) as p: | |
li = list(tqdm.tqdm_notebook(p.imap(func, iterable), total=len(iterable))) | |
return li |