目录
目录README.md

Commit Classification Dashboard for Maintenance Activity

Installation

This dashboard relies on CUDA 11.8. To set up a virtual environment for installation and deployment, follow these steps:

  1. Create a Conda environment named ccenv with Python 3.9:

    conda create --name ccenv python=3.9
    conda activate ccenv
  2. install pytorch for CUDA 11.8:

    pip3 install torch --index-url https://download.pytorch.org/whl/cu118
  3. Install the required packages from the requirements.txt file:

    pip3 install -r requirements.txt
  4. Download the model weight from Google Drive to classifier/core/model.

Docker Option: If you encounter difficulties with environment setup, an alternative is to use a Docker image provided for your convenience. Run the following command to enter the container, where everything is pre-configured for you:

docker run -it -p 7983:7983 0x404/commit-classifier:latest /bin/bash
conda activate ccenv

Now, you’re ready to use the Commit Classification Dashboard with the environment and dependencies properly configured.

Deployment

Deploying the commit classification dashboard is a straightforward process. Follow these steps to get it up and running:

  1. Set Environment Variables: Before deployment, you need to set three environment variables:

    • SECRET_KEY: This is used by Django and can be any random string.
    • DEFAULT_GH_USER: Your GitHub username.
    • DEFAULT_GH_TOKEN: Your GitHub token. If you’re unsure how to generate a GitHub token, refer to this
  2. Depolyment Command: Use the following command to deploy the dashboard:

SECRET_KEY = yourkey
DEFAULT_GH_USER = yourname
DEFAULT_GH_TOKEN = yourtoken
python3 manage.py runserver 0.0.0.0:7983 --insecure
  1. Access the Dashboard: After running the deployment command, you should be able to access the dashboard at yourip:7983.

That’s it! You’ve successfully deployed the commit classification dashboard, enjoy it:)

关于
56.0 KB
邀请码