인터페이스는 현지화되어 있으며, Skill 소개와 설명 문서는 선택한 언어로 AI가 자동 번역합니다. 코드·명령어·경로·전문 용어는 원문을 유지하며 원작자 문서가 우선합니다.
Skills 둘러보기
개발 및 엔지니어링 · SKILL.md

inference

inference

Repository operating skill for Flow Forecast saved-model inference, evaluation, TorchScript conversion, plots, and explainability.

Independent GitHub snapshot · Automated classification · Original documentation governs

Skill 문서

GitHub

name: inference description: "Repository operating skill for Flow Forecast saved-model inference, evaluation, TorchScript conversion, plots, and explainability." disable-model-invocation: true metadata: disco-role: operating license: GPL 3.0

Inference

Use this sub-skill when the task is about loading a Flow Forecast model, running saved-model forecasts or classification inference, computing evaluation metrics, creating confidence-interval plots, exporting TorchScript, or using SHAP/Plotly explainability helpers.

Start with:

What This Sub-skill Covers

  • flood_forecast.deployment.inference.InferenceMode and load_model.
  • infer_now, infer_now_classification, and make_plots.
  • flood_forecast.evaluator.infer_on_torch_model, evaluate_model, and run_evaluation.
  • convert_to_torch_script and the currently placeholder convert_to_onnx.
  • Plotly confidence interval helpers and SHAP summary/heatmap routes.
  • Optional GCS upload/download and W&B logging behavior.

What Belongs Elsewhere

  • Data cleaning, datetime normalization, and loader schema validation belong in data-preparation.
  • Training configs, checkpoint creation, and loss/optimizer selection belong in training.
  • Catchment encoders, CrossViViT, NeuralODE, and GR4 hybrid model internals belong in multimodal-physics.

Typical Workflow

  1. Validate that the package imports and the desired model name is in the registry.
  2. Validate the CSV and inference config locally.
  3. Load the saved JSON config and checkpoint path.
  4. Use InferenceMode or infer_on_torch_model to run the forecast.
  5. Add plots, SHAP, W&B, or GCS only after the local forecast path works.

Operating Notes

  1. InferenceMode wraps load_model, which returns a PyTorchForecast instance.
  2. inference_params.dataset_params should use the test-time loader field names; use scaling for inference-time scaler construction.
  3. datetime_start can be a Python datetime; string parsing in low-level evaluator paths is more restrictive.
  4. num_prediction_samples triggers prediction-sample dataframes for confidence intervals.
  5. save_buck, save_name, wandb_proj, and GCS paths require external credentials and should not be enabled by default.

Shared References And Scripts

Non-goals

  • Do not use this as a cloud-serving infrastructure guide unrelated to Flow Forecast APIs.
  • Do not assume GCS or W&B credentials are present.
  • Do not require the original repository checkout to run an inference recipe.
저장한 Skills