Skip to content

Instantly share code, notes, and snippets.

View munaAchyuta's full-sized avatar
😊

bamana munaAchyuta

😊
View GitHub Profile
import transformers
from datasets import load_dataset
from sklearn.preprocessing import MinMaxScaler
import shap
from rubrix import TextClassificationRecord, TokenAttributions
import rubrix as rb
@jph00
jph00 / webserver.py
Created November 17, 2020 19:18
Minimal web server demo in Python (requires fastcore: `pip install fastcore`)
from fastcore.utils import *
host = 8888,'localhost'
sock = start_server(*host)
print(f'Serving on {host}...')
while True:
conn,addr = sock.accept()
with conn:
data = conn.recv(1024)
print(data.decode())
@jcheong0428
jcheong0428 / synchrony_tutorial.ipynb
Last active February 12, 2024 11:33
Synchrony tutorial notebook
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@vandbt
vandbt / how to install PyTorch in windows 10
Created December 14, 2018 16:06
How to Install PyTorch in Windows 10
1. Install Python
https://www.python.org/downloads/
2. update pip
python -m pip install --upgrade pip
3. install numpy first
according to PyTorch official guide recommand that install numpy first.
pip install numpy
@W4ngatang
W4ngatang / download_glue_data.py
Last active March 3, 2024 18:45
Script for downloading data of the GLUE benchmark (gluebenchmark.com)
''' Script for downloading all GLUE data.
Note: for legal reasons, we are unable to host MRPC.
You can either use the version hosted by the SentEval team, which is already tokenized,
or you can download the original data from (https://download.microsoft.com/download/D/4/6/D46FF87A-F6B9-4252-AA8B-3604ED519838/MSRParaphraseCorpus.msi) and extract the data from it manually.
For Windows users, you can run the .msi file. For Mac and Linux users, consider an external library such as 'cabextract' (see below for an example).
You should then rename and place specific files in a folder (see below for an example).
mkdir MRPC
cabextract MSRParaphraseCorpus.msi -d MRPC