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
# https://github.com/guillaumekln/faster-whisper | |
# pip install faster-whisper | |
# pip install nvidia-cublas-cu11 nvidia-cudnn-cu11 | |
# pip install torch | |
# Export your library prior to running in WSL or virtual env | |
# export LD_LIBRARY_PATH=`python3 -c 'import os; import nvidia.cublas.lib; import nvidia.cudnn.lib; print(os.path.dirname(nvidia.cublas.lib.__file__) + ":" + os.path.dirname(nvidia.cudnn.lib.__file__))'` | |
import os | |
import torch, gc | |
import shutil |
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
// Add your code here. All actions will run unless you explicitly skip them. | |
// Quick tips! | |
// Auto-complete is on. Start typing to see ingredient options. | |
// Hover over any ingredient to see the variable type and an example. | |
// TypeScript v2.92 | |
/* | |
Octoprint Webhook Plugin: https://plugins.octoprint.org/plugins/webhooks/ | |
Webhook: https://maker.ifttt.com/trigger/{event}/json/with/key/{key} |
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
function fcopy ($SourceDir,$DestinationDir) | |
{ | |
Get-ChildItem $SourceDir -Recurse | Where-Object { $_.PSIsContainer -eq $false } | ForEach-Object ($_) { | |
$SourceFile = $_.FullName | |
$DestinationFile = $DestinationDir + $_ | |
write-host "------------------------------------" | |
write-host "Source: $SourceFile" | |
write-host "Dest : $DestinationFile" | |
if (Test-Path "$DestinationFile"){ | |
if( (Get-FileHash "$SourceFile").Hash -ne (Get-FileHash "$DestinationFile").Hash ) { |
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
# Run as admin | |
# Summary: Generates a random shortname for directories, unzips files, generates png from stl, generates png from svg | |
# Pre-req: | |
# Install OpenSCAD (Ex using chocolatey: choco install openscad -y) | |
# Install inkscape (ex using choco: choco install inkscape -y) | |
# Install superdelete (ex using choco: choco install superdelete -y) | |
# Enable Shortnames in Windows 10 by running the following commands (helps with 260 char. limits): | |
# fsutil 8dot3name query | |
# fsutil behavior set disable8dot3 0 | |
# Post [optional] |
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
alias svgtopng="IFS=\$'\n'; set -f; for file in \$(find -name "*.svg"); do _INKSCAPE_GC=disable inkscape \"$file\" -e \"${file%svg}png\"; done; unset IFS; set +f" |
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
$folderPath=Get-Location; | |
$dash = '-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-' | |
Get-ChildItem $folderPath -recurse | %{ | |
if($_.Name -match "^*.`.zip$") | |
{ | |
write-host $dash | |
write-host '-+-+-+-+-+-+ EXTRACTING' | |
write-host $dash |
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
# Run as admin | |
# Summary: Generates a random shortname for directories and generates png from stl | |
# Pre-req: | |
# Install OpenSCAD (Ex using chocolatey: choco install openscad -y) | |
# Enable Shortnames in Windows 10 by running the following commands (helps with 260 char. limits): | |
# fsutil 8dot3name query | |
# fsutil behavior set disable8dot3 0 | |
# Post [optional] | |
# If you want to convert png to jpg run the following from wsl (you'll need imagemagick and parallel) | |
# find . -iname "*.png" | parallel convert -quality 95% {} {.}.jpg |
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
#Generates a random shortname for directories | |
#Enable Shortnames in Windows 10 | |
# fsutil 8dot3name query | |
# fsutil behavior set disable8dot3 0 | |
#Run as admin | |
Get-ChildItem -Recurse -Directory | ForEach-Object { | |
$fullpath = $_.FullName | |
$foldername = $_.Name | |
$ShortPath = (New-Object -ComObject Scripting.FileSystemObject).GetFolder($_.FullName).ShortPath | |
$ShortName = $ShortPath|split-path -leaf |
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
REM Install OpenSCAD (e.g. if using chocolatey run: choco install openscad -y) | |
REM Run batch script in root folder, this will recursively go into all sub folders. | |
echo off | |
call :treeProcess | |
goto :eof | |
:treeProcess | |
for %%f in (*.stl) do ( | |
if not exist "%%~nf.png" ( | |
echo import("%%f"); >"__tmp__%%f_tmp" |
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
# This file contains pin mappings for the stock 2020 Creality Ender 3 | |
# MAX. To use this config, during "make menuconfig" select the | |
# STM32F103 with a "28KiB bootloader" and with "Use USB for | |
# communication" disabled. | |
# Because this printer has factory wiring, mounts, and firmware for | |
# a BLTouch, but does not ship with one at this time, default values | |
# for the sensor have been specified, but disabled, in anticipation of | |
# future revisions or user modification. User should take care to | |
# customize the offsets, particularly z-offset, for their specific unit. |
NewerOlder