Skip to content

Instantly share code, notes, and snippets.

@louis030195
louis030195 / game-network-optimization.md
Last active Jan 22, 2021
Realtime, authoritative server-based, game networking and how to fool Einstein
@louis030195
louis030195 / README.md
Created Jan 3, 2021
Unity ECS Utility AI (reinforcement learning-like but hard-coded state action values & greedy policy)
View README.md
View ovhcloudaitraining.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@louis030195
louis030195 / toxicity.js
Created Nov 19, 2020
Minecraft bot that detect toxic players using TensorflowJS and Mineflayer
View toxicity.js
const mineflayer = require("mineflayer")
require('@tensorflow/tfjs')
const toxicity = require('@tensorflow-models/toxicity')
if (process.argv.length < 4 || process.argv.length > 6) {
console.log('Usage : node toxicity.js <host> <port> [<name>] [<password>]')
process.exit(1)
}
const bot = mineflayer.createBot({
@louis030195
louis030195 / quotesnearestneighbour.ipynb
Last active Nov 11, 2020
Nearest neighbor search on Readwise quotes using FAISS and HuggingFace tools
View quotesnearestneighbour.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@louis030195
louis030195 / quotestovector.ipynb
Last active Nov 8, 2020
Use deep learning to turn Readwise quotes into vectors and visualize the distances between each-other
View quotestovector.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@louis030195
louis030195 / readwise.ipynb
Last active Nov 8, 2020
Readwise API usage
View readwise.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@louis030195
louis030195 / Value.cs
Last active Oct 7, 2020
Automatic differentiation in 3 languages
View Value.cs
using System;
using System.Collections.Generic;
using System.Linq;
public class Value
{
public double Data { get; set; }
public double Gradient { get; set; }
private Action _backward;
private readonly List<Value> _prev;
@louis030195
louis030195 / SpawnThingsAboveGround.cs
Last active Jun 3, 2020
Unity helper to spawn object above ground or try to spawn objects above ground in a random sphere while keeping a given distance
View SpawnThingsAboveGround.cs
public static class Spatial
{
/// <summary>
/// Return position above ground relatively from the prefab size
/// Global position
/// </summary>
/// <param name="position"></param>
/// <param name="prefabHeight">Prefab height needed in order to place well on top of ground</param>
/// <param name="transform">Transform parent</param>
/// <param name="layerMask">Layers to ignore</param>