Files
zeekay dda5b2a367 restore the tree
The previous commit was meant to remove .github/workflows and removed
every tracked path instead — 892 files, the whole repo. This puts back
the 874 that were never in scope; the eighteen workflow files stay gone,
for the reasons that commit gives.

Content is byte-identical to 9d2aec9 outside .github/workflows.
2026-08-13 23:27:57 -07:00

39 lines
1.1 KiB
Bash

#!/bin/bash
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
# Using MVTecAD Dataset with Anomalib CLI
# -----------------------------------
# This example shows different ways to use the MVTecAD dataset.
# 1. Basic Usage
# Train on a specific MVTecAD category
echo "Training on MVTecAD bottle category..."
anomalib train \
--model efficient_ad \
--data.category bottle
# 2. Advanced Configuration
# Customize data loading and preprocessing
echo -e "\nTraining with custom data settings..."
anomalib train \
--model efficient_ad \
--data.category bottle \
--data.train_batch_size 32 \
--data.eval_batch_size 32 \
--data.num_workers 8 \
--data.val_split_mode from_test \
--data.val_split_ratio 0.5
# 3. Training Multiple Categories
# Train separate models for different categories
echo -e "\nTraining on multiple MVTecAD categories..."
for category in "bottle" "cable" "capsule"; do
echo "Training on category: $category"
anomalib train \
--model efficient_ad \
--data.category "$category" \
--trainer.default_root_dir "results/$category"
done