Skip to content

Instantly share code, notes, and snippets.

Avatar

e96031413

View GitHub Profile
@yinguobing
yinguobing / process_video.py
Last active August 26, 2022 01:39
Template module for video frame processing.
View process_video.py
"""Template code for video frame processing.
Features:
- video source from files or webcams.
- automatically flip the frame if reading from webcam.
- built in video writer to output the processed result.
- built in FPS metter.
For more: https://github.com/yinguobing
"""
@YashasSamaga
YashasSamaga / yolov4.py
Last active February 25, 2023 10:09
YOLOv4 on OpenCV DNN
View yolov4.py
import cv2
import time
CONFIDENCE_THRESHOLD = 0.2
NMS_THRESHOLD = 0.4
COLORS = [(0, 255, 255), (255, 255, 0), (0, 255, 0), (255, 0, 0)]
class_names = []
with open("classes.txt", "r") as f:
class_names = [cname.strip() for cname in f.readlines()]
@jpwiedekopf
jpwiedekopf / cross_stitch.py
Created October 5, 2019 21:48
CrossStitch (from Misra et al 2016, arXiv:1604.03539) in tf.keras (Tensorflow 2)
View cross_stitch.py
import tensorflow as tf
class CrossStitch(tf.keras.layers.Layer):
"""Cross-Stitch implementation according to arXiv:1604.03539
Implementation adapted from https://github.com/helloyide/Cross-stitch-Networks-for-Multi-task-Learning"""
def __init__(self, num_tasks, *args, **kwargs):
"""initialize class variables"""
@pknowledge
pknowledge / text_file_to_speech.py
Created September 10, 2019 20:57
TEXT TO SPEECH IN PYTHON | Convert Text to Speech in Python
View text_file_to_speech.py
# Import the Gtts module for text
# to speech conversion
from gtts import gTTS
# import Os module to start the audio file
import os
fh = open("test.txt", "r")
myText = fh.read().replace("\n", " ")
@bradtraversy
bradtraversy / django_crash_course.MD
Last active March 21, 2023 17:50
Commands for Django 2.x Crash Course
View django_crash_course.MD

Django Crash Course Commands

# Install pipenv
pip install pipenv
# Create Venv
pipenv shell
@JerryLokjianming
JerryLokjianming / Crack Sublime Text Windows and Linux.md
Last active March 27, 2023 02:12
Crack Sublime Text 3.2.2 Build 3211 and Sublime Text 4 Alpha 4098 with Hex
View Crack Sublime Text Windows and Linux.md

YouTube Channel https://www.youtube.com/c/jerrylokjianming


How to Crack Sublime Text 3.2.2 Build 3211 with Hex Editor (Windows | Without License) ↓

  1. Download & Install Sublime Text 3.2.2 Build 3211
  2. Visit https://hexed.it/
@CraftingGamerTom
CraftingGamerTom / Learn Git Branching.md
Last active March 22, 2023 15:26
learn-git-branching-solution learn-git-branching-main learn-git-branching-remote learn git branching solution learn git branching main learn git branching remote
View Learn Git Branching.md

Learning Git Branching

Please do not continue if you have not learned the content covered in these assignments. It is important to learn the material. However if, like me, you find yourself needing to complete arbitrary tasks for classes you are capable of testing out of - but its not offered. Please continue...

README: To use this quickly, copy and paste the entire block of code in the 'console' using CTRL-V. They have been written so you do not need to copy each line, one-by-one

Main

1.1 Introduction to Git Commits

@matteocrippa
matteocrippa / flutter.md
Last active March 24, 2023 23:41
Flutter Cheatsheet
View flutter.md

Flutter

A quick cheatsheet of useful snippet for Flutter

Widget

A widget is the basic type of controller in Flutter Material. There are two type of basic Widget we can extend our classes: StatefulWidget or StatelessWidget.

Stateful

StatefulWidget are all the widget that interally have a dynamic value that can change during usage. It can receive an input value in the constructor or reference to functions. You need to create two classes like:

@sibelius
sibelius / learning.md
Last active March 22, 2022 11:05
Learning Path React Native
View learning.md

Basics

  • Learn how to start a new react native project
  • Run it on ios simulator, on android emulator, on a real iPhone device and on a real Android device, with and without debugging enabled.
  • Learn how to upgrade a react native project
  • Learn how to add a package to the project
  • Learn how to add a package that has a native dependency (https://github.com/airbnb/react-native-maps, https://github.com/evollu/react-native-fcm) - DO NOT USE COCOAPODS
  • Learn how to use fetch to get data from your backend

Learn Navigation

@wojteklu
wojteklu / clean_code.md
Last active March 29, 2023 18:02
Summary of 'Clean code' by Robert C. Martin
View clean_code.md

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules