mirror of
https://github.com/oobabooga/text-generation-webui.git
synced 2024-11-22 16:17:57 +01:00
Change a comment
This commit is contained in:
parent
2c1b548cea
commit
f5fb1ee666
@ -50,10 +50,11 @@ default_req_params = {
|
|||||||
def get_default_req_params():
|
def get_default_req_params():
|
||||||
return copy.deepcopy(default_req_params)
|
return copy.deepcopy(default_req_params)
|
||||||
|
|
||||||
# little helper to get defaults if arg is present but None and should be the same type as default.
|
|
||||||
|
|
||||||
|
|
||||||
def default(dic, key, default):
|
def default(dic, key, default):
|
||||||
|
'''
|
||||||
|
little helper to get defaults if arg is present but None and should be the same type as default.
|
||||||
|
'''
|
||||||
val = dic.get(key, default)
|
val = dic.get(key, default)
|
||||||
if not isinstance(val, type(default)):
|
if not isinstance(val, type(default)):
|
||||||
# maybe it's just something like 1 instead of 1.0
|
# maybe it's just something like 1 instead of 1.0
|
||||||
|
Loading…
Reference in New Issue
Block a user