Skip to content

Instantly share code, notes, and snippets.

@avsthiago
avsthiago / opencv_streamlit_webcam.md
Last active February 10, 2024 14:52
How to stream a webcam feed in a Streamlit application
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Thu Mar 29 09:57:55 2018
@author: avsthiago
"""
import numpy as np
np.random.seed(42)
{
"window.zoomLevel": 1,
"workbench.colorTheme": "Default Light+",
"python.jediEnabled": false,
"python.pythonPath": "python",
"python.terminal.launchArgs": [
"-c",
"\"from IPython import start_ipython; start_ipython()\"",
],
"files.autoSave": "afterDelay",
# Blender v2.78 (sub 0) OBJ File: 'somente_suporte.blend'
# www.blender.org
# Blender MTL File: 'somente_suporte.blend'
# Material Count: 2
newmtl Dimension_Red
Ns 0.000000
Ka 1.000000 1.000000 1.000000
Kd 1.000000 0.000000 0.000000
Ks 1.000000 0.000000 0.000000
This file has been truncated, but you can view the full file.
# Blender v2.78 (sub 0) OBJ File: 'somente_caixa.blend'
# www.blender.org
# Blender MTL File: 'somente_caixa.blend'
# Material Count: 11
newmtl Dimension_Red
Ns 0.000000
Ka 1.000000 1.000000 1.000000
Kd 1.000000 0.000000 0.000000
Ks 1.000000 0.000000 0.000000
@avsthiago
avsthiago / Data_augmentation_keras_opencv_brightness_hsv.py
Created April 8, 2018 17:58
Data augmentation using Keras ImageDataGenerator and OpenCV. Also with brightness augmentation.
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Thu Mar 29 09:57:55 2018
@author: avsthiago
"""
from keras.preprocessing.image import ImageDataGenerator
import numpy as np
@avsthiago
avsthiago / bar_primeiro_bimestre.py
Last active September 15, 2020 17:24
Controle bar threads
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
Created on Mon Apr 24 10:15:44 2017
@author: avsthiago, asales, rtibola
"""
"""
Problema Original
http://www.inf.pucrs.br/~emoreno/undergraduate/CC/sisop/sem12.1/material/trabalhos/TP2.pdf