Skip to content

Instantly share code, notes, and snippets.

View arangates's full-sized avatar
🔬
Gedankenerfahrung

Aranganathan Rathinavelu arangates

🔬
Gedankenerfahrung
View GitHub Profile
@arangates
arangates / Music-classification-into-genres.py
Created June 23, 2019 17:42 — forked from sdoshi579/Music-classification-into-genres.py
Model generated to classify extracted features from music clips into different genres
import librosa
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
%matplotlib inline
import os
import csv
# Preprocessing
from sklearn.model_selection import train_test_split
from sklearn.preprocessing import LabelEncoder, StandardScaler
@arangates
arangates / seo.service.ts
Created March 29, 2018 14:23 — forked from nhathiwala/seo.service.ts
SEO Service for Angular 4+
import { Injectable } from '@angular/core';
import { Meta, Title } from '@angular/platform-browser';
export interface TypingSEO {
title?: string;
titleSuffix?: string;
description?: string;
image?: string;
keywords?: string;
url?: string;
@arangates
arangates / meta-tags.md
Created March 29, 2018 14:17 — forked from lancejpollard/meta-tags.md
Complete List of HTML Meta Tags

Copied from http://code.lancepollard.com/complete-list-of-html-meta-tags/

Basic HTML Meta Tags

<meta name="keywords" content="your, tags"/>
<meta name="description" content="150 words"/>
<meta name="subject" content="your website's subject">
<meta name="copyright"content="company name">
<meta name="language" content="ES">
@arangates
arangates / httpparams.service.ts
Created February 26, 2018 11:03 — forked from anonymous/httpparams.service.ts
Abgular 5 HTTPS params conversion
function toHttpParams(params) {
return Object.getOwnPropertyNames(params)
.reduce((p, key) => p.set(key, params[key]), new HttpParams());
}
// Example:
toHttpParams({firstName: 'John', lastName: 'Doe'});
@arangates
arangates / example.component.ts
Created December 11, 2017 08:10 — forked from ckimrie/example.component.ts
Example on how to achieve RxJS observable caching and storage in Angular 2+. Ideal for storing Http requests client side for offline usage.
import { Component, OnInit, OnDestroy } from '@angular/core';
import {Http} from "@angular/http";
import { LocalCacheService } from "./local-cache.service";
@Component({
selector: 'app-example',
templateUrl: './app.component.html',
styleUrls: ['./app.component.scss']
})
export class ExampleComponent implements OnInit, OnDestroy {
@arangates
arangates / libzip_simple.c
Created June 11, 2017 17:13 — forked from mobius/libzip_simple.c
using libzip to extract files
/* Copyright (C) 2011 rocenting#gmail.com */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#include <unistd.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <dirent.h>
@arangates
arangates / pre-receive.sh
Created November 3, 2016 05:37
My pre-receive hook to update my website when I "git push origin master:live"
#!/bin/sh
while read old new branch
do
case "$new-$branch" in
000000000000000000*)
: echo "ignore deleted"
;;
*-refs/heads/live )
echo "UPDATING LIVE SITE";
git archive $new | (
## Raspberry PI as Arduino network programmer ##
This guide will show you how to program an Arduino connected to your Raspberry PI from the Arduino IDE on your local computer.
Linux and OS X for now
###On your Raspberry PI
First install avrdude