Skip to content

Instantly share code, notes, and snippets.

View Brainiarc7's full-sized avatar

Dennis E. Mungai Brainiarc7

View GitHub Profile
@Brainiarc7
Brainiarc7 / README.md
Created February 21, 2018 23:17 — forked from mrbar42/README.md
bash scripts to create VOD HLS stream with ffmpeg almighty (tested on Linux and OS X)

running:

bash create-vod-hls.sh beach.mkv

will produce:

    beach/
      |- playlist.m3u8
 |- 360p.m3u8
@Brainiarc7
Brainiarc7 / conky-setup-clevo-p751dm2-g.md
Last active February 21, 2024 09:24
My Conky configuration

Setting up Conky on Ubuntu 16.04LTS for the Clevo P751DM2-G

System Information:

We extract this with inxi:

installation:

sudo apt-get install inxi
@Brainiarc7
Brainiarc7 / hfsc-shape.sh
Created February 15, 2018 04:14 — forked from bradoaks/hfsc-shape.sh
HFSC - linux traffic shaping's best kept secret
#!/bin/bash
# As the "bufferbloat" folks have recently re-discovered and/or more widely
# publicized, congestion avoidance algorithms (such as those found in TCP) do
# a great job of allowing network endpoints to negotiate transfer rates that
# maximize a link's bandwidth usage without unduly penalizing any particular
# stream. This allows bulk transfer streams to use the maximum available
# bandwidth without affecting the latency of non-bulk (e.g. interactive)
# streams.
@Brainiarc7
Brainiarc7 / nvidia-docker2-deploy-ubuntu-16.04LTS.md
Last active September 17, 2022 04:51
How to correctly install nvidia-docker2 on Ubuntu 16.04LTS

How to install NVIDIA Docker 2 package on Ubuntu and Debian:

If you came to this result (from Google or elsewhere) after realizing that Nvidia-docker's entry on this subject does not result in a working installation, here are the basic steps needed to install this package correctly:

For starters, ensure that you've installed the latest Docker Community edition by following the steps below:

curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo apt-key fingerprint 0EBFCD88

sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"

@Brainiarc7
Brainiarc7 / realtek-alc898-surround-setup-5.1-analog-3.5mmjacks.md
Last active March 21, 2024 20:13
Analog surround sound setup on Linux with a Realtek ALC898 sound card on the Clevo P751DM2-G

Setting up analog surround sound on Ubuntu Linux with a 3 3.5mm capable sound card:

A while back, I received the Logitech Z506 Speaker system, and with Windows, setting it up was a pretty plug and play experience. On Linux, however, its' a wholly different ballgame. For one, there's no Realtek HD Audio control panel here, so what gives? How do you around this problem?

Introducing the tools of the trade:

You'll want to use a tool such as hdajackretask , pavucontrol and pavumeter for the pin re-assignments and audio output monitoring afterwards respectively. The tools are installed by running:

sudo apt-get install alsa-tools-gui pavumeter pavucontrol
sudo apt-get install libprotobuf-dev libleveldb-dev libsnappy-dev libopencv-dev libhdf5-serial-dev protobuf-compiler
sudo apt-get install --no-install-recommends libboost-all-dev
sudo apt-get install -y build-essential cmake git pkg-config
sudo apt-get install -y libprotobuf-dev libleveldb-dev libsnappy-dev libhdf5-serial-dev protobuf-compiler
sudo apt-get install -y libatlas-base-dev
sudo apt-get install -y --no-install-recommends libboost-all-dev
sudo apt-get install -y libgflags-dev libgoogle-glog-dev liblmdb-dev
sudo apt-get install -y python-dev
sudo apt-get install -y python-numpy python-scipy
@Brainiarc7
Brainiarc7 / clevo-p751dm2-g-premamod-tuning.md
Last active July 1, 2018 10:07
Tuning the Premafied Clevo P751DM2-G for maximum performance and thermals under load.

Overclocking the P751DM2-G with the Prema Mod BIOS v 1.06.09PM v2.2:

Hello guys,

A while back, Prema and I flashed the Prema Mod BIOS on the aforementioned chassis, the P751DM2-G (Branded as the Origin Eon 15-X) and I proceeded to make a few tweaks to the machine to suit my purposes:

  1. Applied a mild overclock to the processor, setting all multipliers on the Intel Core i7 7700k to 4.5Ghz.

  2. Applied an AVX offset of 1.

@Brainiarc7
Brainiarc7 / avx.c
Created October 29, 2017 14:47 — forked from juliantaylor/avx.c
avx align bechmark
// gcc avx.c -mavx -std=c99 -O2
// while true; do ./a.out; done > log
// analyze via np.genfromtxt, e.g. min, 10th percentile, median
#include <stdio.h>
#include <string.h>
#include <x86intrin.h>
#include <avxintrin.h>
#define N 5000
void __attribute__((noinline)) add(double * a, int warmup)
@Brainiarc7
Brainiarc7 / README.md
Created October 26, 2017 23:51 — forked from foosel/README.md
Getting the fingerprint reader of a Thinkpad x240 to work under Ubuntu 14.04

lsusb lists the fingerprint reader in the x240 as follows:

Bus 002 Device 003: ID 138a:0017 Validity Sensors, Inc.

There exists experimental driver support for this in a fork of libfprint for vfs5011 sensors, however you'll need to compile the driver yourself. To get the fingerprint sensor to work for lightdm login, su etc, follow these steps.

  1. Install fingerprint-gui:

    sudo add-apt-repository ppa:fingerprint/fingerprint-gui