Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/modelscope/modelscope
/ unpatch_hub
Function
unpatch_hub
modelscope/utils/hf_util/patcher.py:1008–1011 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
1006
1007
1008
def
unpatch_hub():
1009
_unpatch_pretrained_class(get_all_imported_modules())
1010
_unpatch_kernels()
1011
_unpatch_hub()
1012
1013
1014
@contextlib.contextmanager
Callers
3
test_patch_hub_then_unpatch_hub_round_trip
Method · 0.90
test_wrapped_call_nests_inside_patch_hub
Method · 0.90
patch_context
Function · 0.85
Calls
4
_unpatch_pretrained_class
Function · 0.85
get_all_imported_modules
Function · 0.85
_unpatch_kernels
Function · 0.85
_unpatch_hub
Function · 0.85
Tested by
2
test_patch_hub_then_unpatch_hub_round_trip
Method · 0.72
test_wrapped_call_nests_inside_patch_hub
Method · 0.72
Used in the wild
real call sites across dependent graphs
searching dependent graphs…