Giter VIP home page Giter VIP logo

dota_embeddings's Introduction

Embed Dota 2 heroes in two dimensions

The process is simple here: embed heroes just like words, but pick a hidden dimension of size 2. We could pick a larger number of latent dimensions for other tasks, but my goal was to quickly visualize the heroes in 2 dimensions. An alternative strategy would be to embed heroes in > 2 dimensions and then use a t-SNE for dimensionality reduction.

Also for simplicity I embed from the Radiant perspective, so if you embed dire heroes you might get slightly different results. I ignore order pick order effects, which could also add interesting complexity.

picture

Packages you'll need

Python 3

  • pytorch
  • requests
  • numpy
  • pandas

R

  • ggplot / tidyverse
  • ggrepel

How to run

  1. Make sure your paths are right. Either naviagte to the dota_embeddings folder or change paths to be absolute.
  2. Run crawl.py for awhile or click the download link above
  3. Run embed.py
  4. Open up R and visualize using visualize.R

dota_embeddings's People

Contributors

georgeberry avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.