@@ -278,14 +278,17 @@ def validate_model(
278278) -> Tuple [Dict [str , Union [int , float , str ]], Dict [str , Any ]]:
279279 """
280280 Validates a model.
281+ The function can also be called through the command line
282+ :ref:`l-cmd-validate`.
281283
282284 :param model_id: model id to validate
283285 :param task: task used to generate the necessary inputs,
284286 can be left empty to use the default task for this model
285287 if it can be determined
286288 :param do_run: checks the model works with the defined inputs
287289 :param exporter: exporter the model using this exporter,
288- available list: ``export-strict``, ``export-nostrict``, ``onnx``
290+ available list: ``export-strict``, ``export-nostrict``, ...
291+ see below
289292 :param do_same: checks the discrepancies of the exported model
290293 :param verbose: verbosity level
291294 :param dtype: uses this dtype to check the model
@@ -322,6 +325,20 @@ def validate_model(
322325 information:
323326
324327 * ``PRINT_CONFIG``: prints the model configuration
328+
329+ The following exporters are available:
330+
331+ * ``export-nostrict``: run :func:`torch.export.export` (..., strict=False)
332+ * ``onnx-dynamo``: run :func:`torch.onnx.export` (..., dynamo=True),
333+ models can be optimized with ``optimization`` in ``("ir", "os_ort")``
334+ * ``modelbuilder``: use :epkg:`ModelBuilder` to builds the onnx model
335+ * ``custom``: custom exporter (see :epkg:`experimental-experiment`),
336+ models can be optimized with ``optimization`` in
337+ ``("default", "default+onnxruntime", "default+os_ort", "default+onnxruntime+os_ort")``
338+
339+ The default runtime, :epkg:`onnxruntime` is used to validate a model and check the
340+ exported model returns the same outputs as the original one, otherwise,
341+ :class:`onnx_diagnostic.reference.TorchOnnxEvaluator` is used.
325342 """
326343 assert (
327344 not rewrite or patch
0 commit comments