This file contains hidden or 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
import numpy as np | |
import cv2 | |
import os | |
import sys | |
import requests | |
import torch | |
import detectron2 | |
#from detectron2.utils.visualizer import Visualizer | |
from detectron2.data.catalog import MetadataCatalog, DatasetCatalog |
This file contains hidden or 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
>>>> ZSH | |
ZSH_THEME="bunnyruni" | |
plugins=(git zsh-wakatime) | |
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda-10.0/lib64 | |
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/chieh/Downloads/TensorRT7_cuda100/lib | |
export CUDA_HOME=/usr/local/cuda-10.0 | |
export CUDA_INSTALL_DIR=/usr/local/cuda-10.0 | |
#export CUDNN_INSTALL_DIR=/home/chieh/Downloads/cuda_102_cudnn76 |
This file contains hidden or 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
File = 'file_name.txt' | |
Location = '/home/chieh/(Path)' | |
File_path = os.path.join(os.path.abspath(Location), File) | |
assert os.path.isfile(File_path), "Cannot find the file_name.txt file." | |
with open(File_path, 'r') as f: | |
data = f.read().splitlines() |
This file contains hidden or 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
Powerful tools: | |
- Typora : https://typora.io/ | |
- Marp : https://marp.app/ | |
- Slides : https://slides.com/ | |
- Whimsical : https://whimsical.com/ | |
- Flameshot : https://flameshot.js.org/#/ | |
For Data Visualization: | |
- StreamLit : https://www.streamlit.io/ |
This file contains hidden or 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
Extension List: | |
- Better Comments : https://marketplace.visualstudio.com/items?itemName=aaron-bond.better-comments | |
- Atom One Dark Theme : https://marketplace.visualstudio.com/items?itemName=akamud.vscode-theme-onedark | |
- Power Mode : https://marketplace.visualstudio.com/items?itemName=hoovercj.vscode-power-mode | |
- Python : https://marketplace.visualstudio.com/items?itemName=ms-python.python | |
- Material Icon Theme : https://marketplace.visualstudio.com/items?itemName=PKief.material-icon-theme | |
- TODO Highlight : https://marketplace.visualstudio.com/items?itemName=wayou.vscode-todo-highlight | |
- Markdown All in One : https://marketplace.visualstudio.com/items?itemName=yzhang.markdown-all-in-one | |
- Remote - Containers : https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers |
This file contains hidden or 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
import sys | |
import xlwt | |
book = xlwt.Workbook(encoding="utf-8") | |
sheet1 = book.add_sheet("Sheet1") | |
def main(orig_args, data): | |
filename = "speed_time.xls" | |
output(filename, data) |
This file contains hidden or 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
import os | |
def batch_rename(path): | |
count = 0 | |
total = len(os.listdir(path)) | |
for fname in os.listdir(path): | |
time = total - len(str(count)) | |
Extension = fname.split('.')[-1] | |
new_fname = str(0*(time)) + str(count) + '.' + Extension |
This file contains hidden or 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
file name : .flake8 | |
``` | |
[flake8] | |
max-line-length = 100 | |
``` | |
file name : .editorconfig | |
``` |
This file contains hidden or 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 nvcr.io/nvidia/tensorrt:20.03-py3 | |
ENV TEST_PAR=TEST_dockerfile_env |
This file contains hidden or 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
#!/bin/bash | |
apt-get update && apt-get install -y zsh autojump fonts-powerline | |
sudo chsh -s /bin/zsh | |
wget https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh -O - | zsh || true | |
## Resolved: Could not resolve host: github.com | |
git config --global --unset http.proxy | |
git config --global --unset https.proxy |
OlderNewer