File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -627,6 +627,10 @@ def save(
627627 raise ValueError (
628628 f"Provided output_format { output_format } is not supported. Supported options are exported_program | torchscript"
629629 )
630+ if output_format == "aot_inductor" and platform .system () != "Linux" :
631+ raise ValueError (
632+ f"The AOT Inductor format is only supported on Linux, { platform .system ()} is not a supported platform for this format"
633+ )
630634 if not file_path :
631635 raise ValueError ("File path cannot be empty. Please provide a valid file path" )
632636
Original file line number Diff line number Diff line change 11import importlib
22import os
3+ import platform
34import tempfile
45import unittest
56
@@ -645,6 +646,10 @@ def forward(self, x):
645646
646647
647648@pytest .mark .unit
649+ @unittest .skipIf (
650+ platform .system () != "Linux" ,
651+ "Save and load in AOT Inductor format is only supported on Linux" ,
652+ )
648653def test_save_load_aoti (ir , tmp_path ):
649654 """
650655 This tests save/load API on the AOTI format
You can’t perform that action at this time.
0 commit comments