Loading repository dataβ¦
Loading repository dataβ¦
Tmw / repository
Edward Scissorhands is a Slackbot that utilizes machinelearning to remove the background of images share with Edward π€βοΈ
A transparent discovery signal based on current public GitHub metadata.
This score does not audit code, security, maintainers, documentation quality, or suitability. Verify the repository and its current documentation before adoption.
Edward Scissorhands is a slackbot that utilizes machinelearning to remove the background of any uploaded image. Edward works best with images containing people.
Edward depends on a pre-trained Tensorflow model as explained in this blogpost. The fully pre-trained model can be found over their Gitlab Repository.
Note; the model in this repository is merely a mirror. In both cases; pull using git lfs.
By far the easiest way to run Edward is by using Docker. Pull the image directly from Dockerhub, give Edward a SLACK_TOKEN and we're off to the races!
Example:
docker run -it --rm \
-e "SLACK_TOKEN=<your_slack_token>" \
tiemenwaterreus/edward
Where <your_slack_token> is replaced with your bot's Slack Token
slack_tokenGetting a slack (bot) token is easy; just browse to create bot integration page on Slack, give your bot an username (eg: edward) and hit the green button. Hooray! You just made a Slack (bot) integration!
On the next page you can customize your integration some more by providing an icon and a short description. The most important piece is the API Token near the top. Its a pretty long string which starts with xoxb-. Copy this token and pass it in the env-variables of edward.
git clone https://github.com/tmw/edward.git && cd edward
scripts/edward test
Make sure you fill in the missing pieces in your .env file and simply run:
scripts/edward run
if you don't have an .env file, create one by looking at the example (
.example.env)
scripts/edward build
scripts/edward push
For additional tweaks, edward is taking the following environment variables into account when booting up:
| Variable | Type | Meaning |
|---|---|---|
| SLACK_TOKEN | String | Your slack token |
| THREADS | Int | How many threads do we reserve |