This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import re | |
import subprocess | |
def get_blur_values(video_path, start_time, duration): | |
command = [ | |
"ffmpeg", | |
"-i", video_path, | |
"-vf", f"blurdetect=block_width=32:block_height=32,metadata=print:file=-", | |
"-ss", str(start_time), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Program | |
{ | |
private static void Main(string[] _) | |
{ | |
// Initialize StereoKit | |
SKSettings settings = new() | |
{ | |
appName = "ModelScaleSK", | |
assetsFolder = "Assets", | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace SKAudioGraph | |
{ | |
using StereoKit; | |
using System; | |
using System.Linq; | |
using System.Runtime.InteropServices; | |
using System.Threading; | |
using System.Threading.Tasks; | |
using Windows.Foundation; | |
using Windows.Media; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace SKAudioGraph | |
{ | |
using StereoKit; | |
using System; | |
using System.Runtime.InteropServices; | |
using System.Threading.Tasks; | |
using Windows.Foundation; | |
using Windows.Media; | |
using Windows.Media.Audio; | |
using Windows.Media.MediaProperties; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// <copyright file="Program.cs" company="Nakamir, Inc."> | |
// Copyright (c) Nakamir, Inc. All rights reserved. | |
// </copyright> | |
namespace SK.AudioCapture.UWP; | |
using StereoKit; | |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Runtime.InteropServices; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cv2 | |
import numpy as np | |
logo_name = "original-logo.png" | |
logo = cv2.imread(logo_name, cv2.IMREAD_UNCHANGED) | |
assert(logo.any()) | |
h, w, s = logo.shape | |
if w > h: | |
out_img = np.zeros((w, w, s)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cv2 | |
import numpy as np | |
def psycho(img, trippy_factor=1./3): | |
ris = img.astype(np.float32) | |
ris += cv2.randn(img.copy(), 0, 10) | |
kernel = np.zeros((3,3), dtype=np.float32) | |
kernel.fill(trippy_factor) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cv2 as cv | |
import numpy as np | |
dictionary = cv.aruco.Dictionary_get(cv.aruco.DICT_6X6_50) | |
num_markers_x = 4 | |
num_markers_y = 4 | |
marker_length = 0.04 | |
marker_separation = 0.01 |