Skip to content

Instantly share code, notes, and snippets.

View tjoen's full-sized avatar

Theun Kohlbeck tjoen

View GitHub Profile
@Mahedi-61
Mahedi-61 / cuda_11.8_installation_on_Ubuntu_22.04
Last active April 29, 2024 16:34
Instructions for CUDA v11.8 and cuDNN 8.9.7 installation on Ubuntu 22.04 for PyTorch 2.1.2
#!/bin/bash
### steps ####
# Verify the system has a cuda-capable gpu
# Download and install the nvidia cuda toolkit and cudnn
# Setup environmental variables
# Verify the installation
###
### to verify your gpu is cuda enable check

Skill Testing Template

The purpose of this template is to help a Mycroft Community Skill Developer outline how a Community Member can install, configure, and test the Skill. This template is aimed at making Skills easier to test, and thereby increasing the quality of Skills deployed.

Skill Name <- replace this with the name of the Skill you're testing

  • Platform <- which platform is the test being run on? ie Picroft, Mark 1, Linux
  • Device version <-- what Mycroft version is the device running, ie 18.02
  • Who <-- who is running the test
  • Datestamp <-- time and date
  • Language and dialect of tester <-- ie "English, Australian" so that we can identify any key language issues
@forslund
forslund / gist:9d8805fd7adb9e74ec3ea321e1676a21
Last active November 17, 2017 15:18
Simple program to convert png to mycroft display images
import sys
from PIL import Image
def mouth_display_png(image_absolute_path, threshold=70,
invert=False, x=0, y=0):
"""Converts a png image into the appropriate encoding for the
Arduino Mark I enclosure.
NOTE: extract this out of api.py when re structuing the
enclosure folder
@ZWMiller
ZWMiller / streamAudio.py
Created June 19, 2017 16:36
Using Python to plot the current microphone's input and the Fourier Transform
try:
import pyaudio
import numpy as np
import pylab
import matplotlib.pyplot as plt
from scipy.io import wavfile
import time
import sys
import seaborn as sns
except:
@andymotta
andymotta / main.yml
Last active August 18, 2022 14:34
Trigger Jenkins job with Ansible
---
- name: trigger jenkins job
shell: "{{ lookup('template', 'trigger-jenkins.j2') }}"
delegate_to: localhost
- name: wait for job to complete
wait_for:
path: {{ lockfile }}
timeout: 600
#!/usr/bin/env bash
set -Ee
TOP=$(cd $(dirname $0)/.. && pwd -L)
VIRTUALENV_ROOT=${VIRTUALENV_ROOT:-"${HOME}/.virtualenvs/mycroft"}
MYCROFT_CORE_SRC=${TOP}/src/mycroft-core
if [ "$1" = "-q" ]; then
QUIET="echo"
@zeffii
zeffii / fractal.py
Last active February 9, 2017 16:43
equivalent socket adaptive
# ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
@dschep
dschep / raspbian-python3.6.rst
Last active October 24, 2023 14:57 — forked from BMeu/raspbian-python3.5.rst
Installing Python 3.6 on Raspbian

Installing Python 3.6 on Raspbian

As of January 2018, Raspbian does not yet include the latest Python release, Python 3.6. This means we will have to build it ourselves, and here is how to do it. There is also an ansible role attached that automates it all for you.

  1. Install the required build-tools (some might already be installed on your system).

@intrd
intrd / simone_plot.py
Last active March 2, 2018 15:47
Python script to plot WAV file into a image stego300-simone_entao_e_natal @ 3dsctf-2k16
## Python script to plot WAV file into a image stego300-simone_entao_e_natal @ 3dsctf-2k16
# @author intrd - http://dann.com.br/
# @license Creative Commons Attribution-ShareAlike 4.0 International License - http://creativecommons.org/licenses/by-sa/4.0/
from scipy.io import wavfile
from matplotlib import pyplot as plt
import numpy as np
samplerate, data = wavfile.read('sim.wav')
#print a #to print freq values
import bmesh
from sverchok.utils.sv_bmesh_utils import pydata_from_bmesh, bmesh_from_pydata
def average(verts):
vx, vy, vz = 0, 0, 0
for v in verts:
vx += v[0]
vy += v[1]
vz += v[2]
numverts = len(verts)