Skip to content

Instantly share code, notes, and snippets.

View lakshanthad's full-sized avatar
🚀

Lakshantha Dissanayake lakshanthad

🚀
View GitHub Profile
@lakshanthad
lakshanthad / CUDA-TensorRT-Path-Fix.sh
Last active September 4, 2022 18:09
Add TensorRT and CUDA path
#!/bin/bash
echo -e '\n# set environment variable for TensorRT' >> ~/.bashrc
echo 'export TENSORRT_DIR=/usr/include/aarch64-linux-gnu' >> ~/.bashrc
echo -e '\n# set environment variable for CUDA' >> ~/.bashrc
echo 'export PATH=$PATH:/usr/local/cuda/bin' >> ~/.bashrc
echo 'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda/lib64' >> ~/.bashrc
source ~/.bashrc
@lakshanthad
lakshanthad / jetson-free-space.sh
Created July 25, 2022 17:40
Remove around 40% of space on Jetson
# Remove unnecessary packages, clean apt cache and remove thunderbird, libreoffice
apt update
apt autoremove -y
apt clean
apt remove thunderbird libreoffice-* -y
# Remove samples
rm -rf /usr/local/cuda/samples \
/usr/src/cudnn_samples_* \
/usr/src/tensorrt/data \
@lakshanthad
lakshanthad / yolov5-training-for-sensecap-a1101.ipynb
Last active March 23, 2023 15:53
YOLOV5-training-for-Vision-AI.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
function Decoder(bytes, port) {
var decoded = {};
function transformersint(bytes){
value = bytes[0] * 256 + bytes[1];
if (value == 32768){
return;
}
if (value > 32768) {
#!/bin/bash
# Get the Python version
python_version=$(python3 -c 'import sys; print("{:.2f}".format(float(".".join(map(str, sys.version_info[:2])))))')
echo -e '\n# set environment variable for Torch' >> ~/.bashrc
echo 'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.local/lib/python'$python_version'/site-packages/torch.libs:$HOME/.local/lib/python'$python_version'/site-packages/torch/lib' >> ~/.bashrc
sleep 2