This note about software, config in my Ubuntu.
sudo swapoff -a
sudo fallocate -l 1G /swap.img
sudo chmod 600 /swap.img| #!/bin/sh | |
| # Auto install Postman | |
| # Khiem Doan <[email protected]> | |
| # use for Ubuntu | |
| postman_download_url='https://dl.pstmn.io/download/latest/linux64' | |
| file_name='/tmp/postman-linux-x64.tar.gz' | |
| destination_dir='/usr/share/postman' | |
| symbolic_link='/usr/bin/postman' |
| #!/usr/bin/env python3 | |
| # -*- coding: utf-8 -*- | |
| """Remove Vietnamese tones function""" | |
| """Author: Khiem Doan""" | |
| uni_chars_l = 'áàảãạâấầẩẫậăắằẳẵặđèéẻẽẹêếềểễệíìỉĩịóòỏõọôốồổỗộơớờởỡợúùủũụưứừửữựýỳỷỹỵ' | |
| uni_chars_u = 'ÁÀẢÃẠÂẤẦẨẪẬĂẮẰẲẴẶĐÈÉẺẼẸÊẾỀỂỄỆÍÌỈĨỊÓÒỎÕỌÔỐỒỔỖỘƠỚỜỞỠỢÚÙỦŨỤƯỨỪỬỮỰÝỲỶỸỴ' | |
| no_tone_chars_l = 'a'*17 + 'd' + 'e'*11 + 'i'*5 + 'o'*17 + 'u'*11 + 'y'*5 |
| #!/bin/sh | |
| # Auto install Google Chrome | |
| # Khiem Doan <[email protected]> | |
| # use for Ubuntu | |
| sudo rm -f /etc/apt/sources.list.d/google-chrome.list | |
| wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add - | |
| echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" | sudo tee /etc/apt/sources.list.d/google-chrome.list | |
| sudo apt update |
| // KhiemDH - 2019-06-26 | |
| #ifndef _DBG_PRINT_KHIEMDH_ | |
| #define _DBG_PRINT_KHIEMDH_ | |
| #ifndef _DEBUG | |
| #define DbgPrint(_exp, ...) __noop |
| import logging | |
| import logging.handlers | |
| from pathlib import Path | |
| from utils import Filesystem | |
| __author__ = 'KhiemDH' | |
| __github__ = 'https://github.com/khiemdoan' | |
| __email__ = '[email protected]' |
from IPython.display import display
def summary_data(data):
print(f'Dataframe dimensions: {data.shape}')
tab_info = pd.DataFrame(data.dtypes).T.rename(index={0: 'column type'})
tab_info = tab_info.append(pd.DataFrame(data.isnull().sum()).T.rename(index={0: 'null values (nb)'}))
tab_info = tab_info.append(pd.DataFrame(data.isnull().sum() / data.shape[0] * 100).T.rename(index={0: 'null values (%)'}))
display(tab_info)