Skip to content
This repository has been archived by the owner on Nov 25, 2022. It is now read-only.

Commit

Permalink
[MetaSchedule] Fix typo of compare between GlobalVar and str (apache#…
Browse files Browse the repository at this point in the history
…12704)

fix typo of compare between GlobalVar and str
  • Loading branch information
wrongtest-intellif authored and xinetzone committed Nov 25, 2022
1 parent abe913f commit 43ede31
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/tvm/meta_schedule/default_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def mod(mod: Union[PrimFunc, IRModule]) -> IRModule: # pylint: disable=redefine
raise TypeError(f"Expected `mod` to be PrimFunc or IRModule, but gets: {mod}")
func_names = mod.get_global_vars()
(func_name,) = func_names
if len(func_names) == 1 and func_name != "main":
if len(func_names) == 1 and func_name.name_hint != "main":
mod = IRModule({"main": mod[func_name]})
return mod

Expand Down

0 comments on commit 43ede31

Please sign in to comment.