Skip to content

Instantly share code, notes, and snippets.

View zsun14's full-sized avatar

zsun14 zsun14

  • 04:35 (UTC +08:00)
View GitHub Profile
@zsun14
zsun14 / TreeView.py
Created January 22, 2024 03:39 — forked from sunnymax2002/TreeView.py
Wrapper over Treelib to easily generate and update required data for nicegui Tree
from typing import Dict
from treelib import Node, Tree
class TreeNode:
"""If parent_id is -1, node at root level"""
def __init__(self, id, parent_id, disp_text, node_data = None) -> None:
self.id: int = id
self.parent_id: int = parent_id
self.disp_text: str = disp_text
self.node_data = node_data
@zsun14
zsun14 / cuda_11.2_installation_on_Ubuntu_20.04
Created April 2, 2022 07:15 — forked from Mahedi-61/cuda_11.8_installation_on_Ubuntu_22.04
Instructions for CUDA v11.2 and cuDNN 8.1 installation on Ubuntu 20.04 for Pytorch 1.8 & Tensorflow 2.7.0
#!/bin/bash
### steps ####
# verify the system has a cuda-capable gpu
# download and install the nvidia cuda toolkit and cudnn
# setup environmental variables
# verify the installation
###
### to verify your gpu is cuda enable check