Giter Club home page Giter Club logo

trace.moe's Introduction

trace.moe

License Discord

Anime Scene Search Engine

Trace back the scene where an anime screenshots is taken from.

It tells you which anime, which episode, and the exact moment this scene appears.

Try this image yourself.

Web Integrations

Link to trace.moe from other websites, you can pass image URL in query string like this:

https://trace.moe/?url=http://searchimageurl

trace.moe API

For Bots/Apps, refer to https://soruly.github.io/trace.moe-api/

System Overview

This repo is just an index page for the whole trace.moe system. It consists of different parts as below:

Client-side (gray parts):

Server-side (blue and red parts):

Others:

  • anilist-crawler - getting anilist info and store in mariaDB
  • slides - past presentation slides on the project

Hosting your own trace.moe system

You're going to need these docker images.

Parts Docker CI Build Docker Image
MariaDB Docker Image Size
Adminer Docker Image Size
redis Docker Image Size
liresolr GitHub Workflow Status Docker Image Size
trace.moe-www GitHub Workflow Status Docker Image Size
trace.moe-api GitHub Workflow Status Docker Image Size
trace.moe-media GitHub Workflow Status Docker Image Size
trace.moe-worker-hasher GitHub Workflow Status Docker Image Size
trace.moe-worker-loader GitHub Workflow Status Docker Image Size
trace.moe-worker-watcher GitHub Workflow Status Docker Image Size
  1. Copy .env.example to .env and update config as you need
WWW_PORT=3310
API_PORT=3311
MEDIA_PORT=3312
ADMINER_PORT=3313
SOLR_PORT=8983

NEXT_PUBLIC_API_ENDPOINT=http://172.17.0.1:3311    # external URL
NEXT_PUBLIC_MEDIA_ENDPOINT=http://172.17.0.1:3312  # external URL

WATCH_DIR=/home/soruly/trace.moe-incoming/  # suggest using fast drives
MEDIA_DIR=/home/soruly/trace.moe-media/     # suggest using large drives
HASH_DIR=/home/soruly/trace.moe-hash/       # suggest using fast drives
SOLR_DIR=/home/soruly/mycores               # suggest using super fast drives
MYSQL_DIR=/home/soruly/mysql

TRACE_MEDIA_SALT=YOUR_TRACE_MEDIA_SALT
TRACE_API_SALT=YOUR_TRACE_API_SALT
TRACE_API_SECRET=YOUR_TRACE_API_SECRET
MARIADB_ROOT_PASSWORD=YOUR_MARIADB_ROOT_PASSWORD
  1. Ensure the directories are created and are empty before starting the containers. And for SOLR_DIR, you must set the owner to uid,gid to 8983
mkdir -p /home/soruly/trace.moe-incoming/
mkdir -p /home/soruly/trace.moe-media/
mkdir -p /home/soruly/trace.moe-hash/
mkdir -p /home/soruly/mycores
mkdir -p /home/soruly/mysql
sudo chown 8983:8983 /home/soruly/mycores
  1. Start the containers
docker-compose up
  1. Once the cluster is ready, you can adding files to incoming folder

The files in incoming folder must be contained in 1-level folders, e.g.

trace.moe-incoming/foo.mp4  <= not ok
trace.moe-incoming/1/foo.mp4 <= ok
trace.moe-incoming/1/bar/foo.mp4 <= ok, but will be uploaded as /1/foo.mp4

trace.moe assumes the folder name is anilist ID. If your data is not related to anilist ID, you can use any id/text you want. The system would still work without anilist data.

Do not create the folders in the incoming directory. You should first put video files in folders, then move/copy the folders into the incoming directory.

Once the video files are in incoming directory, the watcher would start uploading the video to trace.moe-media. When it's done, it would delete the video in incoming directory. After Hash worker and Load workers complete the job, you can search the video by image in your www website at WWW_PORT.

trace.moe's People

Contributors

soruly avatar dependabot-preview[bot] avatar leslie-wong-h avatar renovate-bot avatar magic-akari avatar mr-quin avatar thblckjkr avatar gitter-badger avatar dependabot-support avatar kj415j45 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.