Skip to content

Instantly share code, notes, and snippets.

View liepieshov's full-sized avatar
🇺🇦
Pythonista from Ukraine

Kostiantyn Liepieshov liepieshov

🇺🇦
Pythonista from Ukraine
  • London, UK
View GitHub Profile
@liepieshov
liepieshov / userChrome.css
Last active June 5, 2023 22:49
Firefox hide top tabs and treestyletab header for TreeStyleTab firefox addon
@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
/* to know your profile dir location go to about:config in your firefox browser */
.tab-background {
background-color: red; /* this sets the color of the tab background */
}
.tab-line {
background-color : red; /* this sets the color of the line above the tab */
@liepieshov
liepieshov / treestyletabStyle.css
Last active June 5, 2023 22:47
Best theming for treestyletab extension in Firefox Dev Edition + Photon theme #justtryit
/* Show title of unread tabs with red and italic font */
/*
.tab.unread .label {
color: red !important;
font-style: italic !important;
}
*/
.tab {
height: 25px;
padding-left: 0;
@liepieshov
liepieshov / gapminder.csv
Created December 27, 2019 20:44
Dataviz gapminder with geo-legend
country continent year gdpPerCap lifeExp pop
Afghanistan Asia 2009 1454.6630148346899 60.483999999999995 28394813
Afghanistan Asia 2010 1637.3779870888 61.028 29185507
Afghanistan Asia 2011 1626.76479325583 61.553000000000004 30117413
Afghanistan Asia 2012 1806.7639297532603 62.053999999999995 31161376
Afghanistan Asia 2013 1874.7656344942002 62.525 32269589
Afghanistan Asia 2014 1897.5259375952103 62.966 33370794
Afghanistan Asia 2015 1886.6929769036103 63.376999999999995 34413603
Afghanistan Asia 2016 1896.9925195748199 63.763000000000005 35383128
Afghanistan Asia 2017 1934.6367541203501 64.13 36296400
@liepieshov
liepieshov / 2nd_file.csv
Created December 27, 2019 00:30
Dataviz data
year growth_rate growth_index
2007 7.90000000000001 100
2008 2.3 102
2009 -14.8 97
2010 4.09999999999999 101
2011 5.2 107
2012 0.200000000000003 107
2013 0 107
2014 -6.59999999999999 100
2015 -9.8 90
@liepieshov
liepieshov / install-cuda.md
Last active January 4, 2022 03:38
Installation guide cuda-10-0 with cudnn 7.5 on Ubuntu (for Tensorflow/Pytorch)

Installation guide cuda-10-0 with cudnn 7.5 on Ubuntu (for Tensorflow/Pytorch)

Remove previous versions of CUDA:

sudo apt-get purge nvidia*
sudo apt-get autoremove
sudo apt-get autoclean
sudo rm -rf /usr/local/cuda*

Install cuda

Go to Nvidia site here https://developer.nvidia.com/cuda-10.0-download-archive

@liepieshov
liepieshov / confusion_matrix_pretty_print.py
Last active May 31, 2020 09:32 — forked from shaypal5/confusion_matrix_pretty_print.py
Pretty print a confusion matrix with seaborn
import pandas as pd
import matplotlib.pyplot as plt
import seaborn as sns
def print_confusion_matrix(confusion_matrix, class_names, normalize=True, figsize = (10,7), fontsize=14):
"""Prints a confusion matrix, as returned by sklearn.metrics.confusion_matrix, as a heatmap.
Arguments
---------
confusion_matrix: numpy.ndarray
@liepieshov
liepieshov / README.md
Last active September 25, 2019 15:58
Playing with Mongodb in nodejs

Playing with some functionalities of mongodb

Run with

node --experimental-modules main.mjs