#!/bin/bash

if [ $# -lt 1 ]
then
	echo "You need to run script like $0 <path-to-conversion-file>"
	exit 1
fi

if [ ! -d venv ]
then
	python3.10 -m venv venv
fi

source venv/bin/activate

python3.10 -m pip install -r requirements.txt

python3.10 convert.py --file "$1" --precision fp16 --type "ema-only" --safe-tensors
