Step-by-Step Instructions

  1. System Update and Package Installation:
sudo apt update && sudo apt upgrade -y
sudo apt install -y git python3 python3-pip python-is-python3
  1. Clone the Repository:
git clone <https://github.com/NicheTensor/NicheImage>
cd NicheImage
  1. Create and activate python virtual environment:
python -m venv main_env
source main_env/bin/activate
  1. Install requirements:
pip install -e .
pip uninstall uvloop -y
git submodule update --init --recursive
. generation_models/custom_pipelines/scripts/download_antelopev2.sh
# Pre-requisites for ComfyUI: Sticker Maker and Face To Many
. generation_models/comfyui_helper/install_comfyui.sh

# Pre-requisites for ComfyUI: Face To Many
. generation_models/comfyui_helper/scripts/download_antelopev2.sh

  1. Start the endpoint
source main_env/bin/activate
pm2 start python --name "miner_endpoint" -- -m services.miner_endpoint.app \\
--model_name FaceToMany \\
--num_replicas X \\ # num_replicas should be set to the total number of GPUs available
--num_gpus Y \\ # num_replicas should be set to 1 (default)
--port 10006 # default port
  1. Start the miner
pm2 start python --name "miner" \\
-- \\
-m neurons.miner.miner \\
--netuid 23 \\
--wallet.name <wallet_name> --wallet.hotkey <wallet_hotkey> \\
--subtensor.network <network> \\ # default is finney
--axon.port <your_public_port> \\
--generate_endpoint [<http://127.0.0.1:10006/generate>](<http://127.0.0.1:10006/generate>) \\ # change if you use different port or host
--info_endpoint [<http://127.0.0.1:10006/info>](<http://127.0.0.1:10006/info>) \\ # change if you use different port or host
--miner.total_volume <your-generation-volume> # default is 40. Change based on your model timeout value and GPU capacity
--miner.max_concurrent_requests <your-max-concurrent-requests> # default is 4. Change based on your model timeout value and GPU capacity
  1. Important notes: