Skip to content

Instantly share code, notes, and snippets.

View yunho-c's full-sized avatar
👋

Yunho Cho yunho-c

👋
View GitHub Profile
@yunho-c
yunho-c / pdf_oxide_pdf2md.py
Created March 1, 2026 19:09
Convert PDF to Markdown using `pdf_oxide`
"""Simple CLI example: convert a PDF file to Markdown using pdf_oxide."""
from pathlib import Path
import typer
from pdf_oxide import PdfDocument
app = typer.Typer(
@yunho-c
yunho-c / index.html
Created February 28, 2026 02:00
jazz night
<div id="container"></div>
<div id="texture_holder">
<img src='https://s3-us-west-2.amazonaws.com/s.cdpn.io/61062/player_texture.jpg' id="texture_man" crossOrigin="anonymous">
<img src='https://s3-us-west-2.amazonaws.com/s.cdpn.io/61062/trumpet_texture.jpg' id="texture_saxo" crossOrigin="anonymous">
<img src='https://s3-us-west-2.amazonaws.com/s.cdpn.io/61062/stage_texture_base.png' id="texture_stage" crossOrigin="anonymous">
<img src='https://s3-us-west-2.amazonaws.com/s.cdpn.io/61062/piano_texture.jpg' id="texture_piano" crossOrigin="anonymous">
<img src='https://s3-us-west-2.amazonaws.com/s.cdpn.io/61062/drum_texture.jpg' id="texture_drum" crossOrigin="anonymous">
<img src='https://s3-us-west-2.amazonaws.com/s.cdpn.io/61062/trumpet_texture.jpg' id="texture_trumpet" crossOrigin="anonymous">
<img src='https://s3-us-west-2.amazonaws.com/s.cdpn.io/61062/kontrabass_texture.jpg' id="texture_kontrabass" crossOrigin="anonymous">
</div>
@yunho-c
yunho-c / urdf2mjcf.py
Created August 9, 2025 18:41
Convert URDF to MJCF
import argparse
import mujoco
from pathlib import Path
def main():
parser = argparse.ArgumentParser(description="Convert a URDF file to a MuJoCo XML file.")
parser.add_argument("input_file", help="The input URDF file path.")
# parser.add_argument("output_file", help="The output XML file path.")
args = parser.parse_args()
@yunho-c
yunho-c / remove_ds_store.sh
Created July 16, 2025 13:49
Remove .DS_Store from current directory and all subdirectories
find . -name ".DS_Store" -delete -print
@yunho-c
yunho-c / ffmpeg-cheatsheet.md
Created July 12, 2025 22:10 — forked from nickkraakman/ffmpeg-cheatsheet.md
FFmpeg cheat sheet for 360 video

FFmpeg Cheat Sheet for 360º video

Brought to you by Headjack

 
FFmpeg is one of the most powerful tools for video transcoding and manipulation, but it's fairly complex and confusing to use. That's why I decided to create this cheat sheet which shows some of the most often used commands.

 
Let's start with some basics:

  • ffmpeg calls the FFmpeg application in the command line window, could also be the full path to the FFmpeg binary or .exe file

Github to Discord Webhook Tutorial

In this tutorial I'll show you how to create a Github webhook that will post updates from your Github account to a channel in Discord. The steps are simple so follow along!

Create a Webhook in a Discord Channel

First you need to create a webhook in a text channel. We're assuming you have both Manage Channel and Manage Webhooks permissions!

  • Go in a channel properties (Alternatively, Server Settings, Webhooks works too)
@yunho-c
yunho-c / sync_jupyter.py
Created June 7, 2025 16:54
Sync `.ipynb` and `.py` files based on last modified time
"""
A script to synchronize Jupyter notebooks (.ipynb) and Python scripts (.py).
This script scans a specified directory for pairs of .py and .ipynb files
with the same base name. It then compares their last modification times
and copies the newer onto the older using `jupytext`.
This is useful for those who prefer to track Jupyter Notebooks in .py files.
Usage:
@yunho-c
yunho-c / Count lines in Git repo
Created June 6, 2025 01:06 — forked from mandiwise/Count lines in Git repo
A command to calculate lines of code in all tracked files in a Git repo
// Reference: http://stackoverflow.com/questions/4822471/count-number-of-lines-in-a-git-repository
$ git ls-files | xargs wc -l
@yunho-c
yunho-c / languages.json
Last active June 3, 2025 21:25
A JSON file of major languages with country mappings and names
{
"none": {
"english_name": "",
"native_name": "",
"countries": []
},
"aa": {
"english_name": "Afar",
"native_name": "Qafar af",
"countries": [
@yunho-c
yunho-c / make_white_pixels_transparent.py
Created April 20, 2025 23:02
Python script to make white pixels transparent
import sys
import argparse
from PIL import Image
import numpy as np
def add_transparency(input_path, output_path, threshold=240):
"""
Add alpha channel to an image based on brightness threshold.
Makes pixels with brightness >= threshold transparent.