Skip to content

Instantly share code, notes, and snippets.

View ADCDS's full-sized avatar
🥒
afiando a mandioca

Adriel Santos ADCDS

🥒
afiando a mandioca
View GitHub Profile
@ADCDS
ADCDS / data.php
Created August 2, 2017 23:17 — forked from jjb3rd/data.php
An updated server-side processing script for DataTables
<?php
/*
* Script: DataTables server-side script for PHP and MySQL
* Copyright: 2012 - John Becker, Beckersoft, Inc.
* Copyright: 2010 - Allan Jardine
* License: GPL v2 or BSD (3-point)
*/
class TableData {
@ADCDS
ADCDS / kmeans.py
Created May 29, 2017 14:17 — forked from mblondel/kmeans.py
Fuzzy K-means and K-medians
# Copyright Mathieu Blondel December 2011
# License: BSD 3 clause
import numpy as np
import pylab as pl
from sklearn.base import BaseEstimator
from sklearn.utils import check_random_state
from sklearn.cluster import MiniBatchKMeans
from sklearn.cluster import KMeans as KMeansGood
@ADCDS
ADCDS / kmeansExample.py
Created May 29, 2017 14:17 — forked from iandanforth/kmeansExample.py
A pure python implementation of K-Means clustering. Optional cluster visualization using plot.ly.
#############################################################################
# Full Imports
import math
import random
"""
This is a pure Python implementation of the K-Means Clustering algorithmn. The
original can be found here:
http://pandoricweb.tumblr.com/post/8646701677/python-implementation-of-the-k-means-clustering
@ADCDS
ADCDS / jquery-datatables-webpack
Created March 25, 2017 17:28 — forked from obonyojimmy/jquery-datatables-webpack
DataTables.net with webpack
Here's how to make jQuery DataTables work with npm and webpack. This is the simplest way I found to do it.
See the previous revision of this gist for a way to do it with forcing AMD to be disabled if you need that.
Install DT core: npm install datatables.net
Install a DT style: npm install datatables.net-dt
Then to initialize DT in your app, do this in your main entry point:
// you can use import or require
import dt from 'datatables.net';