Skip to contents

Available Models

Available Datasets

Usage

All models can be loaded with a single line:

library(petrographer)

# Load any model from the hub
model <- from_pretrained("model_id")

# Run predictions
results <- predict(model, "path/to/image.jpg")

Contributing

To publish your own trained models to this library:

# Configure your board
board <- board_user()

# Publish a trained model
publish_model(
  model_dir = "Detectron2_Models/my_model",
  model_id = "my_model",
  board = board,
  metadata = list(
    description = "Brief description",
    backbone = "resnet50",
    num_classes = 5
  )
)

Contact the package maintainers to have your models added to the public hub.