Background remover
[1] https://www.cutout.pro/remove-video-background #5s
Video splitter
[1] https://echowave.io/app/tools/split/ #many parts
Software Developer, Programming, Web resources and entertaiment. Desarrollo de software, programación, recursos web y entretenimiento.
Background remover
[1] https://www.cutout.pro/remove-video-background #5s
Video splitter
[1] https://echowave.io/app/tools/split/ #many parts
#Learn more: https://stepik.org/lesson/9173
stepik (background revisor code)
import random
def generate(): #create test cases
num_tests = 50
tests = []
tests.append("5\n")
tests.append("11\n")
tests.append("18\n")
for test in range(num_tests):
test_case = "%d\n" % (test)
tests.append(test_case)
tests.append("200\n")
return tests
def solve(dataset): #real solution
n = int(dataset.strip())
if (n == 0):
f = 0;
elif (n == 1):
f = 1;
else:
fm1 = 0
fm2 = 1
for i in range(n):
f = fm1 + fm2
fm2 = fm1
fm1 = f
return str(f)
def check(reply, clue): #validator
return int(reply) == int(clue)
python code snippet to get url for use with vlc and show the camera on LAN
#connection code , previously done in this blog
media = camera.create_media_service()
profiles = media.GetProfiles()
for p in profiles:
print("Profile:", p.Name)
print("Token:", p.token)
uri = media.GetStreamUri({
'StreamSetup': {
'Stream': 'RTP-Unicast',
'Transport': {
'Protocol': 'RTSP'
}
},
'ProfileToken': p.token
})
print("RTSP:", uri.Uri)
print()
#
vlc 'rtsp://admin:your_key@192.168.1.8:554/Streaming/Channels/101?transportmode=unicast&profile=Profile_1'
python code to test camera ONVIF(EZVIZ) on LAN, if you do not know the ip, use nmap to scan.
from onvif import ONVIFCamera
camera = ONVIFCamera(
'192.168.1.8',
80,
'admin',
'your_key', #get from QR or app
no_cache=True
)
print("Connected to ONVIF")
info = camera.devicemgmt.GetDeviceInformation()
print("Manufacturer:", info.Manufacturer)
print("Model:", info.Model)
print("Firmware:", info.FirmwareVersion)
print("Serial:", info.SerialNumber)
print("Hardware ID:", info.HardwareId)
[1] Slides +Animation https://slidespeak.co/free-tools/animate-slides-with-ai
[2] Slides to mp4 https://slidespeak.co/free-tools/convert-powerpoint-to-video-ai
[3] https://app.synthesia.io (To get text to speak/chrome)
[4] Animation introductions https://www.flexclip.com (To get intro)
References:
[1] gas sensors MQx https://naylampmechatronics.com/blog/42_tutorial-sensores-de-gas-mq2-mq3-mq7-y-mq135.html
[2] gas sensor MQ135 https://www.tecneu.com/blogs/tutoriales-de-electronica/mq135
[3] gas sensor MQ137 (Ammonia) https://circuitdigest.com/microcontroller-projects/arduino-mq137-ammonia-sensor
Resources(wifi):
[1] https://mecatronica.saisac.pe/producto/modulo-esp-01-esp8266-wifi/
[2] https://www.electromania.pe/?s=ESP8266&post_type=product
[3] https://www.teslaelectronic.com.pe/producto/modulo-esp8266-serial-wifi/?srsltid=AfmBOoq-9awBhXa6sHpJDswF0XyhD_mICthqr3IEZgQzeOaCFI0GygXP
avrdude: ser_open(): can't open device "/dev/ttyACM0": Permission denied
$ ls -l /dev/ttyACM*
crw-rw-r-- 1 root dialout ... /dev/ttyACM0
Fix:
sudo chmod a+rw /dev/ttyACM0
Resources:
[1] https://www.arduino.cc/en/software/
[2] Simulator https://www.tinkercad.com/
Resources:
[1] https://www.vosviewer.com/download
[2] https://www.vosviewer.com/documentation/Manual_VOSviewer_1.6.20.pdf
[3] https://api.crossref.org/swagger-ui/index.html #how to query
How to run on PC/Linux
javaws file.jnlpIf not installed:
sudo apt install icedtea-netx
echo "HISTSIZE=$HISTSIZE"
echo "HISTFILESIZE=$HISTFILESIZE"
#update the .bachrc file
# Keep more commands in memory
HISTSIZE=10000
# Keep more (or unlimited) lines in the history file
HISTFILESIZE=100000
# or for effectively unlimited on Bash ≥4.3:
# HISTFILESIZE=-1
Escenary: You need to upload many files to github, then need to clone, add the files and upload from local, instead file by file.
cd Downloads/UnsaTesis/Waste/
ls
mkdir github
cd github
git clone https://github.com/fincahuanaco/solid_waste_peru.git
ls
cd solid_waste_peru/
ls
git add .
git commit -m "Add maps of Lima and Arequipa"
git config --global user.email "you@example.com"
git commit -m "Add maps of Lima and Arequipa"
#after added files to directory
git push origin main
git config --global user.email "you@example.com"
git push origin main
git config --global credential.helper store
#store credentials on disk
clear
git push origin main
Change image size during paper writing (overleaf time compilation affected)
sudo apt install pngquant
pngquant --quality=90-100 budget_map.png
pngquant --quality=85-95 waste_stress_result.png #more aggressive
sudo apt install oxipng
#does not installed for me
Bonus
Cut video using ffmpeg
ffmpeg -ss 00:30:30 -i DAIA-Mat-Sec2-S15.mp4 -c copy DAIA-Mat-Sec2-S15_output.mp4
Caso Cantuta 90's
[1] https://www.infobae.com/america/peru/2022/07/23/masacre-de-la-cantuta-el-crimen-de-los-estudiantes-a-manos-de-asesinos-encubiertos-en-las-fuerzas-armadas/
[2] https://elpais.com/internacional/2023-05-29/caso-la-cantuta-los-restos-de-las-victimas-que-permanecieron-en-inglaterra-durante-30-anos.html
String search: ipsos Distribución Poblacional 2022
[1] 2010-2025 https://cpi.pe/banco-de-datos/estadisticas-poblacionales/
Air quality
[1] Map https://www.iqair.com/es/air-quality-map
[2] https://www.senamhi.gob.pe/?p=calidad-del-aire-pronostico
[3] Air and others https://sinia.minam.gob.pe/portal/estadisticas-del-sector-ambiente/?marcoOrdenador=sinia&eid=45&tab=datos
[4] PM2.5, PM10, NO2 https://sinia.minam.gob.pe/portal/estadisticas-del-sector-ambiente/?marcoOrdenador=sinia&eid=148&tab=datos
[1] Crime Index https://www.numbeo.com/crime/rankings.jsp
[2] Traffic Index https://www.numbeo.com/traffic/rankings_by_country.jsp
Resources:
[1] https://objectiveunclear.com/
[2] Airplanes Live 3D https://objectiveunclear.com/airloom.html
[3] https://airplanes.live/
[4] Lima https://globe.airplanes.live/?icao=e80329
Background remover [1] https://www.cutout.pro/remove-video-background #5s Video splitter [1] https://echowave.io/app/tools/split/ #many pa...