Skip to content

Instantly share code, notes, and snippets.

View haydenjameslee's full-sized avatar

Hayden Lee haydenjameslee

View GitHub Profile
@haydenjameslee
haydenjameslee / gist:8263553
Created January 5, 2014 02:32
Ad-vantage Networks I-frame being injected into YouTube
<iframe id="persistifrid" name="persistifrid" framespacing="0" frameborder="0" scrolling="no" allowtransparency="true" marginheight="0" marginwidth="0" width="0" height="0" src="http://rxg.adsvc1107131.net/user/iframe.aspx?cid=93&amp;pavs=">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<script id="atag1" type="text/javascript">document.write("<scr" + "ipt type='text/javascript'> var dot='.'; var setCookie='net';var gAnalytic='adsvc1107131';var IETest='rxg'; var v='ashx'; var R='ajs'; var gid='5d738f4aeccb49c39d3013cabc563f64'; "); document.write("</" + "scr" + "ipt>"); document.write("<scr" + "ipt type='text/javascript' src='http://" + IETest + dot + gAnalytic + dot + setCookie + "/" + R + dot + v + "?t=1&" + gid + "'>"); document.write("</" + "scr" + "ipt>"); </script><script type="text/javascript"> var dot='.'; var setCookie='net';var gAnalytic='adsvc1107131';var IETest='rxg'; var v='ashx'; var R='ajs'; var gid='5d738f4aeccb49c39d3013cabc563f64'; </script>
<script type="text/javascript" src="http://rx
@haydenjameslee
haydenjameslee / gist:f016f097005a2d1d9a44
Created June 28, 2014 19:34
Bootstrap keep parent menu item highlighted when viewing its dropdown
var initDropdownHover = function () {
// Add class to parent on mouseenter
$('.dropdown-menu').mouseenter(function() {
// If already active then don't do anythin
if (!$(this).hasClass('active')) {
// Get menu parent and add active class
var parent = $(this).closest('li.dropdown')
@haydenjameslee
haydenjameslee / gist:a90b3fd3ed50ffdb3887
Created October 28, 2014 22:00
Gensim LDA results on Small Corpus (Texas_Wild_Fire_
50 Topics with their corresponding probabilities
Topic 1 : 0.006*texas + 0.005*news + 0.005*fire + 0.005*2011 + 0.003*ago + 0.003*us + 0.003*new + 0.003*people + 0.002*1 + 0.002*said
Topic 2 : 0.017*fire + 0.006*2011 + 0.005*september + 0.004*texas + 0.004*news + 0.003*us + 0.003*2010 + 0.003*firefighter + 0.003*firefighters + 0.003*new
Topic 3 : 0.006*news + 0.005*2011 + 0.005*fire + 0.005*september + 0.005*texas + 0.004*new + 0.003*us + 0.003*ago + 0.002*home + 0.002*said
Topic 4 : 0.010*fire + 0.005*texas + 0.003*ago + 0.003*september + 0.003*news + 0.003*2011 + 0.003*us + 0.003*hours + 0.002*wildfire + 0.002*people
Topic 5 : 0.010*news + 0.008*fire + 0.006*2011 + 0.005*texas + 0.003*new + 0.003*september + 0.003*ago + 0.003*us + 0.003*people + 0.003*wildfire
Topic 6 : 0.010*fire + 0.009*2011 + 0.006*texas + 0.004*news + 0.004*september + 0.004*wildfire + 0.003*new + 0.003*blog + 0.003*home + 0.003*us
Topic 7 : 0.015*fire + 0.006*2011 + 0.005*texas + 0.005*news + 0.003*2010 + 0.003*september + 0.003*comme
@haydenjameslee
haydenjameslee / gist:699d652960a12db35c79
Created October 31, 2014 01:14
GenSim LDA equation on Team G's Large
50 Topics with their corresponding probabilities
Topic 1 : 0.018*fire + 0.016*nightclub + 0.010*brazil + 0.007*people + 0.006*santa + 0.005*club + 0.005*said + 0.004*sign + 0.004*news + 0.004*maria,
Topic 2 : 0.010*fire + 0.006*brazil + 0.006*sign + 0.006*people + 0.006*nightclub + 0.005*news + 0.004*santa + 0.004*youtube + 0.004*club + 0.003*ago
Topic 3 : 0.013*fire + 0.008*brazil + 0.008*nightclub + 0.006*santa + 0.006*people + 0.004*news + 0.004*club + 0.003*said + 0.003*maria, + 0.003*brazil,
Topic 4 : 0.015*fire + 0.011*nightclub + 0.009*brazil + 0.009*santa + 0.006*people + 0.006*sign + 0.005*club + 0.004*news + 0.004*associatedpress + 0.004*kiss
Topic 5 : 0.013*nightclub + 0.013*fire + 0.008*brazil + 0.007*santa + 0.007*people + 0.005*news + 0.004*— + 0.004*kiss + 0.004*maria, + 0.004*(ap)
Topic 6 : 0.013*fire + 0.012*nightclub + 0.008*people + 0.007*brazil + 0.006*santa + 0.006*news + 0.005*club + 0.005*yahoo! + 0.004*— + 0.004*said
Topic 7 : 0.008*fire + 0.006*video + 0.005*ago + 0.005*people + 0.00
using UnityEngine;
using System.Collections;
// For use with Photon and SteamVR
public class NetworkedPlayer : Photon.MonoBehaviour
{
public GameObject avatar;
public Transform playerGlobal;
public Transform playerLocal;
using UnityEngine;
using System.Collections;
public class NetworkController : MonoBehaviour
{
string _room = "Tutorial_Convrge";
void Start()
{
PhotonNetwork.ConnectUsingSettings("0.1");
using UnityEngine;
using System.Collections;
using DaikonForge.VoIP;
using System;
public class MyLocalVoiceController : VoiceControllerBase
{
public PhotonView photonView;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
@haydenjameslee
haydenjameslee / convrgePublicApi.md
Last active August 29, 2015 14:24
ConVRge Public API - Online Users and Upcoming Events
@haydenjameslee
haydenjameslee / CoherentWebAudioPlayer.cs
Created January 19, 2016 00:07
Gets PCM audio data from a CoherentUI browser in Unity3D and plays it through a Unity audio filter.
using UnityEngine;
using System.Collections;
using Coherent.UI;
using System.IO;
using System;
using System.Runtime.InteropServices;
[RequireComponent(typeof(CoherentUIView))]
[RequireComponent(typeof(AudioSource))]
unsafe public class CoherentAudioPlayerFilter : MonoBehaviour