# Setup environment
export OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES

# Create special Python environment for synthtiger if not already created
if [ ! -d ".venv-synthdog" ] || [ ! -f ".venv-synthdog/bin/activate" ]; then
  python3 -m venv .venv-synthdog
  source .venv-synthdog/bin/activate
  pip install --no-cache-dir synthtiger
else
  source .venv-synthdog/bin/activate
fi


DATA_DIR="TODO: replace with your directory"

# Generate Polish samples
echo "Generating Polish samples..."
synthtiger -o ${DATA_DIR}/static/raw/synthdog/SynthDoG_pl_500k \
    -c 500000 -w 64 -s 42 -v \
    src/datasets/synthdog/template.py \
    SynthDoG \
    config/synthdog/config_pl.yaml


# Generate English samples
echo "Generating English samples..."
synthtiger -o ${DATA_DIR}/static/raw/synthdog/SynthDoG_en_100k \
    -c 100000 -w 64 -s 42 -v \
    src/datasets/synthdog/template.py \
    SynthDoG \
    config/synthdog/config_en.yaml