repo
stringlengths 7
54
| path
stringlengths 4
223
| func_name
stringlengths 1
134
| original_string
stringlengths 75
104k
| language
stringclasses 1
value | code
stringlengths 75
104k
| code_tokens
listlengths 20
28.4k
| docstring
stringlengths 1
46.3k
| docstring_tokens
listlengths 1
1.66k
| sha
stringlengths 40
40
| url
stringlengths 87
315
| partition
stringclasses 1
value | summary
stringlengths 4
350
| obf_code
stringlengths 7.85k
764k
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
tensorflow/tensor2tensor
|
tensor2tensor/layers/discretization.py
|
tanh_discrete_unbottleneck
|
def tanh_discrete_unbottleneck(x, hidden_size):
"""Simple un-discretization from tanh."""
x = tf.layers.dense(x, hidden_size, name="tanh_discrete_unbottleneck")
return x
|
python
|
def tanh_discrete_unbottleneck(x, hidden_size):
"""Simple un-discretization from tanh."""
x = tf.layers.dense(x, hidden_size, name="tanh_discrete_unbottleneck")
return x
|
[
"def",
"tanh_discrete_unbottleneck",
"(",
"x",
",",
"hidden_size",
")",
":",
"x",
"=",
"tf",
".",
"layers",
".",
"dense",
"(",
"x",
",",
"hidden_size",
",",
"name",
"=",
"\"tanh_discrete_unbottleneck\"",
")",
"return",
"x"
] |
Simple un-discretization from tanh.
|
[
"Simple",
"un",
"-",
"discretization",
"from",
"tanh",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/layers/discretization.py#L1393-L1396
|
train
|
Simple un - discretization from tanh.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMd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eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(1438 - 1390) + chr(0b10110 + 0o131) + '\062' + chr(49) + '\066', 0b1000), ehT0Px3KOsy9(chr(1345 - 1297) + chr(111) + '\063' + '\064' + chr(1992 - 1937), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x33' + chr(0b110011) + chr(51), 0o10), ehT0Px3KOsy9(chr(1950 - 1902) + chr(0b1101111) + chr(0b101110 + 0o5) + chr(465 - 417) + chr(0b100001 + 0o25), 0b1000), ehT0Px3KOsy9(chr(0b100011 + 0o15) + chr(0b1100000 + 0o17) + chr(50) + '\x34' + '\x34', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(50) + chr(54) + '\063', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110001 + 0o5) + '\062', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1111 + 0o140) + chr(0b100001 + 0o20) + chr(90 - 39) + chr(0b101101 + 0o6), 0b1000), ehT0Px3KOsy9(chr(48) + chr(10365 - 10254) + chr(0b110010) + chr(0b110110) + chr(602 - 551), 8), ehT0Px3KOsy9(chr(0b110000) + chr(4925 - 4814) + chr(49) + '\x37' + '\x37', 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\x33' + '\062' + chr(50), 0o10), ehT0Px3KOsy9(chr(59 - 11) + chr(9830 - 9719) + chr(1170 - 1121) + chr(0b110000) + '\067', 0b1000), ehT0Px3KOsy9(chr(798 - 750) + chr(11640 - 11529) + chr(2358 - 2308) + chr(95 - 40) + chr(0b111 + 0o51), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1010 + 0o145) + chr(397 - 347) + chr(0b110010), 58415 - 58407), ehT0Px3KOsy9(chr(265 - 217) + '\x6f' + chr(554 - 503) + '\x36' + chr(55), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x32' + '\x36' + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(11937 - 11826) + chr(1536 - 1484) + chr(51), 34985 - 34977), ehT0Px3KOsy9(chr(0b100110 + 0o12) + '\157' + chr(0b10 + 0o62) + chr(0b110001), 14608 - 14600), ehT0Px3KOsy9('\060' + chr(0b100000 + 0o117) + '\x35' + '\x35', ord("\x08")), ehT0Px3KOsy9(chr(0b100111 + 0o11) + '\x6f' + '\063' + '\x32' + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(48) + chr(4289 - 4178) + chr(0b11010 + 0o27) + '\x31', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\061' + chr(0b11111 + 0o24) + chr(0b1110 + 0o51), 35885 - 35877), ehT0Px3KOsy9(chr(0b110000) + chr(0b1100101 + 0o12) + '\063' + chr(0b101000 + 0o15) + '\064', 0b1000), ehT0Px3KOsy9(chr(0b100110 + 0o12) + chr(0b1101111) + '\061' + '\x36' + '\x34', 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110010) + '\065' + chr(0b101010 + 0o14), 44857 - 44849), ehT0Px3KOsy9(chr(501 - 453) + '\x6f' + '\061' + chr(48), 35608 - 35600), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2187 - 2135) + '\061', 8), ehT0Px3KOsy9(chr(48) + chr(111) + chr(2288 - 2238) + '\064' + '\060', 34381 - 34373), ehT0Px3KOsy9(chr(2294 - 2246) + chr(6437 - 6326) + chr(0b100000 + 0o23) + '\x35' + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(349 - 301) + chr(111) + chr(674 - 620) + chr(0b0 + 0o62), 8), ehT0Px3KOsy9(chr(0b101111 + 0o1) + '\x6f' + chr(49) + '\063' + chr(1019 - 970), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1001000 + 0o47) + '\x36' + '\x32', 8), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x31' + chr(0b110100) + chr(0b110000 + 0o1), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(2461 - 2350) + chr(49) + chr(344 - 295) + '\065', 11085 - 11077), ehT0Px3KOsy9(chr(811 - 763) + '\x6f' + chr(49) + '\061', 8), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x33' + chr(0b100101 + 0o16) + '\x33', 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b110111 + 0o70) + chr(51) + chr(51) + '\x34', 2335 - 2327), ehT0Px3KOsy9(chr(447 - 399) + '\157' + chr(1678 - 1628) + chr(54) + chr(0b110110), 0b1000), ehT0Px3KOsy9('\x30' + chr(3697 - 3586) + '\x32' + chr(55) + chr(49), 3430 - 3422), ehT0Px3KOsy9(chr(0b10011 + 0o35) + '\157' + '\x33', 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x35' + '\x30', ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xa0'), chr(0b1100100) + chr(101) + chr(8748 - 8649) + chr(0b1101111) + '\x64' + '\145')(chr(0b1110101) + chr(339 - 223) + chr(0b1100110) + '\055' + chr(0b1001 + 0o57)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def qd2Z4ommZOet(OeWW0F1dBPRQ, qzoyXN3kdhDL):
OeWW0F1dBPRQ = IDJ2eXGCBCDu.layers.dense(OeWW0F1dBPRQ, qzoyXN3kdhDL, name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xfa\x86\xb5\xae\xfb\xd7[(\xd0\r\xb73\xddM\x82\xdbANY\xa5e:\x82\x11\xcdc'), '\x64' + chr(0b101110 + 0o67) + chr(0b111001 + 0o52) + chr(7529 - 7418) + chr(100) + chr(101))('\165' + chr(2727 - 2611) + '\146' + chr(45) + chr(0b111000)))
return OeWW0F1dBPRQ
|
tensorflow/tensor2tensor
|
tensor2tensor/layers/discretization.py
|
isemhash_bottleneck
|
def isemhash_bottleneck(x,
bottleneck_bits,
bottleneck_noise,
discretize_warmup_steps,
mode,
isemhash_noise_dev=0.5,
isemhash_mix_prob=0.5):
"""Improved semantic hashing bottleneck."""
with tf.variable_scope("isemhash_bottleneck"):
x = tf.layers.dense(x, bottleneck_bits, name="dense")
y = common_layers.saturating_sigmoid(x)
if isemhash_noise_dev > 0 and mode == tf.estimator.ModeKeys.TRAIN:
noise = tf.truncated_normal(
common_layers.shape_list(x), mean=0.0, stddev=isemhash_noise_dev)
y = common_layers.saturating_sigmoid(x + noise)
d = tf.to_float(tf.less(0.5, y)) + y - tf.stop_gradient(y)
d = 2.0 * d - 1.0 # Move from [0, 1] to [-1, 1].
if mode == tf.estimator.ModeKeys.TRAIN: # Flip some bits.
noise = tf.random_uniform(common_layers.shape_list(x))
noise = 2.0 * tf.to_float(tf.less(bottleneck_noise, noise)) - 1.0
d *= noise
d = common_layers.mix(
d,
2.0 * y - 1.0,
discretize_warmup_steps,
mode == tf.estimator.ModeKeys.TRAIN,
max_prob=isemhash_mix_prob)
return d, 0.0
|
python
|
def isemhash_bottleneck(x,
bottleneck_bits,
bottleneck_noise,
discretize_warmup_steps,
mode,
isemhash_noise_dev=0.5,
isemhash_mix_prob=0.5):
"""Improved semantic hashing bottleneck."""
with tf.variable_scope("isemhash_bottleneck"):
x = tf.layers.dense(x, bottleneck_bits, name="dense")
y = common_layers.saturating_sigmoid(x)
if isemhash_noise_dev > 0 and mode == tf.estimator.ModeKeys.TRAIN:
noise = tf.truncated_normal(
common_layers.shape_list(x), mean=0.0, stddev=isemhash_noise_dev)
y = common_layers.saturating_sigmoid(x + noise)
d = tf.to_float(tf.less(0.5, y)) + y - tf.stop_gradient(y)
d = 2.0 * d - 1.0 # Move from [0, 1] to [-1, 1].
if mode == tf.estimator.ModeKeys.TRAIN: # Flip some bits.
noise = tf.random_uniform(common_layers.shape_list(x))
noise = 2.0 * tf.to_float(tf.less(bottleneck_noise, noise)) - 1.0
d *= noise
d = common_layers.mix(
d,
2.0 * y - 1.0,
discretize_warmup_steps,
mode == tf.estimator.ModeKeys.TRAIN,
max_prob=isemhash_mix_prob)
return d, 0.0
|
[
"def",
"isemhash_bottleneck",
"(",
"x",
",",
"bottleneck_bits",
",",
"bottleneck_noise",
",",
"discretize_warmup_steps",
",",
"mode",
",",
"isemhash_noise_dev",
"=",
"0.5",
",",
"isemhash_mix_prob",
"=",
"0.5",
")",
":",
"with",
"tf",
".",
"variable_scope",
"(",
"\"isemhash_bottleneck\"",
")",
":",
"x",
"=",
"tf",
".",
"layers",
".",
"dense",
"(",
"x",
",",
"bottleneck_bits",
",",
"name",
"=",
"\"dense\"",
")",
"y",
"=",
"common_layers",
".",
"saturating_sigmoid",
"(",
"x",
")",
"if",
"isemhash_noise_dev",
">",
"0",
"and",
"mode",
"==",
"tf",
".",
"estimator",
".",
"ModeKeys",
".",
"TRAIN",
":",
"noise",
"=",
"tf",
".",
"truncated_normal",
"(",
"common_layers",
".",
"shape_list",
"(",
"x",
")",
",",
"mean",
"=",
"0.0",
",",
"stddev",
"=",
"isemhash_noise_dev",
")",
"y",
"=",
"common_layers",
".",
"saturating_sigmoid",
"(",
"x",
"+",
"noise",
")",
"d",
"=",
"tf",
".",
"to_float",
"(",
"tf",
".",
"less",
"(",
"0.5",
",",
"y",
")",
")",
"+",
"y",
"-",
"tf",
".",
"stop_gradient",
"(",
"y",
")",
"d",
"=",
"2.0",
"*",
"d",
"-",
"1.0",
"# Move from [0, 1] to [-1, 1].",
"if",
"mode",
"==",
"tf",
".",
"estimator",
".",
"ModeKeys",
".",
"TRAIN",
":",
"# Flip some bits.",
"noise",
"=",
"tf",
".",
"random_uniform",
"(",
"common_layers",
".",
"shape_list",
"(",
"x",
")",
")",
"noise",
"=",
"2.0",
"*",
"tf",
".",
"to_float",
"(",
"tf",
".",
"less",
"(",
"bottleneck_noise",
",",
"noise",
")",
")",
"-",
"1.0",
"d",
"*=",
"noise",
"d",
"=",
"common_layers",
".",
"mix",
"(",
"d",
",",
"2.0",
"*",
"y",
"-",
"1.0",
",",
"discretize_warmup_steps",
",",
"mode",
"==",
"tf",
".",
"estimator",
".",
"ModeKeys",
".",
"TRAIN",
",",
"max_prob",
"=",
"isemhash_mix_prob",
")",
"return",
"d",
",",
"0.0"
] |
Improved semantic hashing bottleneck.
|
[
"Improved",
"semantic",
"hashing",
"bottleneck",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/layers/discretization.py#L1399-L1426
|
train
|
Improved semantic hashing bottleneck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UMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(10047 - 9936) + '\063' + chr(48), 0o10), ehT0Px3KOsy9('\060' + chr(0b10011 + 0o134) + chr(1216 - 1166) + '\061' + '\061', 0b1000), ehT0Px3KOsy9('\060' + chr(0b110000 + 0o77) + chr(2728 - 2675), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(7398 - 7287) + chr(0b1101 + 0o45) + chr(0b100001 + 0o21) + chr(0b110010), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(4481 - 4370) + '\061' + chr(54) + chr(0b110011), 58014 - 58006), ehT0Px3KOsy9(chr(0b1100 + 0o44) + chr(0b1101111) + chr(938 - 887) + chr(0b1001 + 0o47) + chr(0b110010), 56251 - 56243), ehT0Px3KOsy9('\060' + chr(0b111010 + 0o65) + chr(50) + chr(0b110101) + '\x36', 822 - 814), ehT0Px3KOsy9(chr(48) + chr(0b11110 + 0o121) + '\x33' + chr(0b100 + 0o57) + '\065', 25942 - 25934), ehT0Px3KOsy9(chr(48) + '\157' + '\062' + '\x37', 9216 - 9208), ehT0Px3KOsy9(chr(0b110000) + chr(9718 - 9607) + chr(2399 - 2349) + chr(0b110010) + chr(0b11110 + 0o23), ord("\x08")), ehT0Px3KOsy9(chr(1264 - 1216) + chr(0b1101 + 0o142) + '\x33' + '\066', 54126 - 54118), ehT0Px3KOsy9(chr(0b110000) + chr(1715 - 1604) + '\063' + chr(49) + chr(49), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(50) + chr(1593 - 1543) + chr(1879 - 1824), ord("\x08")), ehT0Px3KOsy9(chr(2100 - 2052) + chr(0b1101110 + 0o1) + chr(866 - 817) + '\063' + '\061', 0b1000), ehT0Px3KOsy9(chr(1767 - 1719) + chr(8169 - 8058) + chr(0b110110) + '\065', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b101101 + 0o7) + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(0b101101 + 0o3) + '\x6f' + chr(0b1000 + 0o53) + chr(0b110001) + chr(49), 8), ehT0Px3KOsy9('\x30' + chr(0b1010010 + 0o35) + chr(1288 - 1237) + '\x32' + chr(0b110000), 23120 - 23112), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\062' + chr(0b110110) + chr(0b110111), 43674 - 43666), ehT0Px3KOsy9(chr(0b110000) + chr(0b1001001 + 0o46) + chr(2307 - 2258) + '\x36' + '\x31', ord("\x08")), ehT0Px3KOsy9('\060' + chr(1598 - 1487) + chr(0b110110) + chr(0b110001), 50313 - 50305), ehT0Px3KOsy9(chr(924 - 876) + chr(0b1101111) + chr(0b110010) + chr(0b110110) + '\x34', 61158 - 61150), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110011) + chr(297 - 243) + '\x30', 44086 - 44078), ehT0Px3KOsy9(chr(0b101100 + 0o4) + '\x6f' + chr(0b1001 + 0o53) + chr(52), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b1011 + 0o46) + chr(0b110011) + '\x34', 0o10), ehT0Px3KOsy9(chr(2185 - 2137) + chr(0b100 + 0o153) + chr(51) + '\x31' + '\x31', 8), ehT0Px3KOsy9('\x30' + chr(111) + '\063' + chr(54) + chr(0b110110), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(2225 - 2172), 8), ehT0Px3KOsy9(chr(2247 - 2199) + chr(1441 - 1330) + '\061', 16085 - 16077), ehT0Px3KOsy9('\060' + chr(111) + chr(562 - 512) + chr(375 - 320), 8), ehT0Px3KOsy9(chr(265 - 217) + '\157' + chr(0b110001 + 0o0) + chr(49) + chr(0b110010), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1010010 + 0o35) + chr(1765 - 1715) + chr(0b110011) + chr(0b110010), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + '\x31' + chr(0b10101 + 0o33) + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1110 + 0o141) + chr(920 - 869) + chr(0b10101 + 0o41) + '\x34', 0o10), ehT0Px3KOsy9(chr(2080 - 2032) + chr(0b1011000 + 0o27) + '\x33' + chr(2864 - 2809) + '\065', 0o10), ehT0Px3KOsy9(chr(0b100000 + 0o20) + '\x6f' + chr(52) + '\x37', 26770 - 26762), ehT0Px3KOsy9(chr(0b100001 + 0o17) + chr(2807 - 2696) + chr(1521 - 1470) + chr(259 - 204) + chr(0b110100), 0o10), ehT0Px3KOsy9('\060' + '\157' + chr(0b110010) + chr(49) + '\063', 11310 - 11302), ehT0Px3KOsy9(chr(94 - 46) + chr(111) + chr(0b11001 + 0o32) + '\x36' + chr(0b100100 + 0o22), 8), ehT0Px3KOsy9(chr(765 - 717) + chr(0b101011 + 0o104) + chr(0b101110 + 0o4) + chr(596 - 543), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(741 - 688) + chr(0b110000), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'6'), '\x64' + chr(3489 - 3388) + chr(6719 - 6620) + chr(0b1001110 + 0o41) + chr(5727 - 5627) + chr(101))('\x75' + chr(8737 - 8621) + chr(2429 - 2327) + '\055' + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def QY7eekTeV6eV(OeWW0F1dBPRQ, L0tf_yAed5SW, r1G583Dm7QSl, jjDbSmPUfjP2, holLFgwB7vsP, GUSREj_C9LrC=0.5, D2D_LzP17jcT=0.5):
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'n\xe8w\xfb\x12\xa0\xc2\xb8H\xe2}\xa6\xe7<'), chr(7416 - 7316) + chr(0b1100101) + chr(99) + chr(0b1101111) + chr(0b111101 + 0o47) + '\145')('\x75' + chr(0b1110100) + chr(0b1100110) + '\x2d' + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'q\xfa`\xff\x1b\xa3\xdd\xb5H\xf3q\xbd\xe35PK\xac\xb3\xdc'), chr(0b1100100) + chr(0b1010111 + 0o16) + chr(0b1100011) + chr(0b1001100 + 0o43) + chr(100) + chr(101))('\x75' + chr(11039 - 10923) + '\146' + chr(0b11101 + 0o20) + chr(0b10000 + 0o50))):
OeWW0F1dBPRQ = IDJ2eXGCBCDu.layers.dense(OeWW0F1dBPRQ, L0tf_yAed5SW, name=xafqLlk3kkUe(SXOLrMavuUCe(b'|\xeck\xe1\x16'), chr(0b1100100) + chr(101) + '\143' + chr(9437 - 9326) + chr(8837 - 8737) + '\x65')(chr(0b1110101) + chr(2637 - 2521) + chr(9976 - 9874) + chr(725 - 680) + '\070'))
SqiSOtYOqOJH = jSKPaHwSAfVv.saturating_sigmoid(OeWW0F1dBPRQ)
if GUSREj_C9LrC > ehT0Px3KOsy9(chr(538 - 490) + chr(0b1101111) + chr(1856 - 1808), ord("\x08")) and holLFgwB7vsP == xafqLlk3kkUe(IDJ2eXGCBCDu.estimator.ModeKeys, xafqLlk3kkUe(SXOLrMavuUCe(b'L\xdbD\xdb='), chr(0b1100100) + chr(2327 - 2226) + '\143' + chr(0b1101111) + chr(0b111010 + 0o52) + '\x65')('\165' + chr(0b110001 + 0o103) + chr(0b10100 + 0o122) + '\055' + '\070')):
MudPQU2D1pmv = IDJ2eXGCBCDu.truncated_normal(jSKPaHwSAfVv.shape_list(OeWW0F1dBPRQ), mean=0.0, stddev=GUSREj_C9LrC)
SqiSOtYOqOJH = jSKPaHwSAfVv.saturating_sigmoid(OeWW0F1dBPRQ + MudPQU2D1pmv)
pd3lxn9vqWxp = IDJ2eXGCBCDu.to_float(IDJ2eXGCBCDu.less(0.5, SqiSOtYOqOJH)) + SqiSOtYOqOJH - IDJ2eXGCBCDu.stop_gradient(SqiSOtYOqOJH)
pd3lxn9vqWxp = 2.0 * pd3lxn9vqWxp - 1.0
if holLFgwB7vsP == xafqLlk3kkUe(IDJ2eXGCBCDu.estimator.ModeKeys, xafqLlk3kkUe(SXOLrMavuUCe(b'L\xdbD\xdb='), '\144' + chr(101) + '\143' + chr(1983 - 1872) + chr(1169 - 1069) + chr(0b100000 + 0o105))(chr(0b101 + 0o160) + chr(4623 - 4507) + '\x66' + '\055' + chr(496 - 440))):
MudPQU2D1pmv = IDJ2eXGCBCDu.random_uniform(jSKPaHwSAfVv.shape_list(OeWW0F1dBPRQ))
MudPQU2D1pmv = 2.0 * IDJ2eXGCBCDu.to_float(IDJ2eXGCBCDu.less(r1G583Dm7QSl, MudPQU2D1pmv)) - 1.0
pd3lxn9vqWxp *= MudPQU2D1pmv
pd3lxn9vqWxp = jSKPaHwSAfVv.mix(pd3lxn9vqWxp, 2.0 * SqiSOtYOqOJH - 1.0, jjDbSmPUfjP2, holLFgwB7vsP == IDJ2eXGCBCDu.estimator.ModeKeys.TRAIN, max_prob=D2D_LzP17jcT)
return (pd3lxn9vqWxp, 0.0)
|
tensorflow/tensor2tensor
|
tensor2tensor/layers/discretization.py
|
isemhash_unbottleneck
|
def isemhash_unbottleneck(x, hidden_size, isemhash_filter_size_multiplier=1.0):
"""Improved semantic hashing un-bottleneck."""
filter_size = int(hidden_size * isemhash_filter_size_multiplier)
x = 0.5 * (x - 1.0) # Move from [-1, 1] to [0, 1].
with tf.variable_scope("isemhash_unbottleneck"):
h1a = tf.layers.dense(x, filter_size, name="hidden1a")
h1b = tf.layers.dense(1.0 - x, filter_size, name="hidden1b")
h2 = tf.layers.dense(tf.nn.relu(h1a + h1b), filter_size, name="hidden2")
return tf.layers.dense(tf.nn.relu(h2), hidden_size, name="final")
|
python
|
def isemhash_unbottleneck(x, hidden_size, isemhash_filter_size_multiplier=1.0):
"""Improved semantic hashing un-bottleneck."""
filter_size = int(hidden_size * isemhash_filter_size_multiplier)
x = 0.5 * (x - 1.0) # Move from [-1, 1] to [0, 1].
with tf.variable_scope("isemhash_unbottleneck"):
h1a = tf.layers.dense(x, filter_size, name="hidden1a")
h1b = tf.layers.dense(1.0 - x, filter_size, name="hidden1b")
h2 = tf.layers.dense(tf.nn.relu(h1a + h1b), filter_size, name="hidden2")
return tf.layers.dense(tf.nn.relu(h2), hidden_size, name="final")
|
[
"def",
"isemhash_unbottleneck",
"(",
"x",
",",
"hidden_size",
",",
"isemhash_filter_size_multiplier",
"=",
"1.0",
")",
":",
"filter_size",
"=",
"int",
"(",
"hidden_size",
"*",
"isemhash_filter_size_multiplier",
")",
"x",
"=",
"0.5",
"*",
"(",
"x",
"-",
"1.0",
")",
"# Move from [-1, 1] to [0, 1].",
"with",
"tf",
".",
"variable_scope",
"(",
"\"isemhash_unbottleneck\"",
")",
":",
"h1a",
"=",
"tf",
".",
"layers",
".",
"dense",
"(",
"x",
",",
"filter_size",
",",
"name",
"=",
"\"hidden1a\"",
")",
"h1b",
"=",
"tf",
".",
"layers",
".",
"dense",
"(",
"1.0",
"-",
"x",
",",
"filter_size",
",",
"name",
"=",
"\"hidden1b\"",
")",
"h2",
"=",
"tf",
".",
"layers",
".",
"dense",
"(",
"tf",
".",
"nn",
".",
"relu",
"(",
"h1a",
"+",
"h1b",
")",
",",
"filter_size",
",",
"name",
"=",
"\"hidden2\"",
")",
"return",
"tf",
".",
"layers",
".",
"dense",
"(",
"tf",
".",
"nn",
".",
"relu",
"(",
"h2",
")",
",",
"hidden_size",
",",
"name",
"=",
"\"final\"",
")"
] |
Improved semantic hashing un-bottleneck.
|
[
"Improved",
"semantic",
"hashing",
"un",
"-",
"bottleneck",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/layers/discretization.py#L1429-L1437
|
train
|
Improved semantic hashing un - bottleneck.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvx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m1zTRfSmY,reqGiMiVQ77y,bsS9P6_LpdIe,sbGAZlkZOtyh,Cf_Qef15s3_F,eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(9680 - 9569) + '\x33' + chr(0b100001 + 0o17) + '\x31', 0o10), ehT0Px3KOsy9(chr(1175 - 1127) + '\x6f' + '\x33' + chr(0b110110) + '\064', 16923 - 16915), ehT0Px3KOsy9('\x30' + chr(0b100101 + 0o112) + chr(2509 - 2457), 0b1000), ehT0Px3KOsy9(chr(338 - 290) + chr(111) + chr(50) + chr(52) + chr(0b110011), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\062' + chr(1070 - 1022) + chr(0b1110 + 0o51), 0o10), ehT0Px3KOsy9(chr(112 - 64) + chr(111) + '\x31' + chr(55) + '\x32', 0b1000), ehT0Px3KOsy9(chr(0b11011 + 0o25) + '\x6f' + chr(964 - 909) + chr(48), 57472 - 57464), ehT0Px3KOsy9(chr(48) + '\157' + chr(888 - 837) + chr(588 - 537) + chr(0b101001 + 0o16), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(1901 - 1852) + chr(55) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + '\x33' + chr(54) + chr(0b110000 + 0o0), 46838 - 46830), ehT0Px3KOsy9('\060' + '\x6f' + chr(50) + '\x30' + chr(0b110111), 8), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b101 + 0o55) + chr(50) + chr(49), 0o10), ehT0Px3KOsy9(chr(48) + chr(2436 - 2325) + chr(0b11111 + 0o23) + chr(0b110011), 0o10), ehT0Px3KOsy9(chr(0b11000 + 0o30) + chr(0b10 + 0o155) + chr(0b110001) + '\x35' + '\x31', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x34' + '\065', 15815 - 15807), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110100) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x34' + chr(50), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\062' + chr(0b110111) + '\x32', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\x34' + chr(1651 - 1597), 38815 - 38807), ehT0Px3KOsy9(chr(1410 - 1362) + '\157' + '\061' + chr(0b110011) + chr(51), 62830 - 62822), ehT0Px3KOsy9(chr(323 - 275) + chr(0b111100 + 0o63) + '\063' + chr(1666 - 1616) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\062' + chr(0b110011) + chr(48), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x33' + '\x30' + '\061', 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(2514 - 2459) + '\x37', 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x33' + chr(623 - 573) + chr(0b110011), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(474 - 423) + '\x36' + '\x31', 46191 - 46183), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(57 - 6) + '\x33' + chr(731 - 678), 0o10), ehT0Px3KOsy9('\060' + chr(2510 - 2399) + '\x32' + chr(55) + chr(48), 15989 - 15981), ehT0Px3KOsy9(chr(0b1111 + 0o41) + chr(6933 - 6822) + chr(0b110 + 0o54) + chr(1326 - 1273) + '\060', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\067' + chr(309 - 256), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101100 + 0o3) + chr(699 - 649) + '\x32' + '\062', 18391 - 18383), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(0b1101111) + chr(49) + '\x37' + chr(1042 - 989), ord("\x08")), ehT0Px3KOsy9(chr(0b100000 + 0o20) + chr(808 - 697) + chr(51) + '\x37' + '\x30', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1010011 + 0o34) + '\063' + '\x36' + chr(54), 30758 - 30750), ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(10513 - 10402) + chr(0b101100 + 0o6) + chr(52), 44266 - 44258), ehT0Px3KOsy9(chr(48) + chr(0b1000100 + 0o53) + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1001101 + 0o42) + '\x32' + '\x33' + chr(0b10 + 0o56), 8), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(2121 - 2069) + chr(2113 - 2065), 8), ehT0Px3KOsy9(chr(48) + chr(0b1101000 + 0o7) + chr(51) + '\x37' + chr(0b110100), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\x32' + chr(0b101011 + 0o10) + '\066', 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + '\x6f' + '\x35' + chr(0b110000), 54925 - 54917)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xef'), chr(0b1010100 + 0o20) + '\145' + '\143' + '\157' + '\144' + chr(101))(chr(13224 - 13107) + chr(0b1110100) + chr(3859 - 3757) + chr(45) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def jP6ca4Ax9SoV(OeWW0F1dBPRQ, qzoyXN3kdhDL, i3caCegq8ROh=1.0):
deybX8NJ0oEI = ehT0Px3KOsy9(qzoyXN3kdhDL * i3caCegq8ROh)
OeWW0F1dBPRQ = 0.5 * (OeWW0F1dBPRQ - 1.0)
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\xb7\x95v\xca\xe6\x18T\xba$\x83\xe4\xfec\x0c'), chr(8279 - 8179) + chr(0b101 + 0o140) + chr(0b100 + 0o137) + chr(0b1010011 + 0o34) + '\x64' + chr(9576 - 9475))(chr(117) + chr(0b1110100) + '\146' + chr(45) + chr(0b100100 + 0o24)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xa8\x87a\xce\xef\x1bK\xb7$\x85\xe9\xf3|\x1dQLG\xd4C8\xb8'), '\x64' + '\x65' + chr(0b1001000 + 0o33) + chr(1604 - 1493) + '\x64' + chr(0b101110 + 0o67))(chr(8630 - 8513) + '\x74' + chr(0b1100110) + chr(45) + chr(0b11101 + 0o33))):
iT5VkYIrJ3K0 = IDJ2eXGCBCDu.layers.dense(OeWW0F1dBPRQ, deybX8NJ0oEI, name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xa9\x9d`\xc7\xe2\x14\t\xbe'), chr(100) + chr(0b1100101) + chr(0b1100011) + '\157' + chr(0b1010 + 0o132) + chr(0b1100101))('\165' + chr(12581 - 12465) + chr(0b1111 + 0o127) + chr(553 - 508) + '\x38'))
T6pPGkiz_8Et = IDJ2eXGCBCDu.layers.dense(1.0 - OeWW0F1dBPRQ, deybX8NJ0oEI, name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xa9\x9d`\xc7\xe2\x14\t\xbd'), chr(0b1100100) + '\145' + '\143' + chr(12192 - 12081) + chr(100) + '\x65')(chr(0b1110101) + chr(0b1110100) + '\x66' + '\x2d' + '\x38'))
GGNH7JNUgs4j = IDJ2eXGCBCDu.layers.dense(IDJ2eXGCBCDu.nn.relu(iT5VkYIrJ3K0 + T6pPGkiz_8Et), deybX8NJ0oEI, name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xa9\x9d`\xc7\xe2\x14\n'), '\144' + chr(0b1100101) + chr(0b110 + 0o135) + chr(111) + chr(0b1100100) + '\x65')(chr(13124 - 13007) + chr(0b1110100) + chr(7149 - 7047) + '\x2d' + chr(1961 - 1905)))
return xafqLlk3kkUe(IDJ2eXGCBCDu.layers, xafqLlk3kkUe(SXOLrMavuUCe(b'\xa5\x91j\xd0\xe2'), chr(3663 - 3563) + '\x65' + chr(99) + chr(111) + '\x64' + chr(0b1100101))(chr(117) + '\164' + '\146' + chr(0b101101) + chr(0b111000)))(xafqLlk3kkUe(IDJ2eXGCBCDu.nn, xafqLlk3kkUe(SXOLrMavuUCe(b'\xb3\x91h\xd6'), chr(0b1100 + 0o130) + '\x65' + chr(0b11100 + 0o107) + chr(877 - 766) + chr(4810 - 4710) + '\x65')(chr(1736 - 1619) + '\164' + chr(0b1100 + 0o132) + '\055' + chr(1552 - 1496)))(GGNH7JNUgs4j), qzoyXN3kdhDL, name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xa7\x9dj\xc2\xeb'), chr(7868 - 7768) + chr(0b111011 + 0o52) + '\x63' + chr(0b1010001 + 0o36) + '\x64' + chr(0b1100101))(chr(0b1110101) + chr(0b1011101 + 0o27) + chr(203 - 101) + chr(0b110 + 0o47) + chr(1763 - 1707)))
|
tensorflow/tensor2tensor
|
tensor2tensor/layers/discretization.py
|
parametrized_bottleneck
|
def parametrized_bottleneck(x, hparams):
"""Meta-function calling all the above bottlenecks with hparams."""
if hparams.bottleneck_kind == "tanh_discrete":
d, _ = tanh_discrete_bottleneck(
x, hparams.bottleneck_bits, hparams.bottleneck_noise * 0.5,
hparams.discretize_warmup_steps, hparams.mode)
return d, 0.0
if hparams.bottleneck_kind == "isemhash":
return isemhash_bottleneck(
x, hparams.bottleneck_bits, hparams.bottleneck_noise * 0.5,
hparams.discretize_warmup_steps, hparams.mode,
hparams.isemhash_noise_dev, hparams.isemhash_mix_prob)
if hparams.bottleneck_kind == "vq":
return vq_discrete_bottleneck(x, hparams.bottleneck_bits, hparams.vq_beta,
hparams.vq_decay, hparams.vq_epsilon)
if hparams.bottleneck_kind == "em":
return vq_discrete_bottleneck(
x,
hparams.bottleneck_bits,
hparams.vq_beta,
hparams.vq_decay,
hparams.vq_epsilon,
soft_em=True,
num_samples=hparams.vq_num_samples)
if hparams.bottleneck_kind == "gumbel_softmax":
return gumbel_softmax_discrete_bottleneck(
x,
hparams.bottleneck_bits,
hparams.vq_beta,
hparams.vq_decay,
hparams.vq_epsilon,
hparams.temperature_warmup_steps,
hard=False,
summary=True)
raise ValueError(
"Unsupported hparams.bottleneck_kind %s" % hparams.bottleneck_kind)
|
python
|
def parametrized_bottleneck(x, hparams):
"""Meta-function calling all the above bottlenecks with hparams."""
if hparams.bottleneck_kind == "tanh_discrete":
d, _ = tanh_discrete_bottleneck(
x, hparams.bottleneck_bits, hparams.bottleneck_noise * 0.5,
hparams.discretize_warmup_steps, hparams.mode)
return d, 0.0
if hparams.bottleneck_kind == "isemhash":
return isemhash_bottleneck(
x, hparams.bottleneck_bits, hparams.bottleneck_noise * 0.5,
hparams.discretize_warmup_steps, hparams.mode,
hparams.isemhash_noise_dev, hparams.isemhash_mix_prob)
if hparams.bottleneck_kind == "vq":
return vq_discrete_bottleneck(x, hparams.bottleneck_bits, hparams.vq_beta,
hparams.vq_decay, hparams.vq_epsilon)
if hparams.bottleneck_kind == "em":
return vq_discrete_bottleneck(
x,
hparams.bottleneck_bits,
hparams.vq_beta,
hparams.vq_decay,
hparams.vq_epsilon,
soft_em=True,
num_samples=hparams.vq_num_samples)
if hparams.bottleneck_kind == "gumbel_softmax":
return gumbel_softmax_discrete_bottleneck(
x,
hparams.bottleneck_bits,
hparams.vq_beta,
hparams.vq_decay,
hparams.vq_epsilon,
hparams.temperature_warmup_steps,
hard=False,
summary=True)
raise ValueError(
"Unsupported hparams.bottleneck_kind %s" % hparams.bottleneck_kind)
|
[
"def",
"parametrized_bottleneck",
"(",
"x",
",",
"hparams",
")",
":",
"if",
"hparams",
".",
"bottleneck_kind",
"==",
"\"tanh_discrete\"",
":",
"d",
",",
"_",
"=",
"tanh_discrete_bottleneck",
"(",
"x",
",",
"hparams",
".",
"bottleneck_bits",
",",
"hparams",
".",
"bottleneck_noise",
"*",
"0.5",
",",
"hparams",
".",
"discretize_warmup_steps",
",",
"hparams",
".",
"mode",
")",
"return",
"d",
",",
"0.0",
"if",
"hparams",
".",
"bottleneck_kind",
"==",
"\"isemhash\"",
":",
"return",
"isemhash_bottleneck",
"(",
"x",
",",
"hparams",
".",
"bottleneck_bits",
",",
"hparams",
".",
"bottleneck_noise",
"*",
"0.5",
",",
"hparams",
".",
"discretize_warmup_steps",
",",
"hparams",
".",
"mode",
",",
"hparams",
".",
"isemhash_noise_dev",
",",
"hparams",
".",
"isemhash_mix_prob",
")",
"if",
"hparams",
".",
"bottleneck_kind",
"==",
"\"vq\"",
":",
"return",
"vq_discrete_bottleneck",
"(",
"x",
",",
"hparams",
".",
"bottleneck_bits",
",",
"hparams",
".",
"vq_beta",
",",
"hparams",
".",
"vq_decay",
",",
"hparams",
".",
"vq_epsilon",
")",
"if",
"hparams",
".",
"bottleneck_kind",
"==",
"\"em\"",
":",
"return",
"vq_discrete_bottleneck",
"(",
"x",
",",
"hparams",
".",
"bottleneck_bits",
",",
"hparams",
".",
"vq_beta",
",",
"hparams",
".",
"vq_decay",
",",
"hparams",
".",
"vq_epsilon",
",",
"soft_em",
"=",
"True",
",",
"num_samples",
"=",
"hparams",
".",
"vq_num_samples",
")",
"if",
"hparams",
".",
"bottleneck_kind",
"==",
"\"gumbel_softmax\"",
":",
"return",
"gumbel_softmax_discrete_bottleneck",
"(",
"x",
",",
"hparams",
".",
"bottleneck_bits",
",",
"hparams",
".",
"vq_beta",
",",
"hparams",
".",
"vq_decay",
",",
"hparams",
".",
"vq_epsilon",
",",
"hparams",
".",
"temperature_warmup_steps",
",",
"hard",
"=",
"False",
",",
"summary",
"=",
"True",
")",
"raise",
"ValueError",
"(",
"\"Unsupported hparams.bottleneck_kind %s\"",
"%",
"hparams",
".",
"bottleneck_kind",
")"
] |
Meta-function calling all the above bottlenecks with hparams.
|
[
"Meta",
"-",
"function",
"calling",
"all",
"the",
"above",
"bottlenecks",
"with",
"hparams",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/layers/discretization.py#L1440-L1476
|
train
|
Meta - function calling all the above bottlenecks with hparams.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0C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Pw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + chr(3892 - 3781) + chr(0b110010) + '\062' + chr(0b110011 + 0o1), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1100110 + 0o11) + '\x32' + '\x33', 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(49) + chr(113 - 61), 0b1000), ehT0Px3KOsy9(chr(0b101001 + 0o7) + chr(1761 - 1650) + '\067' + chr(0b1 + 0o66), 42399 - 42391), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110010) + chr(0b111 + 0o53) + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(0b101110 + 0o2) + chr(0b1101010 + 0o5) + chr(0b110001) + chr(2384 - 2334) + chr(0b1000 + 0o55), 26459 - 26451), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110000 + 0o6) + '\x37', 0o10), ehT0Px3KOsy9(chr(0b11 + 0o55) + chr(0b1101111) + chr(50) + '\067' + chr(832 - 783), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(1887 - 1837) + '\x35' + '\x33', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\x33' + '\060' + chr(48), 40677 - 40669), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(1509 - 1455) + chr(0b110101 + 0o1), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\063' + chr(413 - 358) + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(1862 - 1814) + '\157' + chr(0b110011) + chr(0b110111) + chr(52), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b111100 + 0o63) + '\x32' + chr(0b1001 + 0o54) + chr(0b110001), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(50) + chr(0b110111) + '\x31', 8), ehT0Px3KOsy9(chr(627 - 579) + chr(2041 - 1930) + chr(0b110001) + '\x32' + chr(756 - 701), 124 - 116), ehT0Px3KOsy9('\x30' + chr(0b1110 + 0o141) + '\x31' + chr(2151 - 2096), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b101101 + 0o5) + chr(0b1001 + 0o47), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110100) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(0b1101 + 0o43) + chr(10997 - 10886) + chr(237 - 187) + '\062' + chr(0b1101 + 0o43), 51430 - 51422), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(51) + chr(0b110110) + chr(0b1011 + 0o53), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b100110 + 0o111) + '\061' + chr(49) + chr(0b100111 + 0o17), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b100000 + 0o117) + chr(50) + chr(0b11001 + 0o33) + chr(0b100011 + 0o17), 969 - 961), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110001) + chr(48) + '\065', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1000001 + 0o56) + chr(0b110001) + '\x35' + chr(0b110001), 35668 - 35660), ehT0Px3KOsy9(chr(48) + chr(0b1011101 + 0o22) + chr(0b110111) + chr(0b110100), 0o10), ehT0Px3KOsy9(chr(0b11010 + 0o26) + '\x6f' + '\x33' + '\060' + '\x31', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\061' + '\060' + chr(0b1010 + 0o51), 14171 - 14163), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b101 + 0o55) + chr(0b110110) + '\062', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b10011 + 0o134) + chr(0b11100 + 0o27) + '\x35' + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\x33' + chr(0b1010 + 0o50) + '\x31', 0o10), ehT0Px3KOsy9('\x30' + chr(0b1 + 0o156) + chr(51) + chr(0b101001 + 0o11), 0o10), ehT0Px3KOsy9(chr(0b101 + 0o53) + '\157' + chr(0b110010) + '\x33' + chr(0b110010), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(505 - 457) + chr(0b1001101 + 0o42) + chr(467 - 412) + '\x36', 57499 - 57491), ehT0Px3KOsy9('\060' + chr(4403 - 4292) + chr(52) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(103 - 55) + chr(8199 - 8088) + '\x31' + '\063' + chr(1461 - 1407), ord("\x08")), ehT0Px3KOsy9(chr(2045 - 1997) + chr(0b1101111) + chr(1317 - 1263) + '\x31', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\x31' + chr(52) + chr(0b100111 + 0o12), 0o10), ehT0Px3KOsy9(chr(0b10111 + 0o31) + chr(0b101011 + 0o104) + chr(2479 - 2428) + chr(0b101000 + 0o12) + chr(1042 - 991), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(0b1000010 + 0o55) + chr(53) + '\060', 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xba'), chr(0b1100100) + '\x65' + chr(5121 - 5022) + '\157' + chr(7202 - 7102) + '\x65')(chr(117) + chr(116) + '\146' + '\x2d' + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def yBDGzvn3cPBQ(OeWW0F1dBPRQ, n4ljua2gi1Pr):
if xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6|xK\xfa0Y\xdc\xc8\xabi\x96\x95\xc7\xdd'), '\144' + chr(270 - 169) + '\143' + chr(111) + chr(0b1100100) + chr(101))(chr(117) + '\164' + chr(0b1011011 + 0o13) + '\055' + '\x38')) == xafqLlk3kkUe(SXOLrMavuUCe(b'\xe0rbW\xc91^\xca\xc8\xb2S\x89\x99'), chr(0b10010 + 0o122) + chr(101) + '\143' + chr(111) + chr(0b1100100) + chr(0b110000 + 0o65))('\165' + '\164' + '\x66' + chr(0b1111 + 0o36) + '\x38'):
(pd3lxn9vqWxp, VNGQdHSFPrso) = v__R6XgmgWtR(OeWW0F1dBPRQ, n4ljua2gi1Pr.bottleneck_bits, n4ljua2gi1Pr.bottleneck_noise * 0.5, n4ljua2gi1Pr.discretize_warmup_steps, n4ljua2gi1Pr.mode)
return (pd3lxn9vqWxp, 0.0)
if xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6|xK\xfa0Y\xdc\xc8\xabi\x96\x95\xc7\xdd'), chr(0b1100100) + chr(0b11101 + 0o110) + chr(2824 - 2725) + '\x6f' + chr(100) + chr(0b1001000 + 0o35))(chr(117) + '\164' + '\146' + chr(0b101101) + chr(0b111000))) == xafqLlk3kkUe(SXOLrMavuUCe(b'\xfd`iR\xfe4D\xd1'), chr(2146 - 2046) + '\145' + chr(0b11001 + 0o112) + '\x6f' + chr(0b101 + 0o137) + chr(0b110 + 0o137))(chr(0b1000011 + 0o62) + '\164' + chr(0b1010011 + 0o23) + chr(0b101101) + chr(56)):
return QY7eekTeV6eV(OeWW0F1dBPRQ, xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6|xK\xfa0Y\xdc\xc8\xabi\x9f\x95\xdd\xca'), chr(100) + '\x65' + '\143' + chr(111) + chr(0b10011 + 0o121) + '\145')(chr(117) + chr(0b1100000 + 0o24) + chr(102) + chr(0b11110 + 0o17) + chr(56))), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6|xK\xfa0Y\xdc\xc8\xabi\x93\x93\xc0\xca2'), chr(0b100101 + 0o77) + chr(0b1100101) + chr(3224 - 3125) + chr(111) + chr(527 - 427) + '\x65')(chr(117) + chr(0b1110100) + '\x66' + chr(1724 - 1679) + chr(1030 - 974))) * 0.5, xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf0z\x7f\\\xe40C\xd0\xd1\xa5i\x8a\x9d\xdb\xd4"\x7fOS\xe4\x93>\xd1'), chr(0b1100100) + '\145' + chr(0b100111 + 0o74) + chr(4966 - 4855) + '\x64' + chr(0b110 + 0o137))('\x75' + '\x74' + chr(0b1100110) + '\x2d' + '\070')), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf9|hZ'), chr(3955 - 3855) + '\x65' + chr(99) + '\x6f' + '\x64' + chr(0b1100101))('\x75' + '\164' + '\146' + '\x2d' + chr(1954 - 1898))), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xfd`iR\xfe4D\xd1\xf4\xaeY\x94\x8f\xcc\xe63jf'), '\144' + '\145' + '\143' + '\x6f' + '\x64' + chr(0b1100101))(chr(0b1110101) + chr(11601 - 11485) + chr(102) + '\055' + chr(2961 - 2905))), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xfd`iR\xfe4D\xd1\xf4\xad_\x85\xa3\xd9\xcb8m'), chr(0b1011011 + 0o11) + chr(101) + '\143' + chr(0b10110 + 0o131) + '\144' + '\145')(chr(0b1110101) + '\164' + '\146' + '\x2d' + '\x38')))
if xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6|xK\xfa0Y\xdc\xc8\xabi\x96\x95\xc7\xdd'), chr(8959 - 8859) + chr(101) + '\x63' + chr(0b101101 + 0o102) + chr(0b110100 + 0o60) + chr(0b10111 + 0o116))('\x75' + chr(11177 - 11061) + chr(0b1100110) + chr(1027 - 982) + chr(2073 - 2017))) == xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2b'), chr(100) + chr(3170 - 3069) + chr(99) + '\x6f' + '\x64' + chr(7427 - 7326))(chr(117) + chr(0b111110 + 0o66) + '\146' + '\055' + chr(3024 - 2968)):
return AA7HUoEwKt_Y(OeWW0F1dBPRQ, xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6|xK\xfa0Y\xdc\xc8\xabi\x9f\x95\xdd\xca'), '\x64' + chr(0b10100 + 0o121) + '\143' + chr(0b10 + 0o155) + '\144' + chr(3710 - 3609))(chr(0b1110101) + chr(116) + chr(0b1100110) + chr(0b100111 + 0o6) + chr(0b111000))), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2bS]\xf3!V'), chr(5568 - 5468) + chr(101) + chr(3970 - 3871) + chr(0b1101111) + chr(0b1011111 + 0o5) + chr(0b1100101))('\165' + chr(0b1110100) + chr(102) + chr(0b101101) + chr(56))), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2bS[\xf36V\xc0'), chr(0b1001000 + 0o34) + chr(9126 - 9025) + chr(1790 - 1691) + '\x6f' + '\x64' + chr(0b1100001 + 0o4))(chr(117) + chr(0b1110100) + chr(0b1100110) + chr(45) + chr(0b111000))), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2bSZ\xe6&^\xd5\xc4\xae'), '\x64' + '\x65' + '\143' + '\157' + chr(0b111110 + 0o46) + chr(8244 - 8143))('\x75' + '\x74' + chr(4443 - 4341) + chr(45) + '\070')))
if xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6|xK\xfa0Y\xdc\xc8\xabi\x96\x95\xc7\xdd'), chr(2222 - 2122) + chr(0b1010111 + 0o16) + '\x63' + '\x6f' + '\x64' + chr(0b1000000 + 0o45))(chr(0b10011 + 0o142) + chr(1361 - 1245) + chr(0b1100110) + '\055' + chr(0b100000 + 0o30))) == xafqLlk3kkUe(SXOLrMavuUCe(b'\xf1~'), chr(0b1100100) + chr(4417 - 4316) + chr(5900 - 5801) + '\x6f' + '\x64' + chr(101))(chr(117) + '\x74' + chr(1781 - 1679) + chr(468 - 423) + chr(56)):
return AA7HUoEwKt_Y(OeWW0F1dBPRQ, xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6|xK\xfa0Y\xdc\xc8\xabi\x9f\x95\xdd\xca'), '\144' + chr(0b10110 + 0o117) + chr(99) + chr(0b1011100 + 0o23) + '\144' + chr(101))(chr(0b1110101) + chr(116) + '\146' + chr(0b101101) + chr(0b111000))), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2bS]\xf3!V'), chr(0b100000 + 0o104) + '\145' + chr(0b1010010 + 0o21) + '\x6f' + chr(0b1011 + 0o131) + '\145')('\x75' + chr(10477 - 10361) + chr(0b1011100 + 0o12) + '\x2d' + chr(56))), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2bS[\xf36V\xc0'), chr(9073 - 8973) + '\145' + chr(8704 - 8605) + chr(111) + chr(100) + chr(0b1000111 + 0o36))('\x75' + chr(116) + '\146' + chr(0b11011 + 0o22) + '\070')), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2bSZ\xe6&^\xd5\xc4\xae'), '\144' + chr(101) + chr(99) + chr(644 - 533) + chr(0b1011101 + 0o7) + chr(101))('\165' + '\164' + chr(0b1010101 + 0o21) + '\x2d' + chr(0b110101 + 0o3))), soft_em=ehT0Px3KOsy9(chr(48) + chr(3311 - 3200) + chr(218 - 169), 0b1000), num_samples=xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2bSQ\xe38h\xca\xca\xadF\x91\x99\xda'), chr(0b101110 + 0o66) + chr(0b1100101) + '\x63' + chr(10121 - 10010) + chr(0b1100100) + '\x65')('\x75' + chr(121 - 5) + chr(2443 - 2341) + '\055' + chr(56))))
if xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6|xK\xfa0Y\xdc\xc8\xabi\x96\x95\xc7\xdd'), '\144' + chr(101) + '\x63' + '\x6f' + chr(2584 - 2484) + '\x65')(chr(0b1010101 + 0o40) + '\164' + chr(10129 - 10027) + '\x2d' + '\070')) == xafqLlk3kkUe(SXOLrMavuUCe(b'\xf3fa]\xf39h\xca\xc4\xa6B\x90\x9d\xd1'), chr(0b1010111 + 0o15) + chr(101) + chr(4823 - 4724) + chr(7631 - 7520) + chr(0b111000 + 0o54) + '\145')('\165' + chr(0b1110100) + chr(3792 - 3690) + chr(0b101101) + chr(0b1000 + 0o60)):
return m3kGAmNq1VlS(OeWW0F1dBPRQ, xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6|xK\xfa0Y\xdc\xc8\xabi\x9f\x95\xdd\xca'), chr(6824 - 6724) + chr(8627 - 8526) + chr(0b1100011) + chr(111) + chr(0b1100000 + 0o4) + chr(0b1100101))('\x75' + '\x74' + chr(0b1010010 + 0o24) + chr(1949 - 1904) + '\x38')), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2bS]\xf3!V'), chr(100) + '\x65' + chr(99) + chr(0b1101111) + chr(100) + chr(101))('\165' + '\x74' + '\x66' + chr(45) + chr(0b100111 + 0o21))), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2bS[\xf36V\xc0'), chr(100) + '\145' + chr(883 - 784) + chr(0b1101111) + '\144' + '\145')(chr(117) + '\x74' + chr(7278 - 7176) + chr(45) + '\070')), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2bSZ\xe6&^\xd5\xc4\xae'), chr(8327 - 8227) + chr(143 - 42) + '\143' + chr(0b1101001 + 0o6) + '\144' + chr(101))('\165' + chr(0b1110100) + chr(0b1100110) + chr(0b101101) + chr(0b1110 + 0o52))), xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b"\xe0vaO\xf3'V\xcd\xde\xb2S\xa2\x8b\xc8\xcb:z`\x7f\xe3\x82+\xd26"), chr(0b10000 + 0o124) + '\145' + '\x63' + '\157' + chr(0b10011 + 0o121) + '\x65')(chr(117) + chr(0b1110100) + '\146' + '\x2d' + '\070')), hard=ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110000), 49025 - 49017), summary=ehT0Px3KOsy9(chr(48) + chr(10318 - 10207) + chr(0b101110 + 0o3), 8))
raise q1QCh3W88sgk(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc1}\x7fJ\xe6%X\xcb\xdf\xa5R\xdd\x94\xd9\xd8%n}S\xbe\x94!\xd61\x05Y\xaf&\xd1\x85\x8eq\xf3iZ\x07{B'), '\144' + chr(0b1010100 + 0o21) + '\x63' + chr(0b110111 + 0o70) + '\x64' + chr(0b1100101))(chr(0b1110101) + '\x74' + '\146' + chr(0b10 + 0o53) + chr(56)) % xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6|xK\xfa0Y\xdc\xc8\xabi\x96\x95\xc7\xdd'), chr(0b101100 + 0o70) + chr(0b11 + 0o142) + chr(0b110011 + 0o60) + '\157' + '\x64' + chr(4515 - 4414))('\x75' + '\x74' + chr(102) + chr(0b101101) + chr(0b11110 + 0o32))))
|
tensorflow/tensor2tensor
|
tensor2tensor/layers/discretization.py
|
parametrized_unbottleneck
|
def parametrized_unbottleneck(x, hidden_size, hparams):
"""Meta-function calling all the above un-bottlenecks with hparams."""
if hparams.bottleneck_kind == "tanh_discrete":
return tanh_discrete_unbottleneck(x, hidden_size)
if hparams.bottleneck_kind == "isemhash":
return isemhash_unbottleneck(x, hidden_size,
hparams.isemhash_filter_size_multiplier)
if hparams.bottleneck_kind in ["vq", "em", "gumbel_softmax"]:
return vq_discrete_unbottleneck(x, hidden_size)
raise ValueError(
"Unsupported hparams.bottleneck_kind %s" % hparams.bottleneck_kind)
|
python
|
def parametrized_unbottleneck(x, hidden_size, hparams):
"""Meta-function calling all the above un-bottlenecks with hparams."""
if hparams.bottleneck_kind == "tanh_discrete":
return tanh_discrete_unbottleneck(x, hidden_size)
if hparams.bottleneck_kind == "isemhash":
return isemhash_unbottleneck(x, hidden_size,
hparams.isemhash_filter_size_multiplier)
if hparams.bottleneck_kind in ["vq", "em", "gumbel_softmax"]:
return vq_discrete_unbottleneck(x, hidden_size)
raise ValueError(
"Unsupported hparams.bottleneck_kind %s" % hparams.bottleneck_kind)
|
[
"def",
"parametrized_unbottleneck",
"(",
"x",
",",
"hidden_size",
",",
"hparams",
")",
":",
"if",
"hparams",
".",
"bottleneck_kind",
"==",
"\"tanh_discrete\"",
":",
"return",
"tanh_discrete_unbottleneck",
"(",
"x",
",",
"hidden_size",
")",
"if",
"hparams",
".",
"bottleneck_kind",
"==",
"\"isemhash\"",
":",
"return",
"isemhash_unbottleneck",
"(",
"x",
",",
"hidden_size",
",",
"hparams",
".",
"isemhash_filter_size_multiplier",
")",
"if",
"hparams",
".",
"bottleneck_kind",
"in",
"[",
"\"vq\"",
",",
"\"em\"",
",",
"\"gumbel_softmax\"",
"]",
":",
"return",
"vq_discrete_unbottleneck",
"(",
"x",
",",
"hidden_size",
")",
"raise",
"ValueError",
"(",
"\"Unsupported hparams.bottleneck_kind %s\"",
"%",
"hparams",
".",
"bottleneck_kind",
")"
] |
Meta-function calling all the above un-bottlenecks with hparams.
|
[
"Meta",
"-",
"function",
"calling",
"all",
"the",
"above",
"un",
"-",
"bottlenecks",
"with",
"hparams",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/layers/discretization.py#L1479-L1489
|
train
|
Meta - function calling all the above un - bottlenecks with hparams.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n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,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + chr(0b1011001 + 0o26) + chr(49) + chr(0b1001 + 0o55) + '\x37', ord("\x08")), ehT0Px3KOsy9('\060' + chr(4049 - 3938) + '\061' + chr(51) + chr(0b101000 + 0o11), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\061' + chr(0b110111) + chr(0b101101 + 0o11), 1893 - 1885), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110010) + chr(0b100111 + 0o13), ord("\x08")), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(9040 - 8929) + chr(0b110011) + chr(2228 - 2173) + chr(0b1110 + 0o44), 60165 - 60157), ehT0Px3KOsy9(chr(273 - 225) + chr(111) + chr(51) + chr(49) + chr(49), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(49) + chr(0b101100 + 0o12) + chr(48), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b10001 + 0o40) + '\x30' + '\x30', 0o10), ehT0Px3KOsy9(chr(0b1111 + 0o41) + chr(111) + chr(0b100001 + 0o21) + chr(0b11101 + 0o24) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(1593 - 1545) + chr(4869 - 4758) + chr(49) + chr(2112 - 2058) + chr(52), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(2155 - 2104) + chr(50) + chr(0b1000 + 0o53), 0b1000), ehT0Px3KOsy9(chr(2247 - 2199) + chr(0b101110 + 0o101) + chr(0b110001) + chr(53) + chr(2305 - 2255), 25459 - 25451), ehT0Px3KOsy9(chr(154 - 106) + chr(0b1101000 + 0o7) + '\063' + '\x35' + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(940 - 891) + chr(2763 - 2710), 10207 - 10199), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x31' + chr(0b11011 + 0o30) + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(961 - 913) + '\157' + chr(196 - 146) + '\x32' + '\063', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(2017 - 1968) + '\060' + chr(877 - 827), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(736 - 686) + chr(50) + '\066', 0o10), ehT0Px3KOsy9(chr(1761 - 1713) + '\x6f' + chr(1663 - 1612) + '\060' + chr(0b10010 + 0o36), 9065 - 9057), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\067' + '\061', ord("\x08")), ehT0Px3KOsy9(chr(528 - 480) + chr(5990 - 5879) + '\062' + chr(0b10011 + 0o37) + chr(0b110011), 8), ehT0Px3KOsy9(chr(0b10 + 0o56) + chr(0b1101111) + '\062' + '\x37' + '\064', 47153 - 47145), ehT0Px3KOsy9('\060' + chr(2368 - 2257) + chr(50) + '\x37' + '\x32', 18819 - 18811), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110000 + 0o2) + chr(336 - 288) + chr(0b10011 + 0o40), 0b1000), ehT0Px3KOsy9(chr(0b1010 + 0o46) + '\x6f' + chr(2064 - 2014) + chr(0b10100 + 0o37) + chr(0b110000), 19287 - 19279), ehT0Px3KOsy9(chr(0b1111 + 0o41) + '\x6f' + '\x31' + '\065' + chr(0b110001), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b101 + 0o54) + chr(53) + '\060', 0o10), ehT0Px3KOsy9(chr(2029 - 1981) + chr(0b1101111) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1000110 + 0o51) + chr(49) + chr(2363 - 2310) + chr(1850 - 1795), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + '\061' + chr(0b110100) + chr(0b10011 + 0o35), 23505 - 23497), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b101 + 0o55) + chr(0b10101 + 0o41) + chr(0b101100 + 0o4), 16923 - 16915), ehT0Px3KOsy9(chr(48) + '\157' + '\061' + chr(0b110110) + chr(134 - 85), 58713 - 58705), ehT0Px3KOsy9(chr(0b101110 + 0o2) + chr(0b10000 + 0o137) + chr(0b110011) + chr(0b101010 + 0o15) + '\065', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(5006 - 4895) + '\x31' + '\x35', 8), ehT0Px3KOsy9(chr(1724 - 1676) + '\x6f' + chr(0b10101 + 0o35) + '\062' + chr(0b11010 + 0o34), 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110011) + '\x37' + chr(0b101001 + 0o14), 8), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110001) + '\x32' + '\060', 0o10), ehT0Px3KOsy9('\060' + chr(111) + '\x32' + chr(0b110111) + chr(49), 0b1000), ehT0Px3KOsy9(chr(0b101001 + 0o7) + '\x6f' + '\x32' + chr(1980 - 1931) + '\x33', ord("\x08")), ehT0Px3KOsy9(chr(0b1111 + 0o41) + chr(0b1101111) + '\061' + chr(0b110000) + chr(0b110001 + 0o0), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + chr(111) + chr(53) + chr(48), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'Y'), '\x64' + '\x65' + chr(591 - 492) + '\157' + chr(7163 - 7063) + '\x65')(chr(0b111111 + 0o66) + chr(7926 - 7810) + chr(0b1100110) + chr(45) + chr(2575 - 2519)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def Bfp9ceFOST_t(OeWW0F1dBPRQ, qzoyXN3kdhDL, n4ljua2gi1Pr):
if xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x156\nf\x96\xac\x1e%\xeb\x1f\x8c\x01\x83c:'), chr(0b1000000 + 0o44) + '\x65' + chr(0b1100011) + chr(111) + chr(4623 - 4523) + chr(2187 - 2086))(chr(0b110010 + 0o103) + '\x74' + '\x66' + '\055' + chr(0b111000))) == xafqLlk3kkUe(SXOLrMavuUCe(b'\x038\x10z\xa5\xad\x193\xeb\x06\xb6\x1e\x8f'), '\x64' + chr(0b1100101) + chr(0b1100011) + chr(0b101101 + 0o102) + chr(6684 - 6584) + chr(0b111100 + 0o51))(chr(0b101000 + 0o115) + chr(0b110000 + 0o104) + chr(0b100110 + 0o100) + chr(0b101101) + '\x38'):
return qd2Z4ommZOet(OeWW0F1dBPRQ, qzoyXN3kdhDL)
if xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x156\nf\x96\xac\x1e%\xeb\x1f\x8c\x01\x83c:'), '\144' + chr(101) + chr(3670 - 3571) + chr(0b1010 + 0o145) + chr(535 - 435) + chr(0b1001101 + 0o30))(chr(0b1110101) + '\164' + chr(0b1100110) + '\x2d' + chr(2985 - 2929))) == xafqLlk3kkUe(SXOLrMavuUCe(b'\x1e*\x1b\x7f\x92\xa8\x03('), chr(4974 - 4874) + '\x65' + '\143' + chr(111) + chr(0b1100100) + chr(1257 - 1156))('\165' + chr(12126 - 12010) + '\x66' + '\055' + chr(0b100011 + 0o25)):
return jP6ca4Ax9SoV(OeWW0F1dBPRQ, qzoyXN3kdhDL, xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1e*\x1b\x7f\x92\xa8\x03(\xd7\x12\xba\x06\x9eh,\xcc1\xff\xba\\\xcc\xd1\xcf\xef\xec\x00\x18o\x06\x05\xc2'), chr(0b1100100) + '\x65' + '\143' + chr(0b101111 + 0o100) + '\x64' + chr(6221 - 6120))(chr(0b1101101 + 0o10) + chr(0b1000001 + 0o63) + '\146' + chr(0b101101) + '\070')))
if xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x156\nf\x96\xac\x1e%\xeb\x1f\x8c\x01\x83c:'), chr(3128 - 3028) + '\145' + chr(0b1011010 + 0o11) + '\x6f' + chr(100) + '\x65')(chr(117) + chr(0b1110100) + chr(5797 - 5695) + chr(0b101101) + chr(0b11100 + 0o34))) in [xafqLlk3kkUe(SXOLrMavuUCe(b'\x01('), '\144' + chr(101) + chr(0b1100011) + chr(111) + chr(0b1010001 + 0o23) + '\x65')(chr(9080 - 8963) + chr(0b110101 + 0o77) + '\x66' + '\055' + '\x38'), xafqLlk3kkUe(SXOLrMavuUCe(b'\x124'), chr(0b1000010 + 0o42) + chr(101) + chr(9081 - 8982) + chr(0b1001010 + 0o45) + chr(9336 - 9236) + '\x65')('\165' + chr(8130 - 8014) + chr(0b1001111 + 0o27) + '\x2d' + '\x38'), xafqLlk3kkUe(SXOLrMavuUCe(b'\x10,\x13p\x9f\xa5/3\xe7\x12\xa7\x07\x8bu'), chr(0b1011111 + 0o5) + chr(0b1100101) + chr(0b100001 + 0o102) + chr(0b1101111) + chr(9577 - 9477) + chr(101))('\x75' + chr(6253 - 6137) + chr(0b1100110) + chr(45) + '\070')]:
return ix49FQPz8XkJ(OeWW0F1dBPRQ, qzoyXN3kdhDL)
raise q1QCh3W88sgk(xafqLlk3kkUe(SXOLrMavuUCe(b'"7\rg\x8a\xb9\x1f2\xfc\x11\xb7J\x82}?\xe1#\xfb\xb3\x17\xf1\xd3\xce\xf7\xf4\x0c\x06f\x0c\x0b\xef\x1a\x94c\xf2\xddu\xca'), chr(0b0 + 0o144) + '\x65' + chr(99) + chr(0b1101111) + '\144' + chr(0b110101 + 0o60))(chr(0b1000010 + 0o63) + '\x74' + chr(9300 - 9198) + chr(45) + chr(0b111000)) % xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x156\nf\x96\xac\x1e%\xeb\x1f\x8c\x01\x83c:'), chr(1931 - 1831) + chr(101) + '\x63' + '\157' + chr(0b100101 + 0o77) + chr(7914 - 7813))('\165' + chr(0b1110100) + chr(1445 - 1343) + chr(0b101101) + chr(0b100111 + 0o21))))
|
tensorflow/tensor2tensor
|
tensor2tensor/layers/discretization.py
|
iaf_hparams
|
def iaf_hparams(hidden_size=512, filter_size=4096):
"""Create hyperpameters for inverse autoregressive flows.
Args:
hidden_size: Width of attention layers and neural network output layer.
filter_size: Hidden layer width for neural network.
Returns:
hparams: Hyperpameters with basic presets for inverse autoregressive flows.
"""
hparams = common_hparams.basic_params1()
# Attention hyperparameters.
hparams.hidden_size = hidden_size
hparams.add_hparam("attention_key_channels", None)
hparams.add_hparam("attention_value_channels", None)
hparams.add_hparam("num_heads", 4)
hparams.add_hparam("attention_dropout", 0.1)
hparams.add_hparam("shared_rel", False)
hparams.add_hparam("block_width", 1)
hparams.add_hparam("block_length", 1)
hparams.add_hparam("q_filter_width", 1)
hparams.add_hparam("kv_filter_width", 1)
# Preprocessing and postprocesing hyperparameters.
hparams.layer_preprocess_sequence = "n"
hparams.layer_prepostprocess_dropout = 0.1
hparams.norm_type = "layer"
hparams.norm_epsilon = 1e-06
hparams.layer_prepostprocess_dropout_broadcast_dims = ""
hparams.layer_postprocess_sequence = "da"
# Feedforward neural network hyperparameters.
hparams.add_hparam("filter_size", filter_size)
hparams.add_hparam("ffn_layer", "conv_hidden_relu")
hparams.add_hparam("relu_dropout", 0.1)
return hparams
|
python
|
def iaf_hparams(hidden_size=512, filter_size=4096):
"""Create hyperpameters for inverse autoregressive flows.
Args:
hidden_size: Width of attention layers and neural network output layer.
filter_size: Hidden layer width for neural network.
Returns:
hparams: Hyperpameters with basic presets for inverse autoregressive flows.
"""
hparams = common_hparams.basic_params1()
# Attention hyperparameters.
hparams.hidden_size = hidden_size
hparams.add_hparam("attention_key_channels", None)
hparams.add_hparam("attention_value_channels", None)
hparams.add_hparam("num_heads", 4)
hparams.add_hparam("attention_dropout", 0.1)
hparams.add_hparam("shared_rel", False)
hparams.add_hparam("block_width", 1)
hparams.add_hparam("block_length", 1)
hparams.add_hparam("q_filter_width", 1)
hparams.add_hparam("kv_filter_width", 1)
# Preprocessing and postprocesing hyperparameters.
hparams.layer_preprocess_sequence = "n"
hparams.layer_prepostprocess_dropout = 0.1
hparams.norm_type = "layer"
hparams.norm_epsilon = 1e-06
hparams.layer_prepostprocess_dropout_broadcast_dims = ""
hparams.layer_postprocess_sequence = "da"
# Feedforward neural network hyperparameters.
hparams.add_hparam("filter_size", filter_size)
hparams.add_hparam("ffn_layer", "conv_hidden_relu")
hparams.add_hparam("relu_dropout", 0.1)
return hparams
|
[
"def",
"iaf_hparams",
"(",
"hidden_size",
"=",
"512",
",",
"filter_size",
"=",
"4096",
")",
":",
"hparams",
"=",
"common_hparams",
".",
"basic_params1",
"(",
")",
"# Attention hyperparameters.",
"hparams",
".",
"hidden_size",
"=",
"hidden_size",
"hparams",
".",
"add_hparam",
"(",
"\"attention_key_channels\"",
",",
"None",
")",
"hparams",
".",
"add_hparam",
"(",
"\"attention_value_channels\"",
",",
"None",
")",
"hparams",
".",
"add_hparam",
"(",
"\"num_heads\"",
",",
"4",
")",
"hparams",
".",
"add_hparam",
"(",
"\"attention_dropout\"",
",",
"0.1",
")",
"hparams",
".",
"add_hparam",
"(",
"\"shared_rel\"",
",",
"False",
")",
"hparams",
".",
"add_hparam",
"(",
"\"block_width\"",
",",
"1",
")",
"hparams",
".",
"add_hparam",
"(",
"\"block_length\"",
",",
"1",
")",
"hparams",
".",
"add_hparam",
"(",
"\"q_filter_width\"",
",",
"1",
")",
"hparams",
".",
"add_hparam",
"(",
"\"kv_filter_width\"",
",",
"1",
")",
"# Preprocessing and postprocesing hyperparameters.",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"n\"",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.1",
"hparams",
".",
"norm_type",
"=",
"\"layer\"",
"hparams",
".",
"norm_epsilon",
"=",
"1e-06",
"hparams",
".",
"layer_prepostprocess_dropout_broadcast_dims",
"=",
"\"\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"da\"",
"# Feedforward neural network hyperparameters.",
"hparams",
".",
"add_hparam",
"(",
"\"filter_size\"",
",",
"filter_size",
")",
"hparams",
".",
"add_hparam",
"(",
"\"ffn_layer\"",
",",
"\"conv_hidden_relu\"",
")",
"hparams",
".",
"add_hparam",
"(",
"\"relu_dropout\"",
",",
"0.1",
")",
"return",
"hparams"
] |
Create hyperpameters for inverse autoregressive flows.
Args:
hidden_size: Width of attention layers and neural network output layer.
filter_size: Hidden layer width for neural network.
Returns:
hparams: Hyperpameters with basic presets for inverse autoregressive flows.
|
[
"Create",
"hyperpameters",
"for",
"inverse",
"autoregressive",
"flows",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/layers/discretization.py#L1492-L1528
|
train
|
Hparams for IAF.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAf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_gSK8V7h0,Rurm1zTRfSmY,reqGiMiVQ77y,bsS9P6_LpdIe,sbGAZlkZOtyh,Cf_Qef15s3_F,eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(332 - 284) + chr(0b1101111) + chr(0b11110 + 0o24) + chr(0b101110 + 0o6) + chr(1459 - 1407), 0o10), ehT0Px3KOsy9(chr(48) + chr(4516 - 4405) + '\x33' + chr(0b1011 + 0o52), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x31' + chr(2121 - 2066) + chr(0b110000 + 0o5), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(346 - 295) + chr(0b11111 + 0o27) + chr(0b101 + 0o61), ord("\x08")), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(11425 - 11314) + chr(49) + '\067' + '\062', 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(0b10 + 0o60) + '\x31' + '\067', 31570 - 31562), ehT0Px3KOsy9(chr(48) + chr(952 - 841) + '\x33' + '\x30' + chr(0b1001 + 0o54), 62766 - 62758), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(50) + chr(0b10000 + 0o40) + '\064', 0o10), ehT0Px3KOsy9(chr(48) + chr(5840 - 5729) + chr(0b110011) + chr(0b110010) + '\067', 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b10000 + 0o41) + '\064' + chr(1347 - 1293), 44061 - 44053), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x31' + chr(0b110011) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + '\061' + chr(0b101001 + 0o14) + '\067', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + '\x33' + '\060' + chr(2015 - 1965), 29131 - 29123), ehT0Px3KOsy9(chr(48) + '\x6f' + '\x36' + chr(1561 - 1513), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b110010 + 0o75) + chr(0b110001) + chr(0b1000 + 0o56) + '\061', 18690 - 18682), ehT0Px3KOsy9(chr(1711 - 1663) + chr(0b1101111) + '\x36' + '\x33', 0b1000), ehT0Px3KOsy9(chr(1705 - 1657) + chr(11382 - 11271) + '\062' + chr(50), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1100101 + 0o12) + '\063' + chr(50) + '\063', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(53) + chr(569 - 520), 35105 - 35097), ehT0Px3KOsy9('\x30' + chr(10815 - 10704) + chr(0b100000 + 0o22) + chr(49) + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(0b11011 + 0o25) + chr(0b1101111) + chr(50) + chr(0b101100 + 0o10) + chr(51), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + '\061' + chr(0b101111 + 0o10) + chr(54), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(5163 - 5052) + chr(1086 - 1035) + '\067' + chr(2261 - 2210), 0b1000), ehT0Px3KOsy9(chr(0b101011 + 0o5) + chr(0b1111 + 0o140) + '\x33' + chr(50) + chr(261 - 213), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(0b101 + 0o55) + chr(55) + chr(1528 - 1474), 58672 - 58664), ehT0Px3KOsy9('\060' + '\157' + chr(50) + chr(0b110111) + '\060', 0o10), ehT0Px3KOsy9(chr(509 - 461) + chr(5320 - 5209) + '\062' + chr(0b111 + 0o55) + '\063', 8), ehT0Px3KOsy9('\x30' + chr(7161 - 7050) + '\x32' + chr(0b110110) + chr(1111 - 1062), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(7958 - 7847) + chr(0b10100 + 0o35) + chr(0b110100) + chr(1653 - 1602), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + '\x33' + chr(0b110110) + '\x35', 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110001) + '\061' + chr(0b11111 + 0o22), 22240 - 22232), ehT0Px3KOsy9(chr(2141 - 2093) + chr(8537 - 8426) + chr(51) + chr(972 - 920) + chr(0b101011 + 0o6), 0o10), ehT0Px3KOsy9('\060' + chr(111) + '\062', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(104 - 55) + '\064' + chr(2000 - 1946), 8), ehT0Px3KOsy9(chr(0b100100 + 0o14) + chr(1503 - 1392) + '\x33' + chr(0b110011 + 0o0) + '\062', 65280 - 65272), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(50) + chr(51) + chr(1884 - 1829), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x31' + chr(2224 - 2171) + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(0b0 + 0o60) + chr(0b1101111) + '\063' + chr(492 - 444) + chr(0b110000), 18283 - 18275), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(49) + '\x34' + chr(2695 - 2642), 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(368 - 317) + chr(2033 - 1983) + chr(2216 - 2161), 8)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(542 - 489) + chr(1514 - 1466), 23647 - 23639)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x8a'), '\144' + chr(101) + '\x63' + '\x6f' + chr(4689 - 4589) + chr(0b1100101))(chr(7870 - 7753) + chr(0b1110100) + '\x66' + chr(824 - 779) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def _nWFGJrjIGqg(qzoyXN3kdhDL=ehT0Px3KOsy9(chr(0b101010 + 0o6) + chr(111) + chr(49) + chr(0b110000) + chr(48) + chr(1358 - 1310), 16534 - 16526), deybX8NJ0oEI=ehT0Px3KOsy9('\060' + chr(8751 - 8640) + chr(49) + '\x30' + chr(1227 - 1179) + chr(0b100 + 0o54) + chr(0b110000), 0o10)):
n4ljua2gi1Pr = vLnG3ZpOXWXZ.basic_params1()
n4ljua2gi1Pr.qzoyXN3kdhDL = qzoyXN3kdhDL
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), '\144' + '\145' + chr(8676 - 8577) + chr(0b1101111) + chr(0b10101 + 0o117) + chr(0b1100101))(chr(7757 - 7640) + '\164' + '\146' + '\055' + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5i\t\x93\x14\xfb\xac\xeb\xb993\n\xbbo\x12[s\xbdG\xeb\xcf\r'), '\144' + chr(0b1100101) + chr(0b1100011) + chr(111) + chr(100) + '\145')(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + chr(279 - 234) + chr(0b111000)), None)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), '\144' + '\145' + chr(154 - 55) + '\x6f' + chr(0b1100100) + chr(0b1100101))(chr(117) + '\x74' + '\x66' + chr(660 - 615) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5i\t\x93\x14\xfb\xac\xeb\xb99.\x0e\xaeE\x14lq\xbbH\xe0\xcd\x1b\x97\xa3'), '\x64' + chr(0b1100101) + chr(0b1100011) + chr(111) + '\144' + '\x65')('\165' + chr(6455 - 6339) + chr(9936 - 9834) + '\055' + chr(0b111000)), None)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), chr(3989 - 3889) + chr(0b1010100 + 0o21) + chr(0b1100011) + chr(111) + chr(3429 - 3329) + chr(101))(chr(117) + '\164' + '\x66' + chr(45) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xcah\x10\xa9\x12\xea\xa4\xe0\xa4'), chr(100) + chr(0b1100101) + chr(0b11101 + 0o106) + '\157' + chr(1639 - 1539) + '\x65')(chr(12511 - 12394) + '\x74' + chr(0b1100110) + chr(0b101101) + chr(0b111000)), ehT0Px3KOsy9('\x30' + chr(0b1101000 + 0o7) + '\x34', 0b1000))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), chr(0b1100100) + chr(0b1010101 + 0o20) + chr(99) + chr(0b1101111) + chr(0b1010 + 0o132) + chr(3143 - 3042))(chr(0b100100 + 0o121) + '\x74' + chr(0b1000011 + 0o43) + chr(0b101010 + 0o3) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5i\t\x93\x14\xfb\xac\xeb\xb99<\x1d\xad@\x1eFf'), chr(0b1100001 + 0o3) + chr(0b1000101 + 0o40) + '\143' + chr(8246 - 8135) + chr(0b101000 + 0o74) + chr(0b1100101))(chr(0b101100 + 0o111) + '\x74' + chr(0b1001011 + 0o33) + chr(45) + chr(1574 - 1518)), 0.1)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), chr(0b1110 + 0o126) + chr(5102 - 5001) + chr(5183 - 5084) + '\x6f' + chr(0b1011101 + 0o7) + chr(101))(chr(0b1110101) + chr(0b1001001 + 0o53) + '\x66' + chr(0b10011 + 0o32) + chr(61 - 5)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xd7u\x1c\x84\x1f\xeb\x9a\xf6\xb2\n'), chr(0b1011100 + 0o10) + chr(8203 - 8102) + '\143' + chr(111) + chr(100) + '\x65')(chr(9647 - 9530) + chr(0b1110001 + 0o3) + chr(0b10011 + 0o123) + chr(0b1010 + 0o43) + chr(2025 - 1969)), ehT0Px3KOsy9(chr(1088 - 1040) + '\157' + chr(48), 0o10))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), chr(100) + chr(0b1100101) + '\143' + chr(0b1101111) + chr(100) + '\145')(chr(0b10101 + 0o140) + chr(9691 - 9575) + '\146' + chr(0b101101) + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc6q\x12\x95\x11\xd0\xb2\xed\xb3\x120'), chr(0b111000 + 0o54) + '\x65' + '\x63' + chr(0b1101111) + '\144' + chr(0b111 + 0o136))(chr(6998 - 6881) + chr(116) + chr(0b1100110) + chr(45) + '\x38'), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110001), 0b1000))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), chr(0b1001101 + 0o27) + '\x65' + chr(99) + '\x6f' + '\x64' + chr(7516 - 7415))(chr(0b1110101) + chr(0b110101 + 0o77) + chr(102) + chr(45) + chr(442 - 386)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc6q\x12\x95\x11\xd0\xa9\xe1\xb9\x01,\x07'), '\144' + chr(0b101101 + 0o70) + chr(3355 - 3256) + chr(111) + chr(100) + chr(0b110001 + 0o64))(chr(0b1011110 + 0o27) + chr(0b1110100) + '\146' + '\055' + '\x38'), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(0b10010 + 0o135) + chr(49), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), chr(0b1000010 + 0o42) + '\x65' + chr(0b101100 + 0o67) + chr(3948 - 3837) + '\x64' + chr(7422 - 7321))(chr(0b1000011 + 0o62) + chr(116) + chr(0b11011 + 0o113) + chr(0b101101) + chr(209 - 153)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xd5B\x1b\x9f\x16\xfb\xa0\xf6\x88\x111\x0b\xb6X'), chr(0b1000011 + 0o41) + chr(0b1000010 + 0o43) + chr(0b111110 + 0o45) + chr(0b100100 + 0o113) + chr(2399 - 2299) + '\145')(chr(0b1110101) + '\x74' + chr(9161 - 9059) + '\055' + chr(0b111000)), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110001), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), chr(0b100000 + 0o104) + '\x65' + chr(99) + chr(0b1101111) + chr(100) + '\x65')(chr(117) + chr(116) + '\146' + '\055' + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xcfk"\x90\x13\xe3\xb1\xe1\xa59/\x06\xa6D\x19'), chr(0b1000 + 0o134) + chr(101) + '\143' + '\x6f' + chr(0b101001 + 0o73) + chr(3877 - 3776))(chr(0b1110101) + '\164' + chr(5772 - 5670) + '\x2d' + '\070'), ehT0Px3KOsy9('\x30' + chr(1997 - 1886) + chr(1891 - 1842), 8))
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'\xca'), chr(100) + chr(101) + chr(0b1100011) + chr(111) + chr(100) + chr(101))(chr(0b10110 + 0o137) + '\164' + chr(9359 - 9257) + chr(0b10011 + 0o32) + '\x38')
n4ljua2gi1Pr.RW_xSzp18UeS = 0.1
n4ljua2gi1Pr.LE5Fu6Tcl7nw = xafqLlk3kkUe(SXOLrMavuUCe(b'\xc8|\x04\x93\x08'), chr(2731 - 2631) + chr(106 - 5) + '\143' + chr(0b1101111) + chr(5526 - 5426) + '\145')(chr(0b100100 + 0o121) + chr(10891 - 10775) + chr(0b1100110) + chr(534 - 489) + chr(56))
n4ljua2gi1Pr.u3Rs21Gpzn3w = 1e-06
n4ljua2gi1Pr.An2Jt26Rv5CT = xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(100) + '\145' + chr(99) + chr(3046 - 2935) + chr(0b101111 + 0o65) + '\145')(chr(0b1000101 + 0o60) + chr(116) + '\x66' + chr(157 - 112) + '\070')
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'\xc0|'), chr(4069 - 3969) + chr(0b1010100 + 0o21) + chr(1498 - 1399) + chr(0b1101111) + chr(0b1100100) + chr(0b101011 + 0o72))(chr(0b1110101) + chr(116) + chr(102) + chr(0b101101) + chr(56))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), '\x64' + chr(0b110 + 0o137) + chr(0b1100011) + chr(0b100010 + 0o115) + '\x64' + chr(101))(chr(646 - 529) + chr(116) + chr(0b1100110) + chr(0b101101) + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc2t\x11\x82\x1f\xfd\x9a\xf7\xbe\x1c='), '\x64' + chr(101) + '\143' + chr(0b101111 + 0o100) + chr(0b1100100) + '\x65')(chr(3558 - 3441) + chr(116) + chr(2765 - 2663) + chr(45) + chr(658 - 602)), deybX8NJ0oEI)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), chr(0b1100100) + '\145' + '\x63' + '\x6f' + '\144' + chr(101))(chr(0b1110101) + chr(116) + '\146' + chr(0b101101) + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc2{\x13\xa9\x16\xee\xbc\xe1\xa5'), '\x64' + '\x65' + chr(9183 - 9084) + chr(930 - 819) + chr(2513 - 2413) + chr(101))('\165' + chr(0b1110100) + chr(0b1100110) + chr(45) + '\070'), xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7r\x13\x80%\xe7\xac\xe0\xb3\x0360\xb0U\x1dF'), chr(0b111 + 0o135) + chr(785 - 684) + chr(0b1100011) + chr(5233 - 5122) + chr(0b1100100) + '\145')(chr(4416 - 4299) + chr(0b1110100) + chr(0b1100110) + '\x2d' + chr(56)))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc5y\x19\xa9\x12\xff\xa4\xf6\xb6\x0b'), chr(0b1011111 + 0o5) + '\x65' + chr(99) + chr(9315 - 9204) + chr(2045 - 1945) + chr(0b111100 + 0o51))(chr(117) + '\164' + '\x66' + chr(0b1000 + 0o45) + chr(906 - 850)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xd6x\x11\x83%\xeb\xb7\xeb\xa7\t-\x1b'), '\144' + chr(0b1100101) + '\x63' + '\x6f' + chr(0b111100 + 0o50) + chr(101))('\x75' + chr(0b100101 + 0o117) + '\146' + '\055' + '\070'), 0.1)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/lm1b.py
|
_original_vocab
|
def _original_vocab(tmp_dir):
"""Returns a set containing the original vocabulary.
This is important for comparing with published results.
Args:
tmp_dir: directory containing dataset.
Returns:
a set of strings
"""
vocab_url = ("http://download.tensorflow.org/models/LM_LSTM_CNN/"
"vocab-2016-09-10.txt")
vocab_filename = os.path.basename(vocab_url + ".en")
vocab_filepath = os.path.join(tmp_dir, vocab_filename)
if not os.path.exists(vocab_filepath):
generator_utils.maybe_download(tmp_dir, vocab_filename, vocab_url)
return set([
text_encoder.native_to_unicode(l.strip())
for l in tf.gfile.Open(vocab_filepath)
])
|
python
|
def _original_vocab(tmp_dir):
"""Returns a set containing the original vocabulary.
This is important for comparing with published results.
Args:
tmp_dir: directory containing dataset.
Returns:
a set of strings
"""
vocab_url = ("http://download.tensorflow.org/models/LM_LSTM_CNN/"
"vocab-2016-09-10.txt")
vocab_filename = os.path.basename(vocab_url + ".en")
vocab_filepath = os.path.join(tmp_dir, vocab_filename)
if not os.path.exists(vocab_filepath):
generator_utils.maybe_download(tmp_dir, vocab_filename, vocab_url)
return set([
text_encoder.native_to_unicode(l.strip())
for l in tf.gfile.Open(vocab_filepath)
])
|
[
"def",
"_original_vocab",
"(",
"tmp_dir",
")",
":",
"vocab_url",
"=",
"(",
"\"http://download.tensorflow.org/models/LM_LSTM_CNN/\"",
"\"vocab-2016-09-10.txt\"",
")",
"vocab_filename",
"=",
"os",
".",
"path",
".",
"basename",
"(",
"vocab_url",
"+",
"\".en\"",
")",
"vocab_filepath",
"=",
"os",
".",
"path",
".",
"join",
"(",
"tmp_dir",
",",
"vocab_filename",
")",
"if",
"not",
"os",
".",
"path",
".",
"exists",
"(",
"vocab_filepath",
")",
":",
"generator_utils",
".",
"maybe_download",
"(",
"tmp_dir",
",",
"vocab_filename",
",",
"vocab_url",
")",
"return",
"set",
"(",
"[",
"text_encoder",
".",
"native_to_unicode",
"(",
"l",
".",
"strip",
"(",
")",
")",
"for",
"l",
"in",
"tf",
".",
"gfile",
".",
"Open",
"(",
"vocab_filepath",
")",
"]",
")"
] |
Returns a set containing the original vocabulary.
This is important for comparing with published results.
Args:
tmp_dir: directory containing dataset.
Returns:
a set of strings
|
[
"Returns",
"a",
"set",
"containing",
"the",
"original",
"vocabulary",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/lm1b.py#L35-L55
|
train
|
Returns a set containing the original vocabulary.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2Q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MOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + chr(0b10011 + 0o134) + chr(0b10100 + 0o36) + chr(1388 - 1336) + '\061', 62631 - 62623), ehT0Px3KOsy9(chr(0b110000) + chr(0b11001 + 0o126) + '\x32' + chr(51) + chr(0b11001 + 0o31), 6056 - 6048), ehT0Px3KOsy9(chr(48) + chr(111) + '\x33' + chr(0b110001) + chr(53), 0b1000), ehT0Px3KOsy9(chr(929 - 881) + chr(0b1101111) + chr(1245 - 1196) + chr(1105 - 1056) + '\064', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110001) + chr(2311 - 2258), 0b1000), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(111) + '\x32' + chr(1888 - 1835) + chr(54), 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110100) + chr(0b110010), 0o10), ehT0Px3KOsy9(chr(314 - 266) + '\x6f' + '\062' + chr(0b101001 + 0o16) + '\x36', 2251 - 2243), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\063' + chr(0b100100 + 0o15) + chr(2448 - 2397), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110010) + chr(53) + chr(0b110101), 14422 - 14414), ehT0Px3KOsy9('\x30' + chr(0b1000011 + 0o54) + '\x32' + chr(0b101010 + 0o15) + chr(1067 - 1015), 0b1000), ehT0Px3KOsy9(chr(0b11010 + 0o26) + chr(111) + '\x34' + chr(0b110000), 43209 - 43201), ehT0Px3KOsy9(chr(0b110000) + chr(11697 - 11586) + chr(0b11010 + 0o30) + '\x35' + '\x32', 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + '\062' + '\x35' + chr(54), 8), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b1101110 + 0o1) + '\063' + '\x35' + '\x37', 3455 - 3447), ehT0Px3KOsy9(chr(0b110000) + chr(0b1000100 + 0o53) + chr(0b110001) + chr(172 - 120) + chr(0b10101 + 0o33), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b11100 + 0o25) + chr(0b11000 + 0o31) + chr(0b10111 + 0o34), 51849 - 51841), ehT0Px3KOsy9(chr(0b110000) + chr(4284 - 4173) + '\061' + chr(50) + chr(702 - 652), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + '\x31' + chr(50) + chr(1828 - 1775), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b10111 + 0o34) + '\063', 17418 - 17410), ehT0Px3KOsy9(chr(0b111 + 0o51) + chr(0b1101111) + chr(0b11000 + 0o32) + chr(0b110110) + chr(55), 10910 - 10902), ehT0Px3KOsy9(chr(0b110000) + chr(0b1100111 + 0o10) + chr(2817 - 2763), 0o10), ehT0Px3KOsy9(chr(0b10101 + 0o33) + chr(0b1101111) + '\062' + '\x36' + chr(0b110111), 8), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110000 + 0o2) + chr(50) + chr(0b100001 + 0o21), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x36' + chr(55), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110001) + chr(0b110000) + chr(1923 - 1869), ord("\x08")), ehT0Px3KOsy9(chr(419 - 371) + chr(111) + chr(0b110011) + chr(0b110110 + 0o1) + '\x31', 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110011) + chr(0b110110) + chr(0b110 + 0o53), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b101010 + 0o105) + '\062' + chr(49) + chr(857 - 802), 0b1000), ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(0b10110 + 0o131) + chr(55) + '\062', ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + '\063' + '\x33', 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(328 - 277) + chr(0b10111 + 0o40), 38394 - 38386), ehT0Px3KOsy9('\060' + chr(111) + chr(0b1101 + 0o46) + '\x36' + '\064', ord("\x08")), ehT0Px3KOsy9(chr(2238 - 2190) + chr(0b1000000 + 0o57) + chr(0b10011 + 0o37) + chr(0b110110) + '\063', 0b1000), ehT0Px3KOsy9(chr(0b110 + 0o52) + '\157' + chr(0b10011 + 0o44) + '\061', 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b1010 + 0o54) + '\066', 0o10), ehT0Px3KOsy9(chr(1289 - 1241) + '\157' + chr(1007 - 958) + chr(52) + chr(51), 24134 - 24126), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110001) + chr(0b110010) + chr(0b110010), 8), ehT0Px3KOsy9(chr(48) + chr(111) + '\x33' + chr(0b110100) + chr(48), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\062' + chr(1876 - 1821) + chr(2450 - 2397), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(0b1100 + 0o143) + chr(53) + chr(48), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x8f'), chr(0b1100100) + '\x65' + '\x63' + '\157' + chr(0b1100100) + '\145')('\x75' + chr(116) + chr(5547 - 5445) + chr(45) + chr(1162 - 1106)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def UVr5LKayTEIb(JsZ36NJUqtml):
hhhiqGbYo54s = xafqLlk3kkUe(SXOLrMavuUCe(b'\xc9\xee\xb9<7\x81\r\xda\xa4\xda\xd2L\xc5\xcf\x8bN?7;h\xd8t\xd1\xfeX1\xd7\x9e\xfd]4r\x9b\xd7\\Z\x10}\xac\xf0\xfe\xd6\x9e\x18@\xf1a\xf0\x85\x82\xcaO\xc9\xcf\x8dMybd-\x9a6\x8e\xbf\x06v\xd7\x85\xf7N'), '\x64' + chr(0b101 + 0o140) + '\x63' + chr(8522 - 8411) + chr(0b1100011 + 0o1) + '\x65')(chr(0b11 + 0o162) + '\164' + chr(102) + chr(0b100111 + 0o6) + chr(0b10110 + 0o42))
EwmY7ynOlhiF = oqhJDdMJfuwx.path.basename(hhhiqGbYo54s + xafqLlk3kkUe(SXOLrMavuUCe(b'\x8f\xff\xa3'), '\144' + chr(8989 - 8888) + chr(99) + chr(0b1001000 + 0o47) + '\144' + '\x65')(chr(0b1110101) + chr(0b1110100) + chr(102) + '\x2d' + chr(0b111000)))
fZzpj6eSosQ9 = oqhJDdMJfuwx.path.join(JsZ36NJUqtml, EwmY7ynOlhiF)
if not xafqLlk3kkUe(oqhJDdMJfuwx.path, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc4\xe2\xa4?y\xdd'), chr(6041 - 5941) + chr(9205 - 9104) + chr(0b1100011) + '\157' + chr(2907 - 2807) + chr(3823 - 3722))(chr(0b1110101) + chr(0b1110100) + chr(462 - 360) + chr(730 - 685) + chr(0b11110 + 0o32)))(fZzpj6eSosQ9):
xafqLlk3kkUe(g1Z_RG9zP4cD, xafqLlk3kkUe(SXOLrMavuUCe(b'\xcc\xfb\xb4.h\xf1F\xd1\xbc\xc3\xd0O\xcb\xca'), chr(100) + chr(0b1100101) + '\x63' + '\157' + chr(8264 - 8164) + chr(0b111 + 0o136))(chr(0b10 + 0o163) + chr(4814 - 4698) + chr(0b1100110) + chr(167 - 122) + '\070'))(JsZ36NJUqtml, EwmY7ynOlhiF, hhhiqGbYo54s)
return MVEN8G6CxlvR([xafqLlk3kkUe(nCRDzZ_Is9fz, xafqLlk3kkUe(SXOLrMavuUCe(b'\xcf\xfb\xb9%{\xcb}\xca\xa4\xf2\xc9N\xc3\xcd\x80\x04.'), '\144' + chr(0b1100101) + chr(0b101010 + 0o71) + chr(0b1101111) + chr(100) + chr(6266 - 6165))(chr(0b1110101) + chr(116) + chr(102) + chr(1905 - 1860) + chr(0b111000)))(xafqLlk3kkUe(aLoH_Mt0dzwO, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd2\xee\xbf%}'), chr(0b1011110 + 0o6) + chr(0b1100101) + chr(99) + '\157' + chr(7609 - 7509) + '\x65')(chr(367 - 250) + chr(116) + chr(0b1001010 + 0o34) + '\x2d' + '\070'))()) for aLoH_Mt0dzwO in xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\xee\xea\xa8"'), chr(100) + chr(3424 - 3323) + chr(99) + '\x6f' + chr(0b101001 + 0o73) + '\145')(chr(9934 - 9817) + chr(0b1000011 + 0o61) + chr(0b1100110) + '\x2d' + chr(0b101111 + 0o11)))(fZzpj6eSosQ9)])
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/lm1b.py
|
_replace_oov
|
def _replace_oov(original_vocab, line):
"""Replace out-of-vocab words with "UNK".
This maintains compatibility with published results.
Args:
original_vocab: a set of strings (The standard vocabulary for the dataset)
line: a unicode string - a space-delimited sequence of words.
Returns:
a unicode string - a space-delimited sequence of words.
"""
return u" ".join(
[word if word in original_vocab else u"UNK" for word in line.split()])
|
python
|
def _replace_oov(original_vocab, line):
"""Replace out-of-vocab words with "UNK".
This maintains compatibility with published results.
Args:
original_vocab: a set of strings (The standard vocabulary for the dataset)
line: a unicode string - a space-delimited sequence of words.
Returns:
a unicode string - a space-delimited sequence of words.
"""
return u" ".join(
[word if word in original_vocab else u"UNK" for word in line.split()])
|
[
"def",
"_replace_oov",
"(",
"original_vocab",
",",
"line",
")",
":",
"return",
"u\" \"",
".",
"join",
"(",
"[",
"word",
"if",
"word",
"in",
"original_vocab",
"else",
"u\"UNK\"",
"for",
"word",
"in",
"line",
".",
"split",
"(",
")",
"]",
")"
] |
Replace out-of-vocab words with "UNK".
This maintains compatibility with published results.
Args:
original_vocab: a set of strings (The standard vocabulary for the dataset)
line: a unicode string - a space-delimited sequence of words.
Returns:
a unicode string - a space-delimited sequence of words.
|
[
"Replace",
"out",
"-",
"of",
"-",
"vocab",
"words",
"with",
"UNK",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/lm1b.py#L58-L71
|
train
|
Replace out - of - vocab words with UNK.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,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sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + '\157' + chr(51) + chr(49) + '\x32', 18021 - 18013), ehT0Px3KOsy9(chr(0b101100 + 0o4) + '\157' + chr(2348 - 2297) + chr(0b101011 + 0o14), 41249 - 41241), ehT0Px3KOsy9(chr(0b11100 + 0o24) + chr(0b1001111 + 0o40) + '\x35' + chr(855 - 806), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1000000 + 0o57) + chr(0b110011) + '\x30' + chr(2103 - 2053), 34603 - 34595), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\062' + '\x34' + chr(572 - 524), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x31' + chr(0b1101 + 0o47) + chr(1765 - 1711), 0o10), ehT0Px3KOsy9(chr(0b100101 + 0o13) + chr(0b1101111) + chr(2134 - 2085) + chr(0b100110 + 0o21) + chr(451 - 398), 0o10), ehT0Px3KOsy9('\060' + chr(1738 - 1627) + chr(0b110001) + '\x34' + chr(385 - 335), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + '\x33' + chr(0b110101) + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(0b100110 + 0o12) + '\157' + chr(0b11111 + 0o30) + chr(0b10101 + 0o34), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110011) + '\x32' + '\067', 58750 - 58742), ehT0Px3KOsy9(chr(0b0 + 0o60) + chr(1117 - 1006) + '\061' + chr(0b11000 + 0o32) + '\066', 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b11011 + 0o30) + chr(0b110000) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(49) + chr(0b101001 + 0o11), 4426 - 4418), ehT0Px3KOsy9(chr(597 - 549) + chr(4064 - 3953) + '\x32' + '\x32', 0o10), ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(0b1100001 + 0o16) + chr(0b100111 + 0o12) + chr(0b100 + 0o62) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(3085 - 2974) + chr(0b110 + 0o55) + chr(53) + chr(48), 8), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110011) + chr(0b100101 + 0o21) + '\x34', 0b1000), ehT0Px3KOsy9(chr(818 - 770) + chr(0b110010 + 0o75) + chr(0b11111 + 0o24) + chr(2644 - 2592) + chr(0b110100), 0o10), ehT0Px3KOsy9('\060' + '\157' + '\x33' + chr(0b110010) + chr(0b110110), 0o10), ehT0Px3KOsy9(chr(908 - 860) + chr(111) + chr(51) + chr(0b100 + 0o57) + chr(1752 - 1701), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b110010 + 0o75) + '\x33' + '\066' + chr(0b11000 + 0o30), ord("\x08")), ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(1222 - 1111) + chr(51) + '\063' + '\x37', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110010) + '\060', 0b1000), ehT0Px3KOsy9(chr(0b11011 + 0o25) + '\x6f' + chr(0b110001) + chr(51) + '\x30', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101110 + 0o1) + '\063' + chr(0b1100 + 0o52) + '\062', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1011110 + 0o21) + chr(1773 - 1723) + chr(0b100100 + 0o14) + '\061', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1010010 + 0o35) + chr(0b110101) + chr(55), ord("\x08")), ehT0Px3KOsy9('\060' + chr(280 - 169) + chr(51) + chr(1983 - 1928), 8), ehT0Px3KOsy9(chr(0b1 + 0o57) + chr(0b1101111) + '\x32' + chr(50) + '\x36', 0o10), ehT0Px3KOsy9('\060' + '\157' + '\x31' + chr(449 - 401) + '\065', 42433 - 42425), ehT0Px3KOsy9(chr(842 - 794) + chr(0b101 + 0o152) + chr(193 - 140) + '\x33', 0o10), ehT0Px3KOsy9(chr(2049 - 2001) + chr(4101 - 3990) + '\067' + chr(0b11011 + 0o25), 0b1000), ehT0Px3KOsy9(chr(0b10111 + 0o31) + '\x6f' + chr(50) + '\x32' + chr(0b1110 + 0o42), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(55), 57862 - 57854), ehT0Px3KOsy9(chr(0b1101 + 0o43) + '\x6f' + chr(0b101000 + 0o17) + chr(1839 - 1785), 0b1000), ehT0Px3KOsy9(chr(0b10111 + 0o31) + '\x6f' + '\x33' + chr(650 - 600) + chr(0b110010), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(164 - 113) + chr(0b111 + 0o57) + '\063', 0o10), ehT0Px3KOsy9(chr(404 - 356) + '\x6f' + chr(1321 - 1271) + chr(0b110100) + chr(52), 60952 - 60944), ehT0Px3KOsy9(chr(0b101101 + 0o3) + '\157' + '\x31' + chr(0b110100) + '\061', 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + '\157' + '\x35' + chr(48), 47933 - 47925)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xe4'), '\144' + chr(5960 - 5859) + chr(7856 - 7757) + chr(471 - 360) + chr(6536 - 6436) + chr(0b1100101))('\165' + '\x74' + chr(2729 - 2627) + chr(45) + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def m6fzRMy3AoJm(rl9P6wPyb05a, LycYkDpyelF6):
return xafqLlk3kkUe(xafqLlk3kkUe(SXOLrMavuUCe(b'\xea'), chr(0b1100100) + chr(0b1011110 + 0o7) + chr(7966 - 7867) + chr(0b1101111) + chr(7159 - 7059) + chr(0b110 + 0o137))(chr(117) + '\x74' + chr(0b1100110) + chr(120 - 75) + '\070'), xafqLlk3kkUe(SXOLrMavuUCe(b'\xa0p@\xac'), chr(8353 - 8253) + '\145' + chr(0b1100011) + '\157' + chr(0b1100100) + '\145')('\165' + chr(0b1110100) + chr(4745 - 4643) + '\055' + '\x38'))([CWnx52wJLqEN if CWnx52wJLqEN in rl9P6wPyb05a else xafqLlk3kkUe(SXOLrMavuUCe(b'\x9fQb'), '\x64' + chr(0b1100101) + chr(99) + '\157' + '\x64' + chr(0b11010 + 0o113))('\x75' + chr(0b1110100) + chr(0b1101 + 0o131) + '\x2d' + '\070') for CWnx52wJLqEN in xafqLlk3kkUe(LycYkDpyelF6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xb9oE\xab\xd4'), chr(1693 - 1593) + chr(5083 - 4982) + '\x63' + chr(0b1101010 + 0o5) + chr(4939 - 4839) + chr(101))('\165' + chr(12814 - 12698) + chr(102) + '\055' + '\x38'))()])
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/lm1b.py
|
_maybe_download_corpus
|
def _maybe_download_corpus(tmp_dir):
"""Download and unpack the corpus.
Args:
tmp_dir: directory containing dataset.
"""
corpus_url = ("http://www.statmt.org/lm-benchmark/"
"1-billion-word-language-modeling-benchmark-r13output.tar.gz")
corpus_filename = os.path.basename(corpus_url)
corpus_filepath = os.path.join(tmp_dir, corpus_filename)
if not os.path.exists(corpus_filepath):
generator_utils.maybe_download(tmp_dir, corpus_filename, corpus_url)
with tarfile.open(corpus_filepath, "r:gz") as corpus_tar:
corpus_tar.extractall(tmp_dir)
|
python
|
def _maybe_download_corpus(tmp_dir):
"""Download and unpack the corpus.
Args:
tmp_dir: directory containing dataset.
"""
corpus_url = ("http://www.statmt.org/lm-benchmark/"
"1-billion-word-language-modeling-benchmark-r13output.tar.gz")
corpus_filename = os.path.basename(corpus_url)
corpus_filepath = os.path.join(tmp_dir, corpus_filename)
if not os.path.exists(corpus_filepath):
generator_utils.maybe_download(tmp_dir, corpus_filename, corpus_url)
with tarfile.open(corpus_filepath, "r:gz") as corpus_tar:
corpus_tar.extractall(tmp_dir)
|
[
"def",
"_maybe_download_corpus",
"(",
"tmp_dir",
")",
":",
"corpus_url",
"=",
"(",
"\"http://www.statmt.org/lm-benchmark/\"",
"\"1-billion-word-language-modeling-benchmark-r13output.tar.gz\"",
")",
"corpus_filename",
"=",
"os",
".",
"path",
".",
"basename",
"(",
"corpus_url",
")",
"corpus_filepath",
"=",
"os",
".",
"path",
".",
"join",
"(",
"tmp_dir",
",",
"corpus_filename",
")",
"if",
"not",
"os",
".",
"path",
".",
"exists",
"(",
"corpus_filepath",
")",
":",
"generator_utils",
".",
"maybe_download",
"(",
"tmp_dir",
",",
"corpus_filename",
",",
"corpus_url",
")",
"with",
"tarfile",
".",
"open",
"(",
"corpus_filepath",
",",
"\"r:gz\"",
")",
"as",
"corpus_tar",
":",
"corpus_tar",
".",
"extractall",
"(",
"tmp_dir",
")"
] |
Download and unpack the corpus.
Args:
tmp_dir: directory containing dataset.
|
[
"Download",
"and",
"unpack",
"the",
"corpus",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/lm1b.py#L90-L103
|
train
|
Download and unpack the corpus.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV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YW,iDQ_gSK8V7h0,Rurm1zTRfSmY,reqGiMiVQ77y,bsS9P6_LpdIe,sbGAZlkZOtyh,Cf_Qef15s3_F,eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + chr(0b1110 + 0o141) + '\x33' + chr(54) + '\x33', ord("\x08")), ehT0Px3KOsy9(chr(2249 - 2201) + '\157' + chr(51), 27571 - 27563), ehT0Px3KOsy9('\060' + '\x6f' + chr(1863 - 1812) + chr(0b11110 + 0o22) + '\x36', ord("\x08")), ehT0Px3KOsy9('\060' + chr(337 - 226) + '\x32' + chr(48) + '\x36', 0o10), ehT0Px3KOsy9(chr(706 - 658) + '\157' + chr(49), 63912 - 63904), ehT0Px3KOsy9(chr(48) + '\157' + chr(50) + '\067' + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b100000 + 0o117) + chr(51) + chr(0b110000) + chr(576 - 526), 0b1000), ehT0Px3KOsy9(chr(0b10101 + 0o33) + '\157' + chr(0b1111 + 0o42) + chr(1928 - 1876) + chr(2980 - 2925), 29768 - 29760), ehT0Px3KOsy9('\x30' + chr(0b10011 + 0o134) + '\062' + chr(301 - 252) + chr(380 - 327), 17650 - 17642), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(49) + chr(0b110010) + chr(0b110110), 0o10), ehT0Px3KOsy9('\x30' + chr(0b110010 + 0o75) + '\064' + chr(0b110 + 0o54), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b11101 + 0o24) + '\064' + chr(0b11001 + 0o30), 0b1000), ehT0Px3KOsy9(chr(0b101100 + 0o4) + '\157' + chr(53) + chr(49), 0o10), ehT0Px3KOsy9(chr(0b110 + 0o52) + '\157' + chr(51) + chr(0b10110 + 0o40) + chr(1389 - 1341), ord("\x08")), ehT0Px3KOsy9(chr(0b11011 + 0o25) + '\x6f' + chr(2200 - 2151) + chr(49) + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(0b100011 + 0o15) + chr(0b110011 + 0o74) + chr(50) + chr(0b111 + 0o51) + chr(952 - 897), 0b1000), ehT0Px3KOsy9(chr(0b11100 + 0o24) + chr(0b11111 + 0o120) + chr(0b110010) + chr(0b11 + 0o62) + chr(0b11011 + 0o30), 0b1000), ehT0Px3KOsy9(chr(338 - 290) + chr(5047 - 4936) + '\x34' + chr(432 - 382), 8), ehT0Px3KOsy9(chr(0b101100 + 0o4) + '\x6f' + chr(0b110001) + '\064' + '\060', 38665 - 38657), ehT0Px3KOsy9(chr(0b110000) + chr(5647 - 5536) + chr(0b110001) + chr(0b100000 + 0o23) + chr(0b110110), 15499 - 15491), ehT0Px3KOsy9('\x30' + chr(0b100101 + 0o112) + chr(0b11101 + 0o26) + chr(2001 - 1949) + chr(0b110000), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(0b10100 + 0o36) + chr(2254 - 2203) + chr(0b1111 + 0o50), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(51) + chr(0b11100 + 0o25) + '\066', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b10000 + 0o42) + '\x37' + chr(0b10000 + 0o43), ord("\x08")), ehT0Px3KOsy9(chr(1171 - 1123) + chr(0b1101111) + chr(1664 - 1615) + chr(0b110100) + chr(48), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110001) + chr(0b110000) + chr(0b101 + 0o53), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(49) + chr(2373 - 2322) + '\066', 8), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110001) + chr(2176 - 2128) + chr(55), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(51) + chr(0b110011) + chr(52), 0o10), ehT0Px3KOsy9('\x30' + chr(4894 - 4783) + chr(0b1011 + 0o47) + chr(1676 - 1625) + chr(49), 0b1000), ehT0Px3KOsy9(chr(0b1010 + 0o46) + '\x6f' + '\062' + chr(0b1110 + 0o50) + chr(50), 0b1000), ehT0Px3KOsy9(chr(2296 - 2248) + chr(0b1010011 + 0o34) + chr(0b110011) + chr(0b10000 + 0o42) + chr(50), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + '\x31', 8), ehT0Px3KOsy9('\060' + chr(111) + '\063' + '\065' + '\062', 8536 - 8528), ehT0Px3KOsy9(chr(0b10111 + 0o31) + chr(111) + chr(49) + chr(0b110000) + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1010 + 0o145) + chr(0b110011) + chr(1117 - 1065) + '\063', 21568 - 21560), ehT0Px3KOsy9(chr(48) + chr(9280 - 9169) + chr(2195 - 2144) + chr(54) + chr(0b110000), 8), ehT0Px3KOsy9(chr(1458 - 1410) + chr(8415 - 8304) + chr(0b10011 + 0o36) + chr(54) + chr(0b110 + 0o57), 10699 - 10691), ehT0Px3KOsy9(chr(48) + chr(0b110110 + 0o71) + '\x33' + chr(412 - 364) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\x31' + chr(55) + chr(0b100101 + 0o14), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + chr(111) + '\x35' + '\x30', ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xdd'), '\144' + '\145' + chr(8089 - 7990) + chr(0b10111 + 0o130) + '\144' + '\145')(chr(0b1110101) + chr(0b1110100) + '\x66' + chr(0b101101) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def nOhugYfEsDse(JsZ36NJUqtml):
SAOBF9_GnBvW = xafqLlk3kkUe(SXOLrMavuUCe(b'\x9bw\xb2\xf6;\x90\xed\x10\xfa!\x0c\x12]\x919\xea\xdf\x0c\x0f,\x87\xb0\xa2\xd6M";)\xbf\xf1\xdf\xb3s\x81k\xd2\xdd\x17\xaa\x15\x9fj\xa9\xe8,\xc8\xad\x15\xe9{N\x00G\x978\xe6\xccGM3\x8f\xfb\xab\xd7\t.9j\xbe\xfc\xdc\xb1i\x87%\x91\x9bX\xb1H\xc0l\xb3\xf2q\xca\xb6I\xf97PON\x8a'), chr(0b110001 + 0o63) + '\x65' + '\x63' + chr(111) + '\144' + chr(0b10101 + 0o120))('\x75' + '\164' + chr(0b1100110 + 0o0) + chr(0b1010 + 0o43) + chr(56))
G9L1oqbIOa_z = oqhJDdMJfuwx.path.basename(SAOBF9_GnBvW)
Z_pTyFt11S5g = oqhJDdMJfuwx.path.join(JsZ36NJUqtml, G9L1oqbIOa_z)
if not xafqLlk3kkUe(oqhJDdMJfuwx.path, xafqLlk3kkUe(SXOLrMavuUCe(b'\x96{\xaf\xf5u\xcc'), chr(0b1100100) + chr(0b1100101) + '\143' + '\x6f' + chr(100) + '\x65')(chr(0b1110101) + chr(146 - 30) + '\x66' + chr(534 - 489) + chr(0b101101 + 0o13)))(Z_pTyFt11S5g):
xafqLlk3kkUe(g1Z_RG9zP4cD, xafqLlk3kkUe(SXOLrMavuUCe(b'\x9eb\xbf\xe4d\xe0\xa6\x08\xfa8N\x0eH\x94'), chr(0b1100100) + chr(0b1100101) + chr(99) + '\157' + chr(0b1100 + 0o130) + '\x65')(chr(117) + '\164' + '\146' + chr(45) + chr(2406 - 2350)))(JsZ36NJUqtml, G9L1oqbIOa_z, SAOBF9_GnBvW)
with xafqLlk3kkUe(RxqDt8LqC5Ns, xafqLlk3kkUe(SXOLrMavuUCe(b'\x9cs\xa3\xe8'), chr(100) + '\x65' + '\x63' + chr(111) + chr(0b111101 + 0o47) + chr(0b1110 + 0o127))(chr(9812 - 9695) + chr(0b1110100) + '\x66' + chr(439 - 394) + chr(2300 - 2244)))(Z_pTyFt11S5g, xafqLlk3kkUe(SXOLrMavuUCe(b'\x819\xa1\xfc'), '\x64' + chr(10152 - 10051) + chr(0b1100011) + chr(111) + chr(100) + '\x65')('\x75' + chr(0b1110100) + chr(9799 - 9697) + chr(0b100111 + 0o6) + '\x38')) as nzUckwk81aug:
xafqLlk3kkUe(nzUckwk81aug, xafqLlk3kkUe(SXOLrMavuUCe(b'\x96{\xb2\xf4`\xdc\xb6\x06\xe1:'), chr(100) + chr(8743 - 8642) + chr(0b1110 + 0o125) + chr(111) + chr(735 - 635) + '\145')('\165' + '\164' + chr(102) + '\055' + chr(56)))(JsZ36NJUqtml)
|
tensorflow/tensor2tensor
|
tensor2tensor/models/research/cycle_gan.py
|
lossfn
|
def lossfn(real_input, fake_input, compress, hparams, lsgan, name):
"""Loss function."""
eps = 1e-12
with tf.variable_scope(name):
d1 = discriminator(real_input, compress, hparams, "discriminator")
d2 = discriminator(fake_input, compress, hparams, "discriminator",
reuse=True)
if lsgan:
dloss = tf.reduce_mean(
tf.squared_difference(d1, 0.9)) + tf.reduce_mean(tf.square(d2))
gloss = tf.reduce_mean(tf.squared_difference(d2, 0.9))
loss = (dloss + gloss)/2
else: # cross_entropy
dloss = -tf.reduce_mean(
tf.log(d1 + eps)) - tf.reduce_mean(tf.log1p(eps - d2))
gloss = -tf.reduce_mean(tf.log(d2 + eps))
loss = (dloss + gloss)/2
return loss
|
python
|
def lossfn(real_input, fake_input, compress, hparams, lsgan, name):
"""Loss function."""
eps = 1e-12
with tf.variable_scope(name):
d1 = discriminator(real_input, compress, hparams, "discriminator")
d2 = discriminator(fake_input, compress, hparams, "discriminator",
reuse=True)
if lsgan:
dloss = tf.reduce_mean(
tf.squared_difference(d1, 0.9)) + tf.reduce_mean(tf.square(d2))
gloss = tf.reduce_mean(tf.squared_difference(d2, 0.9))
loss = (dloss + gloss)/2
else: # cross_entropy
dloss = -tf.reduce_mean(
tf.log(d1 + eps)) - tf.reduce_mean(tf.log1p(eps - d2))
gloss = -tf.reduce_mean(tf.log(d2 + eps))
loss = (dloss + gloss)/2
return loss
|
[
"def",
"lossfn",
"(",
"real_input",
",",
"fake_input",
",",
"compress",
",",
"hparams",
",",
"lsgan",
",",
"name",
")",
":",
"eps",
"=",
"1e-12",
"with",
"tf",
".",
"variable_scope",
"(",
"name",
")",
":",
"d1",
"=",
"discriminator",
"(",
"real_input",
",",
"compress",
",",
"hparams",
",",
"\"discriminator\"",
")",
"d2",
"=",
"discriminator",
"(",
"fake_input",
",",
"compress",
",",
"hparams",
",",
"\"discriminator\"",
",",
"reuse",
"=",
"True",
")",
"if",
"lsgan",
":",
"dloss",
"=",
"tf",
".",
"reduce_mean",
"(",
"tf",
".",
"squared_difference",
"(",
"d1",
",",
"0.9",
")",
")",
"+",
"tf",
".",
"reduce_mean",
"(",
"tf",
".",
"square",
"(",
"d2",
")",
")",
"gloss",
"=",
"tf",
".",
"reduce_mean",
"(",
"tf",
".",
"squared_difference",
"(",
"d2",
",",
"0.9",
")",
")",
"loss",
"=",
"(",
"dloss",
"+",
"gloss",
")",
"/",
"2",
"else",
":",
"# cross_entropy",
"dloss",
"=",
"-",
"tf",
".",
"reduce_mean",
"(",
"tf",
".",
"log",
"(",
"d1",
"+",
"eps",
")",
")",
"-",
"tf",
".",
"reduce_mean",
"(",
"tf",
".",
"log1p",
"(",
"eps",
"-",
"d2",
")",
")",
"gloss",
"=",
"-",
"tf",
".",
"reduce_mean",
"(",
"tf",
".",
"log",
"(",
"d2",
"+",
"eps",
")",
")",
"loss",
"=",
"(",
"dloss",
"+",
"gloss",
")",
"/",
"2",
"return",
"loss"
] |
Loss function.
|
[
"Loss",
"function",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/research/cycle_gan.py#L46-L63
|
train
|
Loss function.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdT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C8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b100100 + 0o16) + chr(841 - 789) + chr(0b110100), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(1684 - 1573) + '\061' + chr(0b110010) + chr(0b110101), 45797 - 45789), ehT0Px3KOsy9(chr(0b10100 + 0o34) + chr(3087 - 2976) + chr(1566 - 1516) + chr(0b110001) + chr(0b110010), 53846 - 53838), ehT0Px3KOsy9(chr(1999 - 1951) + chr(0b1101111) + chr(50) + '\061' + '\061', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110010) + chr(2288 - 2239) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x32' + chr(0b110010) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(2457 - 2407) + chr(53) + chr(1939 - 1890), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1001 + 0o146) + chr(0b110010) + '\067' + chr(0b11000 + 0o35), 15458 - 15450), ehT0Px3KOsy9('\060' + chr(111) + chr(962 - 912) + chr(0b10110 + 0o32) + '\x30', 10951 - 10943), ehT0Px3KOsy9('\x30' + chr(0b101001 + 0o106) + chr(0b100 + 0o55) + '\x37' + chr(54), 50515 - 50507), ehT0Px3KOsy9(chr(0b1111 + 0o41) + chr(10918 - 10807) + chr(0b110010) + chr(134 - 85) + chr(1963 - 1915), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\061' + chr(50) + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(6223 - 6112) + chr(0b11111 + 0o24) + '\x33' + chr(0b11001 + 0o33), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b10110 + 0o131) + '\067' + chr(0b1100 + 0o47), 0o10), ehT0Px3KOsy9(chr(0b10100 + 0o34) + '\157' + '\x32' + chr(48) + chr(0b110000 + 0o7), 47772 - 47764), ehT0Px3KOsy9('\x30' + chr(5929 - 5818) + chr(0b110010) + chr(50) + chr(0b1000 + 0o55), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(0b11010 + 0o31) + chr(0b110101 + 0o0) + chr(0b10011 + 0o36), 0o10), ehT0Px3KOsy9(chr(578 - 530) + chr(0b1101000 + 0o7) + '\x31' + chr(913 - 861) + chr(0b110011), 16851 - 16843), ehT0Px3KOsy9(chr(172 - 124) + chr(0b1101111) + chr(0b101 + 0o55) + chr(49) + chr(49), 8), ehT0Px3KOsy9(chr(1980 - 1932) + '\157' + chr(49) + chr(51) + chr(0b110011), 9323 - 9315), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b10000 + 0o42) + chr(0b11110 + 0o26) + chr(2547 - 2493), ord("\x08")), ehT0Px3KOsy9(chr(0b1000 + 0o50) + '\157' + chr(49) + '\x34' + chr(0b10000 + 0o44), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110001) + chr(0b11001 + 0o34) + chr(0b110000), 33674 - 33666), ehT0Px3KOsy9('\060' + chr(4387 - 4276) + '\062' + chr(1978 - 1929) + chr(51), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(655 - 604) + chr(0b110011) + chr(0b1101 + 0o50), ord("\x08")), ehT0Px3KOsy9(chr(535 - 487) + chr(0b1101111 + 0o0) + chr(0b110010) + chr(50) + '\067', 0o10), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(111) + '\063' + chr(49) + '\063', 0b1000), ehT0Px3KOsy9(chr(1766 - 1718) + chr(0b110001 + 0o76) + '\x31' + chr(0b10001 + 0o37) + chr(53), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(7743 - 7632) + '\x32' + chr(0b110110) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(1075 - 1027) + '\x6f' + chr(0b110011) + chr(48), 0o10), ehT0Px3KOsy9(chr(124 - 76) + chr(0b110111 + 0o70) + '\062' + chr(0b110010) + chr(0b1100 + 0o46), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(53) + chr(0b110010), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110100) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(0b1101111) + chr(0b11110 + 0o23) + chr(0b101101 + 0o4) + chr(2564 - 2511), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(1463 - 1412) + '\x36' + '\062', 28117 - 28109), ehT0Px3KOsy9('\x30' + chr(0b110110 + 0o71) + chr(50) + chr(0b1001 + 0o50) + chr(1339 - 1289), 8), ehT0Px3KOsy9('\060' + '\157' + chr(0b110101) + '\062', 8), ehT0Px3KOsy9(chr(48) + chr(111) + '\x33' + chr(50) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(9518 - 9407) + chr(0b101010 + 0o11) + '\061', 14006 - 13998), ehT0Px3KOsy9(chr(48) + '\x6f' + '\062' + '\x35' + '\061', 8)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b1000 + 0o50) + chr(0b1101111) + chr(2692 - 2639) + '\x30', 20418 - 20410)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x8a'), chr(100) + '\145' + '\143' + chr(0b1101111) + '\x64' + '\145')(chr(0b1110101) + '\x74' + chr(1559 - 1457) + chr(0b101101) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def wRfxdY1ig9SP(TiHyCgI00kHt, pH_WL8ISSWwA, xNrsUM6GazDP, n4ljua2gi1Pr, nL6uwpVI7Ms9, AIvJRzLdDfgF):
ANx8zFubz7L8 = 1e-12
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd24\xf8\xe0\xea\xf4\xc5\xd8\xdf\r\xeb?\xac^'), chr(7757 - 7657) + '\x65' + chr(99) + chr(11524 - 11413) + chr(100) + chr(5917 - 5816))(chr(117) + chr(0b100010 + 0o122) + chr(102) + '\x2d' + '\070'))(AIvJRzLdDfgF):
tENsTyQHEJlq = PgtWWoVsho2z(TiHyCgI00kHt, xNrsUM6GazDP, n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc0<\xf9\xea\xf9\xff\xc4\xd4\xee\x1f\xfc?\xae'), chr(3128 - 3028) + '\x65' + '\x63' + chr(111) + '\x64' + chr(0b1100101))('\x75' + chr(0b1000111 + 0o55) + '\x66' + '\055' + chr(0b11010 + 0o36)))
oaWjI9ziMA4V = PgtWWoVsho2z(pH_WL8ISSWwA, xNrsUM6GazDP, n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc0<\xf9\xea\xf9\xff\xc4\xd4\xee\x1f\xfc?\xae'), '\144' + chr(9159 - 9058) + chr(0b1100011) + chr(10190 - 10079) + chr(0b1010010 + 0o22) + chr(0b1100101))(chr(117) + chr(12148 - 12032) + chr(0b11111 + 0o107) + chr(45) + chr(56)), reuse=ehT0Px3KOsy9(chr(1058 - 1010) + chr(0b1011000 + 0o27) + chr(2205 - 2156), 0o10))
if nL6uwpVI7Ms9:
nj5ae4nELPdZ = IDJ2eXGCBCDu.reduce_mean(IDJ2eXGCBCDu.squared_difference(tENsTyQHEJlq, 0.9)) + IDJ2eXGCBCDu.reduce_mean(IDJ2eXGCBCDu.square(oaWjI9ziMA4V))
R_pYoTWU74MZ = IDJ2eXGCBCDu.reduce_mean(IDJ2eXGCBCDu.squared_difference(oaWjI9ziMA4V, 0.9))
YpO0BcZ6fMsf = (nj5ae4nELPdZ + R_pYoTWU74MZ) / ehT0Px3KOsy9('\060' + chr(637 - 526) + chr(0b110010), ord("\x08"))
else:
nj5ae4nELPdZ = -IDJ2eXGCBCDu.reduce_mean(IDJ2eXGCBCDu.log(tENsTyQHEJlq + ANx8zFubz7L8)) - IDJ2eXGCBCDu.reduce_mean(IDJ2eXGCBCDu.log1p(ANx8zFubz7L8 - oaWjI9ziMA4V))
R_pYoTWU74MZ = -IDJ2eXGCBCDu.reduce_mean(IDJ2eXGCBCDu.log(oaWjI9ziMA4V + ANx8zFubz7L8))
YpO0BcZ6fMsf = (nj5ae4nELPdZ + R_pYoTWU74MZ) / ehT0Px3KOsy9(chr(0b110000) + chr(0b1101110 + 0o1) + '\x32', 8)
return YpO0BcZ6fMsf
|
tensorflow/tensor2tensor
|
tensor2tensor/models/research/cycle_gan.py
|
cycle_gan_internal
|
def cycle_gan_internal(inputs, targets, _, hparams):
"""Cycle GAN, main step used for training."""
with tf.variable_scope("cycle_gan"):
# Embed inputs and targets.
inputs_orig, targets_orig = tf.to_int32(inputs), tf.to_int32(targets)
inputs = common_layers.embedding(
inputs_orig, hparams.vocab_size, hparams.hidden_size, "embed")
targets = common_layers.embedding(
targets_orig, hparams.vocab_size, hparams.hidden_size,
"embed", reuse=True)
x, _ = split_on_batch(inputs)
_, y = split_on_batch(targets)
# Y --> X
y_fake = generator(y, hparams, "Fy", reuse=False)
y_to_x_loss = lossfn(y, y_fake, True, hparams, True, "YtoX")
# X --> Y
x_fake = generator(x, hparams, "Gx", reuse=False)
x_to_y_loss = lossfn(y, x_fake, True, hparams, True, "XtoY")
# Cycle-Consistency
y_fake_ = generator(y_fake, hparams, "Gx", reuse=True)
x_fake_ = generator(x_fake, hparams, "Fy", reuse=True)
x_to_x_loss = hparams.cycle_loss_multiplier1 * tf.reduce_mean(
tf.abs(x_fake_ - x))
y_to_y_loss = hparams.cycle_loss_multiplier2 * tf.reduce_mean(
tf.abs(y_fake_ - y))
cycloss = x_to_x_loss + y_to_y_loss
sample_generated = generator(inputs, hparams, "Gx", reuse=True)
sample_generated = tf.layers.dense(
sample_generated, hparams.vocab_size, name="softmax", reuse=None)
sample_generated = tf.stop_gradient(
tf.expand_dims(sample_generated, axis=2))
losses = {"cycloss": cycloss,
"y_to_x_loss": y_to_x_loss,
"x_to_y_loss": x_to_y_loss}
return sample_generated, losses
|
python
|
def cycle_gan_internal(inputs, targets, _, hparams):
"""Cycle GAN, main step used for training."""
with tf.variable_scope("cycle_gan"):
# Embed inputs and targets.
inputs_orig, targets_orig = tf.to_int32(inputs), tf.to_int32(targets)
inputs = common_layers.embedding(
inputs_orig, hparams.vocab_size, hparams.hidden_size, "embed")
targets = common_layers.embedding(
targets_orig, hparams.vocab_size, hparams.hidden_size,
"embed", reuse=True)
x, _ = split_on_batch(inputs)
_, y = split_on_batch(targets)
# Y --> X
y_fake = generator(y, hparams, "Fy", reuse=False)
y_to_x_loss = lossfn(y, y_fake, True, hparams, True, "YtoX")
# X --> Y
x_fake = generator(x, hparams, "Gx", reuse=False)
x_to_y_loss = lossfn(y, x_fake, True, hparams, True, "XtoY")
# Cycle-Consistency
y_fake_ = generator(y_fake, hparams, "Gx", reuse=True)
x_fake_ = generator(x_fake, hparams, "Fy", reuse=True)
x_to_x_loss = hparams.cycle_loss_multiplier1 * tf.reduce_mean(
tf.abs(x_fake_ - x))
y_to_y_loss = hparams.cycle_loss_multiplier2 * tf.reduce_mean(
tf.abs(y_fake_ - y))
cycloss = x_to_x_loss + y_to_y_loss
sample_generated = generator(inputs, hparams, "Gx", reuse=True)
sample_generated = tf.layers.dense(
sample_generated, hparams.vocab_size, name="softmax", reuse=None)
sample_generated = tf.stop_gradient(
tf.expand_dims(sample_generated, axis=2))
losses = {"cycloss": cycloss,
"y_to_x_loss": y_to_x_loss,
"x_to_y_loss": x_to_y_loss}
return sample_generated, losses
|
[
"def",
"cycle_gan_internal",
"(",
"inputs",
",",
"targets",
",",
"_",
",",
"hparams",
")",
":",
"with",
"tf",
".",
"variable_scope",
"(",
"\"cycle_gan\"",
")",
":",
"# Embed inputs and targets.",
"inputs_orig",
",",
"targets_orig",
"=",
"tf",
".",
"to_int32",
"(",
"inputs",
")",
",",
"tf",
".",
"to_int32",
"(",
"targets",
")",
"inputs",
"=",
"common_layers",
".",
"embedding",
"(",
"inputs_orig",
",",
"hparams",
".",
"vocab_size",
",",
"hparams",
".",
"hidden_size",
",",
"\"embed\"",
")",
"targets",
"=",
"common_layers",
".",
"embedding",
"(",
"targets_orig",
",",
"hparams",
".",
"vocab_size",
",",
"hparams",
".",
"hidden_size",
",",
"\"embed\"",
",",
"reuse",
"=",
"True",
")",
"x",
",",
"_",
"=",
"split_on_batch",
"(",
"inputs",
")",
"_",
",",
"y",
"=",
"split_on_batch",
"(",
"targets",
")",
"# Y --> X",
"y_fake",
"=",
"generator",
"(",
"y",
",",
"hparams",
",",
"\"Fy\"",
",",
"reuse",
"=",
"False",
")",
"y_to_x_loss",
"=",
"lossfn",
"(",
"y",
",",
"y_fake",
",",
"True",
",",
"hparams",
",",
"True",
",",
"\"YtoX\"",
")",
"# X --> Y",
"x_fake",
"=",
"generator",
"(",
"x",
",",
"hparams",
",",
"\"Gx\"",
",",
"reuse",
"=",
"False",
")",
"x_to_y_loss",
"=",
"lossfn",
"(",
"y",
",",
"x_fake",
",",
"True",
",",
"hparams",
",",
"True",
",",
"\"XtoY\"",
")",
"# Cycle-Consistency",
"y_fake_",
"=",
"generator",
"(",
"y_fake",
",",
"hparams",
",",
"\"Gx\"",
",",
"reuse",
"=",
"True",
")",
"x_fake_",
"=",
"generator",
"(",
"x_fake",
",",
"hparams",
",",
"\"Fy\"",
",",
"reuse",
"=",
"True",
")",
"x_to_x_loss",
"=",
"hparams",
".",
"cycle_loss_multiplier1",
"*",
"tf",
".",
"reduce_mean",
"(",
"tf",
".",
"abs",
"(",
"x_fake_",
"-",
"x",
")",
")",
"y_to_y_loss",
"=",
"hparams",
".",
"cycle_loss_multiplier2",
"*",
"tf",
".",
"reduce_mean",
"(",
"tf",
".",
"abs",
"(",
"y_fake_",
"-",
"y",
")",
")",
"cycloss",
"=",
"x_to_x_loss",
"+",
"y_to_y_loss",
"sample_generated",
"=",
"generator",
"(",
"inputs",
",",
"hparams",
",",
"\"Gx\"",
",",
"reuse",
"=",
"True",
")",
"sample_generated",
"=",
"tf",
".",
"layers",
".",
"dense",
"(",
"sample_generated",
",",
"hparams",
".",
"vocab_size",
",",
"name",
"=",
"\"softmax\"",
",",
"reuse",
"=",
"None",
")",
"sample_generated",
"=",
"tf",
".",
"stop_gradient",
"(",
"tf",
".",
"expand_dims",
"(",
"sample_generated",
",",
"axis",
"=",
"2",
")",
")",
"losses",
"=",
"{",
"\"cycloss\"",
":",
"cycloss",
",",
"\"y_to_x_loss\"",
":",
"y_to_x_loss",
",",
"\"x_to_y_loss\"",
":",
"x_to_y_loss",
"}",
"return",
"sample_generated",
",",
"losses"
] |
Cycle GAN, main step used for training.
|
[
"Cycle",
"GAN",
"main",
"step",
"used",
"for",
"training",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/research/cycle_gan.py#L72-L113
|
train
|
Cycle GAN main step used for training.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3t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BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(1864 - 1816) + chr(111) + '\x31' + '\x31' + chr(0b110101), 13837 - 13829), ehT0Px3KOsy9('\x30' + '\157' + chr(377 - 327) + chr(0b101111 + 0o3) + chr(967 - 915), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(50) + chr(603 - 551) + '\061', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(1726 - 1615) + chr(1694 - 1644) + '\062', 0o10), ehT0Px3KOsy9(chr(1249 - 1201) + '\x6f' + chr(1486 - 1432) + '\064', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110011 + 0o1) + chr(0b100000 + 0o24), 0b1000), ehT0Px3KOsy9(chr(657 - 609) + chr(12197 - 12086) + '\067' + chr(55), 20024 - 20016), ehT0Px3KOsy9(chr(48) + chr(111) + '\x32' + '\x34' + chr(51), 13245 - 13237), ehT0Px3KOsy9(chr(1515 - 1467) + chr(11579 - 11468) + '\x33' + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(464 - 416) + '\x6f' + '\062' + chr(52) + '\x31', 8), ehT0Px3KOsy9(chr(217 - 169) + chr(0b1011111 + 0o20) + chr(0b110001) + chr(0b1000 + 0o54) + chr(110 - 59), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x32' + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b110001 + 0o76) + chr(51) + '\x36' + '\x31', 0o10), ehT0Px3KOsy9(chr(0b0 + 0o60) + chr(111) + chr(0b110011) + chr(0b1000 + 0o52) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b100000 + 0o117) + chr(0b110010) + chr(648 - 599) + chr(0b110010), 36326 - 36318), ehT0Px3KOsy9(chr(0b11011 + 0o25) + chr(0b10000 + 0o137) + chr(0b110011) + chr(1333 - 1285) + '\x33', 0o10), ehT0Px3KOsy9('\060' + chr(3910 - 3799) + chr(712 - 662) + chr(0b110000 + 0o7) + chr(0b100000 + 0o26), 4323 - 4315), ehT0Px3KOsy9(chr(1057 - 1009) + '\157' + '\063' + '\x32' + chr(323 - 268), 0o10), ehT0Px3KOsy9('\x30' + chr(5883 - 5772) + chr(1809 - 1758) + chr(0b101 + 0o56) + '\063', 39394 - 39386), ehT0Px3KOsy9(chr(2238 - 2190) + chr(111) + chr(0b110010) + chr(48) + chr(924 - 876), ord("\x08")), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(111) + chr(0b110001) + chr(0b101 + 0o56), 60841 - 60833), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110111) + chr(0b1011 + 0o50), ord("\x08")), ehT0Px3KOsy9(chr(245 - 197) + '\x6f' + chr(50) + chr(75 - 22) + chr(1708 - 1653), 0o10), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(0b1000111 + 0o50) + chr(2157 - 2106) + chr(50), 8), ehT0Px3KOsy9('\x30' + '\157' + '\063' + '\067' + chr(1972 - 1919), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x31' + chr(0b110100 + 0o2), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b10111 + 0o40) + chr(279 - 227), ord("\x08")), ehT0Px3KOsy9(chr(1080 - 1032) + '\157' + '\062' + '\062' + chr(145 - 96), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(51) + chr(913 - 861), 35879 - 35871), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\065' + chr(0b110011), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(6364 - 6253) + chr(1721 - 1670) + '\065' + '\x35', 0b1000), ehT0Px3KOsy9(chr(1877 - 1829) + chr(0b1101111) + '\065' + chr(1388 - 1334), 0o10), ehT0Px3KOsy9(chr(0b1 + 0o57) + chr(999 - 888) + chr(901 - 851) + '\064' + chr(48), 28230 - 28222), ehT0Px3KOsy9(chr(0b110000) + chr(10990 - 10879) + chr(0b110010) + '\061' + '\x30', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(51) + chr(1929 - 1877) + '\062', ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + '\x33' + '\x36' + '\067', 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(0b1 + 0o60) + chr(0b100110 + 0o13) + '\x33', 0o10), ehT0Px3KOsy9(chr(0b101 + 0o53) + '\x6f' + chr(0b10111 + 0o33) + '\x31' + chr(0b100100 + 0o22), 11773 - 11765), ehT0Px3KOsy9(chr(0b110000) + chr(6781 - 6670) + chr(244 - 194) + chr(2110 - 2060) + chr(1749 - 1700), 8), ehT0Px3KOsy9(chr(906 - 858) + chr(0b110011 + 0o74) + chr(0b100 + 0o55) + '\x33' + '\061', 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(0b10111 + 0o130) + chr(0b11100 + 0o31) + chr(0b100100 + 0o14), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'c'), chr(0b1100100) + chr(0b1100101) + chr(99) + '\x6f' + chr(100) + '\x65')(chr(0b110011 + 0o102) + '\x74' + '\146' + '\x2d' + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def srNuHbcZZ5Zh(vXoupepMtCXU, xIEmRseySp3z, VNGQdHSFPrso, n4ljua2gi1Pr):
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b';\xf5\xd3{UFS\xc6E\xd2\x00~\x81\xb0'), chr(0b1010111 + 0o15) + chr(0b1100101) + chr(9370 - 9271) + chr(0b1101111) + chr(0b111000 + 0o54) + '\x65')(chr(0b1110101) + chr(116) + '\146' + chr(45) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'.\xed\xc2~Q{X\xc2t'), chr(100) + '\145' + chr(0b11011 + 0o110) + chr(0b1101111) + chr(9574 - 9474) + '\145')('\165' + chr(116) + chr(0b100110 + 0o100) + '\x2d' + chr(0b110 + 0o62))):
(jdmcTKqDXTkH, RMxdYJVFptLI) = (IDJ2eXGCBCDu.to_int32(vXoupepMtCXU), IDJ2eXGCBCDu.to_int32(xIEmRseySp3z))
vXoupepMtCXU = jSKPaHwSAfVv.embedding(jdmcTKqDXTkH, n4ljua2gi1Pr.CeyMIoSyrpkQ, n4ljua2gi1Pr.qzoyXN3kdhDL, xafqLlk3kkUe(SXOLrMavuUCe(b'(\xf9\xc3wP'), chr(0b1100100) + chr(1503 - 1402) + '\143' + chr(0b1101111) + '\144' + chr(101))(chr(5393 - 5276) + chr(0b1101001 + 0o13) + '\146' + '\x2d' + chr(558 - 502)))
xIEmRseySp3z = jSKPaHwSAfVv.embedding(RMxdYJVFptLI, n4ljua2gi1Pr.CeyMIoSyrpkQ, n4ljua2gi1Pr.qzoyXN3kdhDL, xafqLlk3kkUe(SXOLrMavuUCe(b'(\xf9\xc3wP'), chr(0b111000 + 0o54) + '\x65' + chr(99) + chr(8669 - 8558) + chr(1298 - 1198) + chr(2267 - 2166))('\x75' + '\x74' + chr(0b1100110) + chr(1769 - 1724) + '\070'), reuse=ehT0Px3KOsy9('\x30' + chr(10952 - 10841) + chr(0b11101 + 0o24), 0o10))
(OeWW0F1dBPRQ, VNGQdHSFPrso) = klcYe2QFTHP6(vXoupepMtCXU)
(VNGQdHSFPrso, SqiSOtYOqOJH) = klcYe2QFTHP6(xIEmRseySp3z)
xSxDw8SGT55k = bTFcxMKbQoFz(SqiSOtYOqOJH, n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x0b\xed'), chr(6373 - 6273) + chr(101) + chr(194 - 95) + chr(0b1101111) + chr(0b1100100) + '\145')(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + chr(0b101101) + chr(0b1010 + 0o56)), reuse=ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(48), ord("\x08")))
mDtaJ5wrED5j = wRfxdY1ig9SP(SqiSOtYOqOJH, xSxDw8SGT55k, ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(49), 8), n4ljua2gi1Pr, ehT0Px3KOsy9(chr(863 - 815) + '\x6f' + chr(0b110001), 8), xafqLlk3kkUe(SXOLrMavuUCe(b'\x14\xe0\xceJ'), chr(0b1011011 + 0o11) + chr(101) + '\x63' + chr(111) + chr(100) + chr(4482 - 4381))(chr(0b1110101) + chr(0b110 + 0o156) + chr(102) + '\055' + '\x38'))
JtqGwXcO4cVM = bTFcxMKbQoFz(OeWW0F1dBPRQ, n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\n\xec'), chr(0b111111 + 0o45) + chr(0b1100101) + '\x63' + chr(587 - 476) + chr(100) + '\145')(chr(0b111 + 0o156) + '\164' + '\x66' + chr(0b1010 + 0o43) + chr(0b11110 + 0o32)), reuse=ehT0Px3KOsy9('\x30' + chr(0b111011 + 0o64) + chr(0b110000), 8))
dwZOvg7DQiKE = wRfxdY1ig9SP(SqiSOtYOqOJH, JtqGwXcO4cVM, ehT0Px3KOsy9('\060' + '\x6f' + chr(0b111 + 0o52), 8), n4ljua2gi1Pr, ehT0Px3KOsy9('\060' + chr(111) + chr(2104 - 2055), 8), xafqLlk3kkUe(SXOLrMavuUCe(b'\x15\xe0\xceK'), chr(0b1001110 + 0o26) + chr(4404 - 4303) + '\143' + '\x6f' + chr(1351 - 1251) + chr(0b11 + 0o142))('\165' + chr(10435 - 10319) + '\146' + chr(0b11 + 0o52) + chr(0b111000)))
iIpazqYjgPg1 = bTFcxMKbQoFz(xSxDw8SGT55k, n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\n\xec'), chr(100) + chr(0b1100101) + chr(99) + chr(0b1001 + 0o146) + '\144' + '\x65')(chr(0b1110101) + '\x74' + chr(0b1011101 + 0o11) + chr(45) + '\x38'), reuse=ehT0Px3KOsy9(chr(1993 - 1945) + chr(0b1101111) + chr(49), 8))
edsp0N5K4YmP = bTFcxMKbQoFz(JtqGwXcO4cVM, n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x0b\xed'), chr(0b110 + 0o136) + chr(0b1100101) + '\x63' + '\x6f' + '\144' + chr(0b1100101))(chr(117) + chr(0b11111 + 0o125) + chr(9983 - 9881) + chr(0b101101) + '\070'), reuse=ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2128 - 2079), 8))
xV35btWKgyO4 = n4ljua2gi1Pr.cycle_loss_multiplier1 * IDJ2eXGCBCDu.reduce_mean(IDJ2eXGCBCDu.abs(edsp0N5K4YmP - OeWW0F1dBPRQ))
JB1nuhlwnSLM = n4ljua2gi1Pr.cycle_loss_multiplier2 * IDJ2eXGCBCDu.reduce_mean(IDJ2eXGCBCDu.abs(iIpazqYjgPg1 - SqiSOtYOqOJH))
aoQ62xxfMYym = xV35btWKgyO4 + JB1nuhlwnSLM
b8zc4oxo0iLB = bTFcxMKbQoFz(vXoupepMtCXU, n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\n\xec'), chr(0b1100100) + chr(0b1100101) + '\x63' + chr(0b1101111) + chr(0b11100 + 0o110) + chr(0b1001111 + 0o26))('\165' + chr(250 - 134) + chr(1020 - 918) + chr(0b101011 + 0o2) + chr(1908 - 1852)), reuse=ehT0Px3KOsy9('\x30' + '\x6f' + chr(656 - 607), 8))
b8zc4oxo0iLB = IDJ2eXGCBCDu.layers.dense(b8zc4oxo0iLB, n4ljua2gi1Pr.CeyMIoSyrpkQ, name=xafqLlk3kkUe(SXOLrMavuUCe(b'>\xfb\xc7fYEG'), '\144' + chr(5474 - 5373) + chr(99) + chr(111) + chr(100) + chr(0b100110 + 0o77))('\x75' + chr(4692 - 4576) + chr(0b1100110) + '\x2d' + chr(0b111000)), reuse=None)
b8zc4oxo0iLB = IDJ2eXGCBCDu.stop_gradient(IDJ2eXGCBCDu.expand_dims(b8zc4oxo0iLB, axis=ehT0Px3KOsy9(chr(48) + chr(4603 - 4492) + chr(1073 - 1023), ord("\x08"))))
eJKWkHA7qzlZ = {xafqLlk3kkUe(SXOLrMavuUCe(b'.\xed\xc2~[WL'), chr(100) + chr(0b1100101) + chr(0b1100011) + '\157' + chr(0b1011101 + 0o7) + '\x65')('\x75' + '\x74' + chr(0b1100110) + '\x2d' + chr(56)): aoQ62xxfMYym, xafqLlk3kkUe(SXOLrMavuUCe(b'4\xcb\xd5}k\\`\xcfu\xd2\x10'), chr(0b111001 + 0o53) + chr(101) + '\x63' + chr(0b111001 + 0o66) + chr(100) + chr(101))('\165' + chr(116) + '\146' + chr(0b1101 + 0o40) + chr(56)): mDtaJ5wrED5j, xafqLlk3kkUe(SXOLrMavuUCe(b'5\xcb\xd5}k]`\xcfu\xd2\x10'), chr(0b1100100) + chr(101) + '\143' + chr(635 - 524) + chr(100) + '\145')(chr(0b1110101) + '\164' + chr(0b1100110) + chr(606 - 561) + '\x38'): dwZOvg7DQiKE}
return (b8zc4oxo0iLB, eJKWkHA7qzlZ)
|
tensorflow/tensor2tensor
|
tensor2tensor/models/research/cycle_gan.py
|
cycle_gan_small
|
def cycle_gan_small():
"""Set of hyperparameters."""
hparams = transformer_vae.transformer_ae_small()
hparams.batch_size = 2048
hparams.bottom = {
"inputs": modalities.identity_bottom,
"targets": modalities.identity_bottom,
}
hparams.top = {
"targets": modalities.identity_top,
}
hparams.weight_decay = 3.0
hparams.learning_rate = 0.05
hparams.kl_warmup_steps = 5000
hparams.learning_rate_warmup_steps = 3000
hparams.add_hparam("vocab_size", 66) # Vocabulary size, need to set here.
hparams.add_hparam("cycle_loss_multiplier1", 10.0)
hparams.add_hparam("cycle_loss_multiplier2", 10.0)
return hparams
|
python
|
def cycle_gan_small():
"""Set of hyperparameters."""
hparams = transformer_vae.transformer_ae_small()
hparams.batch_size = 2048
hparams.bottom = {
"inputs": modalities.identity_bottom,
"targets": modalities.identity_bottom,
}
hparams.top = {
"targets": modalities.identity_top,
}
hparams.weight_decay = 3.0
hparams.learning_rate = 0.05
hparams.kl_warmup_steps = 5000
hparams.learning_rate_warmup_steps = 3000
hparams.add_hparam("vocab_size", 66) # Vocabulary size, need to set here.
hparams.add_hparam("cycle_loss_multiplier1", 10.0)
hparams.add_hparam("cycle_loss_multiplier2", 10.0)
return hparams
|
[
"def",
"cycle_gan_small",
"(",
")",
":",
"hparams",
"=",
"transformer_vae",
".",
"transformer_ae_small",
"(",
")",
"hparams",
".",
"batch_size",
"=",
"2048",
"hparams",
".",
"bottom",
"=",
"{",
"\"inputs\"",
":",
"modalities",
".",
"identity_bottom",
",",
"\"targets\"",
":",
"modalities",
".",
"identity_bottom",
",",
"}",
"hparams",
".",
"top",
"=",
"{",
"\"targets\"",
":",
"modalities",
".",
"identity_top",
",",
"}",
"hparams",
".",
"weight_decay",
"=",
"3.0",
"hparams",
".",
"learning_rate",
"=",
"0.05",
"hparams",
".",
"kl_warmup_steps",
"=",
"5000",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"3000",
"hparams",
".",
"add_hparam",
"(",
"\"vocab_size\"",
",",
"66",
")",
"# Vocabulary size, need to set here.",
"hparams",
".",
"add_hparam",
"(",
"\"cycle_loss_multiplier1\"",
",",
"10.0",
")",
"hparams",
".",
"add_hparam",
"(",
"\"cycle_loss_multiplier2\"",
",",
"10.0",
")",
"return",
"hparams"
] |
Set of hyperparameters.
|
[
"Set",
"of",
"hyperparameters",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/research/cycle_gan.py#L126-L144
|
train
|
Set of hyperparameters for training on - the - fly.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYK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qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + chr(0b11010 + 0o125) + chr(49) + chr(0b110010) + chr(0b110110 + 0o0), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x33' + chr(0b1000 + 0o55) + '\065', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b110010 + 0o75) + chr(825 - 775) + '\066' + chr(53), 22786 - 22778), ehT0Px3KOsy9('\x30' + chr(111) + chr(930 - 881) + chr(51) + chr(606 - 556), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(1661 - 1612) + chr(368 - 318) + '\060', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110111) + '\x35', 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\063', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\x31' + chr(0b10111 + 0o31), ord("\x08")), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(111) + chr(55) + chr(0b100111 + 0o13), 17187 - 17179), ehT0Px3KOsy9(chr(540 - 492) + chr(0b11011 + 0o124) + chr(0b100010 + 0o20) + '\x31' + chr(0b110000), 0b1000), ehT0Px3KOsy9(chr(1941 - 1893) + chr(0b1000011 + 0o54) + chr(51) + chr(0b100110 + 0o13) + chr(55), 19376 - 19368), ehT0Px3KOsy9(chr(74 - 26) + chr(111) + chr(0b110011) + '\061' + '\063', 0o10), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(111) + '\x33' + chr(1172 - 1120) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110010) + '\x32', 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(50) + '\x37' + chr(2089 - 2038), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\x33' + chr(471 - 421) + '\067', 0b1000), ehT0Px3KOsy9('\x30' + chr(1863 - 1752) + chr(1629 - 1575) + chr(333 - 283), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1100010 + 0o15) + chr(51) + chr(2111 - 2063), 0b1000), ehT0Px3KOsy9(chr(0b10101 + 0o33) + '\157' + '\063' + chr(0b110100) + chr(0b110101), 26677 - 26669), ehT0Px3KOsy9(chr(156 - 108) + chr(0b1101111) + '\061' + '\x34' + chr(826 - 777), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(3458 - 3347) + chr(2451 - 2401) + chr(55) + '\062', 31680 - 31672), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(2228 - 2178) + chr(0b110110 + 0o1) + chr(0b110001), 42447 - 42439), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110010) + chr(0b110100) + '\065', 0o10), ehT0Px3KOsy9(chr(1162 - 1114) + chr(0b1101111) + chr(0b101000 + 0o13) + '\x37' + '\065', 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110011) + chr(0b1101 + 0o45) + chr(0b110110), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\x31' + chr(0b110011 + 0o3) + chr(0b1110 + 0o51), 0o10), ehT0Px3KOsy9(chr(0b11100 + 0o24) + chr(0b111 + 0o150) + chr(0b10110 + 0o35) + chr(0b110101), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110011) + '\062' + '\067', 8), ehT0Px3KOsy9('\x30' + '\x6f' + chr(50) + chr(0b110100) + chr(0b10101 + 0o40), 8), ehT0Px3KOsy9('\060' + chr(9813 - 9702) + chr(54) + chr(0b1010 + 0o50), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(50) + chr(49) + chr(0b110101), 62479 - 62471), ehT0Px3KOsy9(chr(1140 - 1092) + chr(1419 - 1308) + chr(49) + chr(0b10000 + 0o45), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(1760 - 1710) + chr(0b100111 + 0o14) + '\x32', 2877 - 2869), ehT0Px3KOsy9(chr(1609 - 1561) + chr(0b1101111) + chr(1129 - 1079) + chr(0b1101 + 0o43) + chr(0b0 + 0o67), 48262 - 48254), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b111 + 0o53) + chr(0b110011) + chr(0b110010), 8), ehT0Px3KOsy9('\060' + chr(0b101000 + 0o107) + chr(1252 - 1200) + chr(0b101 + 0o54), 1259 - 1251), ehT0Px3KOsy9(chr(2099 - 2051) + chr(0b110001 + 0o76) + chr(443 - 394) + chr(55) + chr(0b110101), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b100010 + 0o20) + chr(0b110111) + '\064', 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\061' + chr(491 - 439) + chr(0b110101), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(1667 - 1619) + chr(0b1101111) + chr(53) + chr(48), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'x'), chr(100) + '\x65' + '\x63' + '\x6f' + chr(100) + '\145')('\165' + chr(7074 - 6958) + chr(9461 - 9359) + chr(0b100111 + 0o6) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def z1cQC4UW_krA():
n4ljua2gi1Pr = I4pwnXTtSrtH.transformer_ae_small()
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\x30' + '\157' + '\x34' + chr(0b110000) + chr(1575 - 1527) + '\x30', 0b1000)
n4ljua2gi1Pr.kXxsZxlIQUSQ = {xafqLlk3kkUe(SXOLrMavuUCe(b'?\x83\xc5/$N'), chr(6572 - 6472) + chr(101) + chr(0b1100011) + chr(111) + chr(100) + chr(101))('\165' + '\x74' + '\x66' + '\x2d' + chr(0b111000)): PuPeNl0CuqOQ.identity_bottom, xafqLlk3kkUe(SXOLrMavuUCe(b'"\x8c\xc7=5Ip'), '\x64' + chr(101) + '\143' + '\157' + chr(0b1011001 + 0o13) + chr(101))('\x75' + chr(9060 - 8944) + chr(0b1100110) + '\055' + '\070'): PuPeNl0CuqOQ.identity_bottom}
n4ljua2gi1Pr.qxrVBjeryNEZ = {xafqLlk3kkUe(SXOLrMavuUCe(b'"\x8c\xc7=5Ip'), '\144' + chr(2773 - 2672) + chr(99) + chr(111) + chr(0b1100100) + chr(998 - 897))(chr(0b1110101 + 0o0) + chr(0b1110100) + chr(5794 - 5692) + chr(0b11110 + 0o17) + chr(56)): PuPeNl0CuqOQ.identity_top}
n4ljua2gi1Pr.eB4rJl6fUxw9 = 3.0
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.05
n4ljua2gi1Pr.RJDjLTrNm7M6 = ehT0Px3KOsy9(chr(0b11111 + 0o21) + chr(0b1100110 + 0o11) + chr(0b10000 + 0o41) + chr(483 - 434) + '\066' + '\061' + '\060', 0b1000)
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9('\x30' + chr(6082 - 5971) + '\065' + chr(0b11 + 0o63) + chr(2164 - 2109) + chr(0b110000), ord("\x08"))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'7\x89\xd1\x058Mbz[\xe5'), '\144' + chr(3958 - 3857) + '\143' + chr(7681 - 7570) + '\144' + '\x65')(chr(0b1110101) + '\164' + chr(0b1100110) + '\x2d' + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b' \x82\xd6;2bpa@\xed'), '\144' + chr(0b1100101) + chr(99) + '\x6f' + chr(100) + chr(0b1100101))(chr(117) + chr(0b111101 + 0o67) + chr(0b101 + 0o141) + chr(1813 - 1768) + chr(3102 - 3046)), ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(781 - 670) + chr(49) + chr(1398 - 1350) + chr(0b110010), ord("\x08")))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'7\x89\xd1\x058Mbz[\xe5'), chr(0b1011110 + 0o6) + chr(101) + '\143' + chr(111) + chr(3359 - 3259) + chr(714 - 613))(chr(117) + chr(0b10111 + 0o135) + chr(8227 - 8125) + '\x2d' + chr(2046 - 1990)))(xafqLlk3kkUe(SXOLrMavuUCe(b'5\x94\xd665bogI\xfb\x90\xa6\x93~\xcf\xbeBt\x8c\x04\xc8\x88'), chr(0b1010010 + 0o22) + chr(0b110001 + 0o64) + chr(9464 - 9365) + chr(111) + chr(100) + '\x65')(chr(117) + '\x74' + '\146' + chr(0b100001 + 0o14) + chr(0b1001 + 0o57)), 10.0)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'7\x89\xd1\x058Mbz[\xe5'), '\x64' + chr(101) + chr(0b110010 + 0o61) + chr(2541 - 2430) + chr(5973 - 5873) + chr(101))(chr(0b1110101) + '\164' + chr(102) + chr(1563 - 1518) + chr(0b100010 + 0o26)))(xafqLlk3kkUe(SXOLrMavuUCe(b'5\x94\xd665bogI\xfb\x90\xa6\x93~\xcf\xbeBt\x8c\x04\xc8\x8b'), chr(100) + chr(5409 - 5308) + chr(99) + '\157' + chr(0b1 + 0o143) + chr(6258 - 6157))(chr(5486 - 5369) + chr(9003 - 8887) + chr(0b11010 + 0o114) + chr(0b1010 + 0o43) + chr(0b111000)), 10.0)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/video/nfg_interpolate.py
|
decode_hparams
|
def decode_hparams(overrides=""):
"""Hparams for decoding."""
hparams = decoding.decode_hparams()
# Number of interpolations between [0.0, 1.0].
hparams.add_hparam("num_interp", 11)
# Which level(s) to interpolate.
hparams.add_hparam("level_interp", [0, 1, 2])
# "all" or "ranked", interpolate all channels or a "ranked".
hparams.add_hparam("channel_interp", "all")
# interpolate channels ranked according to squared L2 norm.
hparams.add_hparam("rank_interp", 1)
# Whether on not to save frames as summaries
hparams.add_hparam("save_frames", True)
hparams.parse(overrides)
return hparams
|
python
|
def decode_hparams(overrides=""):
"""Hparams for decoding."""
hparams = decoding.decode_hparams()
# Number of interpolations between [0.0, 1.0].
hparams.add_hparam("num_interp", 11)
# Which level(s) to interpolate.
hparams.add_hparam("level_interp", [0, 1, 2])
# "all" or "ranked", interpolate all channels or a "ranked".
hparams.add_hparam("channel_interp", "all")
# interpolate channels ranked according to squared L2 norm.
hparams.add_hparam("rank_interp", 1)
# Whether on not to save frames as summaries
hparams.add_hparam("save_frames", True)
hparams.parse(overrides)
return hparams
|
[
"def",
"decode_hparams",
"(",
"overrides",
"=",
"\"\"",
")",
":",
"hparams",
"=",
"decoding",
".",
"decode_hparams",
"(",
")",
"# Number of interpolations between [0.0, 1.0].",
"hparams",
".",
"add_hparam",
"(",
"\"num_interp\"",
",",
"11",
")",
"# Which level(s) to interpolate.",
"hparams",
".",
"add_hparam",
"(",
"\"level_interp\"",
",",
"[",
"0",
",",
"1",
",",
"2",
"]",
")",
"# \"all\" or \"ranked\", interpolate all channels or a \"ranked\".",
"hparams",
".",
"add_hparam",
"(",
"\"channel_interp\"",
",",
"\"all\"",
")",
"# interpolate channels ranked according to squared L2 norm.",
"hparams",
".",
"add_hparam",
"(",
"\"rank_interp\"",
",",
"1",
")",
"# Whether on not to save frames as summaries",
"hparams",
".",
"add_hparam",
"(",
"\"save_frames\"",
",",
"True",
")",
"hparams",
".",
"parse",
"(",
"overrides",
")",
"return",
"hparams"
] |
Hparams for decoding.
|
[
"Hparams",
"for",
"decoding",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/video/nfg_interpolate.py#L53-L67
|
train
|
Hparams for decoding.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,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D,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(2018 - 1970) + chr(0b100 + 0o153) + chr(0b110011) + chr(0b110110) + chr(1219 - 1164), 59990 - 59982), ehT0Px3KOsy9(chr(1923 - 1875) + chr(629 - 518) + chr(0b110010) + chr(51) + chr(52), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(1069 - 1018) + chr(0b100001 + 0o17) + chr(49), 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(49) + chr(52) + chr(55), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + '\x31' + '\064' + chr(1930 - 1882), ord("\x08")), ehT0Px3KOsy9(chr(0b10010 + 0o36) + '\157' + chr(0b110001) + chr(49) + chr(55), 0o10), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(111) + chr(1871 - 1822) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1001010 + 0o45) + chr(0b110011) + '\x37' + chr(51), 0o10), ehT0Px3KOsy9(chr(0b11000 + 0o30) + chr(915 - 804) + '\063' + chr(2624 - 2571) + chr(0b110001), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + '\065' + chr(435 - 385), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(4614 - 4503) + '\062' + chr(52), 12063 - 12055), ehT0Px3KOsy9(chr(1525 - 1477) + chr(0b10111 + 0o130) + '\x33', 49956 - 49948), ehT0Px3KOsy9('\x30' + chr(0b1100111 + 0o10) + '\x37' + '\062', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(10618 - 10507) + '\063' + '\061' + chr(376 - 328), 0b1000), ehT0Px3KOsy9(chr(1219 - 1171) + '\157' + chr(364 - 314) + chr(0b110001) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(1436 - 1388) + chr(111) + chr(0b110010) + '\066' + chr(0b111 + 0o56), 0b1000), ehT0Px3KOsy9('\x30' + chr(10932 - 10821) + '\x36' + chr(53), 64127 - 64119), ehT0Px3KOsy9('\060' + '\x6f' + chr(1916 - 1867) + chr(0b110000) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1011111 + 0o20) + chr(0b111 + 0o52) + chr(50) + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(647 - 599) + chr(0b1101111) + '\061' + chr(0b110001) + chr(0b110000), 0b1000), ehT0Px3KOsy9('\060' + chr(8052 - 7941) + chr(139 - 88) + chr(1798 - 1746) + chr(0b101100 + 0o6), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\063' + chr(2081 - 2028) + chr(930 - 880), 10058 - 10050), ehT0Px3KOsy9('\x30' + '\x6f' + '\x31' + chr(0b11 + 0o64) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(54) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(1488 - 1440) + chr(0b1100010 + 0o15) + chr(0b110101) + '\x33', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1000 + 0o147) + chr(50) + '\064' + '\064', 7862 - 7854), ehT0Px3KOsy9(chr(0b10111 + 0o31) + chr(0b1101111) + '\063' + chr(52) + '\x37', 0o10), ehT0Px3KOsy9(chr(949 - 901) + '\x6f' + chr(0b1110 + 0o43) + chr(2229 - 2179) + chr(49), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b101000 + 0o107) + '\x33' + chr(54) + chr(0b11 + 0o56), 0b1000), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(0b1101111) + chr(0b110001) + chr(0b110101) + chr(0b11101 + 0o26), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(50) + chr(0b11101 + 0o30) + '\066', 0o10), ehT0Px3KOsy9(chr(0b1001 + 0o47) + '\157' + '\x32' + chr(0b110100) + '\x34', 8), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(870 - 820) + '\x35' + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(1914 - 1866) + chr(0b1100001 + 0o16) + chr(1826 - 1776) + chr(0b110011) + chr(0b110001), 433 - 425), ehT0Px3KOsy9(chr(1063 - 1015) + chr(5129 - 5018) + chr(0b110011) + '\x33' + chr(517 - 465), 0b1000), ehT0Px3KOsy9(chr(1029 - 981) + chr(0b1100001 + 0o16) + chr(0b110010) + '\061' + chr(55), ord("\x08")), ehT0Px3KOsy9(chr(1883 - 1835) + chr(0b1101111) + chr(603 - 552) + chr(54) + chr(51), 6253 - 6245), ehT0Px3KOsy9(chr(48) + chr(111) + chr(50) + chr(54) + '\066', 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(306 - 255) + chr(646 - 593) + '\065', 3186 - 3178), ehT0Px3KOsy9(chr(0b110000) + chr(5812 - 5701) + chr(0b10100 + 0o35) + '\x36' + chr(985 - 935), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(10380 - 10269) + chr(0b100 + 0o61) + chr(0b110000), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xd9'), '\144' + '\145' + chr(1314 - 1215) + chr(0b1101111) + chr(0b1001110 + 0o26) + chr(101))(chr(418 - 301) + chr(116) + chr(102) + chr(0b101101) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def LrQSWg3uwmK8(de6iQhrbBQ5Y=xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(0b111 + 0o135) + chr(8988 - 8887) + chr(99) + chr(3957 - 3846) + chr(0b1100100) + chr(0b100011 + 0o102))(chr(117) + chr(1588 - 1472) + '\x66' + chr(0b1 + 0o54) + chr(0b1110 + 0o52))):
n4ljua2gi1Pr = jyVHS0IYLm_8.decode_hparams()
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x96\xf8\xa58\x08?k\x89\x88G'), chr(1545 - 1445) + '\x65' + chr(8649 - 8550) + chr(5822 - 5711) + '\144' + chr(6359 - 6258))(chr(0b1011101 + 0o30) + '\164' + chr(0b1100110) + '\055' + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x99\xe9\xac8\t!~\x9e\x9bZ'), chr(0b1100100) + chr(0b100101 + 0o100) + chr(1221 - 1122) + chr(1126 - 1015) + chr(0b1100100) + '\145')(chr(0b111010 + 0o73) + chr(0b110000 + 0o104) + '\x66' + chr(0b11111 + 0o16) + chr(0b111000)), ehT0Px3KOsy9(chr(0b110000) + chr(7020 - 6909) + chr(975 - 926) + chr(0b110011), 0o10))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x96\xf8\xa58\x08?k\x89\x88G'), '\144' + chr(101) + chr(0b1100011) + chr(0b111101 + 0o62) + chr(100) + '\x65')(chr(0b101001 + 0o114) + chr(11546 - 11430) + chr(0b110100 + 0o62) + '\055' + chr(0b100010 + 0o26)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x9b\xf9\xb7\x02\x0c\x10c\x95\x9dOfs'), chr(0b1100100) + chr(101) + chr(0b1001010 + 0o31) + '\x6f' + chr(0b10000 + 0o124) + chr(8132 - 8031))('\x75' + chr(116) + '\x66' + chr(276 - 231) + chr(0b111000)), [ehT0Px3KOsy9(chr(1726 - 1678) + '\157' + chr(0b110000), 23208 - 23200), ehT0Px3KOsy9(chr(0b101011 + 0o5) + chr(111) + chr(49), 5885 - 5877), ehT0Px3KOsy9('\060' + chr(1171 - 1060) + chr(1123 - 1073), 0o10)])
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x96\xf8\xa58\x08?k\x89\x88G'), chr(6124 - 6024) + '\145' + '\x63' + '\x6f' + '\x64' + '\145')(chr(117) + chr(10153 - 10037) + chr(102) + '\055' + chr(0b100100 + 0o24)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x94\xf4\xa0\t\x0e*f\xa4\x80D`fH\xb8'), chr(6145 - 6045) + '\x65' + chr(0b11100 + 0o107) + chr(0b11111 + 0o120) + chr(0b1100100) + chr(0b1000001 + 0o44))(chr(0b1011000 + 0o35) + '\x74' + chr(303 - 201) + chr(45) + chr(56)), xafqLlk3kkUe(SXOLrMavuUCe(b'\x96\xf0\xad'), '\x64' + chr(101) + chr(0b1100011) + chr(111) + chr(100) + '\145')('\x75' + chr(2471 - 2355) + '\146' + chr(1110 - 1065) + '\070'))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x96\xf8\xa58\x08?k\x89\x88G'), chr(0b1100100) + chr(101) + chr(0b1001000 + 0o33) + chr(0b111 + 0o150) + chr(9652 - 9552) + chr(0b1010 + 0o133))(chr(0b1000110 + 0o57) + chr(3308 - 3192) + chr(8429 - 8327) + '\x2d' + chr(0b1111 + 0o51)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x85\xfd\xaf\x0c?&d\x8f\x8cXd'), chr(100) + chr(0b110111 + 0o56) + '\x63' + '\157' + '\144' + chr(0b1000001 + 0o44))(chr(117) + chr(0b1110100) + '\146' + '\x2d' + '\x38'), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x31', 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x96\xf8\xa58\x08?k\x89\x88G'), '\x64' + chr(0b1001001 + 0o34) + chr(0b1100011) + chr(111) + '\x64' + chr(0b1010101 + 0o20))(chr(2314 - 2197) + chr(116) + '\146' + chr(45) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x84\xfd\xb7\x02?)x\x9a\x84Og'), '\x64' + chr(0b1100101) + '\143' + chr(111) + chr(4259 - 4159) + chr(0b1100101))(chr(0b1110101) + chr(116) + chr(4745 - 4643) + chr(0b101100 + 0o1) + chr(56)), ehT0Px3KOsy9(chr(48) + chr(313 - 202) + '\x31', 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x87\xfd\xb3\x14\x05'), chr(8457 - 8357) + chr(7425 - 7324) + chr(0b1100011) + '\157' + '\x64' + chr(0b1100101))(chr(4906 - 4789) + chr(0b1011010 + 0o32) + chr(0b1100110) + chr(45) + chr(0b11111 + 0o31)))(de6iQhrbBQ5Y)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/video/nfg_interpolate.py
|
preprocess_frame
|
def preprocess_frame(frame):
"""Preprocess frame.
1. Converts [0, 255] to [-0.5, 0.5]
2. Adds uniform noise.
Args:
frame: 3-D Tensor representing pixels.
Returns:
frame: 3-D Tensor with values in between [-0.5, 0.5]
"""
# Normalize from [0.0, 1.0] -> [-0.5, 0.5]
frame = common_layers.convert_rgb_to_real(frame)
frame = frame - 0.5
frame, _ = glow_ops.uniform_binning_correction(frame)
return frame
|
python
|
def preprocess_frame(frame):
"""Preprocess frame.
1. Converts [0, 255] to [-0.5, 0.5]
2. Adds uniform noise.
Args:
frame: 3-D Tensor representing pixels.
Returns:
frame: 3-D Tensor with values in between [-0.5, 0.5]
"""
# Normalize from [0.0, 1.0] -> [-0.5, 0.5]
frame = common_layers.convert_rgb_to_real(frame)
frame = frame - 0.5
frame, _ = glow_ops.uniform_binning_correction(frame)
return frame
|
[
"def",
"preprocess_frame",
"(",
"frame",
")",
":",
"# Normalize from [0.0, 1.0] -> [-0.5, 0.5]",
"frame",
"=",
"common_layers",
".",
"convert_rgb_to_real",
"(",
"frame",
")",
"frame",
"=",
"frame",
"-",
"0.5",
"frame",
",",
"_",
"=",
"glow_ops",
".",
"uniform_binning_correction",
"(",
"frame",
")",
"return",
"frame"
] |
Preprocess frame.
1. Converts [0, 255] to [-0.5, 0.5]
2. Adds uniform noise.
Args:
frame: 3-D Tensor representing pixels.
Returns:
frame: 3-D Tensor with values in between [-0.5, 0.5]
|
[
"Preprocess",
"frame",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/video/nfg_interpolate.py#L70-L85
|
train
|
Preprocess frame.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfx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EDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(0b10010 + 0o135) + '\x32' + chr(54) + chr(0b101011 + 0o10), 0o10), ehT0Px3KOsy9(chr(1105 - 1057) + chr(111) + chr(0b10 + 0o61) + chr(0b110011) + '\067', 30851 - 30843), ehT0Px3KOsy9(chr(0b101001 + 0o7) + chr(0b1101111) + chr(0b110011), 0o10), ehT0Px3KOsy9(chr(0b0 + 0o60) + '\x6f' + chr(0b11101 + 0o24) + chr(0b110100) + chr(52), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + '\x33' + '\x36' + '\x34', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x31' + chr(0b110010) + chr(0b110110), 3950 - 3942), ehT0Px3KOsy9(chr(48) + chr(0b11011 + 0o124) + '\062' + '\065' + '\063', 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b1111 + 0o42) + '\060' + '\067', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b101011 + 0o6) + chr(250 - 201), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(49) + '\066' + '\x34', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110001) + chr(2220 - 2165) + '\063', 0b1000), ehT0Px3KOsy9(chr(48) + chr(10373 - 10262) + chr(1823 - 1770) + chr(0b11101 + 0o24), 0o10), ehT0Px3KOsy9('\x30' + '\157' + '\064', 26639 - 26631), ehT0Px3KOsy9(chr(0b101011 + 0o5) + chr(0b1110 + 0o141) + chr(49) + chr(0b110001 + 0o0) + '\x34', 52212 - 52204), ehT0Px3KOsy9(chr(403 - 355) + chr(0b101101 + 0o102) + chr(50) + '\063' + '\061', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(50) + chr(0b110111) + '\x30', 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110000 + 0o2) + '\064' + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110001) + '\x31' + '\x31', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(49) + chr(0b100101 + 0o17) + chr(0b100 + 0o63), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(52) + chr(0b100010 + 0o24), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(1951 - 1902) + '\063' + '\061', 49361 - 49353), ehT0Px3KOsy9('\060' + chr(111) + chr(2283 - 2233) + chr(0b110011) + chr(0b110010 + 0o4), ord("\x08")), ehT0Px3KOsy9(chr(0b1011 + 0o45) + '\157' + chr(50) + '\063' + '\064', 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b1111 + 0o44) + chr(49) + chr(52), 15258 - 15250), ehT0Px3KOsy9('\060' + chr(0b111011 + 0o64) + '\064' + '\067', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(55) + '\063', 0b1000), ehT0Px3KOsy9(chr(0b10111 + 0o31) + chr(0b1011110 + 0o21) + chr(51) + chr(1719 - 1669), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(586 - 536) + chr(0b110110) + chr(51), 8), ehT0Px3KOsy9(chr(1237 - 1189) + chr(111) + chr(0b110010) + '\x30' + chr(0b110100), 51011 - 51003), ehT0Px3KOsy9(chr(234 - 186) + '\157' + chr(0b11001 + 0o30) + chr(0b110100) + chr(388 - 338), 0b1000), ehT0Px3KOsy9(chr(1870 - 1822) + '\x6f' + chr(51) + '\062' + '\062', 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(482 - 432) + '\x34' + chr(53), 0o10), ehT0Px3KOsy9(chr(2174 - 2126) + '\157' + chr(1824 - 1773) + chr(0b110101) + '\x32', 0b1000), ehT0Px3KOsy9(chr(2071 - 2023) + chr(111) + chr(256 - 206) + '\064', ord("\x08")), ehT0Px3KOsy9(chr(1148 - 1100) + '\157' + chr(49) + '\061' + chr(0b110111), 23671 - 23663), ehT0Px3KOsy9('\x30' + chr(1377 - 1266) + '\063' + chr(0b110010) + chr(0b1110 + 0o42), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b110101 + 0o72) + chr(0b11110 + 0o26) + chr(0b10010 + 0o37), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\063' + '\x36' + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(1579 - 1531) + '\157' + chr(397 - 347) + chr(50) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b10101 + 0o34) + chr(2516 - 2465) + '\x32', ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110101 + 0o0) + '\x30', 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x9d'), '\x64' + chr(0b110100 + 0o61) + chr(99) + '\157' + chr(9592 - 9492) + chr(101))('\x75' + chr(116) + chr(8374 - 8272) + '\x2d' + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def QnTmibuviXq4(C4IqNNmLfHXB):
C4IqNNmLfHXB = jSKPaHwSAfVv.convert_rgb_to_real(C4IqNNmLfHXB)
C4IqNNmLfHXB = C4IqNNmLfHXB - 0.5
(C4IqNNmLfHXB, VNGQdHSFPrso) = RVYZnhb7AvdJ.uniform_binning_correction(C4IqNNmLfHXB)
return C4IqNNmLfHXB
|
tensorflow/tensor2tensor
|
tensor2tensor/models/video/nfg_interpolate.py
|
frame_to_latents
|
def frame_to_latents(frame, hparams):
"""Encode frames to latents."""
# Preprocess
frame = preprocess_frame(frame)
# Encode [X_t] to [z^1_t, z^2_t .. z^l_t]
glow_vals = glow_ops.encoder_decoder(
"codec", frame, hparams, eps=None, reverse=False)
z_top, _, level_eps, _, _ = glow_vals
return z_top, level_eps
|
python
|
def frame_to_latents(frame, hparams):
"""Encode frames to latents."""
# Preprocess
frame = preprocess_frame(frame)
# Encode [X_t] to [z^1_t, z^2_t .. z^l_t]
glow_vals = glow_ops.encoder_decoder(
"codec", frame, hparams, eps=None, reverse=False)
z_top, _, level_eps, _, _ = glow_vals
return z_top, level_eps
|
[
"def",
"frame_to_latents",
"(",
"frame",
",",
"hparams",
")",
":",
"# Preprocess",
"frame",
"=",
"preprocess_frame",
"(",
"frame",
")",
"# Encode [X_t] to [z^1_t, z^2_t .. z^l_t]",
"glow_vals",
"=",
"glow_ops",
".",
"encoder_decoder",
"(",
"\"codec\"",
",",
"frame",
",",
"hparams",
",",
"eps",
"=",
"None",
",",
"reverse",
"=",
"False",
")",
"z_top",
",",
"_",
",",
"level_eps",
",",
"_",
",",
"_",
"=",
"glow_vals",
"return",
"z_top",
",",
"level_eps"
] |
Encode frames to latents.
|
[
"Encode",
"frames",
"to",
"latents",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d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ByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + chr(111) + chr(50) + chr(54), 0b1000), ehT0Px3KOsy9(chr(983 - 935) + chr(111) + chr(1970 - 1919) + chr(0b110110) + '\x32', ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(50) + chr(0b10110 + 0o41) + chr(972 - 920), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(10735 - 10624) + chr(51) + '\064' + '\065', 32721 - 32713), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1868 - 1818) + chr(0b110101) + chr(0b110001), 231 - 223), ehT0Px3KOsy9('\060' + chr(8010 - 7899) + '\x31' + '\x33' + chr(0b110110), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1207 - 1156) + chr(2273 - 2222) + '\x33', 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\062' + chr(0b110001), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110011) + chr(2315 - 2262) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(2107 - 1996) + '\x37' + '\062', 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110001) + chr(50) + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\062' + chr(54) + '\065', 0b1000), ehT0Px3KOsy9(chr(0b11 + 0o55) + '\x6f' + chr(49) + '\x36' + chr(1129 - 1076), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(50) + chr(50), 0b1000), ehT0Px3KOsy9(chr(0b101 + 0o53) + '\x6f' + '\x32' + chr(49) + chr(0b110110), 0b1000), ehT0Px3KOsy9('\060' + '\157' + '\x32' + chr(0b10010 + 0o36) + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(0b111 + 0o51) + chr(111) + chr(49) + chr(48), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1010000 + 0o37) + chr(51) + '\x32', 0b1000), ehT0Px3KOsy9(chr(501 - 453) + chr(0b1011101 + 0o22) + chr(0b100101 + 0o15) + chr(0b1111 + 0o46) + '\x37', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1000101 + 0o52) + '\x33' + '\x30' + chr(52), 25838 - 25830), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x33' + '\x36' + chr(50), 8), ehT0Px3KOsy9('\x30' + chr(111) + chr(2283 - 2234) + chr(52) + '\064', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110011) + chr(991 - 937) + chr(295 - 244), ord("\x08")), ehT0Px3KOsy9(chr(1252 - 1204) + chr(111) + '\x31' + chr(1469 - 1420) + '\062', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x33' + '\067' + chr(0b110100), ord("\x08")), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b1000101 + 0o52) + chr(2346 - 2295) + chr(0b110101) + chr(0b110010), 0o10), ehT0Px3KOsy9(chr(1706 - 1658) + chr(0b1000111 + 0o50) + chr(0b110010 + 0o0) + chr(51) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x35' + chr(810 - 757), 0b1000), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(0b1111 + 0o140) + chr(51) + chr(0b1001 + 0o54) + '\x35', 0b1000), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(0b110111 + 0o70) + chr(52) + chr(51), 47196 - 47188), ehT0Px3KOsy9('\060' + chr(0b11110 + 0o121) + '\063' + chr(0b110101) + chr(1137 - 1082), 0b1000), ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(111) + chr(0b1010 + 0o51) + '\060', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b10010 + 0o135) + chr(1734 - 1683) + '\066' + chr(784 - 736), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(50) + chr(1752 - 1698) + chr(0b1100 + 0o46), 0o10), ehT0Px3KOsy9(chr(1414 - 1366) + '\x6f' + '\063' + '\x37' + chr(832 - 781), 52419 - 52411), ehT0Px3KOsy9(chr(1682 - 1634) + '\x6f' + chr(49) + chr(2551 - 2499) + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(664 - 616) + chr(111) + chr(0b11101 + 0o25) + chr(293 - 244) + chr(0b1001 + 0o47), 64484 - 64476), ehT0Px3KOsy9('\x30' + chr(0b100111 + 0o110) + chr(0b11 + 0o57) + chr(0b110101) + '\066', 53572 - 53564), ehT0Px3KOsy9(chr(48) + '\157' + chr(51) + chr(0b101010 + 0o6) + chr(0b110001), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + '\x33' + chr(1745 - 1696) + chr(0b101110 + 0o10), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(1663 - 1552) + chr(53) + '\060', 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'8'), chr(8252 - 8152) + '\x65' + chr(0b1100011) + chr(9985 - 9874) + chr(484 - 384) + chr(7035 - 6934))(chr(0b1110101) + '\164' + '\x66' + chr(45) + chr(0b11101 + 0o33)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def xCmT3Fu4L4nb(C4IqNNmLfHXB, n4ljua2gi1Pr):
C4IqNNmLfHXB = QnTmibuviXq4(C4IqNNmLfHXB)
VYorOy3j276V = RVYZnhb7AvdJ.encoder_decoder(xafqLlk3kkUe(SXOLrMavuUCe(b'u\x9d\xd8\x80\xca'), chr(0b1100100) + chr(0b1100100 + 0o1) + '\x63' + chr(111) + '\144' + chr(2773 - 2672))(chr(0b1001111 + 0o46) + chr(0b1001001 + 0o53) + '\146' + chr(0b10101 + 0o30) + '\070'), C4IqNNmLfHXB, n4ljua2gi1Pr, eps=None, reverse=ehT0Px3KOsy9(chr(0b101101 + 0o3) + '\x6f' + chr(48), 0b1000))
(ck5Xa8xiXirS, VNGQdHSFPrso, xPwEhwkiKVjL, VNGQdHSFPrso, VNGQdHSFPrso) = VYorOy3j276V
return (ck5Xa8xiXirS, xPwEhwkiKVjL)
|
tensorflow/tensor2tensor
|
tensor2tensor/models/video/nfg_interpolate.py
|
latents_to_frames
|
def latents_to_frames(z_top_interp, level_eps_interp, hparams):
"""Decodes latents to frames."""
# Decode [z^1_t, z^2_t .. z^l_t] to [X_t]
images, _, _, _ = glow_ops.encoder_decoder(
"codec", z_top_interp, hparams, eps=level_eps_interp, reverse=True)
images = glow_ops.postprocess(images)
return images
|
python
|
def latents_to_frames(z_top_interp, level_eps_interp, hparams):
"""Decodes latents to frames."""
# Decode [z^1_t, z^2_t .. z^l_t] to [X_t]
images, _, _, _ = glow_ops.encoder_decoder(
"codec", z_top_interp, hparams, eps=level_eps_interp, reverse=True)
images = glow_ops.postprocess(images)
return images
|
[
"def",
"latents_to_frames",
"(",
"z_top_interp",
",",
"level_eps_interp",
",",
"hparams",
")",
":",
"# Decode [z^1_t, z^2_t .. z^l_t] to [X_t]",
"images",
",",
"_",
",",
"_",
",",
"_",
"=",
"glow_ops",
".",
"encoder_decoder",
"(",
"\"codec\"",
",",
"z_top_interp",
",",
"hparams",
",",
"eps",
"=",
"level_eps_interp",
",",
"reverse",
"=",
"True",
")",
"images",
"=",
"glow_ops",
".",
"postprocess",
"(",
"images",
")",
"return",
"images"
] |
Decodes latents to frames.
|
[
"Decodes",
"latents",
"to",
"frames",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/video/nfg_interpolate.py#L100-L106
|
train
|
Decodes latents to frames.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU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zcVJsrp8,tzcpInYwBvYW,iDQ_gSK8V7h0,Rurm1zTRfSmY,reqGiMiVQ77y,bsS9P6_LpdIe,sbGAZlkZOtyh,Cf_Qef15s3_F,eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + chr(111) + '\062' + '\x34', 57986 - 57978), ehT0Px3KOsy9('\060' + chr(11804 - 11693) + chr(0b110101) + chr(0b110111), 0b1000), ehT0Px3KOsy9(chr(0b1111 + 0o41) + chr(0b1101111) + chr(2491 - 2436) + chr(0b110100), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x36' + chr(51), 0b1000), ehT0Px3KOsy9(chr(302 - 254) + '\x6f' + '\x36' + chr(325 - 270), 52024 - 52016), ehT0Px3KOsy9(chr(0b100 + 0o54) + '\x6f' + chr(0b110001) + chr(0b100001 + 0o26) + '\065', 0o10), ehT0Px3KOsy9(chr(1334 - 1286) + '\x6f' + chr(54) + chr(53), 0b1000), ehT0Px3KOsy9('\060' + chr(0b10101 + 0o132) + '\062' + chr(54) + chr(50), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110011) + chr(1912 - 1863) + chr(0b110111), 0b1000), ehT0Px3KOsy9('\060' + chr(11354 - 11243) + '\061' + chr(51) + chr(245 - 196), 0o10), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(5569 - 5458) + chr(50) + chr(52) + '\x30', 0o10), ehT0Px3KOsy9('\060' + '\157' + '\x32' + chr(0b110001 + 0o4) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(127 - 79) + '\x6f' + chr(352 - 303) + '\065', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(9591 - 9480) + '\061' + chr(51) + chr(50), ord("\x08")), ehT0Px3KOsy9('\060' + chr(5615 - 5504) + chr(0b10001 + 0o40) + chr(0b10 + 0o63) + chr(0b100111 + 0o11), 0o10), ehT0Px3KOsy9(chr(1741 - 1693) + chr(0b1000011 + 0o54) + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(51) + chr(885 - 837), 32684 - 32676), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110001 + 0o1) + chr(0b1001 + 0o47), 0b1000), ehT0Px3KOsy9(chr(1202 - 1154) + '\157' + chr(0b110010) + chr(49) + chr(0b110101), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\063' + chr(53), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b10111 + 0o130) + chr(2063 - 2013) + chr(48) + chr(51), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(50) + chr(2357 - 2307) + chr(0b11000 + 0o33), 36010 - 36002), ehT0Px3KOsy9('\060' + chr(0b11010 + 0o125) + chr(0b110011) + chr(0b110010) + '\067', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x34' + '\066', 0o10), ehT0Px3KOsy9(chr(1612 - 1564) + chr(111) + chr(0b100110 + 0o14) + chr(0b0 + 0o65) + '\060', 8), ehT0Px3KOsy9('\060' + chr(111) + chr(280 - 230) + chr(0b110001) + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x31' + chr(49) + chr(51), 0o10), ehT0Px3KOsy9(chr(75 - 27) + chr(111) + chr(465 - 416) + '\x33' + chr(1057 - 1007), 8), ehT0Px3KOsy9('\x30' + chr(0b1101101 + 0o2) + '\x31' + chr(0b110001) + chr(0b110100), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(1017 - 968) + chr(2180 - 2131) + '\063', 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110011) + chr(0b110001 + 0o3) + '\061', 0b1000), ehT0Px3KOsy9(chr(48) + chr(4912 - 4801) + chr(0b110010) + chr(55) + chr(372 - 321), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110010) + chr(1301 - 1252) + chr(52), 65031 - 65023), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110010) + chr(0b11100 + 0o27) + '\x32', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1011110 + 0o21) + chr(50) + chr(51) + '\x37', 0o10), ehT0Px3KOsy9(chr(0b11000 + 0o30) + chr(111) + chr(51) + chr(0b110000) + '\066', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(49) + chr(1752 - 1698) + '\x33', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110100) + chr(1953 - 1900), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1000110 + 0o51) + chr(50) + '\x36' + chr(49), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x32' + chr(55) + '\067', 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(0b1010110 + 0o31) + '\x35' + chr(0b110000), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b':'), '\144' + chr(0b1100101) + chr(5666 - 5567) + chr(4174 - 4063) + '\x64' + '\145')('\165' + chr(2376 - 2260) + chr(0b1100110) + chr(1919 - 1874) + chr(0b11100 + 0o34)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def _bYfW2s32LHI(i4nbYCiNa3yl, z6yKZVBJIVDl, n4ljua2gi1Pr):
(YJOmEcibG8C0, VNGQdHSFPrso, VNGQdHSFPrso, VNGQdHSFPrso) = RVYZnhb7AvdJ.encoder_decoder(xafqLlk3kkUe(SXOLrMavuUCe(b'w@XVT'), chr(0b10000 + 0o124) + '\145' + chr(4916 - 4817) + '\x6f' + chr(4471 - 4371) + chr(6083 - 5982))('\x75' + chr(3391 - 3275) + chr(0b100010 + 0o104) + chr(0b110 + 0o47) + chr(56)), i4nbYCiNa3yl, n4ljua2gi1Pr, eps=z6yKZVBJIVDl, reverse=ehT0Px3KOsy9(chr(48) + chr(111) + chr(1011 - 962), 0b1000))
YJOmEcibG8C0 = RVYZnhb7AvdJ.postprocess(YJOmEcibG8C0)
return YJOmEcibG8C0
|
tensorflow/tensor2tensor
|
tensor2tensor/models/video/nfg_interpolate.py
|
interpolate
|
def interpolate(features, hparams, decode_hp):
"""Interpolate between the first input frame and last target frame.
Args:
features: dict of tensors
hparams: HParams, training hparams.
decode_hp: HParams, decode hparams.
Returns:
images: interpolated images, 4-D Tensor, shape=(num_interp, H, W, C)
first_frame: image, 3-D Tensor, shape=(1, H, W, C)
last_frame: image, 3-D Tensor, shape=(1, H, W, C)
"""
inputs, targets = features["inputs"], features["targets"]
inputs = tf.unstack(inputs, axis=1)
targets = tf.unstack(targets, axis=1)
coeffs = np.linspace(0.0, 1.0, decode_hp.num_interp)
# (X_1, X_t) -> (z_1, z_t)
first_frame, last_frame = inputs[0], targets[-1]
first_top_z, first_level_eps = frame_to_latents(first_frame, hparams)
last_top_z, last_level_eps = frame_to_latents(last_frame, hparams)
# Interpolate latents at all levels.
first_lats = first_level_eps + [first_top_z]
last_lats = last_level_eps + [last_top_z]
interp_lats = []
lat_iterator = enumerate(zip(first_lats, last_lats))
for level_ind, (first_lat, last_lat) in lat_iterator:
if level_ind in decode_hp.level_interp:
if decode_hp.channel_interp == "all":
interp_lat = glow_ops.linear_interpolate(first_lat, last_lat, coeffs)
else:
interp_lat = glow_ops.linear_interpolate_rank(
first_lat, last_lat, coeffs, decode_hp.rank_interp)
else:
interp_lat = tf.tile(first_lat, [decode_hp.num_interp, 1, 1, 1])
interp_lats.append(interp_lat)
level_eps_interp = interp_lats[:hparams.n_levels-1]
z_top_interp = interp_lats[-1]
images = latents_to_frames(z_top_interp, level_eps_interp, hparams)
return images, first_frame, last_frame
|
python
|
def interpolate(features, hparams, decode_hp):
"""Interpolate between the first input frame and last target frame.
Args:
features: dict of tensors
hparams: HParams, training hparams.
decode_hp: HParams, decode hparams.
Returns:
images: interpolated images, 4-D Tensor, shape=(num_interp, H, W, C)
first_frame: image, 3-D Tensor, shape=(1, H, W, C)
last_frame: image, 3-D Tensor, shape=(1, H, W, C)
"""
inputs, targets = features["inputs"], features["targets"]
inputs = tf.unstack(inputs, axis=1)
targets = tf.unstack(targets, axis=1)
coeffs = np.linspace(0.0, 1.0, decode_hp.num_interp)
# (X_1, X_t) -> (z_1, z_t)
first_frame, last_frame = inputs[0], targets[-1]
first_top_z, first_level_eps = frame_to_latents(first_frame, hparams)
last_top_z, last_level_eps = frame_to_latents(last_frame, hparams)
# Interpolate latents at all levels.
first_lats = first_level_eps + [first_top_z]
last_lats = last_level_eps + [last_top_z]
interp_lats = []
lat_iterator = enumerate(zip(first_lats, last_lats))
for level_ind, (first_lat, last_lat) in lat_iterator:
if level_ind in decode_hp.level_interp:
if decode_hp.channel_interp == "all":
interp_lat = glow_ops.linear_interpolate(first_lat, last_lat, coeffs)
else:
interp_lat = glow_ops.linear_interpolate_rank(
first_lat, last_lat, coeffs, decode_hp.rank_interp)
else:
interp_lat = tf.tile(first_lat, [decode_hp.num_interp, 1, 1, 1])
interp_lats.append(interp_lat)
level_eps_interp = interp_lats[:hparams.n_levels-1]
z_top_interp = interp_lats[-1]
images = latents_to_frames(z_top_interp, level_eps_interp, hparams)
return images, first_frame, last_frame
|
[
"def",
"interpolate",
"(",
"features",
",",
"hparams",
",",
"decode_hp",
")",
":",
"inputs",
",",
"targets",
"=",
"features",
"[",
"\"inputs\"",
"]",
",",
"features",
"[",
"\"targets\"",
"]",
"inputs",
"=",
"tf",
".",
"unstack",
"(",
"inputs",
",",
"axis",
"=",
"1",
")",
"targets",
"=",
"tf",
".",
"unstack",
"(",
"targets",
",",
"axis",
"=",
"1",
")",
"coeffs",
"=",
"np",
".",
"linspace",
"(",
"0.0",
",",
"1.0",
",",
"decode_hp",
".",
"num_interp",
")",
"# (X_1, X_t) -> (z_1, z_t)",
"first_frame",
",",
"last_frame",
"=",
"inputs",
"[",
"0",
"]",
",",
"targets",
"[",
"-",
"1",
"]",
"first_top_z",
",",
"first_level_eps",
"=",
"frame_to_latents",
"(",
"first_frame",
",",
"hparams",
")",
"last_top_z",
",",
"last_level_eps",
"=",
"frame_to_latents",
"(",
"last_frame",
",",
"hparams",
")",
"# Interpolate latents at all levels.",
"first_lats",
"=",
"first_level_eps",
"+",
"[",
"first_top_z",
"]",
"last_lats",
"=",
"last_level_eps",
"+",
"[",
"last_top_z",
"]",
"interp_lats",
"=",
"[",
"]",
"lat_iterator",
"=",
"enumerate",
"(",
"zip",
"(",
"first_lats",
",",
"last_lats",
")",
")",
"for",
"level_ind",
",",
"(",
"first_lat",
",",
"last_lat",
")",
"in",
"lat_iterator",
":",
"if",
"level_ind",
"in",
"decode_hp",
".",
"level_interp",
":",
"if",
"decode_hp",
".",
"channel_interp",
"==",
"\"all\"",
":",
"interp_lat",
"=",
"glow_ops",
".",
"linear_interpolate",
"(",
"first_lat",
",",
"last_lat",
",",
"coeffs",
")",
"else",
":",
"interp_lat",
"=",
"glow_ops",
".",
"linear_interpolate_rank",
"(",
"first_lat",
",",
"last_lat",
",",
"coeffs",
",",
"decode_hp",
".",
"rank_interp",
")",
"else",
":",
"interp_lat",
"=",
"tf",
".",
"tile",
"(",
"first_lat",
",",
"[",
"decode_hp",
".",
"num_interp",
",",
"1",
",",
"1",
",",
"1",
"]",
")",
"interp_lats",
".",
"append",
"(",
"interp_lat",
")",
"level_eps_interp",
"=",
"interp_lats",
"[",
":",
"hparams",
".",
"n_levels",
"-",
"1",
"]",
"z_top_interp",
"=",
"interp_lats",
"[",
"-",
"1",
"]",
"images",
"=",
"latents_to_frames",
"(",
"z_top_interp",
",",
"level_eps_interp",
",",
"hparams",
")",
"return",
"images",
",",
"first_frame",
",",
"last_frame"
] |
Interpolate between the first input frame and last target frame.
Args:
features: dict of tensors
hparams: HParams, training hparams.
decode_hp: HParams, decode hparams.
Returns:
images: interpolated images, 4-D Tensor, shape=(num_interp, H, W, C)
first_frame: image, 3-D Tensor, shape=(1, H, W, C)
last_frame: image, 3-D Tensor, shape=(1, H, W, C)
|
[
"Interpolate",
"between",
"the",
"first",
"input",
"frame",
"and",
"last",
"target",
"frame",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/video/nfg_interpolate.py#L109-L150
|
train
|
Interpolate between the first input frame and last target frame.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr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bortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(182 - 134) + chr(6566 - 6455) + chr(0b110010) + chr(0b110010) + chr(2278 - 2227), ord("\x08")), ehT0Px3KOsy9(chr(0b11011 + 0o25) + chr(111) + '\062' + '\063' + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\061' + chr(0b110111) + '\x37', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110001) + chr(1246 - 1198) + chr(50), 45676 - 45668), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b100011 + 0o114) + chr(146 - 96) + chr(0b110010) + chr(0b100 + 0o56), 0b1000), ehT0Px3KOsy9('\x30' + chr(5055 - 4944) + '\061' + '\x34' + chr(0b11101 + 0o30), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(51) + chr(0b110110) + chr(0b110110), 16657 - 16649), ehT0Px3KOsy9(chr(0b100001 + 0o17) + chr(0b111011 + 0o64) + '\063' + '\x35' + '\060', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x33' + '\062' + chr(0b10100 + 0o36), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(49) + '\064', 0o10), ehT0Px3KOsy9(chr(0b100010 + 0o16) + chr(0b101100 + 0o103) + chr(0b110011) + chr(0b110111) + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(0b1101111) + chr(51) + '\x33' + chr(51), 42912 - 42904), ehT0Px3KOsy9(chr(0b100001 + 0o17) + '\157' + chr(49) + '\x34' + chr(56 - 1), 0b1000), ehT0Px3KOsy9('\060' + chr(11783 - 11672) + chr(0b11100 + 0o31) + '\063', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110011) + '\x32' + chr(1055 - 1000), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(50) + '\x35', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b100000 + 0o117) + '\x35' + chr(683 - 634), ord("\x08")), ehT0Px3KOsy9(chr(0b100000 + 0o20) + '\x6f' + chr(0b100 + 0o56) + '\065' + chr(0b1010 + 0o47), 0o10), ehT0Px3KOsy9(chr(0b1011 + 0o45) + '\x6f' + chr(0b110001) + chr(50) + chr(2323 - 2269), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\x31' + '\x34' + chr(50), 0b1000), ehT0Px3KOsy9(chr(0b100 + 0o54) + '\157' + chr(2586 - 2535) + '\063' + chr(0b10001 + 0o43), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(49) + chr(1460 - 1410) + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(822 - 774) + chr(4087 - 3976) + chr(49), 0o10), ehT0Px3KOsy9('\x30' + chr(2880 - 2769) + '\063' + chr(1732 - 1680), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1010001 + 0o36) + '\x31' + chr(0b110011) + chr(1938 - 1885), ord("\x08")), ehT0Px3KOsy9(chr(0b0 + 0o60) + '\157' + '\063' + '\064' + '\x30', 63681 - 63673), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b101000 + 0o12) + chr(389 - 338) + chr(0b1001 + 0o50), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(10461 - 10350) + chr(0b0 + 0o61) + '\x34' + chr(2498 - 2447), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\067' + chr(0b100100 + 0o21), 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(2790 - 2736) + '\066', 0o10), ehT0Px3KOsy9(chr(0b1011 + 0o45) + '\157' + chr(1988 - 1939) + chr(51) + chr(240 - 187), 8), ehT0Px3KOsy9('\x30' + chr(0b111000 + 0o67) + chr(0b110001) + chr(0b1101 + 0o43) + chr(0b110010), 8), ehT0Px3KOsy9(chr(48) + chr(0b1000000 + 0o57) + chr(0b110010) + chr(52) + chr(0b1010 + 0o55), 17865 - 17857), ehT0Px3KOsy9(chr(48) + chr(0b1011110 + 0o21) + chr(0b101000 + 0o13) + chr(110 - 60) + chr(0b110000), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1351 - 1301) + '\x36' + '\067', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + '\062' + '\061' + chr(0b110100 + 0o3), 63495 - 63487), ehT0Px3KOsy9('\x30' + chr(965 - 854) + chr(1040 - 990) + '\062' + chr(54), 0o10), ehT0Px3KOsy9(chr(0b11100 + 0o24) + chr(1681 - 1570) + chr(261 - 210) + '\x31' + chr(1402 - 1348), 46524 - 46516), ehT0Px3KOsy9('\x30' + chr(835 - 724) + '\061' + chr(1386 - 1337) + '\067', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1010000 + 0o37) + '\063' + '\064' + chr(54), ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b1101111) + chr(0b100001 + 0o24) + '\060', 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xbd'), '\x64' + chr(101) + chr(226 - 127) + chr(7137 - 7026) + chr(6302 - 6202) + '\145')(chr(0b1110101) + '\164' + chr(0b1010111 + 0o17) + chr(1526 - 1481) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def dvicgWo84O5F(EEf4r9nUvta_, n4ljua2gi1Pr, dcaitvFqg9pp):
(vXoupepMtCXU, xIEmRseySp3z) = (EEf4r9nUvta_[xafqLlk3kkUe(SXOLrMavuUCe(b'\xfa\xf1\x0f7\xe6\x16'), '\144' + chr(1766 - 1665) + chr(1228 - 1129) + '\157' + '\144' + '\x65')(chr(117) + '\164' + '\x66' + chr(244 - 199) + chr(2838 - 2782))], EEf4r9nUvta_[xafqLlk3kkUe(SXOLrMavuUCe(b'\xe7\xfe\r%\xf7\x11\x85'), '\144' + chr(0b1100101) + chr(0b1100011) + chr(111) + chr(0b1100100) + chr(101))('\165' + chr(1480 - 1364) + chr(0b1100110) + chr(45) + '\x38')])
vXoupepMtCXU = IDJ2eXGCBCDu.unstack(vXoupepMtCXU, axis=ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(2686 - 2575) + chr(0b100 + 0o55), 8))
xIEmRseySp3z = IDJ2eXGCBCDu.unstack(xIEmRseySp3z, axis=ehT0Px3KOsy9(chr(1883 - 1835) + '\x6f' + '\x31', 8))
Mq2X4hHIvLYE = WqUC3KWvYVup.linspace(0.0, 1.0, dcaitvFqg9pp.num_interp)
(niQlyUHVkLEK, pZyvSDKTOzsc) = (vXoupepMtCXU[ehT0Px3KOsy9(chr(0b10101 + 0o33) + chr(5471 - 5360) + chr(48), 0o10)], xIEmRseySp3z[-ehT0Px3KOsy9(chr(48) + '\x6f' + chr(49), 8)])
(TMIDxGdXXZfa, Cg9rvzHVbFDu) = xCmT3Fu4L4nb(niQlyUHVkLEK, n4ljua2gi1Pr)
(IT2bT0VsJfQI, oNLzCzcO_Pz1) = xCmT3Fu4L4nb(pZyvSDKTOzsc, n4ljua2gi1Pr)
RxAvfHuAs7wo = Cg9rvzHVbFDu + [TMIDxGdXXZfa]
WnzALcIIaU8P = oNLzCzcO_Pz1 + [IT2bT0VsJfQI]
pfrF8BsR8FDl = []
kiv68UOapSlx = YlkZvXL8qwsX(pZ0NK2y6HRbn(RxAvfHuAs7wo, WnzALcIIaU8P))
for (qof0sWb_lpNA, (Zs5kE3l9AFSY, oil75F2jCzT1)) in kiv68UOapSlx:
if qof0sWb_lpNA in xafqLlk3kkUe(dcaitvFqg9pp, xafqLlk3kkUe(SXOLrMavuUCe(b"\xff\xfa\t'\xfe:\x9f\x86\xa6i\x8b\xab"), chr(0b1100100) + chr(101) + chr(0b1100011) + chr(0b1101111) + chr(0b1100100) + chr(101))(chr(0b1110101) + '\164' + chr(0b1000001 + 0o45) + chr(68 - 23) + chr(56))):
if xafqLlk3kkUe(dcaitvFqg9pp, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf0\xf7\x1e,\xfc\x00\x9a\xb7\xbbb\x8d\xbe\x15['), chr(1523 - 1423) + chr(0b1100101) + '\x63' + chr(0b1101111) + chr(0b1100100) + '\x65')('\x75' + '\164' + chr(102) + '\055' + '\070')) == xafqLlk3kkUe(SXOLrMavuUCe(b'\xf2\xf3\x13'), chr(0b1100100) + '\145' + chr(99) + chr(111) + '\144' + chr(7245 - 7144))(chr(10663 - 10546) + '\164' + '\x66' + chr(0b101101) + '\x38'):
_A5oEDZidZi2 = RVYZnhb7AvdJ.linear_interpolate(Zs5kE3l9AFSY, oil75F2jCzT1, Mq2X4hHIvLYE)
else:
_A5oEDZidZi2 = RVYZnhb7AvdJ.linear_interpolate_rank(Zs5kE3l9AFSY, oil75F2jCzT1, Mq2X4hHIvLYE, dcaitvFqg9pp.rank_interp)
else:
_A5oEDZidZi2 = IDJ2eXGCBCDu.tile(Zs5kE3l9AFSY, [dcaitvFqg9pp.num_interp, ehT0Px3KOsy9(chr(1709 - 1661) + '\x6f' + chr(49), 8), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\061', 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x31', 8)])
xafqLlk3kkUe(pfrF8BsR8FDl, xafqLlk3kkUe(SXOLrMavuUCe(b"\xf2\xef\x0f'\xfc\x01"), chr(100) + '\145' + chr(0b1100011 + 0o0) + '\x6f' + chr(0b1100100) + '\x65')(chr(117) + chr(116) + chr(102) + chr(45) + '\070'))(_A5oEDZidZi2)
z6yKZVBJIVDl = pfrF8BsR8FDl[:n4ljua2gi1Pr.n_levels - ehT0Px3KOsy9(chr(0b110000) + chr(0b1000111 + 0o50) + '\x31', 8)]
i4nbYCiNa3yl = pfrF8BsR8FDl[-ehT0Px3KOsy9('\060' + '\x6f' + '\061', 8)]
YJOmEcibG8C0 = _bYfW2s32LHI(i4nbYCiNa3yl, z6yKZVBJIVDl, n4ljua2gi1Pr)
return (YJOmEcibG8C0, niQlyUHVkLEK, pZyvSDKTOzsc)
|
tensorflow/tensor2tensor
|
tensor2tensor/models/video/nfg_interpolate.py
|
get_summaries_log_dir
|
def get_summaries_log_dir(decode_hp, output_dir, dataset_split):
"""Get nested summaries_log_dir based on decode_hp."""
child_dir = decode_hp.summaries_log_dir
level_dir = "".join([str(level) for level in decode_hp.level_interp])
if decode_hp.channel_interp == "all":
rank_dir = "all"
else:
rank_dir = "rank_%d" % decode_hp.rank_interp
child_dir = "%s/%s_%s" % (child_dir, level_dir, rank_dir)
if dataset_split is not None:
child_dir += "_{}".format(dataset_split)
return os.path.join(output_dir, child_dir)
|
python
|
def get_summaries_log_dir(decode_hp, output_dir, dataset_split):
"""Get nested summaries_log_dir based on decode_hp."""
child_dir = decode_hp.summaries_log_dir
level_dir = "".join([str(level) for level in decode_hp.level_interp])
if decode_hp.channel_interp == "all":
rank_dir = "all"
else:
rank_dir = "rank_%d" % decode_hp.rank_interp
child_dir = "%s/%s_%s" % (child_dir, level_dir, rank_dir)
if dataset_split is not None:
child_dir += "_{}".format(dataset_split)
return os.path.join(output_dir, child_dir)
|
[
"def",
"get_summaries_log_dir",
"(",
"decode_hp",
",",
"output_dir",
",",
"dataset_split",
")",
":",
"child_dir",
"=",
"decode_hp",
".",
"summaries_log_dir",
"level_dir",
"=",
"\"\"",
".",
"join",
"(",
"[",
"str",
"(",
"level",
")",
"for",
"level",
"in",
"decode_hp",
".",
"level_interp",
"]",
")",
"if",
"decode_hp",
".",
"channel_interp",
"==",
"\"all\"",
":",
"rank_dir",
"=",
"\"all\"",
"else",
":",
"rank_dir",
"=",
"\"rank_%d\"",
"%",
"decode_hp",
".",
"rank_interp",
"child_dir",
"=",
"\"%s/%s_%s\"",
"%",
"(",
"child_dir",
",",
"level_dir",
",",
"rank_dir",
")",
"if",
"dataset_split",
"is",
"not",
"None",
":",
"child_dir",
"+=",
"\"_{}\"",
".",
"format",
"(",
"dataset_split",
")",
"return",
"os",
".",
"path",
".",
"join",
"(",
"output_dir",
",",
"child_dir",
")"
] |
Get nested summaries_log_dir based on decode_hp.
|
[
"Get",
"nested",
"summaries_log_dir",
"based",
"on",
"decode_hp",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca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HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b100011 + 0o15) + chr(9909 - 9798) + chr(176 - 121) + '\x36', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b10011 + 0o36) + chr(0b110110) + '\x32', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b11010 + 0o125) + '\061' + chr(54) + '\x34', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110001) + '\x36' + chr(1368 - 1319), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x34' + chr(1084 - 1030), 0o10), ehT0Px3KOsy9(chr(0b1100 + 0o44) + chr(0b1101111) + '\x32' + chr(0b1110 + 0o42), ord("\x08")), ehT0Px3KOsy9(chr(2095 - 2047) + '\x6f' + chr(600 - 549) + '\x32' + '\067', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b11011 + 0o124) + chr(49) + '\x33' + chr(56 - 8), 0o10), ehT0Px3KOsy9('\060' + chr(0b110011 + 0o74) + '\x32' + chr(2098 - 2044) + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(2183 - 2133) + chr(52) + chr(49), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + '\x33' + chr(809 - 754) + '\065', 55161 - 55153), ehT0Px3KOsy9('\x30' + '\x6f' + '\061' + '\x30' + chr(51), 40762 - 40754), ehT0Px3KOsy9(chr(0b10110 + 0o32) + '\x6f' + chr(2143 - 2094) + '\x36' + chr(0b1101 + 0o51), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(241 - 190) + chr(0b110110) + chr(49), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(51) + chr(2160 - 2111) + '\065', 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(1439 - 1390) + chr(0b110001) + chr(0b1111 + 0o43), 53776 - 53768), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x33' + chr(2221 - 2170) + chr(64 - 16), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(9963 - 9852) + '\x32' + chr(2075 - 2027), 8), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110010) + chr(53) + chr(50), 28560 - 28552), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110010) + '\x33' + chr(0b110011 + 0o3), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(454 - 405) + chr(0b11110 + 0o24) + chr(2784 - 2729), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(49) + '\x32' + '\066', 26515 - 26507), ehT0Px3KOsy9(chr(0b110000) + chr(4267 - 4156) + '\x34' + '\x35', 32829 - 32821), ehT0Px3KOsy9(chr(2058 - 2010) + chr(11754 - 11643) + '\x32' + chr(0b110001) + '\066', 54664 - 54656), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(652 - 599) + chr(53), 0o10), ehT0Px3KOsy9(chr(1633 - 1585) + chr(0b1101111) + chr(558 - 508) + chr(0b110011) + chr(52), 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(0b11111 + 0o24) + chr(0b110000) + chr(0b110101), 0o10), ehT0Px3KOsy9('\060' + '\157' + chr(858 - 804) + chr(0b110000), 32188 - 32180), ehT0Px3KOsy9('\060' + chr(111) + '\x32' + chr(54) + '\067', 6911 - 6903), ehT0Px3KOsy9('\060' + '\157' + '\062' + chr(695 - 646) + chr(2270 - 2219), 1719 - 1711), ehT0Px3KOsy9(chr(48) + chr(0b101010 + 0o105) + chr(0b110100) + chr(628 - 580), 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b100110 + 0o20) + '\x34', 43724 - 43716), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b101010 + 0o7) + '\x33' + '\x31', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1100100 + 0o13) + chr(0b110010) + chr(0b110101) + '\060', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\066' + chr(0b11010 + 0o31), 17426 - 17418), ehT0Px3KOsy9(chr(2161 - 2113) + '\157' + chr(0b110001) + chr(0b10100 + 0o36), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(8553 - 8442) + chr(0b110001) + chr(0b100011 + 0o17) + chr(2184 - 2131), 0b1000), ehT0Px3KOsy9(chr(0b100101 + 0o13) + chr(0b10000 + 0o137) + chr(0b110110 + 0o0) + chr(298 - 245), 0b1000), ehT0Px3KOsy9(chr(1200 - 1152) + chr(11620 - 11509) + chr(2242 - 2192) + '\060' + '\067', ord("\x08")), ehT0Px3KOsy9(chr(0b10111 + 0o31) + '\157' + chr(1865 - 1813) + chr(49), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(638 - 590) + chr(12099 - 11988) + chr(53) + '\060', 39344 - 39336)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x10'), chr(100) + '\x65' + chr(0b11001 + 0o112) + chr(111) + chr(0b1100100) + chr(0b1100101))(chr(0b111000 + 0o75) + chr(0b100101 + 0o117) + '\x66' + '\x2d' + chr(2461 - 2405)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def PNwx2jMxNFEU(dcaitvFqg9pp, nd0OX_BS6_o4, XqbfPmad1kJ4):
SFhNrnqLHTmk = dcaitvFqg9pp.summaries_log_dir
AydIN3O19ZVO = xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(0b1011 + 0o131) + '\145' + '\x63' + '\157' + chr(0b1100100) + chr(0b1100101))(chr(0b1110101) + chr(116) + chr(0b10 + 0o144) + '\055' + chr(0b111000)).join([M8_cKLkHVB2V(K3VjCQe_lvJZ) for K3VjCQe_lvJZ in dcaitvFqg9pp.level_interp])
if xafqLlk3kkUe(dcaitvFqg9pp, xafqLlk3kkUe(SXOLrMavuUCe(b']\x1a\x15\x1fHu\xbb\x07\xd9\xcf\x89&\x04\x81'), chr(100) + chr(0b111010 + 0o53) + chr(0b1100011) + chr(111) + chr(1858 - 1758) + chr(862 - 761))('\x75' + chr(0b11011 + 0o131) + '\146' + chr(0b101101) + '\x38')) == xafqLlk3kkUe(SXOLrMavuUCe(b'_\x1e\x18'), '\144' + '\145' + '\143' + chr(0b1101111) + chr(100) + chr(0b1000101 + 0o40))('\x75' + '\x74' + chr(0b1100110) + chr(45) + '\x38'):
HTFhsd6W1a5Q = xafqLlk3kkUe(SXOLrMavuUCe(b'_\x1e\x18'), chr(0b1100100) + '\x65' + chr(4613 - 4514) + chr(0b101110 + 0o101) + chr(0b1010110 + 0o16) + '\145')(chr(0b1110101) + chr(4580 - 4464) + chr(0b1100110) + '\055' + chr(2437 - 2381))
else:
HTFhsd6W1a5Q = xafqLlk3kkUe(SXOLrMavuUCe(b'L\x13\x1a\x1ay5\xb3'), chr(1155 - 1055) + chr(0b1100101) + chr(0b1100011) + chr(0b1101111) + chr(100) + '\x65')(chr(1856 - 1739) + chr(0b1110100) + '\146' + '\x2d' + chr(56)) % dcaitvFqg9pp.rank_interp
SFhNrnqLHTmk = xafqLlk3kkUe(SXOLrMavuUCe(b'\x1b\x01[TUO\xf2+'), chr(0b1010101 + 0o17) + chr(0b1100101) + chr(0b111100 + 0o47) + '\x6f' + chr(100) + '\x65')(chr(117) + chr(0b110011 + 0o101) + chr(0b1100110) + '\x2d' + chr(1723 - 1667)) % (SFhNrnqLHTmk, AydIN3O19ZVO, HTFhsd6W1a5Q)
if XqbfPmad1kJ4 is not None:
SFhNrnqLHTmk += xafqLlk3kkUe(SXOLrMavuUCe(b'a\t\t'), '\x64' + '\x65' + chr(0b1100011) + '\157' + chr(0b1100100) + '\x65')(chr(117) + chr(0b10110 + 0o136) + chr(0b1001100 + 0o32) + chr(45) + chr(0b111000)).V4roHaS3Ppej(XqbfPmad1kJ4)
return xafqLlk3kkUe(oqhJDdMJfuwx.path, xafqLlk3kkUe(SXOLrMavuUCe(b'T\x1d\x1d\x1f'), chr(0b1100001 + 0o3) + '\145' + chr(0b1100011) + '\x6f' + chr(6358 - 6258) + '\145')(chr(0b1110101) + chr(3616 - 3500) + chr(7007 - 6905) + '\055' + '\x38'))(nd0OX_BS6_o4, SFhNrnqLHTmk)
|
tensorflow/tensor2tensor
|
tensor2tensor/models/video/nfg_interpolate.py
|
interpolations_to_summary
|
def interpolations_to_summary(sample_ind, interpolations, first_frame,
last_frame, hparams, decode_hp):
"""Converts interpolated frames into tf summaries.
The summaries consists of:
1. Image summary corresponding to the first frame.
2. Image summary corresponding to the last frame.
3. The interpolated frames as a gif summary.
Args:
sample_ind: int
interpolations: Numpy array, shape=(num_interp, H, W, 3)
first_frame: Numpy array, shape=(HWC)
last_frame: Numpy array, shape=(HWC)
hparams: HParams, train hparams
decode_hp: HParams, decode hparams
Returns:
summaries: list of tf Summary Values.
"""
parent_tag = "sample_%d" % sample_ind
frame_shape = hparams.problem.frame_shape
interp_shape = [hparams.batch_size, decode_hp.num_interp] + frame_shape
interpolations = np.reshape(interpolations, interp_shape)
interp_tag = "%s/interp/%s" % (parent_tag, decode_hp.channel_interp)
if decode_hp.channel_interp == "ranked":
interp_tag = "%s/rank_%d" % (interp_tag, decode_hp.rank_interp)
summaries, _ = common_video.py_gif_summary(
interp_tag, interpolations, return_summary_value=True,
max_outputs=decode_hp.max_display_outputs,
fps=decode_hp.frames_per_second)
if decode_hp.save_frames:
first_frame_summ = image_utils.image_to_tf_summary_value(
first_frame, "%s/first" % parent_tag)
last_frame_summ = image_utils.image_to_tf_summary_value(
last_frame, "%s/last" % parent_tag)
summaries.append(first_frame_summ)
summaries.append(last_frame_summ)
return summaries
|
python
|
def interpolations_to_summary(sample_ind, interpolations, first_frame,
last_frame, hparams, decode_hp):
"""Converts interpolated frames into tf summaries.
The summaries consists of:
1. Image summary corresponding to the first frame.
2. Image summary corresponding to the last frame.
3. The interpolated frames as a gif summary.
Args:
sample_ind: int
interpolations: Numpy array, shape=(num_interp, H, W, 3)
first_frame: Numpy array, shape=(HWC)
last_frame: Numpy array, shape=(HWC)
hparams: HParams, train hparams
decode_hp: HParams, decode hparams
Returns:
summaries: list of tf Summary Values.
"""
parent_tag = "sample_%d" % sample_ind
frame_shape = hparams.problem.frame_shape
interp_shape = [hparams.batch_size, decode_hp.num_interp] + frame_shape
interpolations = np.reshape(interpolations, interp_shape)
interp_tag = "%s/interp/%s" % (parent_tag, decode_hp.channel_interp)
if decode_hp.channel_interp == "ranked":
interp_tag = "%s/rank_%d" % (interp_tag, decode_hp.rank_interp)
summaries, _ = common_video.py_gif_summary(
interp_tag, interpolations, return_summary_value=True,
max_outputs=decode_hp.max_display_outputs,
fps=decode_hp.frames_per_second)
if decode_hp.save_frames:
first_frame_summ = image_utils.image_to_tf_summary_value(
first_frame, "%s/first" % parent_tag)
last_frame_summ = image_utils.image_to_tf_summary_value(
last_frame, "%s/last" % parent_tag)
summaries.append(first_frame_summ)
summaries.append(last_frame_summ)
return summaries
|
[
"def",
"interpolations_to_summary",
"(",
"sample_ind",
",",
"interpolations",
",",
"first_frame",
",",
"last_frame",
",",
"hparams",
",",
"decode_hp",
")",
":",
"parent_tag",
"=",
"\"sample_%d\"",
"%",
"sample_ind",
"frame_shape",
"=",
"hparams",
".",
"problem",
".",
"frame_shape",
"interp_shape",
"=",
"[",
"hparams",
".",
"batch_size",
",",
"decode_hp",
".",
"num_interp",
"]",
"+",
"frame_shape",
"interpolations",
"=",
"np",
".",
"reshape",
"(",
"interpolations",
",",
"interp_shape",
")",
"interp_tag",
"=",
"\"%s/interp/%s\"",
"%",
"(",
"parent_tag",
",",
"decode_hp",
".",
"channel_interp",
")",
"if",
"decode_hp",
".",
"channel_interp",
"==",
"\"ranked\"",
":",
"interp_tag",
"=",
"\"%s/rank_%d\"",
"%",
"(",
"interp_tag",
",",
"decode_hp",
".",
"rank_interp",
")",
"summaries",
",",
"_",
"=",
"common_video",
".",
"py_gif_summary",
"(",
"interp_tag",
",",
"interpolations",
",",
"return_summary_value",
"=",
"True",
",",
"max_outputs",
"=",
"decode_hp",
".",
"max_display_outputs",
",",
"fps",
"=",
"decode_hp",
".",
"frames_per_second",
")",
"if",
"decode_hp",
".",
"save_frames",
":",
"first_frame_summ",
"=",
"image_utils",
".",
"image_to_tf_summary_value",
"(",
"first_frame",
",",
"\"%s/first\"",
"%",
"parent_tag",
")",
"last_frame_summ",
"=",
"image_utils",
".",
"image_to_tf_summary_value",
"(",
"last_frame",
",",
"\"%s/last\"",
"%",
"parent_tag",
")",
"summaries",
".",
"append",
"(",
"first_frame_summ",
")",
"summaries",
".",
"append",
"(",
"last_frame_summ",
")",
"return",
"summaries"
] |
Converts interpolated frames into tf summaries.
The summaries consists of:
1. Image summary corresponding to the first frame.
2. Image summary corresponding to the last frame.
3. The interpolated frames as a gif summary.
Args:
sample_ind: int
interpolations: Numpy array, shape=(num_interp, H, W, 3)
first_frame: Numpy array, shape=(HWC)
last_frame: Numpy array, shape=(HWC)
hparams: HParams, train hparams
decode_hp: HParams, decode hparams
Returns:
summaries: list of tf Summary Values.
|
[
"Converts",
"interpolated",
"frames",
"into",
"tf",
"summaries",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/video/nfg_interpolate.py#L167-L205
|
train
|
Converts interpolated frames into a list of tf summaries.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7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WkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110010) + chr(55) + chr(0b10101 + 0o42), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + '\x31' + chr(55) + chr(0b11001 + 0o30), ord("\x08")), ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(0b1001111 + 0o40) + chr(0b100100 + 0o16) + '\062' + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(54) + chr(2527 - 2473), 0o10), ehT0Px3KOsy9(chr(0b10001 + 0o37) + chr(0b1101111) + chr(1688 - 1639) + '\x34' + chr(0b101001 + 0o11), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110001) + '\x30', ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110111) + '\x35', 19044 - 19036), ehT0Px3KOsy9('\x30' + '\157' + chr(0b1100 + 0o45) + chr(0b110000 + 0o2) + chr(0b10010 + 0o40), 13580 - 13572), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(1874 - 1824) + chr(52) + '\x37', 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\061' + chr(0b110010) + '\x32', 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b101000 + 0o12) + '\x34', 1232 - 1224), ehT0Px3KOsy9(chr(0b110000) + chr(7656 - 7545) + chr(0b110011) + '\x33' + chr(0b110010), ord("\x08")), ehT0Px3KOsy9(chr(0b100101 + 0o13) + chr(111) + '\062' + chr(0b110010) + chr(0b1011 + 0o52), ord("\x08")), ehT0Px3KOsy9(chr(2183 - 2135) + chr(8728 - 8617) + chr(331 - 282) + chr(0b11110 + 0o26) + chr(702 - 652), 8), ehT0Px3KOsy9('\060' + chr(0b1101100 + 0o3) + '\x32' + chr(2215 - 2164) + '\x30', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b1001 + 0o51) + chr(0b100101 + 0o17), 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b11111 + 0o23) + chr(0b11111 + 0o30) + chr(0b100111 + 0o16), 24607 - 24599), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b10010 + 0o40) + chr(48) + chr(1157 - 1108), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\x36' + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(117 - 69) + chr(9275 - 9164) + chr(513 - 464) + '\x35' + '\064', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(4960 - 4849) + '\x32' + chr(0b110101) + chr(1011 - 962), 0b1000), ehT0Px3KOsy9('\x30' + chr(10016 - 9905) + chr(0b110011) + chr(0b110010 + 0o5) + chr(1830 - 1777), 27950 - 27942), ehT0Px3KOsy9(chr(86 - 38) + chr(0b1101111) + '\x31' + chr(0b101011 + 0o14) + chr(993 - 939), 0o10), ehT0Px3KOsy9(chr(0b1011 + 0o45) + '\157' + chr(0b1100 + 0o46) + '\x34' + chr(1385 - 1333), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\061' + chr(1793 - 1741) + chr(2295 - 2247), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(51) + chr(51) + chr(0b110100), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + '\063' + chr(0b11001 + 0o36) + chr(0b110110), 2114 - 2106), ehT0Px3KOsy9('\x30' + '\x6f' + '\063' + '\060' + chr(1560 - 1508), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + '\x33' + chr(53) + chr(51), 0o10), ehT0Px3KOsy9(chr(1710 - 1662) + '\157' + chr(0b1010 + 0o47) + chr(0b110011) + '\x30', 40835 - 40827), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b1110 + 0o47) + chr(0b110100), 15987 - 15979), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x31' + '\x32' + chr(1518 - 1467), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(0b1 + 0o62) + chr(48) + '\066', 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + chr(612 - 562) + chr(49) + '\067', 0o10), ehT0Px3KOsy9('\x30' + chr(8613 - 8502) + chr(49) + chr(0b11000 + 0o30) + '\061', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b10111 + 0o34) + '\065', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b100111 + 0o110) + chr(50) + '\x31' + chr(0b101110 + 0o4), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b101001 + 0o12) + chr(54) + '\x32', 58204 - 58196), ehT0Px3KOsy9(chr(1060 - 1012) + chr(111) + '\062' + '\067' + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(0b10001 + 0o37) + chr(0b110110 + 0o71) + chr(0b110011) + '\x35' + '\x36', 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(241 - 193) + '\x6f' + chr(880 - 827) + chr(0b10100 + 0o34), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x91'), '\x64' + chr(4158 - 4057) + '\x63' + '\x6f' + chr(2412 - 2312) + '\x65')('\165' + '\164' + chr(0b1100110) + chr(0b101101) + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def KIJztncR05EE(ZE9icZxPMz9D, D7uHpwBC9MHk, niQlyUHVkLEK, pZyvSDKTOzsc, n4ljua2gi1Pr, dcaitvFqg9pp):
HW3g6FdW6Vr5 = xafqLlk3kkUe(SXOLrMavuUCe(b'\xcc\x18\xfdF\x0embw\xc3'), chr(0b1100100) + chr(101) + chr(7167 - 7068) + chr(0b111011 + 0o64) + chr(100) + chr(0b10111 + 0o116))(chr(0b1010111 + 0o36) + '\x74' + chr(102) + chr(45) + '\x38') % ZE9icZxPMz9D
eut3NH0zeXzv = n4ljua2gi1Pr.problem.frame_shape
h0cM5eRhu5S6 = [n4ljua2gi1Pr.ix9dZyeAmUxY, dcaitvFqg9pp.num_interp] + eut3NH0zeXzv
D7uHpwBC9MHk = WqUC3KWvYVup.reshape(D7uHpwBC9MHk, h0cM5eRhu5S6)
NsrU_xSpUXUC = xafqLlk3kkUe(SXOLrMavuUCe(b'\x9a\n\xbf_\x0c|X \xd7}1\xa9'), chr(0b1100100) + '\x65' + chr(99) + chr(0b1101111) + '\144' + chr(101))(chr(8339 - 8222) + '\x74' + '\x66' + chr(0b101101) + chr(0b1000 + 0o60)) % (HW3g6FdW6Vr5, dcaitvFqg9pp.channel_interp)
if xafqLlk3kkUe(dcaitvFqg9pp, xafqLlk3kkUe(SXOLrMavuUCe(b'\xdc\x11\xf1X\x0cmQ\r\xce<`\xbf\xe7\x12'), '\x64' + chr(101) + chr(99) + '\157' + chr(0b1100100) + '\145')('\165' + chr(116) + chr(0b1100000 + 0o6) + chr(0b101101) + chr(1324 - 1268))) == xafqLlk3kkUe(SXOLrMavuUCe(b'\xcd\x18\xfe]\x07l'), '\x64' + '\x65' + '\143' + chr(111) + chr(0b1100100) + chr(101))(chr(0b1110101) + '\x74' + chr(0b1100110) + '\055' + chr(0b111000)):
NsrU_xSpUXUC = xafqLlk3kkUe(SXOLrMavuUCe(b'\x9a\n\xbfD\x03fV\r\x826'), '\144' + chr(6100 - 5999) + '\x63' + chr(0b110010 + 0o75) + chr(0b1001100 + 0o30) + chr(7963 - 7862))('\x75' + chr(116) + chr(0b1100110) + '\055' + chr(0b110110 + 0o2)) % (NsrU_xSpUXUC, dcaitvFqg9pp.rank_interp)
(Ss61w8pBYeZH, VNGQdHSFPrso) = feDooRjkbHzt.py_gif_summary(NsrU_xSpUXUC, D7uHpwBC9MHk, return_summary_value=ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110001), 0b1000), max_outputs=dcaitvFqg9pp.max_display_outputs, fps=dcaitvFqg9pp.frames_per_second)
if xafqLlk3kkUe(dcaitvFqg9pp, xafqLlk3kkUe(SXOLrMavuUCe(b'\xcc\x18\xe6S=nO3\xca7g'), chr(0b1100 + 0o130) + '\x65' + '\143' + chr(0b1101111) + chr(100) + '\x65')('\x75' + chr(0b1110100) + chr(102) + '\055' + '\070')):
NV0Xl1dK_8Wg = sOwVd6RdzUcC.image_to_tf_summary_value(niQlyUHVkLEK, xafqLlk3kkUe(SXOLrMavuUCe(b'\x9a\n\xbfP\x0bzN&'), chr(0b1010010 + 0o22) + chr(7265 - 7164) + chr(0b1100011) + chr(111) + '\144' + chr(0b1011000 + 0o15))(chr(0b1110101) + chr(116) + chr(5861 - 5759) + chr(45) + chr(1428 - 1372)) % HW3g6FdW6Vr5)
k0W7Us5QLvli = sOwVd6RdzUcC.image_to_tf_summary_value(pZyvSDKTOzsc, xafqLlk3kkUe(SXOLrMavuUCe(b'\x9a\n\xbfZ\x03{I'), chr(0b11011 + 0o111) + chr(0b1100101) + '\143' + chr(111) + chr(4613 - 4513) + chr(0b1100101))(chr(1270 - 1153) + chr(0b100001 + 0o123) + chr(8312 - 8210) + chr(45) + chr(0b111000)) % HW3g6FdW6Vr5)
xafqLlk3kkUe(Ss61w8pBYeZH, xafqLlk3kkUe(SXOLrMavuUCe(b'\xde\t\xe0S\x0cl'), chr(100) + chr(3900 - 3799) + chr(4618 - 4519) + chr(0b1101111) + chr(0b11101 + 0o107) + chr(0b1000010 + 0o43))(chr(4308 - 4191) + '\164' + '\146' + chr(45) + chr(0b111000)))(NV0Xl1dK_8Wg)
xafqLlk3kkUe(Ss61w8pBYeZH, xafqLlk3kkUe(SXOLrMavuUCe(b'\xde\t\xe0S\x0cl'), chr(5195 - 5095) + '\x65' + chr(6030 - 5931) + chr(12023 - 11912) + '\144' + chr(0b1000011 + 0o42))('\165' + chr(0b1110100) + chr(0b1100110) + chr(0b11101 + 0o20) + chr(0b101000 + 0o20)))(k0W7Us5QLvli)
return Ss61w8pBYeZH
|
tensorflow/tensor2tensor
|
tensor2tensor/models/video/epva_params.py
|
next_frame_epva
|
def next_frame_epva():
"""EPVA hparams."""
hparams = basic_deterministic_params.next_frame_basic_deterministic()
hparams.video_num_input_frames = 4
hparams.video_num_target_frames = 4
hparams.bottom = {
"inputs": modalities.video_raw_bottom,
"targets": modalities.video_raw_targets_bottom,
}
hparams.loss = {
"targets": modalities.video_l2_raw_loss,
}
hparams.top = {
"targets": modalities.video_raw_top,
}
hparams.learning_rate_schedule = "constant"
hparams.learning_rate_constant = 1e-05
hparams.batch_size = 2
hparams.clip_grad_norm = 0.01
# TODO(msaffar): disentangle EPVA from SV2P
hparams.add_hparam("reward_prediction", False)
hparams.add_hparam("clip_pixel_values", True)
hparams.add_hparam("context_frames", 5)
hparams.add_hparam("enc_learning_rate", 1e-5)
hparams.add_hparam("enc_pred_loss_scale", 0.1)
hparams.add_hparam("enc_pred_loss_scale_delay", 6e5)
hparams.add_hparam("enc_size", 64)
hparams.add_hparam("enc_keep_prob", .65)
hparams.add_hparam("enc_pred_use_l1_loss", False)
hparams.add_hparam("enc_pred_use_l2norm", False)
hparams.add_hparam("van_learning_rate", 3e-5)
hparams.add_hparam("van_keep_prob", .9)
hparams.add_hparam("sequence_length ", 64)
hparams.add_hparam("skip_num", 2)
hparams.add_hparam("pred_noise_std", 0)
hparams.add_hparam("lstm_state_noise_stddev", 0)
return hparams
|
python
|
def next_frame_epva():
"""EPVA hparams."""
hparams = basic_deterministic_params.next_frame_basic_deterministic()
hparams.video_num_input_frames = 4
hparams.video_num_target_frames = 4
hparams.bottom = {
"inputs": modalities.video_raw_bottom,
"targets": modalities.video_raw_targets_bottom,
}
hparams.loss = {
"targets": modalities.video_l2_raw_loss,
}
hparams.top = {
"targets": modalities.video_raw_top,
}
hparams.learning_rate_schedule = "constant"
hparams.learning_rate_constant = 1e-05
hparams.batch_size = 2
hparams.clip_grad_norm = 0.01
# TODO(msaffar): disentangle EPVA from SV2P
hparams.add_hparam("reward_prediction", False)
hparams.add_hparam("clip_pixel_values", True)
hparams.add_hparam("context_frames", 5)
hparams.add_hparam("enc_learning_rate", 1e-5)
hparams.add_hparam("enc_pred_loss_scale", 0.1)
hparams.add_hparam("enc_pred_loss_scale_delay", 6e5)
hparams.add_hparam("enc_size", 64)
hparams.add_hparam("enc_keep_prob", .65)
hparams.add_hparam("enc_pred_use_l1_loss", False)
hparams.add_hparam("enc_pred_use_l2norm", False)
hparams.add_hparam("van_learning_rate", 3e-5)
hparams.add_hparam("van_keep_prob", .9)
hparams.add_hparam("sequence_length ", 64)
hparams.add_hparam("skip_num", 2)
hparams.add_hparam("pred_noise_std", 0)
hparams.add_hparam("lstm_state_noise_stddev", 0)
return hparams
|
[
"def",
"next_frame_epva",
"(",
")",
":",
"hparams",
"=",
"basic_deterministic_params",
".",
"next_frame_basic_deterministic",
"(",
")",
"hparams",
".",
"video_num_input_frames",
"=",
"4",
"hparams",
".",
"video_num_target_frames",
"=",
"4",
"hparams",
".",
"bottom",
"=",
"{",
"\"inputs\"",
":",
"modalities",
".",
"video_raw_bottom",
",",
"\"targets\"",
":",
"modalities",
".",
"video_raw_targets_bottom",
",",
"}",
"hparams",
".",
"loss",
"=",
"{",
"\"targets\"",
":",
"modalities",
".",
"video_l2_raw_loss",
",",
"}",
"hparams",
".",
"top",
"=",
"{",
"\"targets\"",
":",
"modalities",
".",
"video_raw_top",
",",
"}",
"hparams",
".",
"learning_rate_schedule",
"=",
"\"constant\"",
"hparams",
".",
"learning_rate_constant",
"=",
"1e-05",
"hparams",
".",
"batch_size",
"=",
"2",
"hparams",
".",
"clip_grad_norm",
"=",
"0.01",
"# TODO(msaffar): disentangle EPVA from SV2P",
"hparams",
".",
"add_hparam",
"(",
"\"reward_prediction\"",
",",
"False",
")",
"hparams",
".",
"add_hparam",
"(",
"\"clip_pixel_values\"",
",",
"True",
")",
"hparams",
".",
"add_hparam",
"(",
"\"context_frames\"",
",",
"5",
")",
"hparams",
".",
"add_hparam",
"(",
"\"enc_learning_rate\"",
",",
"1e-5",
")",
"hparams",
".",
"add_hparam",
"(",
"\"enc_pred_loss_scale\"",
",",
"0.1",
")",
"hparams",
".",
"add_hparam",
"(",
"\"enc_pred_loss_scale_delay\"",
",",
"6e5",
")",
"hparams",
".",
"add_hparam",
"(",
"\"enc_size\"",
",",
"64",
")",
"hparams",
".",
"add_hparam",
"(",
"\"enc_keep_prob\"",
",",
".65",
")",
"hparams",
".",
"add_hparam",
"(",
"\"enc_pred_use_l1_loss\"",
",",
"False",
")",
"hparams",
".",
"add_hparam",
"(",
"\"enc_pred_use_l2norm\"",
",",
"False",
")",
"hparams",
".",
"add_hparam",
"(",
"\"van_learning_rate\"",
",",
"3e-5",
")",
"hparams",
".",
"add_hparam",
"(",
"\"van_keep_prob\"",
",",
".9",
")",
"hparams",
".",
"add_hparam",
"(",
"\"sequence_length \"",
",",
"64",
")",
"hparams",
".",
"add_hparam",
"(",
"\"skip_num\"",
",",
"2",
")",
"hparams",
".",
"add_hparam",
"(",
"\"pred_noise_std\"",
",",
"0",
")",
"hparams",
".",
"add_hparam",
"(",
"\"lstm_state_noise_stddev\"",
",",
"0",
")",
"return",
"hparams"
] |
EPVA hparams.
|
[
"EPVA",
"hparams",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/video/epva_params.py#L27-L63
|
train
|
EPVA hparams.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrh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fv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + chr(7006 - 6895) + chr(49) + '\066' + chr(0b110111), 40494 - 40486), ehT0Px3KOsy9(chr(0b1100 + 0o44) + chr(0b1101111) + chr(0b110011) + chr(0b110010) + '\063', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\066' + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b1111 + 0o41) + '\x6f' + chr(1927 - 1872) + chr(0b110111), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(0b10100 + 0o37) + chr(0b100111 + 0o20) + chr(48), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(0b110010) + '\x35' + chr(0b110101), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(49) + chr(0b101000 + 0o13) + '\065', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x33' + chr(0b11101 + 0o26) + chr(1128 - 1076), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\x32' + '\x34', 45380 - 45372), ehT0Px3KOsy9(chr(0b110000) + chr(3965 - 3854) + chr(50) + chr(1604 - 1552) + chr(1828 - 1774), ord("\x08")), ehT0Px3KOsy9(chr(0b10 + 0o56) + '\x6f' + chr(0b111 + 0o54) + '\061' + chr(0b110010), 44809 - 44801), ehT0Px3KOsy9(chr(775 - 727) + chr(0b1101111) + '\x31' + chr(208 - 155) + '\066', 0b1000), ehT0Px3KOsy9('\x30' + chr(5873 - 5762) + '\x32' + chr(53) + '\x31', 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\x31' + chr(1315 - 1262) + chr(0b100110 + 0o20), 8), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b101011 + 0o6) + chr(0b110001) + '\x33', 48455 - 48447), ehT0Px3KOsy9(chr(112 - 64) + chr(0b101001 + 0o106) + chr(1950 - 1900) + chr(0b1101 + 0o52) + '\062', 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110011) + '\x34' + '\062', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b11011 + 0o124) + '\063' + chr(0b110011) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(857 - 809) + chr(111) + chr(49) + chr(0b10100 + 0o36) + '\x35', 0b1000), ehT0Px3KOsy9(chr(0b11001 + 0o27) + '\x6f' + chr(49) + chr(51), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(1164 - 1109) + chr(52), 15456 - 15448), ehT0Px3KOsy9(chr(0b111 + 0o51) + '\x6f' + chr(1822 - 1773) + chr(0b110100) + '\066', ord("\x08")), ehT0Px3KOsy9(chr(0b100011 + 0o15) + chr(10776 - 10665) + chr(1333 - 1282) + chr(54) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110010) + chr(0b110101) + chr(2537 - 2486), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b11111 + 0o26) + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b101100 + 0o103) + '\x31' + chr(1667 - 1613) + chr(1908 - 1856), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(51) + chr(0b110100) + chr(269 - 216), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(109 - 59) + '\x30', 43372 - 43364), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b100001 + 0o20) + chr(0b11111 + 0o23) + '\x35', 8), ehT0Px3KOsy9(chr(1682 - 1634) + chr(8176 - 8065) + '\063' + chr(1610 - 1558) + chr(0b110101), 8), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110001) + chr(0b110011) + chr(2143 - 2093), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\x31' + '\x36' + '\064', 8), ehT0Px3KOsy9(chr(0b1100 + 0o44) + chr(111) + '\x32' + chr(54) + '\063', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x33' + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(48) + chr(2234 - 2123) + '\064' + '\x30', 0o10), ehT0Px3KOsy9(chr(2022 - 1974) + chr(111) + chr(50) + '\x34', 8), ehT0Px3KOsy9(chr(48) + chr(4115 - 4004) + chr(1311 - 1256) + '\x30', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1001010 + 0o45) + chr(49) + chr(0b1001 + 0o50) + chr(1421 - 1369), 0b1000), ehT0Px3KOsy9(chr(1612 - 1564) + chr(0b1001011 + 0o44) + '\x33' + chr(0b10111 + 0o37) + '\060', 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(1164 - 1115) + '\067' + chr(0b110001), 30974 - 30966)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + '\157' + '\x35' + '\x30', ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'Y'), '\144' + chr(0b1100101) + '\x63' + '\x6f' + chr(0b10001 + 0o123) + '\x65')(chr(5713 - 5596) + chr(116) + chr(102) + '\x2d' + chr(2537 - 2481)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def wbxqSjSVqzS1():
n4ljua2gi1Pr = Gw_gMrmFHoKr.next_frame_basic_deterministic()
n4ljua2gi1Pr.UUXW9NWPZxPI = ehT0Px3KOsy9(chr(0b110000) + chr(5849 - 5738) + chr(478 - 426), 36497 - 36489)
n4ljua2gi1Pr.UxYiT0ZFW2SZ = ehT0Px3KOsy9('\060' + '\157' + chr(0b101000 + 0o14), 8)
n4ljua2gi1Pr.kXxsZxlIQUSQ = {xafqLlk3kkUe(SXOLrMavuUCe(b'\x1e\xbdAJ\x8c\xde'), chr(100) + chr(8017 - 7916) + chr(1883 - 1784) + '\157' + chr(100) + '\x65')(chr(0b1110101) + chr(0b1110100) + chr(102) + '\055' + chr(56)): PuPeNl0CuqOQ.video_raw_bottom, xafqLlk3kkUe(SXOLrMavuUCe(b'\x03\xb2CX\x9d\xd9.'), chr(9546 - 9446) + chr(3904 - 3803) + chr(0b11110 + 0o105) + '\157' + '\144' + '\145')(chr(0b1110101) + chr(0b1010111 + 0o35) + chr(4679 - 4577) + chr(45) + chr(0b111000)): PuPeNl0CuqOQ.video_raw_targets_bottom}
n4ljua2gi1Pr.YpO0BcZ6fMsf = {xafqLlk3kkUe(SXOLrMavuUCe(b'\x03\xb2CX\x9d\xd9.'), chr(0b1100100) + chr(0b100100 + 0o101) + '\143' + chr(0b1101111) + chr(100) + '\x65')(chr(0b1101100 + 0o11) + chr(2789 - 2673) + chr(0b1001111 + 0o27) + '\x2d' + chr(0b10100 + 0o44)): PuPeNl0CuqOQ.video_l2_raw_loss}
n4ljua2gi1Pr.qxrVBjeryNEZ = {xafqLlk3kkUe(SXOLrMavuUCe(b'\x03\xb2CX\x9d\xd9.'), chr(3042 - 2942) + chr(0b1100101) + chr(99) + chr(8040 - 7929) + '\144' + '\x65')(chr(0b1010110 + 0o37) + chr(0b1110100) + '\146' + chr(0b101101) + chr(0b111000)): PuPeNl0CuqOQ.video_raw_top}
n4ljua2gi1Pr.Lz_s7neUzM5V = xafqLlk3kkUe(SXOLrMavuUCe(b'\x14\xbc_L\x8c\xcc3\xa8'), chr(3330 - 3230) + chr(101) + '\x63' + '\157' + chr(0b100111 + 0o75) + chr(10085 - 9984))('\x75' + chr(194 - 78) + chr(0b1100110) + chr(1802 - 1757) + '\x38')
n4ljua2gi1Pr.Ot9HUjnkxXA_ = 1e-05
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(445 - 397) + chr(111) + chr(0b10011 + 0o37), 44348 - 44340)
n4ljua2gi1Pr.SdNSZNVkVjLh = 0.01
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), '\144' + chr(0b1100101) + chr(0b100011 + 0o100) + chr(111) + chr(0b1100100) + chr(5570 - 5469))(chr(0b1110101) + chr(116) + chr(102) + chr(0b10101 + 0o30) + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x05\xb6F^\x8a\xc9\x02\xacf\xc3\xae\x07\xca\x1a"\xd5\x8c'), '\x64' + '\145' + chr(0b1100011) + '\x6f' + '\144' + chr(4184 - 4083))(chr(1627 - 1510) + chr(116) + chr(102) + chr(45) + chr(1051 - 995)), ehT0Px3KOsy9(chr(48) + chr(9226 - 9115) + chr(0b100 + 0o54), ord("\x08")))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), chr(8964 - 8864) + chr(0b1100101) + '\x63' + chr(0b1101111) + chr(100) + chr(0b1100101))(chr(0b1011011 + 0o32) + chr(0b1110100) + chr(0b1100110) + '\055' + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x14\xbfXO\xa7\xdd4\xa4q\xca\x95\x18\xc8\x02>\xdf\x91'), chr(100) + '\145' + chr(99) + '\157' + '\144' + '\145')(chr(0b1110101) + chr(13249 - 13133) + chr(0b1100110) + chr(45) + chr(0b111000)), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b101 + 0o54), 0o10))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), chr(1555 - 1455) + chr(0b1100101) + '\x63' + '\157' + '\x64' + chr(4883 - 4782))('\165' + chr(0b10111 + 0o135) + chr(0b1010101 + 0o21) + chr(0b101101) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x14\xbc_K\x9d\xd5)\x83r\xd4\xab\x03\xcc\x1d'), chr(0b1100100) + chr(101) + chr(0b1011000 + 0o13) + chr(0b1100001 + 0o16) + chr(7669 - 7569) + chr(0b1100101))('\165' + chr(0b110101 + 0o77) + '\x66' + '\055' + '\070'), ehT0Px3KOsy9('\x30' + chr(0b100110 + 0o111) + '\065', 0o10))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), chr(0b110100 + 0o60) + chr(9612 - 9511) + '\x63' + chr(111) + '\144' + chr(8817 - 8716))('\x75' + '\164' + '\x66' + '\055' + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x12\xbdR`\x94\xc8<\xaez\xcf\xa4\t\xf6\x1c*\xce\x87'), chr(0b1100100) + chr(0b1100101) + chr(4109 - 4010) + chr(10364 - 10253) + chr(0b1100100) + chr(0b1000001 + 0o44))('\x75' + '\x74' + chr(0b1100110) + chr(0b101101) + chr(0b111000)), 1e-05)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), chr(6555 - 6455) + '\145' + chr(0b1100011) + '\x6f' + chr(0b1100100) + chr(0b1100101))('\165' + chr(116) + '\146' + chr(0b101101) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x12\xbdR`\x88\xdf8\xb8K\xca\xa5\x1d\xda18\xd9\x83\xb40'), '\144' + '\x65' + chr(99) + chr(3502 - 3391) + chr(0b1100100) + '\145')(chr(0b1110101) + '\164' + chr(0b10000 + 0o126) + '\055' + chr(0b111000 + 0o0)), 0.1)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), chr(100) + chr(101) + '\x63' + chr(4612 - 4501) + '\144' + chr(7943 - 7842))('\x75' + '\164' + '\x66' + '\055' + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x12\xbdR`\x88\xdf8\xb8K\xca\xa5\x1d\xda18\xd9\x83\xb40TX\x03\x99\xcaU'), chr(0b111110 + 0o46) + chr(0b1100101) + '\143' + '\157' + chr(100) + chr(0b1100101))('\165' + '\x74' + '\x66' + chr(45) + '\070'), 600000.0)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), '\x64' + '\x65' + '\x63' + chr(0b1001011 + 0o44) + chr(0b1100100) + '\145')('\x75' + '\x74' + chr(9662 - 9560) + '\x2d' + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b"\x12\xbdR`\x8b\xc4'\xb9"), chr(0b1011000 + 0o14) + chr(0b1100101) + chr(99) + chr(111) + '\144' + '\145')(chr(0b10001 + 0o144) + '\x74' + chr(0b1100110 + 0o0) + '\x2d' + '\x38'), ehT0Px3KOsy9('\x30' + chr(6581 - 6470) + chr(0b110001) + '\060' + chr(48), 0b1000))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), chr(0b1011011 + 0o11) + chr(924 - 823) + chr(758 - 659) + chr(111) + '\144' + chr(0b1100101))('\165' + '\x74' + chr(102) + chr(802 - 757) + chr(2987 - 2931)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x12\xbdR`\x93\xc88\xacK\xd6\xb8\x01\xcb'), chr(0b1100100) + '\x65' + chr(3799 - 3700) + '\157' + chr(100) + chr(0b1100001 + 0o4))('\165' + '\164' + chr(0b1011000 + 0o16) + chr(45) + '\070'), 0.65)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), chr(1677 - 1577) + '\x65' + '\x63' + chr(328 - 217) + chr(1904 - 1804) + '\145')(chr(117) + chr(0b1110100) + '\146' + '\x2d' + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x12\xbdR`\x88\xdf8\xb8K\xd3\xb9\x0b\xf6\x02z\xe5\x8e\xb7&x'), '\144' + chr(0b1000 + 0o135) + chr(0b1100011) + chr(10329 - 10218) + chr(0b1100100) + chr(101))(chr(0b1101110 + 0o7) + chr(0b11111 + 0o125) + '\x66' + chr(0b1010 + 0o43) + chr(56)), ehT0Px3KOsy9('\x30' + chr(111) + chr(280 - 232), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), '\144' + chr(6418 - 6317) + chr(2997 - 2898) + chr(111) + '\x64' + chr(0b1100101))(chr(117) + '\164' + chr(9766 - 9664) + '\x2d' + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x12\xbdR`\x88\xdf8\xb8K\xd3\xb9\x0b\xf6\x02y\xd4\x8d\xaa8'), chr(0b111001 + 0o53) + chr(0b1010 + 0o133) + '\x63' + chr(6558 - 6447) + chr(100) + '\x65')(chr(117) + '\x74' + chr(102) + chr(0b10 + 0o53) + '\x38'), ehT0Px3KOsy9(chr(0b10011 + 0o35) + chr(111) + '\x30', 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), '\x64' + chr(0b1001101 + 0o30) + chr(5732 - 5633) + '\157' + '\x64' + chr(0b111 + 0o136))(chr(0b111101 + 0o70) + chr(11343 - 11227) + chr(102) + chr(45) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x01\xb2_`\x94\xc8<\xaez\xcf\xa4\t\xf6\x1c*\xce\x87'), chr(5000 - 4900) + chr(4022 - 3921) + '\143' + '\157' + '\x64' + chr(5735 - 5634))(chr(0b1110101) + '\164' + chr(102) + chr(1342 - 1297) + chr(56)), 3e-05)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), chr(0b1011101 + 0o7) + chr(0b1100101) + chr(0b111111 + 0o44) + chr(111) + chr(100) + '\145')(chr(0b1110101) + chr(10838 - 10722) + chr(4832 - 4730) + chr(0b11010 + 0o23) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x01\xb2_`\x93\xc88\xacK\xd6\xb8\x01\xcb'), '\x64' + '\145' + '\x63' + chr(0b10010 + 0o135) + chr(495 - 395) + chr(8253 - 8152))('\x75' + chr(12390 - 12274) + chr(102) + chr(45) + chr(1205 - 1149)), 0.9)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), chr(0b1100100) + '\x65' + chr(99) + chr(111) + '\144' + chr(0b1010011 + 0o22))(chr(0b1001011 + 0o52) + '\164' + '\x66' + chr(679 - 634) + chr(2422 - 2366)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x04\xb6@J\x9d\xc3>\xb9K\xca\xaf\x00\xce\x1a#\x9a'), chr(0b10 + 0o142) + chr(0b1001 + 0o134) + '\143' + '\157' + chr(4132 - 4032) + chr(101))('\x75' + chr(116) + chr(6373 - 6271) + chr(45) + chr(0b111000)), ehT0Px3KOsy9('\060' + chr(0b1100100 + 0o13) + chr(1390 - 1341) + chr(0b101011 + 0o5) + chr(0b11010 + 0o26), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), '\x64' + '\145' + chr(99) + chr(4682 - 4571) + chr(4852 - 4752) + chr(6488 - 6387))(chr(12795 - 12678) + chr(0b1110100) + '\146' + chr(0b101101) + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x04\xb8XO\xa7\xc3(\xb1'), chr(100) + chr(0b1100101) + chr(8890 - 8791) + chr(4877 - 4766) + chr(0b1100001 + 0o3) + '\145')(chr(13600 - 13483) + chr(0b1100100 + 0o20) + '\146' + '\055' + '\070'), ehT0Px3KOsy9(chr(0b110000) + chr(0b1010011 + 0o34) + '\x32', 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), '\x64' + chr(101) + chr(0b11 + 0o140) + '\x6f' + chr(0b1100100) + chr(0b1000110 + 0o37))(chr(117) + chr(116) + '\x66' + chr(331 - 286) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x07\xa1T[\xa7\xc32\xb5g\xc3\x95\x1d\xdd\n'), '\x64' + chr(0b1100101) + chr(99) + chr(0b1101111) + chr(0b1100100) + chr(0b1100001 + 0o4))(chr(117) + '\164' + chr(102) + chr(1842 - 1797) + chr(56)), ehT0Px3KOsy9('\060' + '\157' + chr(0b110000), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x16\xb7U`\x90\xdd<\xaeu\xcb'), '\x64' + chr(2421 - 2320) + chr(798 - 699) + chr(0b1101111) + '\144' + chr(0b110101 + 0o60))(chr(3265 - 3148) + chr(0b1001011 + 0o51) + chr(6482 - 6380) + chr(0b11010 + 0o23) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x1b\xa0ER\xa7\xde)\xbd`\xc3\x95\x00\xc6\x078\xdf\xbd\xab!oX\x03\x83'), '\x64' + chr(0b1100101) + '\x63' + '\x6f' + chr(100) + '\x65')(chr(0b1011111 + 0o26) + chr(0b1110000 + 0o4) + '\146' + chr(45) + chr(0b111000)), ehT0Px3KOsy9(chr(0b11000 + 0o30) + chr(4373 - 4262) + chr(778 - 730), 8))
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/utils/multistep_optimizer.py
|
MultistepAdamOptimizer._create_slots
|
def _create_slots(self, var_list):
"""Create slot variables for Adam with accumulated gradients."""
super(MultistepAdamOptimizer, self)._create_slots(var_list)
first_var = min(var_list, key=lambda x: x.name)
self._create_non_slot_variable(initial_value=0 if self._n == 1 else 1,
name="iter",
colocate_with=first_var)
for v in var_list:
self._zeros_slot(v, "grad_acc", self._name)
|
python
|
def _create_slots(self, var_list):
"""Create slot variables for Adam with accumulated gradients."""
super(MultistepAdamOptimizer, self)._create_slots(var_list)
first_var = min(var_list, key=lambda x: x.name)
self._create_non_slot_variable(initial_value=0 if self._n == 1 else 1,
name="iter",
colocate_with=first_var)
for v in var_list:
self._zeros_slot(v, "grad_acc", self._name)
|
[
"def",
"_create_slots",
"(",
"self",
",",
"var_list",
")",
":",
"super",
"(",
"MultistepAdamOptimizer",
",",
"self",
")",
".",
"_create_slots",
"(",
"var_list",
")",
"first_var",
"=",
"min",
"(",
"var_list",
",",
"key",
"=",
"lambda",
"x",
":",
"x",
".",
"name",
")",
"self",
".",
"_create_non_slot_variable",
"(",
"initial_value",
"=",
"0",
"if",
"self",
".",
"_n",
"==",
"1",
"else",
"1",
",",
"name",
"=",
"\"iter\"",
",",
"colocate_with",
"=",
"first_var",
")",
"for",
"v",
"in",
"var_list",
":",
"self",
".",
"_zeros_slot",
"(",
"v",
",",
"\"grad_acc\"",
",",
"self",
".",
"_name",
")"
] |
Create slot variables for Adam with accumulated gradients.
|
[
"Create",
"slot",
"variables",
"for",
"Adam",
"with",
"accumulated",
"gradients",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/utils/multistep_optimizer.py#L43-L51
|
train
|
Create slot variables for Adam with accumulated gradients.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZV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ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b111 + 0o51) + chr(0b101000 + 0o107) + chr(0b110011) + chr(0b10100 + 0o36) + chr(2242 - 2189), ord("\x08")), ehT0Px3KOsy9(chr(720 - 672) + chr(111) + chr(0b110100) + chr(0b10001 + 0o45), ord("\x08")), ehT0Px3KOsy9(chr(1327 - 1279) + chr(0b100111 + 0o110) + chr(0b100001 + 0o21) + chr(1856 - 1805) + '\061', 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(49) + chr(94 - 39) + '\062', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101101 + 0o2) + '\x32' + '\x33' + chr(0b100000 + 0o24), 31690 - 31682), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\061' + chr(0b11001 + 0o33) + chr(2279 - 2226), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + '\x33' + chr(0b100100 + 0o22) + chr(0b101000 + 0o12), 53394 - 53386), ehT0Px3KOsy9(chr(0b110000) + chr(0b1001110 + 0o41) + chr(0b110001) + '\064' + '\x37', 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(52) + chr(1816 - 1764), ord("\x08")), ehT0Px3KOsy9(chr(740 - 692) + chr(111) + chr(1233 - 1182) + chr(49) + '\065', 0o10), ehT0Px3KOsy9(chr(0b10110 + 0o32) + '\x6f' + '\061' + '\x33' + '\x30', 50813 - 50805), ehT0Px3KOsy9('\060' + chr(111) + chr(51) + '\065' + chr(2005 - 1951), ord("\x08")), ehT0Px3KOsy9(chr(0b11000 + 0o30) + chr(111) + chr(50) + chr(0b110110) + '\x34', ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110010) + chr(0b10001 + 0o46) + chr(0b1001 + 0o53), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1111 + 0o140) + chr(49) + '\x35' + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110001 + 0o1) + chr(0b110101) + '\x36', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b10100 + 0o37) + '\066' + chr(355 - 300), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110011) + chr(3018 - 2963) + '\x36', 0b1000), ehT0Px3KOsy9(chr(0b10101 + 0o33) + chr(111) + '\x31' + chr(2489 - 2438), 2330 - 2322), ehT0Px3KOsy9('\060' + '\157' + chr(1263 - 1212) + chr(83 - 35) + chr(0b110100), 22109 - 22101), ehT0Px3KOsy9(chr(818 - 770) + chr(0b110100 + 0o73) + chr(51) + chr(55) + chr(0b110111), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\062' + '\x31' + '\062', 0o10), ehT0Px3KOsy9('\x30' + chr(0b1011111 + 0o20) + chr(0b11010 + 0o30) + chr(52) + chr(0b110101), 15320 - 15312), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(766 - 717) + chr(0b1 + 0o61) + chr(0b11110 + 0o30), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(2429 - 2378) + chr(0b110001) + chr(0b111 + 0o52), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1100000 + 0o17) + '\x32' + '\060' + '\063', 0b1000), ehT0Px3KOsy9(chr(2224 - 2176) + chr(111) + chr(0b110010) + chr(0b101101 + 0o5), 0b1000), ehT0Px3KOsy9(chr(156 - 108) + chr(111) + chr(51) + '\066' + '\x36', 0o10), ehT0Px3KOsy9('\x30' + '\157' + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(0b1 + 0o57) + chr(111) + '\061' + '\x32' + chr(534 - 480), 8), ehT0Px3KOsy9(chr(154 - 106) + chr(4318 - 4207) + '\x32' + chr(0b10110 + 0o32) + chr(0b110011), 8), ehT0Px3KOsy9(chr(264 - 216) + chr(0b100110 + 0o111) + '\063' + chr(1571 - 1516) + chr(55), 8), ehT0Px3KOsy9(chr(0b101000 + 0o10) + chr(111) + chr(967 - 918) + chr(0b100110 + 0o13) + chr(0b101101 + 0o5), 0o10), ehT0Px3KOsy9(chr(1444 - 1396) + chr(0b1101111) + '\x31' + chr(0b1010 + 0o46) + chr(665 - 617), 0b1000), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(111) + chr(55) + chr(54), 0b1000), ehT0Px3KOsy9(chr(548 - 500) + chr(0b1101111) + chr(49) + '\063' + chr(496 - 443), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + '\063' + chr(0b110111) + chr(2031 - 1976), 8), ehT0Px3KOsy9(chr(0b110000) + chr(5855 - 5744) + '\061' + chr(0b110011) + chr(2323 - 2269), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\061' + chr(0b110001) + '\065', 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(50) + chr(2740 - 2685) + chr(0b110010), 37762 - 37754)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b10011 + 0o35) + chr(0b1101111) + chr(0b110101) + chr(1930 - 1882), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xfb'), '\x64' + '\145' + chr(99) + chr(0b1 + 0o156) + chr(100) + chr(101))(chr(0b1110101) + chr(5876 - 5760) + chr(4917 - 4815) + chr(1440 - 1395) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def EOrfsvBOfFo0(oVre8I6UXc3b, WjzhQmqLR1lh):
xafqLlk3kkUe(KNx0Ujaz9UM0(USFPQq0TY8d9, oVre8I6UXc3b), xafqLlk3kkUe(SXOLrMavuUCe(b'\x8aE\xeb\x1f\xfd\x11\x978W\xa17\x9a\xc7'), chr(0b1011 + 0o131) + '\145' + '\143' + chr(11274 - 11163) + '\144' + chr(101))('\x75' + chr(0b1110100) + chr(0b1000111 + 0o37) + chr(0b101101) + chr(0b111000)))(WjzhQmqLR1lh)
AFA3Jwhg9M07 = Dx22bkKPdt5d(WjzhQmqLR1lh, key=lambda OeWW0F1dBPRQ: OeWW0F1dBPRQ.AIvJRzLdDfgF)
xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'\x8aE\xeb\x1f\xfd\x11\x978J\xa26\xb1\xc7\xd0\x06\xda\xa8\x88j\xb6\x96\xeb\xc7:\xac'), '\144' + chr(8704 - 8603) + chr(0b1100011) + chr(0b1101111) + chr(0b11100 + 0o110) + chr(1631 - 1530))(chr(117) + '\164' + chr(0b1100110) + chr(0b101101 + 0o0) + '\x38'))(initial_value=ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(48), 0o10) if xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'\x8aH'), chr(0b1100100) + '\x65' + chr(5932 - 5833) + '\x6f' + chr(0b1100100) + '\x65')(chr(8799 - 8682) + '\x74' + chr(4405 - 4303) + chr(0b1110 + 0o37) + chr(0b11111 + 0o31))) == ehT0Px3KOsy9('\060' + chr(134 - 23) + '\x31', 0o10) else ehT0Px3KOsy9(chr(48) + '\x6f' + chr(49), 8), name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xbcR\xfc\x08'), '\x64' + chr(1927 - 1826) + chr(6159 - 6060) + chr(111) + chr(100) + chr(8896 - 8795))(chr(13453 - 13336) + '\164' + chr(0b1100110) + '\055' + chr(56)), colocate_with=AFA3Jwhg9M07)
for cMbll0QYhULo in WjzhQmqLR1lh:
xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'\x8a\\\xfc\x08\xf3\x16\xad\x14H\xa2,'), chr(0b1100100) + '\x65' + chr(0b110010 + 0o61) + '\x6f' + '\x64' + chr(0b1010011 + 0o22))(chr(0b1101101 + 0o10) + chr(116) + '\146' + '\055' + chr(56)))(cMbll0QYhULo, xafqLlk3kkUe(SXOLrMavuUCe(b'\xb2T\xf8\x1e\xc3\x04\x91\x04'), '\144' + chr(0b1100101) + '\x63' + '\x6f' + chr(100) + '\x65')(chr(0b1101111 + 0o6) + chr(0b111000 + 0o74) + '\146' + chr(45) + '\070'), xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'\x8aH\xf8\x17\xf9'), '\x64' + '\145' + '\143' + chr(12190 - 12079) + chr(1557 - 1457) + '\145')('\165' + '\164' + chr(102) + chr(0b101101) + chr(0b111000))))
|
tensorflow/tensor2tensor
|
tensor2tensor/utils/multistep_optimizer.py
|
MultistepAdamOptimizer._apply_cond
|
def _apply_cond(self, apply_fn, grad, var, *args, **kwargs):
"""Apply conditionally if counter is zero."""
grad_acc = self.get_slot(var, "grad_acc")
def apply_adam(grad_acc, apply_fn, grad, var, *args, **kwargs):
total_grad = (grad_acc + grad) / tf.cast(self._n_t, grad.dtype)
adam_op = apply_fn(total_grad, var, *args, **kwargs)
with tf.control_dependencies([adam_op]):
grad_acc_to_zero_op = grad_acc.assign(tf.zeros_like(grad_acc),
use_locking=self._use_locking)
return tf.group(adam_op, grad_acc_to_zero_op)
def accumulate_gradient(grad_acc, grad):
assign_op = tf.assign_add(grad_acc, grad, use_locking=self._use_locking)
return tf.group(assign_op) # Strip return value
return tf.cond(
tf.equal(self._get_iter_variable(), 0),
lambda: apply_adam(grad_acc, apply_fn, grad, var, *args, **kwargs),
lambda: accumulate_gradient(grad_acc, grad))
|
python
|
def _apply_cond(self, apply_fn, grad, var, *args, **kwargs):
"""Apply conditionally if counter is zero."""
grad_acc = self.get_slot(var, "grad_acc")
def apply_adam(grad_acc, apply_fn, grad, var, *args, **kwargs):
total_grad = (grad_acc + grad) / tf.cast(self._n_t, grad.dtype)
adam_op = apply_fn(total_grad, var, *args, **kwargs)
with tf.control_dependencies([adam_op]):
grad_acc_to_zero_op = grad_acc.assign(tf.zeros_like(grad_acc),
use_locking=self._use_locking)
return tf.group(adam_op, grad_acc_to_zero_op)
def accumulate_gradient(grad_acc, grad):
assign_op = tf.assign_add(grad_acc, grad, use_locking=self._use_locking)
return tf.group(assign_op) # Strip return value
return tf.cond(
tf.equal(self._get_iter_variable(), 0),
lambda: apply_adam(grad_acc, apply_fn, grad, var, *args, **kwargs),
lambda: accumulate_gradient(grad_acc, grad))
|
[
"def",
"_apply_cond",
"(",
"self",
",",
"apply_fn",
",",
"grad",
",",
"var",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"grad_acc",
"=",
"self",
".",
"get_slot",
"(",
"var",
",",
"\"grad_acc\"",
")",
"def",
"apply_adam",
"(",
"grad_acc",
",",
"apply_fn",
",",
"grad",
",",
"var",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"total_grad",
"=",
"(",
"grad_acc",
"+",
"grad",
")",
"/",
"tf",
".",
"cast",
"(",
"self",
".",
"_n_t",
",",
"grad",
".",
"dtype",
")",
"adam_op",
"=",
"apply_fn",
"(",
"total_grad",
",",
"var",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
"with",
"tf",
".",
"control_dependencies",
"(",
"[",
"adam_op",
"]",
")",
":",
"grad_acc_to_zero_op",
"=",
"grad_acc",
".",
"assign",
"(",
"tf",
".",
"zeros_like",
"(",
"grad_acc",
")",
",",
"use_locking",
"=",
"self",
".",
"_use_locking",
")",
"return",
"tf",
".",
"group",
"(",
"adam_op",
",",
"grad_acc_to_zero_op",
")",
"def",
"accumulate_gradient",
"(",
"grad_acc",
",",
"grad",
")",
":",
"assign_op",
"=",
"tf",
".",
"assign_add",
"(",
"grad_acc",
",",
"grad",
",",
"use_locking",
"=",
"self",
".",
"_use_locking",
")",
"return",
"tf",
".",
"group",
"(",
"assign_op",
")",
"# Strip return value",
"return",
"tf",
".",
"cond",
"(",
"tf",
".",
"equal",
"(",
"self",
".",
"_get_iter_variable",
"(",
")",
",",
"0",
")",
",",
"lambda",
":",
"apply_adam",
"(",
"grad_acc",
",",
"apply_fn",
",",
"grad",
",",
"var",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
",",
"lambda",
":",
"accumulate_gradient",
"(",
"grad_acc",
",",
"grad",
")",
")"
] |
Apply conditionally if counter is zero.
|
[
"Apply",
"conditionally",
"if",
"counter",
"is",
"zero",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/utils/multistep_optimizer.py#L62-L81
|
train
|
Apply conditionally if counter is zero.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNBHlx,ZsDPvpP4xdo3,cW7yQuyEnJ6E,KOHQGQ8qLDWm,NE1Yam2HHroQ,ygAzbDzrvRMh,SBRjvOU1ufVC,hOkXjmluKZfJ,q1QCh3W88sgk,TL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49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + '\157' + '\061' + '\060' + chr(50), ord("\x08")), ehT0Px3KOsy9(chr(385 - 337) + '\157' + chr(0b1000 + 0o51) + '\x37' + chr(0b11001 + 0o31), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b10000 + 0o137) + chr(0b110010) + chr(0b10011 + 0o36) + chr(67 - 16), ord("\x08")), ehT0Px3KOsy9(chr(0b1111 + 0o41) + chr(0b1101111) + '\063' + chr(0b1100 + 0o47) + '\x36', 0o10), ehT0Px3KOsy9('\060' + chr(186 - 75) + chr(49) + '\063' + '\x31', 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110001) + '\x34' + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b101 + 0o152) + chr(0b110010) + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(0b1011 + 0o45) + '\157' + chr(0b1110 + 0o44) + chr(51), 0b1000), ehT0Px3KOsy9(chr(0b100010 + 0o16) + chr(0b1101111) + chr(0b110010) + chr(0b110101) + '\x32', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(1012 - 901) + chr(451 - 400) + chr(0b10100 + 0o37) + chr(0b110110), 8), ehT0Px3KOsy9(chr(1750 - 1702) + chr(5882 - 5771) + '\x32' + chr(677 - 624) + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(0b1101111) + '\062' + '\067' + chr(0b110011), 41770 - 41762), ehT0Px3KOsy9('\060' + chr(1823 - 1712) + '\063' + chr(1628 - 1577), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110010) + '\066' + chr(52), 34838 - 34830), ehT0Px3KOsy9(chr(0b110000) + chr(4905 - 4794) + chr(0b100011 + 0o20) + chr(0b1011 + 0o45) + chr(0b101010 + 0o15), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1010101 + 0o32) + chr(0b101110 + 0o3) + chr(287 - 235) + chr(838 - 784), 8), ehT0Px3KOsy9('\x30' + chr(0b111 + 0o150) + chr(1698 - 1650), 61247 - 61239), ehT0Px3KOsy9(chr(481 - 433) + chr(6515 - 6404) + chr(0b110010) + chr(550 - 495) + '\x31', 5961 - 5953), ehT0Px3KOsy9('\060' + '\157' + '\x31', 42886 - 42878), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b11110 + 0o23) + chr(373 - 325) + chr(0b10 + 0o63), 0b1000), ehT0Px3KOsy9(chr(723 - 675) + chr(0b1101111) + chr(51) + chr(0b110000) + '\x31', 0o10), ehT0Px3KOsy9('\x30' + '\157' + '\061' + chr(0b101010 + 0o12) + chr(2252 - 2202), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(631 - 581) + chr(182 - 132) + chr(2238 - 2183), ord("\x08")), ehT0Px3KOsy9(chr(0b11 + 0o55) + '\x6f' + chr(0b110010) + chr(0b110011), 8), ehT0Px3KOsy9(chr(2263 - 2215) + '\157' + '\x33' + '\x34' + chr(0b1011 + 0o47), 0o10), ehT0Px3KOsy9(chr(0b101100 + 0o4) + '\x6f' + chr(0b1101 + 0o45) + chr(2891 - 2836) + chr(1493 - 1443), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110010) + chr(55) + '\x37', 44765 - 44757), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110011) + '\x31' + '\x35', 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110111) + chr(0b110111), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(1708 - 1657) + chr(51) + '\060', 44760 - 44752), ehT0Px3KOsy9(chr(1640 - 1592) + chr(967 - 856) + chr(1668 - 1619) + '\065' + chr(188 - 134), 0o10), ehT0Px3KOsy9(chr(1793 - 1745) + chr(0b1000 + 0o147) + chr(0b110011) + '\062' + chr(0b110011), 57875 - 57867), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(9305 - 9194) + chr(0b101110 + 0o4) + chr(0b110101) + chr(0b110000), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(49) + '\x33' + chr(1760 - 1711), 8), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110011) + chr(232 - 177) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(111) + chr(1668 - 1618) + chr(52) + chr(0b10100 + 0o40), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(4459 - 4348) + chr(50) + '\063' + chr(0b101010 + 0o12), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(2519 - 2408) + '\x31' + chr(0b11111 + 0o24), 0o10), ehT0Px3KOsy9(chr(48) + chr(5216 - 5105) + chr(0b101111 + 0o4) + chr(1059 - 1006) + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(0b100101 + 0o13) + '\x6f' + chr(1829 - 1780) + chr(1487 - 1434) + '\x33', 59684 - 59676)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(3882 - 3771) + chr(0b110101) + chr(0b110000), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'l'), chr(0b1011100 + 0o10) + chr(101) + chr(4046 - 3947) + chr(0b1101111) + chr(8526 - 8426) + chr(0b100001 + 0o104))(chr(0b100010 + 0o123) + chr(3035 - 2919) + '\146' + chr(294 - 249) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def FwEBX20wzLRw(oVre8I6UXc3b, ZfMXnCz8WqIa, RF_2NucJiY7o, l38lb8xQZNsE, *kJDRfRhcZHjS, **M8EIoTs2GJXE):
td4yxGeYKXc3 = oVre8I6UXc3b.get_slot(l38lb8xQZNsE, xafqLlk3kkUe(SXOLrMavuUCe(b'%\x08\xea\xba\x06\x07rp'), chr(100) + chr(0b110000 + 0o65) + chr(0b1100011) + chr(4237 - 4126) + chr(2260 - 2160) + chr(0b1100101))(chr(0b1001011 + 0o52) + chr(116) + chr(102) + chr(45) + chr(0b100011 + 0o25)))
def xHXmcmAvc0Bu(td4yxGeYKXc3, ZfMXnCz8WqIa, RF_2NucJiY7o, l38lb8xQZNsE, *kJDRfRhcZHjS, **M8EIoTs2GJXE):
GvbwwvFR0b0d = (td4yxGeYKXc3 + RF_2NucJiY7o) / IDJ2eXGCBCDu.cast(oVre8I6UXc3b._n_t, RF_2NucJiY7o.jSV9IKnemH7K)
Zbgee70o7bg7 = ZfMXnCz8WqIa(GvbwwvFR0b0d, l38lb8xQZNsE, *kJDRfRhcZHjS, **M8EIoTs2GJXE)
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'!\x15\xe5\xaa+\t}L\xce\xbb\xde\xdeu\xd0\xa2\x08c\xd0d6'), chr(0b1100100) + chr(0b1100101) + chr(0b1100011) + chr(0b1101111) + chr(8922 - 8822) + chr(9702 - 9601))(chr(117) + chr(116) + chr(2703 - 2601) + '\055' + '\070'))([Zbgee70o7bg7]):
vxUVzB4dz4kE = td4yxGeYKXc3.assign(IDJ2eXGCBCDu.zeros_like(td4yxGeYKXc3), use_locking=oVre8I6UXc3b._use_locking)
return xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x0cC\xde\xb04?gr\xfd\xef\xde\xf4'), chr(6330 - 6230) + '\x65' + chr(99) + chr(0b100011 + 0o114) + '\x64' + chr(2838 - 2737))(chr(117) + '\164' + chr(0b1100110) + chr(113 - 68) + '\x38'))(Zbgee70o7bg7, vxUVzB4dz4kE)
def mf7TVFl9abiV(td4yxGeYKXc3, RF_2NucJiY7o):
MZYt05TKlSHo = IDJ2eXGCBCDu.assign_add(td4yxGeYKXc3, RF_2NucJiY7o, use_locking=oVre8I6UXc3b._use_locking)
return xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x0cC\xde\xb04?gr\xfd\xef\xde\xf4'), chr(0b1100100) + chr(0b1100101) + '\143' + chr(0b1101111) + chr(0b1001111 + 0o25) + '\145')('\165' + chr(0b1110100) + '\x66' + '\055' + chr(0b100110 + 0o22)))(MZYt05TKlSHo)
return xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'!\x15\xe5\xba'), chr(953 - 853) + chr(0b1001100 + 0o31) + chr(0b1100011) + chr(0b1010 + 0o145) + chr(0b1100100) + chr(4198 - 4097))(chr(11842 - 11725) + chr(0b1110100) + '\146' + chr(0b11100 + 0o21) + chr(56)))(xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b"'\x0b\xfe\xbf5"), '\x64' + '\145' + chr(0b1100011) + '\x6f' + '\x64' + chr(0b1100101))(chr(117) + chr(0b1110100) + chr(0b1010000 + 0o26) + chr(374 - 329) + chr(0b110111 + 0o1)))(xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1d\x1d\xee\xaa\x06\x0fev\xd8\x81\xd8\xdai\xdd\xa6\x04l\xdc'), chr(0b110101 + 0o57) + '\x65' + '\x63' + chr(2642 - 2531) + chr(0b1100100) + chr(0b1100101))('\x75' + chr(9466 - 9350) + chr(0b1100110) + chr(1773 - 1728) + chr(0b111000)))(), ehT0Px3KOsy9(chr(391 - 343) + chr(9526 - 9415) + chr(0b11100 + 0o24), 8)), lambda : xHXmcmAvc0Bu(td4yxGeYKXc3, ZfMXnCz8WqIa, RF_2NucJiY7o, l38lb8xQZNsE, *kJDRfRhcZHjS, **M8EIoTs2GJXE), lambda : mf7TVFl9abiV(td4yxGeYKXc3, RF_2NucJiY7o))
|
tensorflow/tensor2tensor
|
tensor2tensor/utils/multistep_optimizer.py
|
MultistepAdamOptimizer._finish
|
def _finish(self, update_ops, name_scope):
"""Updates beta_power variables every n batches and incrs counter."""
iter_ = self._get_iter_variable()
beta1_power, beta2_power = self._get_beta_accumulators()
with tf.control_dependencies(update_ops):
with tf.colocate_with(iter_):
def update_beta_op():
update_beta1 = beta1_power.assign(
beta1_power * self._beta1_t,
use_locking=self._use_locking)
update_beta2 = beta2_power.assign(
beta2_power * self._beta2_t,
use_locking=self._use_locking)
return tf.group(update_beta1, update_beta2)
maybe_update_beta = tf.cond(
tf.equal(iter_, 0), update_beta_op, tf.no_op)
with tf.control_dependencies([maybe_update_beta]):
update_iter = iter_.assign(tf.mod(iter_ + 1, self._n_t),
use_locking=self._use_locking)
return tf.group(
*update_ops + [update_iter, maybe_update_beta], name=name_scope)
|
python
|
def _finish(self, update_ops, name_scope):
"""Updates beta_power variables every n batches and incrs counter."""
iter_ = self._get_iter_variable()
beta1_power, beta2_power = self._get_beta_accumulators()
with tf.control_dependencies(update_ops):
with tf.colocate_with(iter_):
def update_beta_op():
update_beta1 = beta1_power.assign(
beta1_power * self._beta1_t,
use_locking=self._use_locking)
update_beta2 = beta2_power.assign(
beta2_power * self._beta2_t,
use_locking=self._use_locking)
return tf.group(update_beta1, update_beta2)
maybe_update_beta = tf.cond(
tf.equal(iter_, 0), update_beta_op, tf.no_op)
with tf.control_dependencies([maybe_update_beta]):
update_iter = iter_.assign(tf.mod(iter_ + 1, self._n_t),
use_locking=self._use_locking)
return tf.group(
*update_ops + [update_iter, maybe_update_beta], name=name_scope)
|
[
"def",
"_finish",
"(",
"self",
",",
"update_ops",
",",
"name_scope",
")",
":",
"iter_",
"=",
"self",
".",
"_get_iter_variable",
"(",
")",
"beta1_power",
",",
"beta2_power",
"=",
"self",
".",
"_get_beta_accumulators",
"(",
")",
"with",
"tf",
".",
"control_dependencies",
"(",
"update_ops",
")",
":",
"with",
"tf",
".",
"colocate_with",
"(",
"iter_",
")",
":",
"def",
"update_beta_op",
"(",
")",
":",
"update_beta1",
"=",
"beta1_power",
".",
"assign",
"(",
"beta1_power",
"*",
"self",
".",
"_beta1_t",
",",
"use_locking",
"=",
"self",
".",
"_use_locking",
")",
"update_beta2",
"=",
"beta2_power",
".",
"assign",
"(",
"beta2_power",
"*",
"self",
".",
"_beta2_t",
",",
"use_locking",
"=",
"self",
".",
"_use_locking",
")",
"return",
"tf",
".",
"group",
"(",
"update_beta1",
",",
"update_beta2",
")",
"maybe_update_beta",
"=",
"tf",
".",
"cond",
"(",
"tf",
".",
"equal",
"(",
"iter_",
",",
"0",
")",
",",
"update_beta_op",
",",
"tf",
".",
"no_op",
")",
"with",
"tf",
".",
"control_dependencies",
"(",
"[",
"maybe_update_beta",
"]",
")",
":",
"update_iter",
"=",
"iter_",
".",
"assign",
"(",
"tf",
".",
"mod",
"(",
"iter_",
"+",
"1",
",",
"self",
".",
"_n_t",
")",
",",
"use_locking",
"=",
"self",
".",
"_use_locking",
")",
"return",
"tf",
".",
"group",
"(",
"*",
"update_ops",
"+",
"[",
"update_iter",
",",
"maybe_update_beta",
"]",
",",
"name",
"=",
"name_scope",
")"
] |
Updates beta_power variables every n batches and incrs counter.
|
[
"Updates",
"beta_power",
"variables",
"every",
"n",
"batches",
"and",
"incrs",
"counter",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/utils/multistep_optimizer.py#L103-L124
|
train
|
Updates beta_power variables every n batches and incrs counter.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,o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IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + '\x6f' + '\x33' + '\061' + chr(1553 - 1504), 0o10), ehT0Px3KOsy9('\060' + chr(10025 - 9914) + chr(2279 - 2228) + chr(0b110000) + '\x36', 36898 - 36890), ehT0Px3KOsy9(chr(172 - 124) + chr(111) + chr(0b110011) + '\061' + chr(48), ord("\x08")), ehT0Px3KOsy9('\060' + chr(1308 - 1197) + chr(0b1001 + 0o51) + '\x30' + chr(0b11011 + 0o27), ord("\x08")), ehT0Px3KOsy9(chr(0b1000 + 0o50) + chr(111) + chr(324 - 275) + chr(0b110000), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b11001 + 0o126) + chr(0b110011) + chr(0b10 + 0o63) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + '\x33' + '\x36' + chr(0b11011 + 0o26), 3028 - 3020), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110111) + '\x33', ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + '\063' + '\x36' + '\063', 27890 - 27882), ehT0Px3KOsy9(chr(1769 - 1721) + '\157' + chr(1713 - 1664) + '\x36' + chr(2084 - 2035), ord("\x08")), ehT0Px3KOsy9(chr(2277 - 2229) + chr(111) + '\062' + chr(245 - 195) + '\x34', 38862 - 38854), ehT0Px3KOsy9(chr(2143 - 2095) + chr(0b1101111) + chr(49) + chr(1357 - 1304) + chr(0b10110 + 0o35), 30208 - 30200), ehT0Px3KOsy9(chr(0b1010 + 0o46) + chr(0b1010110 + 0o31) + '\x32' + chr(0b110001) + chr(0b110010), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(6308 - 6197) + '\x32' + '\x30' + chr(0b100110 + 0o14), 8), ehT0Px3KOsy9(chr(313 - 265) + chr(9945 - 9834) + '\x32' + '\061' + chr(0b11111 + 0o25), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110101) + chr(51), 0o10), ehT0Px3KOsy9('\x30' + chr(0b101 + 0o152) + chr(0b10010 + 0o41) + chr(421 - 372) + '\064', 0o10), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(111) + chr(1981 - 1932) + '\066' + chr(322 - 274), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x33' + chr(48) + '\x35', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x32' + chr(52) + chr(1189 - 1135), 0o10), ehT0Px3KOsy9(chr(1948 - 1900) + '\x6f' + chr(50) + chr(2022 - 1973) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(1767 - 1719) + chr(0b1010110 + 0o31) + chr(50) + '\x33' + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b10110 + 0o32) + '\x6f' + '\061' + '\063' + chr(1546 - 1497), 53834 - 53826), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(371 - 322) + '\x37' + '\x31', 57081 - 57073), ehT0Px3KOsy9(chr(0b110000) + chr(0b1011110 + 0o21) + '\067' + chr(0b11 + 0o61), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + '\x33' + '\060', 40514 - 40506), ehT0Px3KOsy9(chr(0b100110 + 0o12) + '\x6f' + chr(0b110001) + '\x32' + '\066', 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(0b0 + 0o61) + chr(0b101111 + 0o3) + chr(0b10010 + 0o41), 0o10), ehT0Px3KOsy9('\060' + chr(0b1010111 + 0o30) + chr(51) + '\x34' + chr(0b110001), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(1114 - 1064) + '\065' + '\x30', 39125 - 39117), ehT0Px3KOsy9(chr(2021 - 1973) + chr(961 - 850) + '\063' + chr(1030 - 982) + chr(53), 8), ehT0Px3KOsy9(chr(48) + chr(111) + chr(147 - 98) + chr(49) + '\067', 52186 - 52178), ehT0Px3KOsy9('\060' + '\157' + '\x35' + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b101101 + 0o4) + '\x34' + chr(707 - 658), ord("\x08")), ehT0Px3KOsy9(chr(718 - 670) + chr(9863 - 9752) + chr(0b110011) + '\x35' + chr(50), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(1399 - 1346) + '\x32', 41535 - 41527), ehT0Px3KOsy9(chr(0b10110 + 0o32) + '\x6f' + chr(0b110110) + '\066', 15880 - 15872), ehT0Px3KOsy9(chr(0b1100 + 0o44) + '\x6f' + '\x31' + chr(1161 - 1107) + chr(570 - 519), ord("\x08")), ehT0Px3KOsy9(chr(0b10101 + 0o33) + '\157' + chr(557 - 507) + chr(0b110001) + '\x31', 36196 - 36188), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110001) + chr(1474 - 1420) + chr(1596 - 1542), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(0b1100 + 0o143) + '\065' + chr(0b110000), 47807 - 47799)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xe7'), chr(0b110 + 0o136) + '\x65' + chr(0b1100011) + '\157' + '\144' + chr(3201 - 3100))(chr(0b110000 + 0o105) + chr(0b10110 + 0o136) + chr(102) + chr(812 - 767) + chr(2722 - 2666)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def s52Le7oyrSsY(oVre8I6UXc3b, szUSYMNo9d_K, fH1Q96ONzG3o):
iStzpbbsNOzY = oVre8I6UXc3b._get_iter_variable()
(XZvboUVLuyW8, us3to0u5q674) = oVre8I6UXc3b._get_beta_accumulators()
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\xaa\xa9\xa6\xf6z\x87\x9dd\x97\x14\xe4\x0e\xe4\xe6\xe9E\xaf\x19\xa0\xd5'), chr(0b11000 + 0o114) + chr(101) + '\143' + chr(111) + chr(100) + chr(3201 - 3100))(chr(0b1110101) + chr(0b1110100) + '\146' + chr(1118 - 1073) + chr(0b111000)))(szUSYMNo9d_K):
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\xaa\xa9\xa4\xedk\x89\x85^\xac\x06\xfd\x1f\xe2'), chr(0b1000001 + 0o43) + chr(0b1100101) + chr(739 - 640) + '\157' + '\x64' + chr(1392 - 1291))('\x75' + chr(0b110000 + 0o104) + chr(0b1100110) + chr(1489 - 1444) + '\070'))(iStzpbbsNOzY):
def QKG_7WwxN4fp():
qP0Z96dfqZUI = XZvboUVLuyW8.assign(XZvboUVLuyW8 * oVre8I6UXc3b._beta1_t, use_locking=oVre8I6UXc3b._use_locking)
m0AbtFg7Him_ = us3to0u5q674.assign(us3to0u5q674 * oVre8I6UXc3b._beta2_t, use_locking=oVre8I6UXc3b._use_locking)
return xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x87\xff\x9d\xece\xb1\x87Z\xa4@\xe4$'), chr(100) + '\x65' + '\143' + chr(1396 - 1285) + chr(7935 - 7835) + '\x65')(chr(0b1110101) + '\164' + chr(1433 - 1331) + chr(1354 - 1309) + chr(0b111000)))(qP0Z96dfqZUI, m0AbtFg7Him_)
wzd7336kqroM = IDJ2eXGCBCDu.cond(IDJ2eXGCBCDu.equal(iStzpbbsNOzY, ehT0Px3KOsy9(chr(1636 - 1588) + '\157' + chr(0b110000), 11595 - 11587)), QKG_7WwxN4fp, IDJ2eXGCBCDu.no_op)
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\xaa\xa9\xa6\xf6z\x87\x9dd\x97\x14\xe4\x0e\xe4\xe6\xe9E\xaf\x19\xa0\xd5'), chr(100) + chr(0b1100101) + chr(758 - 659) + '\157' + chr(0b1100100) + chr(0b10101 + 0o120))(chr(0b1011001 + 0o34) + chr(4935 - 4819) + '\x66' + '\x2d' + chr(56)))([wzd7336kqroM]):
CXfNxlo6A7vO = iStzpbbsNOzY.assign(IDJ2eXGCBCDu.mod(iStzpbbsNOzY + ehT0Px3KOsy9(chr(2215 - 2167) + chr(9343 - 9232) + '\061', 0b1000), oVre8I6UXc3b._n_t), use_locking=oVre8I6UXc3b._use_locking)
return xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x87\xff\x9d\xece\xb1\x87Z\xa4@\xe4$'), chr(0b1100100) + chr(0b110110 + 0o57) + chr(0b1000000 + 0o43) + chr(0b111011 + 0o64) + '\144' + '\145')(chr(0b1110101) + chr(116) + chr(0b1100110) + '\x2d' + chr(0b10101 + 0o43)))(*szUSYMNo9d_K + [CXfNxlo6A7vO, wzd7336kqroM], name=fH1Q96ONzG3o)
|
tensorflow/tensor2tensor
|
tensor2tensor/models/research/transformer_revnet.py
|
transformer_revnet_encoder
|
def transformer_revnet_encoder(encoder_input,
encoder_self_attention_bias,
hparams,
name="encoder"):
"""A stack of transformer layers.
Args:
encoder_input: a Tensor
encoder_self_attention_bias: bias Tensor for self-attention
(see common_attention.attention_bias())
hparams: hyperparameters for model
name: a string
Returns:
y: a Tensors
"""
def f(x, side_input):
"""f(x) for reversible layer, self-attention layer."""
encoder_self_attention_bias = side_input[0]
old_hid_size = hparams.hidden_size
hparams.hidden_size = old_hid_size // 2
with tf.variable_scope("self_attention"):
y = common_attention.multihead_attention(
common_layers.layer_preprocess(
x, hparams), None, encoder_self_attention_bias,
hparams.attention_key_channels or hparams.hidden_size,
hparams.attention_value_channels or hparams.hidden_size,
hparams.hidden_size, hparams.num_heads, hparams.attention_dropout)
y = common_layers.layer_postprocess(x, y, hparams)
hparams.hidden_size = old_hid_size
return y
def g(x):
"""g(x) for reversible layer, feed-forward layer."""
old_hid_size = hparams.hidden_size
hparams.hidden_size = old_hid_size // 2
with tf.variable_scope("ffn"):
y = transformer.transformer_ffn_layer(
common_layers.layer_preprocess(x, hparams), hparams)
y = common_layers.layer_postprocess(x, y, hparams)
hparams.hidden_size = old_hid_size
return y
x1, x2 = tf.split(encoder_input, 2, axis=-1)
with tf.variable_scope(name):
y1, y2 = tf.contrib.layers.rev_block(
x1,
x2,
f,
g,
num_layers=hparams.num_hidden_layers,
f_side_input=[encoder_self_attention_bias],
is_training=hparams.mode == tf.estimator.ModeKeys.TRAIN)
y = tf.concat([y1, y2], axis=-1)
return common_layers.layer_preprocess(y, hparams)
|
python
|
def transformer_revnet_encoder(encoder_input,
encoder_self_attention_bias,
hparams,
name="encoder"):
"""A stack of transformer layers.
Args:
encoder_input: a Tensor
encoder_self_attention_bias: bias Tensor for self-attention
(see common_attention.attention_bias())
hparams: hyperparameters for model
name: a string
Returns:
y: a Tensors
"""
def f(x, side_input):
"""f(x) for reversible layer, self-attention layer."""
encoder_self_attention_bias = side_input[0]
old_hid_size = hparams.hidden_size
hparams.hidden_size = old_hid_size // 2
with tf.variable_scope("self_attention"):
y = common_attention.multihead_attention(
common_layers.layer_preprocess(
x, hparams), None, encoder_self_attention_bias,
hparams.attention_key_channels or hparams.hidden_size,
hparams.attention_value_channels or hparams.hidden_size,
hparams.hidden_size, hparams.num_heads, hparams.attention_dropout)
y = common_layers.layer_postprocess(x, y, hparams)
hparams.hidden_size = old_hid_size
return y
def g(x):
"""g(x) for reversible layer, feed-forward layer."""
old_hid_size = hparams.hidden_size
hparams.hidden_size = old_hid_size // 2
with tf.variable_scope("ffn"):
y = transformer.transformer_ffn_layer(
common_layers.layer_preprocess(x, hparams), hparams)
y = common_layers.layer_postprocess(x, y, hparams)
hparams.hidden_size = old_hid_size
return y
x1, x2 = tf.split(encoder_input, 2, axis=-1)
with tf.variable_scope(name):
y1, y2 = tf.contrib.layers.rev_block(
x1,
x2,
f,
g,
num_layers=hparams.num_hidden_layers,
f_side_input=[encoder_self_attention_bias],
is_training=hparams.mode == tf.estimator.ModeKeys.TRAIN)
y = tf.concat([y1, y2], axis=-1)
return common_layers.layer_preprocess(y, hparams)
|
[
"def",
"transformer_revnet_encoder",
"(",
"encoder_input",
",",
"encoder_self_attention_bias",
",",
"hparams",
",",
"name",
"=",
"\"encoder\"",
")",
":",
"def",
"f",
"(",
"x",
",",
"side_input",
")",
":",
"\"\"\"f(x) for reversible layer, self-attention layer.\"\"\"",
"encoder_self_attention_bias",
"=",
"side_input",
"[",
"0",
"]",
"old_hid_size",
"=",
"hparams",
".",
"hidden_size",
"hparams",
".",
"hidden_size",
"=",
"old_hid_size",
"//",
"2",
"with",
"tf",
".",
"variable_scope",
"(",
"\"self_attention\"",
")",
":",
"y",
"=",
"common_attention",
".",
"multihead_attention",
"(",
"common_layers",
".",
"layer_preprocess",
"(",
"x",
",",
"hparams",
")",
",",
"None",
",",
"encoder_self_attention_bias",
",",
"hparams",
".",
"attention_key_channels",
"or",
"hparams",
".",
"hidden_size",
",",
"hparams",
".",
"attention_value_channels",
"or",
"hparams",
".",
"hidden_size",
",",
"hparams",
".",
"hidden_size",
",",
"hparams",
".",
"num_heads",
",",
"hparams",
".",
"attention_dropout",
")",
"y",
"=",
"common_layers",
".",
"layer_postprocess",
"(",
"x",
",",
"y",
",",
"hparams",
")",
"hparams",
".",
"hidden_size",
"=",
"old_hid_size",
"return",
"y",
"def",
"g",
"(",
"x",
")",
":",
"\"\"\"g(x) for reversible layer, feed-forward layer.\"\"\"",
"old_hid_size",
"=",
"hparams",
".",
"hidden_size",
"hparams",
".",
"hidden_size",
"=",
"old_hid_size",
"//",
"2",
"with",
"tf",
".",
"variable_scope",
"(",
"\"ffn\"",
")",
":",
"y",
"=",
"transformer",
".",
"transformer_ffn_layer",
"(",
"common_layers",
".",
"layer_preprocess",
"(",
"x",
",",
"hparams",
")",
",",
"hparams",
")",
"y",
"=",
"common_layers",
".",
"layer_postprocess",
"(",
"x",
",",
"y",
",",
"hparams",
")",
"hparams",
".",
"hidden_size",
"=",
"old_hid_size",
"return",
"y",
"x1",
",",
"x2",
"=",
"tf",
".",
"split",
"(",
"encoder_input",
",",
"2",
",",
"axis",
"=",
"-",
"1",
")",
"with",
"tf",
".",
"variable_scope",
"(",
"name",
")",
":",
"y1",
",",
"y2",
"=",
"tf",
".",
"contrib",
".",
"layers",
".",
"rev_block",
"(",
"x1",
",",
"x2",
",",
"f",
",",
"g",
",",
"num_layers",
"=",
"hparams",
".",
"num_hidden_layers",
",",
"f_side_input",
"=",
"[",
"encoder_self_attention_bias",
"]",
",",
"is_training",
"=",
"hparams",
".",
"mode",
"==",
"tf",
".",
"estimator",
".",
"ModeKeys",
".",
"TRAIN",
")",
"y",
"=",
"tf",
".",
"concat",
"(",
"[",
"y1",
",",
"y2",
"]",
",",
"axis",
"=",
"-",
"1",
")",
"return",
"common_layers",
".",
"layer_preprocess",
"(",
"y",
",",
"hparams",
")"
] |
A stack of transformer layers.
Args:
encoder_input: a Tensor
encoder_self_attention_bias: bias Tensor for self-attention
(see common_attention.attention_bias())
hparams: hyperparameters for model
name: a string
Returns:
y: a Tensors
|
[
"A",
"stack",
"of",
"transformer",
"layers",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/research/transformer_revnet.py#L73-L133
|
train
|
A stack of transformer layers.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0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h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + chr(0b1010 + 0o145) + '\x33' + chr(0b110100) + chr(1763 - 1714), 2554 - 2546), ehT0Px3KOsy9(chr(109 - 61) + chr(7372 - 7261) + chr(51) + chr(48) + chr(1710 - 1657), ord("\x08")), ehT0Px3KOsy9(chr(0b11100 + 0o24) + '\x6f' + '\062' + chr(0b101001 + 0o16), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(50) + chr(416 - 367), 0o10), ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(0b1101001 + 0o6) + '\x32' + chr(0b110011) + '\x32', 0b1000), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(0b1101111) + chr(1705 - 1656), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x33' + '\060' + '\067', ord("\x08")), ehT0Px3KOsy9(chr(0b11011 + 0o25) + '\157' + chr(0b110001), 8), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(1636 - 1586) + '\064' + '\063', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1000100 + 0o53) + chr(51) + '\060' + chr(0b101100 + 0o4), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b101010 + 0o7) + chr(55) + '\x35', 31324 - 31316), ehT0Px3KOsy9('\x30' + chr(11783 - 11672) + chr(305 - 254) + chr(2315 - 2263) + chr(840 - 791), 8), ehT0Px3KOsy9('\060' + chr(1870 - 1759) + chr(519 - 468), 0b1000), ehT0Px3KOsy9(chr(1008 - 960) + chr(0b1011111 + 0o20) + '\x32' + chr(0b110110) + chr(194 - 145), 0o10), ehT0Px3KOsy9(chr(0b1 + 0o57) + chr(0b1101111) + '\061' + '\062' + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1000111 + 0o50) + chr(0b110010) + chr(49) + '\x36', 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b10010 + 0o41) + chr(0b110111) + '\x34', 24250 - 24242), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b1101111) + '\x31' + chr(48) + chr(0b101100 + 0o12), 0o10), ehT0Px3KOsy9(chr(48) + chr(1897 - 1786) + '\x31' + chr(0b100011 + 0o16), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b10001 + 0o40) + chr(51) + '\061', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110001) + chr(0b100010 + 0o21) + chr(0b10001 + 0o43), ord("\x08")), ehT0Px3KOsy9('\060' + chr(5744 - 5633) + chr(51) + '\065' + chr(1077 - 1026), ord("\x08")), ehT0Px3KOsy9(chr(147 - 99) + chr(0b11001 + 0o126) + chr(721 - 670) + chr(54) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(0b100000 + 0o20) + chr(1784 - 1673) + chr(0b110111) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(111) + chr(0b110011) + chr(0b110010) + chr(0b10100 + 0o43), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b1011 + 0o50) + chr(53) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110011) + chr(0b110101) + '\061', 6450 - 6442), ehT0Px3KOsy9(chr(1512 - 1464) + '\x6f' + chr(49) + chr(0b0 + 0o62) + '\065', 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(311 - 260) + '\x36' + chr(0b11111 + 0o30), 8), ehT0Px3KOsy9(chr(0b101101 + 0o3) + '\x6f' + '\063' + chr(54) + chr(885 - 830), 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(1765 - 1716) + chr(0b11001 + 0o35) + chr(0b110010), 26880 - 26872), ehT0Px3KOsy9(chr(1205 - 1157) + chr(0b1101111) + '\x33' + '\067' + chr(0b11100 + 0o33), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x31' + chr(52) + '\x37', 0b1000), ehT0Px3KOsy9('\x30' + chr(9796 - 9685) + chr(478 - 427) + chr(0b110101) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(1582 - 1534) + chr(111) + chr(0b110001) + '\061' + chr(0b100110 + 0o14), 55320 - 55312), ehT0Px3KOsy9(chr(0b110000) + chr(0b110111 + 0o70) + chr(0b110101) + '\x37', 0b1000), ehT0Px3KOsy9(chr(0b100010 + 0o16) + chr(1849 - 1738) + chr(52) + chr(405 - 356), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b101101 + 0o102) + chr(0b110001 + 0o2) + '\x32' + chr(53), 0b1000), ehT0Px3KOsy9(chr(917 - 869) + chr(0b1101111) + chr(51) + '\066' + chr(119 - 70), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\063' + '\066' + chr(0b110000), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(6111 - 6000) + '\x35' + '\060', ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xcf'), chr(100) + '\x65' + chr(99) + chr(0b1101111) + '\144' + chr(0b1100101))(chr(117) + '\164' + '\146' + '\055' + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def WJkDMOEa1myf(LDEM1Zag9l0P, cMrr2bkEBgTQ, n4ljua2gi1Pr, AIvJRzLdDfgF=xafqLlk3kkUe(SXOLrMavuUCe(b'\x84\xabt~\xfed\xb5'), chr(4652 - 4552) + '\x65' + chr(0b1001110 + 0o25) + chr(111) + '\144' + chr(101))('\x75' + '\164' + chr(0b1110 + 0o130) + chr(0b101101) + chr(698 - 642))):
def EGyt1xfPT1P6(OeWW0F1dBPRQ, z0aQYihK_MSS):
cMrr2bkEBgTQ = z0aQYihK_MSS[ehT0Px3KOsy9('\060' + chr(0b1101111) + '\060', 19570 - 19562)]
tQZNxACjRyS5 = n4ljua2gi1Pr.qzoyXN3kdhDL
n4ljua2gi1Pr.qzoyXN3kdhDL = tQZNxACjRyS5 // ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110010), ord("\x08"))
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x97\xa4ex\xfbc\xabd\xfc\xb3\x1e\x8es\xd4'), chr(100) + '\145' + chr(9778 - 9679) + '\x6f' + '\x64' + chr(101))('\165' + chr(0b1110010 + 0o2) + chr(102) + chr(45) + chr(0b100011 + 0o25)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x92\xa0{w\xc5`\xb3u\xc6\xae\t\x88l\xdf'), '\x64' + '\x65' + '\x63' + '\157' + chr(5861 - 5761) + '\145')('\x75' + '\164' + chr(0b1000100 + 0o42) + chr(45) + chr(830 - 774))):
SqiSOtYOqOJH = WOnrfm4dlYcf.multihead_attention(jSKPaHwSAfVv.layer_preprocess(OeWW0F1dBPRQ, n4ljua2gi1Pr), None, cMrr2bkEBgTQ, n4ljua2gi1Pr.attention_key_channels or n4ljua2gi1Pr.qzoyXN3kdhDL, n4ljua2gi1Pr.attention_value_channels or n4ljua2gi1Pr.qzoyXN3kdhDL, n4ljua2gi1Pr.qzoyXN3kdhDL, n4ljua2gi1Pr.vRVqPOZ1hUG7, n4ljua2gi1Pr.RdMRr3qkYioQ)
SqiSOtYOqOJH = jSKPaHwSAfVv.layer_postprocess(OeWW0F1dBPRQ, SqiSOtYOqOJH, n4ljua2gi1Pr)
n4ljua2gi1Pr.qzoyXN3kdhDL = tQZNxACjRyS5
return SqiSOtYOqOJH
def RWHpzFEeviFP(OeWW0F1dBPRQ):
tQZNxACjRyS5 = n4ljua2gi1Pr.qzoyXN3kdhDL
n4ljua2gi1Pr.qzoyXN3kdhDL = tQZNxACjRyS5 // ehT0Px3KOsy9('\060' + chr(0b1101111) + '\062', 8)
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x97\xa4ex\xfbc\xabd\xfc\xb3\x1e\x8es\xd4'), chr(1489 - 1389) + '\145' + chr(0b1001110 + 0o25) + chr(0b1001001 + 0o46) + '\x64' + chr(101))(chr(2185 - 2068) + chr(0b1110100) + chr(102) + '\055' + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x87\xa3y'), '\x64' + chr(1384 - 1283) + '\x63' + chr(111) + chr(6533 - 6433) + chr(0b100100 + 0o101))(chr(12498 - 12381) + '\164' + '\146' + '\055' + '\070')):
SqiSOtYOqOJH = Nk9m9eKr4iuF.transformer_ffn_layer(jSKPaHwSAfVv.layer_preprocess(OeWW0F1dBPRQ, n4ljua2gi1Pr), n4ljua2gi1Pr)
SqiSOtYOqOJH = jSKPaHwSAfVv.layer_postprocess(OeWW0F1dBPRQ, SqiSOtYOqOJH, n4ljua2gi1Pr)
n4ljua2gi1Pr.qzoyXN3kdhDL = tQZNxACjRyS5
return SqiSOtYOqOJH
(pci1T9SDshKa, OVXzvB9BcGF_) = IDJ2eXGCBCDu.split(LDEM1Zag9l0P, ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x32', 8), axis=-ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(0b1101111) + '\x31', 8))
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x97\xa4ex\xfbc\xabd\xfc\xb3\x1e\x8es\xd4'), chr(0b1001 + 0o133) + chr(0b1100101) + '\x63' + '\157' + chr(100) + '\145')(chr(10163 - 10046) + chr(0b1110100) + chr(0b101100 + 0o72) + chr(0b1110 + 0o37) + chr(0b10011 + 0o45)))(AIvJRzLdDfgF):
(bdlzQNguJ1X_, dgC_QAONOODe) = IDJ2eXGCBCDu.contrib.layers.rev_block(pci1T9SDshKa, OVXzvB9BcGF_, EGyt1xfPT1P6, RWHpzFEeviFP, num_layers=n4ljua2gi1Pr.jZh5_pLUoOoZ, f_side_input=[cMrr2bkEBgTQ], is_training=n4ljua2gi1Pr.mode == IDJ2eXGCBCDu.estimator.ModeKeys.TRAIN)
SqiSOtYOqOJH = IDJ2eXGCBCDu.concat([bdlzQNguJ1X_, dgC_QAONOODe], axis=-ehT0Px3KOsy9(chr(0b101010 + 0o6) + chr(0b1101111) + '\061', 8))
return xafqLlk3kkUe(jSKPaHwSAfVv, xafqLlk3kkUe(SXOLrMavuUCe(b'\x8d\xa4nt\xe8^\xb7s\xc6\xb0\x0f\x8e`\xd4$\xfd'), chr(526 - 426) + chr(0b1001001 + 0o34) + chr(4932 - 4833) + chr(0b1101111) + chr(0b1001011 + 0o31) + '\145')(chr(1342 - 1225) + chr(0b1111 + 0o145) + '\146' + chr(290 - 245) + chr(1400 - 1344)))(SqiSOtYOqOJH, n4ljua2gi1Pr)
|
tensorflow/tensor2tensor
|
tensor2tensor/models/research/transformer_revnet.py
|
transformer_revnet_decoder
|
def transformer_revnet_decoder(decoder_input,
encoder_output,
decoder_self_attention_bias,
encoder_decoder_attention_bias,
hparams,
name="decoder"):
"""A stack of transformer layers.
Args:
decoder_input: a Tensor
encoder_output: a Tensor
decoder_self_attention_bias: bias Tensor for self-attention
(see common_attention.attention_bias())
encoder_decoder_attention_bias: bias Tensor for encoder-decoder attention
(see common_attention.attention_bias())
hparams: hyperparameters for model
name: a string
Returns:
y: a Tensors
"""
def f(x, side_input):
"""f(x) for reversible layer, self-attention and enc-dec attention."""
decoder_self_attention_bias = side_input[0]
encoder_decoder_attention_bias = side_input[1]
encoder_output = side_input[2]
old_hid_size = hparams.hidden_size
hparams.hidden_size = old_hid_size // 2
with tf.variable_scope("self_attention"):
y = common_attention.multihead_attention(
common_layers.layer_preprocess(
x, hparams), None, decoder_self_attention_bias,
hparams.attention_key_channels or hparams.hidden_size,
hparams.attention_value_channels or hparams.hidden_size,
hparams.hidden_size, hparams.num_heads, hparams.attention_dropout)
y = common_layers.layer_postprocess(x, y, hparams)
if encoder_output is not None:
with tf.variable_scope("encdec_attention"):
y = common_attention.multihead_attention(
common_layers.layer_preprocess(
x, hparams), encoder_output, encoder_decoder_attention_bias,
hparams.attention_key_channels or hparams.hidden_size,
hparams.attention_value_channels or hparams.hidden_size,
hparams.hidden_size, hparams.num_heads, hparams.attention_dropout)
y = common_layers.layer_postprocess(x, y, hparams)
hparams.hidden_size = old_hid_size
return y
def g(x):
"""g(x) for reversible layer, feed-forward layer."""
old_hid_size = hparams.hidden_size
hparams.hidden_size = old_hid_size // 2
with tf.variable_scope("ffn"):
y = transformer.transformer_ffn_layer(
common_layers.layer_preprocess(x, hparams), hparams)
y = common_layers.layer_postprocess(x, y, hparams)
hparams.hidden_size = old_hid_size
return y
x1, x2 = tf.split(decoder_input, 2, axis=-1)
with tf.variable_scope(name):
y1, y2 = tf.contrib.layers.rev_block(
x1,
x2,
f,
g,
num_layers=hparams.num_hidden_layers,
f_side_input=[
decoder_self_attention_bias, encoder_decoder_attention_bias,
encoder_output
],
is_training=hparams.mode == tf.estimator.ModeKeys.TRAIN)
y = tf.concat([y1, y2], axis=-1)
return common_layers.layer_preprocess(y, hparams)
|
python
|
def transformer_revnet_decoder(decoder_input,
encoder_output,
decoder_self_attention_bias,
encoder_decoder_attention_bias,
hparams,
name="decoder"):
"""A stack of transformer layers.
Args:
decoder_input: a Tensor
encoder_output: a Tensor
decoder_self_attention_bias: bias Tensor for self-attention
(see common_attention.attention_bias())
encoder_decoder_attention_bias: bias Tensor for encoder-decoder attention
(see common_attention.attention_bias())
hparams: hyperparameters for model
name: a string
Returns:
y: a Tensors
"""
def f(x, side_input):
"""f(x) for reversible layer, self-attention and enc-dec attention."""
decoder_self_attention_bias = side_input[0]
encoder_decoder_attention_bias = side_input[1]
encoder_output = side_input[2]
old_hid_size = hparams.hidden_size
hparams.hidden_size = old_hid_size // 2
with tf.variable_scope("self_attention"):
y = common_attention.multihead_attention(
common_layers.layer_preprocess(
x, hparams), None, decoder_self_attention_bias,
hparams.attention_key_channels or hparams.hidden_size,
hparams.attention_value_channels or hparams.hidden_size,
hparams.hidden_size, hparams.num_heads, hparams.attention_dropout)
y = common_layers.layer_postprocess(x, y, hparams)
if encoder_output is not None:
with tf.variable_scope("encdec_attention"):
y = common_attention.multihead_attention(
common_layers.layer_preprocess(
x, hparams), encoder_output, encoder_decoder_attention_bias,
hparams.attention_key_channels or hparams.hidden_size,
hparams.attention_value_channels or hparams.hidden_size,
hparams.hidden_size, hparams.num_heads, hparams.attention_dropout)
y = common_layers.layer_postprocess(x, y, hparams)
hparams.hidden_size = old_hid_size
return y
def g(x):
"""g(x) for reversible layer, feed-forward layer."""
old_hid_size = hparams.hidden_size
hparams.hidden_size = old_hid_size // 2
with tf.variable_scope("ffn"):
y = transformer.transformer_ffn_layer(
common_layers.layer_preprocess(x, hparams), hparams)
y = common_layers.layer_postprocess(x, y, hparams)
hparams.hidden_size = old_hid_size
return y
x1, x2 = tf.split(decoder_input, 2, axis=-1)
with tf.variable_scope(name):
y1, y2 = tf.contrib.layers.rev_block(
x1,
x2,
f,
g,
num_layers=hparams.num_hidden_layers,
f_side_input=[
decoder_self_attention_bias, encoder_decoder_attention_bias,
encoder_output
],
is_training=hparams.mode == tf.estimator.ModeKeys.TRAIN)
y = tf.concat([y1, y2], axis=-1)
return common_layers.layer_preprocess(y, hparams)
|
[
"def",
"transformer_revnet_decoder",
"(",
"decoder_input",
",",
"encoder_output",
",",
"decoder_self_attention_bias",
",",
"encoder_decoder_attention_bias",
",",
"hparams",
",",
"name",
"=",
"\"decoder\"",
")",
":",
"def",
"f",
"(",
"x",
",",
"side_input",
")",
":",
"\"\"\"f(x) for reversible layer, self-attention and enc-dec attention.\"\"\"",
"decoder_self_attention_bias",
"=",
"side_input",
"[",
"0",
"]",
"encoder_decoder_attention_bias",
"=",
"side_input",
"[",
"1",
"]",
"encoder_output",
"=",
"side_input",
"[",
"2",
"]",
"old_hid_size",
"=",
"hparams",
".",
"hidden_size",
"hparams",
".",
"hidden_size",
"=",
"old_hid_size",
"//",
"2",
"with",
"tf",
".",
"variable_scope",
"(",
"\"self_attention\"",
")",
":",
"y",
"=",
"common_attention",
".",
"multihead_attention",
"(",
"common_layers",
".",
"layer_preprocess",
"(",
"x",
",",
"hparams",
")",
",",
"None",
",",
"decoder_self_attention_bias",
",",
"hparams",
".",
"attention_key_channels",
"or",
"hparams",
".",
"hidden_size",
",",
"hparams",
".",
"attention_value_channels",
"or",
"hparams",
".",
"hidden_size",
",",
"hparams",
".",
"hidden_size",
",",
"hparams",
".",
"num_heads",
",",
"hparams",
".",
"attention_dropout",
")",
"y",
"=",
"common_layers",
".",
"layer_postprocess",
"(",
"x",
",",
"y",
",",
"hparams",
")",
"if",
"encoder_output",
"is",
"not",
"None",
":",
"with",
"tf",
".",
"variable_scope",
"(",
"\"encdec_attention\"",
")",
":",
"y",
"=",
"common_attention",
".",
"multihead_attention",
"(",
"common_layers",
".",
"layer_preprocess",
"(",
"x",
",",
"hparams",
")",
",",
"encoder_output",
",",
"encoder_decoder_attention_bias",
",",
"hparams",
".",
"attention_key_channels",
"or",
"hparams",
".",
"hidden_size",
",",
"hparams",
".",
"attention_value_channels",
"or",
"hparams",
".",
"hidden_size",
",",
"hparams",
".",
"hidden_size",
",",
"hparams",
".",
"num_heads",
",",
"hparams",
".",
"attention_dropout",
")",
"y",
"=",
"common_layers",
".",
"layer_postprocess",
"(",
"x",
",",
"y",
",",
"hparams",
")",
"hparams",
".",
"hidden_size",
"=",
"old_hid_size",
"return",
"y",
"def",
"g",
"(",
"x",
")",
":",
"\"\"\"g(x) for reversible layer, feed-forward layer.\"\"\"",
"old_hid_size",
"=",
"hparams",
".",
"hidden_size",
"hparams",
".",
"hidden_size",
"=",
"old_hid_size",
"//",
"2",
"with",
"tf",
".",
"variable_scope",
"(",
"\"ffn\"",
")",
":",
"y",
"=",
"transformer",
".",
"transformer_ffn_layer",
"(",
"common_layers",
".",
"layer_preprocess",
"(",
"x",
",",
"hparams",
")",
",",
"hparams",
")",
"y",
"=",
"common_layers",
".",
"layer_postprocess",
"(",
"x",
",",
"y",
",",
"hparams",
")",
"hparams",
".",
"hidden_size",
"=",
"old_hid_size",
"return",
"y",
"x1",
",",
"x2",
"=",
"tf",
".",
"split",
"(",
"decoder_input",
",",
"2",
",",
"axis",
"=",
"-",
"1",
")",
"with",
"tf",
".",
"variable_scope",
"(",
"name",
")",
":",
"y1",
",",
"y2",
"=",
"tf",
".",
"contrib",
".",
"layers",
".",
"rev_block",
"(",
"x1",
",",
"x2",
",",
"f",
",",
"g",
",",
"num_layers",
"=",
"hparams",
".",
"num_hidden_layers",
",",
"f_side_input",
"=",
"[",
"decoder_self_attention_bias",
",",
"encoder_decoder_attention_bias",
",",
"encoder_output",
"]",
",",
"is_training",
"=",
"hparams",
".",
"mode",
"==",
"tf",
".",
"estimator",
".",
"ModeKeys",
".",
"TRAIN",
")",
"y",
"=",
"tf",
".",
"concat",
"(",
"[",
"y1",
",",
"y2",
"]",
",",
"axis",
"=",
"-",
"1",
")",
"return",
"common_layers",
".",
"layer_preprocess",
"(",
"y",
",",
"hparams",
")"
] |
A stack of transformer layers.
Args:
decoder_input: a Tensor
encoder_output: a Tensor
decoder_self_attention_bias: bias Tensor for self-attention
(see common_attention.attention_bias())
encoder_decoder_attention_bias: bias Tensor for encoder-decoder attention
(see common_attention.attention_bias())
hparams: hyperparameters for model
name: a string
Returns:
y: a Tensors
|
[
"A",
"stack",
"of",
"transformer",
"layers",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/research/transformer_revnet.py#L136-L213
|
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w0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\061' + chr(0b110001) + chr(53), 46122 - 46114), ehT0Px3KOsy9('\x30' + '\x6f' + chr(52) + chr(0b110001 + 0o2), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + '\x32' + '\x35' + '\062', 0o10), ehT0Px3KOsy9('\060' + chr(0b1001100 + 0o43) + chr(1880 - 1831) + chr(0b11110 + 0o23) + chr(100 - 51), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b1110 + 0o45) + chr(1144 - 1091) + chr(49), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1001 + 0o146) + chr(0b110001) + chr(0b1011 + 0o54) + chr(50), 25346 - 25338), ehT0Px3KOsy9('\x30' + chr(0b110110 + 0o71) + chr(50) + chr(55) + chr(0b11000 + 0o34), 0o10), ehT0Px3KOsy9(chr(1076 - 1028) + chr(0b1101111) + '\x32' + chr(0b100001 + 0o20) + '\x32', 0o10), ehT0Px3KOsy9(chr(0b11000 + 0o30) + chr(111) + '\x34' + chr(0b110110), 31608 - 31600), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110010) + chr(0b110000) + chr(54), 48915 - 48907), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(51) + chr(0b11001 + 0o31) + chr(0b10110 + 0o36), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(1316 - 1263) + chr(48), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110011) + chr(1140 - 1087) + chr(1531 - 1483), 64659 - 64651), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\061' + chr(1733 - 1684) + chr(1573 - 1525), 47274 - 47266), ehT0Px3KOsy9(chr(1129 - 1081) + chr(111) + chr(989 - 940) + chr(50) + '\x36', 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x33' + chr(53) + chr(0b1010 + 0o53), 54406 - 54398), ehT0Px3KOsy9(chr(1663 - 1615) + chr(450 - 339) + '\x31' + chr(55) + '\065', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(2119 - 2069) + chr(0b110110) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1001011 + 0o44) + chr(0b110011) + '\065' + chr(48), 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b1001000 + 0o47) + chr(0b110010) + '\x36' + '\064', 0b1000), ehT0Px3KOsy9('\060' + chr(12158 - 12047) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(111) + chr(55), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x31' + '\x33' + chr(0b101101 + 0o3), 0b1000), ehT0Px3KOsy9('\x30' + chr(11656 - 11545) + chr(0b110001) + chr(0b110011) + chr(49), 12241 - 12233), ehT0Px3KOsy9(chr(48) + chr(111) + chr(51) + chr(0b110110) + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(0b101111 + 0o1) + chr(0b110001 + 0o76) + chr(0b110010) + '\067' + chr(1609 - 1561), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110011) + chr(0b110101) + chr(2344 - 2292), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x34' + chr(0b10100 + 0o37), 8), ehT0Px3KOsy9('\x30' + '\157' + chr(1249 - 1199) + chr(2388 - 2335), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x32' + chr(0b110101) + '\x31', 58334 - 58326), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x31' + chr(0b110110) + chr(0b11010 + 0o34), 0o10), ehT0Px3KOsy9('\060' + chr(0b101 + 0o152) + chr(0b110111) + chr(1947 - 1899), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b111111 + 0o60) + '\061' + '\x36' + chr(1646 - 1597), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + '\061' + chr(0b10101 + 0o34) + chr(0b11000 + 0o33), 0b1000), ehT0Px3KOsy9(chr(0b111 + 0o51) + chr(0b1010100 + 0o33) + chr(0b110110), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(1992 - 1942) + chr(0b100110 + 0o21) + chr(853 - 804), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(53) + chr(50), ord("\x08")), ehT0Px3KOsy9('\060' + chr(11223 - 11112) + chr(49) + '\x35' + '\x32', 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b101000 + 0o13) + '\x36' + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b100 + 0o153) + '\x33' + '\x30', 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2291 - 2238) + chr(0b110000), 8)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'c'), '\x64' + chr(0b10011 + 0o122) + chr(0b10 + 0o141) + '\157' + '\144' + chr(0b1001100 + 0o31))(chr(0b111000 + 0o75) + chr(0b1110100) + chr(3795 - 3693) + '\055' + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def xDvCBj0cA7zR(t5Jz9byuSQ65, NE_S2zAzN4PI, Z0c2rFCFDCFc, iuvkQfeRHfn5, n4ljua2gi1Pr, AIvJRzLdDfgF=xafqLlk3kkUe(SXOLrMavuUCe(b')F\xc9&\x8d\x1f\xce'), chr(100) + chr(101) + '\143' + chr(4696 - 4585) + '\144' + chr(0b1100101))('\165' + '\164' + '\146' + chr(0b111 + 0o46) + chr(0b111000))):
def EGyt1xfPT1P6(OeWW0F1dBPRQ, z0aQYihK_MSS):
Z0c2rFCFDCFc = z0aQYihK_MSS[ehT0Px3KOsy9(chr(2156 - 2108) + chr(0b1101111) + chr(0b110000), 63999 - 63991)]
iuvkQfeRHfn5 = z0aQYihK_MSS[ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b10100 + 0o35), 0b1000)]
NE_S2zAzN4PI = z0aQYihK_MSS[ehT0Px3KOsy9('\x30' + '\x6f' + chr(2389 - 2339), ord("\x08"))]
tQZNxACjRyS5 = n4ljua2gi1Pr.qzoyXN3kdhDL
n4ljua2gi1Pr.qzoyXN3kdhDL = tQZNxACjRyS5 // ehT0Px3KOsy9(chr(1231 - 1183) + '\x6f' + '\x32', 8)
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b';B\xd8 \x88\x18\xd0\xefy\xf5\xb7G\x98-'), '\144' + '\145' + '\x63' + chr(2896 - 2785) + chr(100) + '\x65')(chr(6426 - 6309) + chr(0b1110100) + chr(0b1100110) + '\055' + chr(0b110111 + 0o1)))(xafqLlk3kkUe(SXOLrMavuUCe(b'>F\xc6/\xb6\x1b\xc8\xfeC\xe8\xa0A\x87&'), chr(1863 - 1763) + '\145' + chr(99) + chr(0b100001 + 0o116) + chr(9571 - 9471) + chr(7972 - 7871))('\165' + chr(0b1110100) + chr(0b1100110) + chr(0b101101) + chr(0b11111 + 0o31))):
SqiSOtYOqOJH = WOnrfm4dlYcf.multihead_attention(jSKPaHwSAfVv.layer_preprocess(OeWW0F1dBPRQ, n4ljua2gi1Pr), None, Z0c2rFCFDCFc, n4ljua2gi1Pr.attention_key_channels or n4ljua2gi1Pr.qzoyXN3kdhDL, n4ljua2gi1Pr.attention_value_channels or n4ljua2gi1Pr.qzoyXN3kdhDL, n4ljua2gi1Pr.qzoyXN3kdhDL, n4ljua2gi1Pr.vRVqPOZ1hUG7, n4ljua2gi1Pr.RdMRr3qkYioQ)
SqiSOtYOqOJH = jSKPaHwSAfVv.layer_postprocess(OeWW0F1dBPRQ, SqiSOtYOqOJH, n4ljua2gi1Pr)
if NE_S2zAzN4PI is not None:
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b';B\xd8 \x88\x18\xd0\xefy\xf5\xb7G\x98-'), '\144' + chr(0b1100001 + 0o4) + '\143' + '\x6f' + '\x64' + chr(0b100111 + 0o76))(chr(0b1110101) + '\164' + chr(0b1100110) + '\055' + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'(M\xc9-\x8c\x19\xe3\xebR\xf2\xb1F\x9c!9\x83'), '\144' + '\x65' + chr(0b1100011) + '\157' + chr(7777 - 7677) + chr(8487 - 8386))(chr(3805 - 3688) + chr(2095 - 1979) + '\x66' + chr(0b101000 + 0o5) + '\x38')):
SqiSOtYOqOJH = WOnrfm4dlYcf.multihead_attention(jSKPaHwSAfVv.layer_preprocess(OeWW0F1dBPRQ, n4ljua2gi1Pr), NE_S2zAzN4PI, iuvkQfeRHfn5, n4ljua2gi1Pr.attention_key_channels or n4ljua2gi1Pr.qzoyXN3kdhDL, n4ljua2gi1Pr.attention_value_channels or n4ljua2gi1Pr.qzoyXN3kdhDL, n4ljua2gi1Pr.qzoyXN3kdhDL, n4ljua2gi1Pr.vRVqPOZ1hUG7, n4ljua2gi1Pr.RdMRr3qkYioQ)
SqiSOtYOqOJH = jSKPaHwSAfVv.layer_postprocess(OeWW0F1dBPRQ, SqiSOtYOqOJH, n4ljua2gi1Pr)
n4ljua2gi1Pr.qzoyXN3kdhDL = tQZNxACjRyS5
return SqiSOtYOqOJH
def RWHpzFEeviFP(OeWW0F1dBPRQ):
tQZNxACjRyS5 = n4ljua2gi1Pr.qzoyXN3kdhDL
n4ljua2gi1Pr.qzoyXN3kdhDL = tQZNxACjRyS5 // ehT0Px3KOsy9('\060' + chr(0b101011 + 0o104) + chr(0b11100 + 0o26), 8)
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b';B\xd8 \x88\x18\xd0\xefy\xf5\xb7G\x98-'), chr(2187 - 2087) + '\145' + chr(99) + chr(12099 - 11988) + chr(5071 - 4971) + chr(0b1100101))(chr(591 - 474) + chr(116) + chr(102) + '\x2d' + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'+E\xc4'), chr(0b111100 + 0o50) + '\145' + chr(99) + '\157' + chr(100) + '\145')(chr(8463 - 8346) + chr(0b101101 + 0o107) + '\146' + '\x2d' + chr(0b10100 + 0o44))):
SqiSOtYOqOJH = Nk9m9eKr4iuF.transformer_ffn_layer(jSKPaHwSAfVv.layer_preprocess(OeWW0F1dBPRQ, n4ljua2gi1Pr), n4ljua2gi1Pr)
SqiSOtYOqOJH = jSKPaHwSAfVv.layer_postprocess(OeWW0F1dBPRQ, SqiSOtYOqOJH, n4ljua2gi1Pr)
n4ljua2gi1Pr.qzoyXN3kdhDL = tQZNxACjRyS5
return SqiSOtYOqOJH
(pci1T9SDshKa, OVXzvB9BcGF_) = IDJ2eXGCBCDu.split(t5Jz9byuSQ65, ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110010 + 0o0), 8), axis=-ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2129 - 2080), 8))
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b';B\xd8 \x88\x18\xd0\xefy\xf5\xb7G\x98-'), chr(100) + chr(0b1100101) + chr(0b1100011) + chr(0b1101111) + '\144' + chr(101))(chr(0b1101001 + 0o14) + chr(11569 - 11453) + '\x66' + chr(0b101101) + chr(56)))(AIvJRzLdDfgF):
(bdlzQNguJ1X_, dgC_QAONOODe) = IDJ2eXGCBCDu.contrib.layers.rev_block(pci1T9SDshKa, OVXzvB9BcGF_, EGyt1xfPT1P6, RWHpzFEeviFP, num_layers=n4ljua2gi1Pr.jZh5_pLUoOoZ, f_side_input=[Z0c2rFCFDCFc, iuvkQfeRHfn5, NE_S2zAzN4PI], is_training=n4ljua2gi1Pr.mode == IDJ2eXGCBCDu.estimator.ModeKeys.TRAIN)
SqiSOtYOqOJH = IDJ2eXGCBCDu.concat([bdlzQNguJ1X_, dgC_QAONOODe], axis=-ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b11010 + 0o27), 8))
return xafqLlk3kkUe(jSKPaHwSAfVv, xafqLlk3kkUe(SXOLrMavuUCe(b'!B\xd3,\x9b%\xcc\xf8C\xf6\xa6G\x8b-%\x9e'), chr(1078 - 978) + '\x65' + '\x63' + '\157' + '\x64' + '\145')(chr(117) + '\164' + chr(102) + chr(0b1101 + 0o40) + '\x38'))(SqiSOtYOqOJH, n4ljua2gi1Pr)
|
tensorflow/tensor2tensor
|
tensor2tensor/models/research/transformer_revnet.py
|
transformer_revnet_base
|
def transformer_revnet_base():
"""Base hparams for TransformerRevnet."""
hparams = transformer.transformer_big()
# Use settings from transformer_n_da
hparams.layer_preprocess_sequence = "n"
hparams.layer_postprocess_sequence = "da"
hparams.learning_rate = 0.4
return hparams
|
python
|
def transformer_revnet_base():
"""Base hparams for TransformerRevnet."""
hparams = transformer.transformer_big()
# Use settings from transformer_n_da
hparams.layer_preprocess_sequence = "n"
hparams.layer_postprocess_sequence = "da"
hparams.learning_rate = 0.4
return hparams
|
[
"def",
"transformer_revnet_base",
"(",
")",
":",
"hparams",
"=",
"transformer",
".",
"transformer_big",
"(",
")",
"# Use settings from transformer_n_da",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"n\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"da\"",
"hparams",
".",
"learning_rate",
"=",
"0.4",
"return",
"hparams"
] |
Base hparams for TransformerRevnet.
|
[
"Base",
"hparams",
"for",
"TransformerRevnet",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/research/transformer_revnet.py#L217-L226
|
train
|
Base hparams for TransformerRevnet.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJm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Rurm1zTRfSmY,reqGiMiVQ77y,bsS9P6_LpdIe,sbGAZlkZOtyh,Cf_Qef15s3_F,eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110011) + '\060' + chr(386 - 332), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(49) + '\x34' + chr(0b101100 + 0o11), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(1226 - 1176) + chr(0b11000 + 0o35) + chr(50), 0o10), ehT0Px3KOsy9('\060' + chr(4198 - 4087) + chr(0b101100 + 0o6) + chr(0b1010 + 0o50) + chr(1358 - 1305), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b10101 + 0o35) + chr(51) + '\x34', 0b1000), ehT0Px3KOsy9(chr(712 - 664) + '\157' + '\061' + chr(49), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b101 + 0o152) + chr(0b11000 + 0o31) + '\x34' + '\x32', 30820 - 30812), ehT0Px3KOsy9(chr(48) + chr(3587 - 3476) + chr(0b100111 + 0o12) + chr(764 - 712) + chr(0b110010), 8), ehT0Px3KOsy9(chr(48) + chr(111) + '\061' + chr(49) + chr(50), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x32' + chr(2158 - 2104) + chr(50), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + '\062' + chr(2042 - 1991) + chr(48), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x32' + chr(1011 - 957) + chr(1845 - 1795), 8), ehT0Px3KOsy9(chr(0b10011 + 0o35) + chr(8707 - 8596) + chr(0b10010 + 0o45) + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(51) + chr(0b110111) + chr(0b110100), 51264 - 51256), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(51) + chr(54) + '\x34', 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(50) + chr(0b110100), ord("\x08")), ehT0Px3KOsy9(chr(0b101010 + 0o6) + chr(1987 - 1876) + '\061' + chr(0b110011) + chr(0b110001), 15672 - 15664), ehT0Px3KOsy9('\060' + chr(5914 - 5803) + chr(1586 - 1535) + chr(0b100001 + 0o23) + chr(0b10101 + 0o40), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(1381 - 1332) + chr(432 - 382) + chr(1512 - 1459), 2992 - 2984), ehT0Px3KOsy9(chr(0b101111 + 0o1) + chr(0b100101 + 0o112) + chr(0b110010) + chr(781 - 727) + chr(0b1100 + 0o47), 0o10), ehT0Px3KOsy9('\x30' + chr(1204 - 1093) + chr(50) + chr(50) + chr(2269 - 2216), 8), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110001) + '\064' + '\x35', 8), ehT0Px3KOsy9(chr(1052 - 1004) + '\157' + chr(1934 - 1881) + '\x34', 0b1000), ehT0Px3KOsy9('\060' + chr(7549 - 7438) + chr(0b100001 + 0o25) + '\064', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(2157 - 2105) + '\060', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x31' + chr(0b110011) + '\062', 0b1000), ehT0Px3KOsy9(chr(80 - 32) + '\157' + chr(465 - 414) + '\x32' + chr(362 - 307), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(51) + chr(48) + chr(1931 - 1881), 0b1000), ehT0Px3KOsy9(chr(104 - 56) + chr(0b1101111) + '\062' + chr(0b100001 + 0o25) + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(49) + chr(50) + '\064', 0b1000), ehT0Px3KOsy9(chr(48) + chr(7615 - 7504) + chr(0b110010 + 0o1), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b110011 + 0o74) + chr(49) + '\062', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(253 - 203) + '\x35' + chr(0b101000 + 0o17), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b0 + 0o62) + chr(2321 - 2270) + chr(2050 - 1999), 1957 - 1949), ehT0Px3KOsy9(chr(805 - 757) + chr(0b100110 + 0o111) + chr(0b100101 + 0o16) + chr(2523 - 2470) + '\061', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\062' + chr(48) + chr(52), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x33', 8), ehT0Px3KOsy9(chr(1473 - 1425) + '\x6f' + chr(49) + chr(0b1100 + 0o53) + chr(53), 9148 - 9140), ehT0Px3KOsy9(chr(0b110000) + chr(123 - 12) + chr(51) + chr(48) + chr(0b10000 + 0o43), 56397 - 56389), ehT0Px3KOsy9(chr(0b101111 + 0o1) + chr(0b1101111) + '\067' + chr(411 - 357), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(784 - 673) + chr(1306 - 1253) + chr(48), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xe8'), chr(0b1100100) + '\145' + chr(99) + chr(11509 - 11398) + '\144' + chr(0b10100 + 0o121))(chr(0b1010001 + 0o44) + '\164' + chr(0b1100110) + chr(0b1110 + 0o37) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def iG4PLXP65yjt():
n4ljua2gi1Pr = Nk9m9eKr4iuF.transformer_big()
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'\xa8'), '\144' + chr(4204 - 4103) + chr(0b1100011) + chr(0b1101111) + chr(100) + chr(682 - 581))(chr(0b1001010 + 0o53) + chr(0b110001 + 0o103) + chr(102) + chr(1275 - 1230) + chr(0b100100 + 0o24))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'\xa2\x04'), chr(0b10001 + 0o123) + chr(101) + chr(0b1100011) + '\x6f' + '\144' + chr(101))(chr(12198 - 12081) + chr(1050 - 934) + '\x66' + '\x2d' + '\x38')
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.4
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/research/transformer_revnet.py
|
transformer_revnet_big
|
def transformer_revnet_big():
"""Base hparams for TransformerRevnet."""
hparams = transformer_revnet_base()
# The TransformerRevnet uses significantly less memory than the Transformer.
# Increase batch size and model size.
hparams.batch_size *= 2
hparams.hidden_size *= 2
hparams.num_heads *= 2
hparams.num_hidden_layers += 1
return hparams
|
python
|
def transformer_revnet_big():
"""Base hparams for TransformerRevnet."""
hparams = transformer_revnet_base()
# The TransformerRevnet uses significantly less memory than the Transformer.
# Increase batch size and model size.
hparams.batch_size *= 2
hparams.hidden_size *= 2
hparams.num_heads *= 2
hparams.num_hidden_layers += 1
return hparams
|
[
"def",
"transformer_revnet_big",
"(",
")",
":",
"hparams",
"=",
"transformer_revnet_base",
"(",
")",
"# The TransformerRevnet uses significantly less memory than the Transformer.",
"# Increase batch size and model size.",
"hparams",
".",
"batch_size",
"*=",
"2",
"hparams",
".",
"hidden_size",
"*=",
"2",
"hparams",
".",
"num_heads",
"*=",
"2",
"hparams",
".",
"num_hidden_layers",
"+=",
"1",
"return",
"hparams"
] |
Base hparams for TransformerRevnet.
|
[
"Base",
"hparams",
"for",
"TransformerRevnet",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/research/transformer_revnet.py#L230-L240
|
train
|
Base hparams for TransformerRevnet with big batch size.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bd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PkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(901 - 853) + chr(111) + chr(49) + chr(0b111 + 0o56), 22477 - 22469), ehT0Px3KOsy9(chr(415 - 367) + chr(0b1101111) + '\x31' + chr(1948 - 1899) + chr(54), 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110000 + 0o1) + chr(0b1110 + 0o45) + chr(54), 38821 - 38813), ehT0Px3KOsy9(chr(0b101111 + 0o1) + '\x6f' + chr(0b11111 + 0o24) + chr(0b110011) + chr(2026 - 1975), 59116 - 59108), ehT0Px3KOsy9(chr(48) + chr(273 - 162) + chr(0b11101 + 0o30), 0o10), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(305 - 194) + chr(50) + '\x35' + '\066', 37500 - 37492), ehT0Px3KOsy9(chr(48) + chr(0b110000 + 0o77) + chr(0b101010 + 0o12) + '\066', 44984 - 44976), ehT0Px3KOsy9(chr(1167 - 1119) + chr(111) + '\x35', 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110001) + chr(1935 - 1883) + '\063', 0b1000), ehT0Px3KOsy9(chr(215 - 167) + chr(0b10100 + 0o133) + '\062' + chr(607 - 559), 0b1000), ehT0Px3KOsy9(chr(0b11011 + 0o25) + chr(0b10111 + 0o130) + chr(50) + chr(1214 - 1160) + chr(1250 - 1195), 0b1000), ehT0Px3KOsy9(chr(1787 - 1739) + chr(0b111111 + 0o60) + '\063' + '\065' + chr(48), 28260 - 28252), ehT0Px3KOsy9(chr(48) + '\x6f' + '\x33' + chr(54) + '\066', 0o10), ehT0Px3KOsy9('\060' + chr(0b1010011 + 0o34) + '\x32' + chr(0b110101) + '\061', 0b1000), ehT0Px3KOsy9(chr(1967 - 1919) + chr(0b11100 + 0o123) + chr(51) + chr(0b110110) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(6659 - 6548) + chr(0b1010 + 0o47) + chr(213 - 161) + chr(0b11100 + 0o26), 0b1000), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(7383 - 7272) + chr(50) + chr(0b10001 + 0o43) + '\067', 0b1000), ehT0Px3KOsy9('\x30' + chr(4863 - 4752) + chr(50) + '\x31' + chr(1356 - 1304), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + '\063' + chr(2325 - 2275) + '\x37', 0b1000), ehT0Px3KOsy9(chr(0b10101 + 0o33) + chr(7080 - 6969) + '\x31' + chr(49), 0b1000), ehT0Px3KOsy9(chr(0b10111 + 0o31) + '\157' + chr(2473 - 2423) + '\x30' + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + '\x31' + '\x30' + '\x32', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x35' + '\x35', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b11000 + 0o127) + chr(51) + '\065' + chr(1709 - 1655), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(51) + chr(2160 - 2110), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(5514 - 5403) + chr(2214 - 2162) + chr(0b101101 + 0o4), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b100111 + 0o13) + chr(0b101000 + 0o11) + '\062', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(11506 - 11395) + chr(0b110010) + '\x37', 0o10), ehT0Px3KOsy9(chr(0b1011 + 0o45) + chr(0b1010001 + 0o36) + chr(49) + chr(0b110111) + '\x34', 30591 - 30583), ehT0Px3KOsy9(chr(48) + '\x6f' + '\x34' + '\064', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b101011 + 0o6) + chr(51) + '\x35', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(2016 - 1967) + chr(0b110111) + chr(1135 - 1081), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x32' + chr(0b110101) + chr(725 - 675), 0b1000), ehT0Px3KOsy9('\x30' + chr(3077 - 2966) + chr(351 - 296) + chr(2212 - 2157), 0b1000), ehT0Px3KOsy9(chr(1620 - 1572) + '\x6f' + chr(0b100010 + 0o21) + '\063' + chr(1754 - 1703), 8), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(10266 - 10155) + '\x33' + '\065' + chr(1920 - 1868), 0o10), ehT0Px3KOsy9('\x30' + '\157' + '\061' + chr(1024 - 972) + '\x32', 8), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110110) + chr(402 - 349), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(51) + chr(0b1000 + 0o53) + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\063' + '\x32' + chr(0b1001 + 0o53), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110101) + chr(0b110000), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'#'), chr(6118 - 6018) + chr(0b1100101) + '\143' + '\x6f' + chr(0b11110 + 0o106) + chr(0b1100101))('\165' + chr(0b10111 + 0o135) + chr(0b1100110) + '\x2d' + chr(1334 - 1278)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def hbLnqTbUo7ac():
n4ljua2gi1Pr = iG4PLXP65yjt()
n4ljua2gi1Pr.ix9dZyeAmUxY *= ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110010), 16554 - 16546)
n4ljua2gi1Pr.qzoyXN3kdhDL *= ehT0Px3KOsy9(chr(0b1100 + 0o44) + '\x6f' + chr(0b110010), 8)
n4ljua2gi1Pr.vRVqPOZ1hUG7 *= ehT0Px3KOsy9(chr(311 - 263) + '\157' + '\x32', 8)
n4ljua2gi1Pr.jZh5_pLUoOoZ += ehT0Px3KOsy9(chr(361 - 313) + '\157' + chr(711 - 662), 0o10)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/utils/devices.py
|
data_parallelism_from_flags
|
def data_parallelism_from_flags(daisy_chain_variables=True, all_workers=False):
"""Over which devices do we split each training batch.
In old-fashioned async mode, we split the batch over all GPUs on the
current worker.
In sync mode, we split the batch over all the parameter server GPUs.
This function returns an expert_utils.Parallelism object, which can be used
to build the model. It is configured in a way that any variables created
by `tf.get_variable` will be assigned to the parameter servers and shared
between datashards.
Args:
daisy_chain_variables: whether to copy variables in a daisy chain on GPUs.
all_workers: whether the devices are all async workers or just this one.
Returns:
a expert_utils.Parallelism.
"""
dp_arg_names = inspect.getargspec(data_parallelism).args
blacklist = ["daisy_chain_variables", "all_workers"]
kwargs = {}
for arg in dp_arg_names:
if arg in blacklist:
continue
kwargs[arg] = getattr(tf.flags.FLAGS, arg)
return data_parallelism(
daisy_chain_variables=daisy_chain_variables,
all_workers=all_workers,
**kwargs)
|
python
|
def data_parallelism_from_flags(daisy_chain_variables=True, all_workers=False):
"""Over which devices do we split each training batch.
In old-fashioned async mode, we split the batch over all GPUs on the
current worker.
In sync mode, we split the batch over all the parameter server GPUs.
This function returns an expert_utils.Parallelism object, which can be used
to build the model. It is configured in a way that any variables created
by `tf.get_variable` will be assigned to the parameter servers and shared
between datashards.
Args:
daisy_chain_variables: whether to copy variables in a daisy chain on GPUs.
all_workers: whether the devices are all async workers or just this one.
Returns:
a expert_utils.Parallelism.
"""
dp_arg_names = inspect.getargspec(data_parallelism).args
blacklist = ["daisy_chain_variables", "all_workers"]
kwargs = {}
for arg in dp_arg_names:
if arg in blacklist:
continue
kwargs[arg] = getattr(tf.flags.FLAGS, arg)
return data_parallelism(
daisy_chain_variables=daisy_chain_variables,
all_workers=all_workers,
**kwargs)
|
[
"def",
"data_parallelism_from_flags",
"(",
"daisy_chain_variables",
"=",
"True",
",",
"all_workers",
"=",
"False",
")",
":",
"dp_arg_names",
"=",
"inspect",
".",
"getargspec",
"(",
"data_parallelism",
")",
".",
"args",
"blacklist",
"=",
"[",
"\"daisy_chain_variables\"",
",",
"\"all_workers\"",
"]",
"kwargs",
"=",
"{",
"}",
"for",
"arg",
"in",
"dp_arg_names",
":",
"if",
"arg",
"in",
"blacklist",
":",
"continue",
"kwargs",
"[",
"arg",
"]",
"=",
"getattr",
"(",
"tf",
".",
"flags",
".",
"FLAGS",
",",
"arg",
")",
"return",
"data_parallelism",
"(",
"daisy_chain_variables",
"=",
"daisy_chain_variables",
",",
"all_workers",
"=",
"all_workers",
",",
"*",
"*",
"kwargs",
")"
] |
Over which devices do we split each training batch.
In old-fashioned async mode, we split the batch over all GPUs on the
current worker.
In sync mode, we split the batch over all the parameter server GPUs.
This function returns an expert_utils.Parallelism object, which can be used
to build the model. It is configured in a way that any variables created
by `tf.get_variable` will be assigned to the parameter servers and shared
between datashards.
Args:
daisy_chain_variables: whether to copy variables in a daisy chain on GPUs.
all_workers: whether the devices are all async workers or just this one.
Returns:
a expert_utils.Parallelism.
|
[
"Over",
"which",
"devices",
"do",
"we",
"split",
"each",
"training",
"batch",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/utils/devices.py#L26-L59
|
train
|
This function creates a data_parallelism object from the flags passed in.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNBHlx,ZsDPvpP4xdo3,cW7yQuyEnJ6E,KOHQGQ8qLDWm,NE1Yam2HHroQ,ygAzbDzrvRMh,SBRjvOU1ufVC,hOkXjmluK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M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + '\157' + chr(1920 - 1870) + '\061' + chr(0b110100), 4415 - 4407), ehT0Px3KOsy9('\x30' + '\x6f' + '\063' + chr(0b110010) + chr(0b110101), 48183 - 48175), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x33' + chr(0b0 + 0o65), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(49) + chr(54) + chr(51), 0o10), ehT0Px3KOsy9('\x30' + chr(0b111111 + 0o60) + '\x32' + chr(198 - 147) + chr(49), 0b1000), ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(6036 - 5925) + chr(1457 - 1408) + chr(0b111 + 0o56) + chr(0b110011), 47464 - 47456), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110101) + chr(0b100001 + 0o26), 3535 - 3527), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(51) + '\061', 0o10), ehT0Px3KOsy9(chr(0b11100 + 0o24) + '\157' + chr(0b110001) + '\066' + chr(131 - 82), 22924 - 22916), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b101100 + 0o7) + chr(0b1110 + 0o42) + chr(1867 - 1819), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1010000 + 0o37) + chr(51) + chr(0b10000 + 0o41) + '\061', 13121 - 13113), ehT0Px3KOsy9(chr(0b110000) + chr(11814 - 11703) + chr(0b101110 + 0o4) + chr(876 - 828) + chr(0b110001 + 0o0), 5478 - 5470), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b101111 + 0o4) + '\x35' + chr(0b101110 + 0o5), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b1001 + 0o52) + chr(0b110010) + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(1668 - 1620) + chr(111) + chr(0b110000 + 0o2) + chr(49), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(1776 - 1725) + chr(0b100111 + 0o13) + chr(1081 - 1029), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b11010 + 0o34) + '\066', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b10 + 0o57) + chr(75 - 23) + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110101) + chr(48), 0o10), ehT0Px3KOsy9(chr(0b101101 + 0o3) + '\157' + chr(2650 - 2597) + chr(0b100111 + 0o17), 56041 - 56033), ehT0Px3KOsy9('\x30' + chr(0b1111 + 0o140) + '\x32' + chr(51) + chr(50), 49979 - 49971), ehT0Px3KOsy9(chr(48) + chr(4344 - 4233) + chr(0b11101 + 0o24) + chr(50) + '\x34', 18170 - 18162), ehT0Px3KOsy9(chr(1411 - 1363) + chr(1839 - 1728) + chr(0b110011) + chr(48) + '\064', 0o10), ehT0Px3KOsy9('\060' + chr(7639 - 7528) + '\x33' + chr(0b110111), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(513 - 463) + chr(51) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(0b1011 + 0o45) + chr(0b1101111) + chr(0b110011) + '\063' + chr(53), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(1085 - 1034) + chr(0b110011) + chr(0b10101 + 0o37), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\x31' + chr(55) + '\x34', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(50) + '\067' + chr(0b110010), 38383 - 38375), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b1001 + 0o50) + '\065' + chr(0b100101 + 0o21), 0b1000), ehT0Px3KOsy9('\060' + chr(9778 - 9667) + '\066' + '\x31', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b100101 + 0o112) + chr(0b110010) + chr(0b10001 + 0o40) + chr(0b11000 + 0o32), ord("\x08")), ehT0Px3KOsy9(chr(889 - 841) + chr(0b1101111) + chr(0b10111 + 0o34) + chr(0b110011) + chr(0b100000 + 0o20), 0b1000), ehT0Px3KOsy9(chr(1988 - 1940) + chr(9917 - 9806) + chr(50), 3568 - 3560), ehT0Px3KOsy9(chr(0b1111 + 0o41) + chr(0b1001001 + 0o46) + chr(51) + chr(1463 - 1412) + chr(0b110011 + 0o0), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\064' + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(1922 - 1872) + '\067' + '\066', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\061' + chr(0b110101) + '\063', 8), ehT0Px3KOsy9(chr(0b100000 + 0o20) + '\x6f' + chr(0b110010) + chr(54) + '\060', 53403 - 53395), ehT0Px3KOsy9('\060' + '\157' + chr(49) + chr(52) + chr(183 - 131), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b1110 + 0o47) + chr(0b110000), 8)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xa2'), '\144' + chr(0b1001101 + 0o30) + '\143' + '\x6f' + '\x64' + chr(5803 - 5702))('\165' + '\164' + chr(0b1010110 + 0o20) + '\055' + chr(0b11000 + 0o40)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def c_ZPU2bFy2wL(m812svkc5bkk=ehT0Px3KOsy9('\060' + chr(11850 - 11739) + chr(49), 0o10), oVx_JuZw9z5G=ehT0Px3KOsy9('\060' + chr(916 - 805) + '\060', 0o10)):
MlrV66kUplFn = kzXqv8ZZwm75.getargspec(iP4ZSqFqAOG_).kJDRfRhcZHjS
TOIA4F3b9ATP = [xafqLlk3kkUe(SXOLrMavuUCe(b'\xe8\xb4t\x00\xe04Lq\x10\xa9\xa7\xde\x9d\xb0c\xbdW\x00DK\xe9'), chr(100) + chr(0b1100101) + chr(0b11000 + 0o113) + chr(0b1010010 + 0o35) + chr(0b1100100) + chr(0b1100101))(chr(0b1110101) + chr(116) + chr(0b1001011 + 0o33) + '\055' + chr(2034 - 1978)), xafqLlk3kkUe(SXOLrMavuUCe(b'\xed\xb9q,\xee\x04]r\x14\xb2\xba'), chr(0b111100 + 0o50) + chr(0b1011000 + 0o15) + '\x63' + '\157' + chr(0b100010 + 0o102) + chr(5110 - 5009))(chr(0b100010 + 0o123) + chr(116) + chr(0b10110 + 0o120) + '\x2d' + chr(2201 - 2145))]
M8EIoTs2GJXE = {}
for LTE9MPUbqSos in MlrV66kUplFn:
if LTE9MPUbqSos in TOIA4F3b9ATP:
continue
M8EIoTs2GJXE[LTE9MPUbqSos] = xafqLlk3kkUe(IDJ2eXGCBCDu.flags.FLAGS, LTE9MPUbqSos)
return iP4ZSqFqAOG_(daisy_chain_variables=m812svkc5bkk, all_workers=oVx_JuZw9z5G, **M8EIoTs2GJXE)
|
tensorflow/tensor2tensor
|
tensor2tensor/utils/devices.py
|
data_parallelism
|
def data_parallelism(daisy_chain_variables=True,
all_workers=False,
ps_replicas=0,
ps_job="/job:ps",
ps_gpu=0,
schedule="continuous_train_and_eval",
sync=False,
worker_gpu=1,
worker_replicas=1,
worker_id=0,
gpu_order="",
worker_job="/job:localhost",
no_data_parallelism=False):
"""See data_parallelism_from_flags."""
tf.logging.info("schedule=%s" % schedule)
tf.logging.info("worker_gpu=%s" % worker_gpu)
tf.logging.info("sync=%s" % sync)
def _ps_replicas(all_workers=False):
if all_workers:
return list(range(ps_replicas))
# Worker K will be using replicas {0,...n-1} + K*n if we have n replicas.
num_replicas = ps_replicas // worker_replicas
return [d + worker_id * num_replicas for d in range(num_replicas)]
def _gpu_order(num_gpus):
if gpu_order:
ret = [int(s) for s in gpu_order.split(" ")]
if len(ret) == num_gpus:
return ret
return list(range(num_gpus))
def _ps_gpus(all_workers=False):
ps_gpus = []
for d in _ps_replicas(all_workers=all_workers):
ps_gpus.extend([(d, gpu) for gpu in _gpu_order(ps_gpu)])
return ps_gpus
def ps_devices(all_workers=False):
"""List of ps devices (where to put the experts).
Args:
all_workers: whether the list is for all async workers or just this one.
Returns:
a list of device names
"""
if ps_replicas > 0:
if ps_gpu > 0:
return [
ps_job + "/task:%d/GPU:%d" % (d, gpu)
for (d, gpu) in _ps_gpus(all_workers=all_workers)
]
else:
return [
ps_job + "/task:%d" % d
for d in _ps_replicas(all_workers=all_workers)
]
else:
if worker_gpu > 0:
return ["gpu:%d" % d for d in _gpu_order(worker_gpu)]
else:
return [""]
def _replica_device_setter(worker_device):
if ps_replicas == 0:
return worker_device
return tf.train.replica_device_setter(
worker_device=worker_device,
ps_tasks=ps_replicas,
ps_device=ps_job + "/GPU:0" if ps_gpu > 0 else ps_job)
is_single_machine = ps_replicas == 0 and worker_replicas == 1
if no_data_parallelism:
datashard_devices = [""]
caching_devices = None
elif is_single_machine:
tf.logging.warn(
"Schedule=%s. Assuming that training is running on a single machine.",
schedule)
datashard_devices = ["gpu:%d" % d for d in _gpu_order(worker_gpu)]
if worker_gpu < 1:
datashard_devices += ["cpu:0"]
caching_devices = None
elif sync and ps_replicas > 0:
# compute on ps
datashard_devices = [
_replica_device_setter(d) for d in ps_devices(all_workers=all_workers)
]
if ps_gpu > 0 and ps_replicas > 1:
caching_devices = [
ps_job + "/task:%d/cpu:0" % d
for (d, _) in _ps_gpus(all_workers=all_workers)
]
else:
caching_devices = None
else:
# compute on worker - this is either a single-worker setup or asynchronous
# with parameter servers.
if worker_gpu > 1:
datashard_devices = [
_replica_device_setter(worker_job + "/GPU:%d" % d)
for d in _gpu_order(worker_gpu)
]
caching_devices = None
else:
datashard_devices = [_replica_device_setter(worker_job)]
caching_devices = None
tf.logging.info("datashard_devices: %s", datashard_devices)
tf.logging.info("caching_devices: %s", caching_devices)
tf.logging.info("ps_devices: %s", ps_devices(all_workers=all_workers))
return eu.Parallelism(
datashard_devices,
caching_devices=caching_devices,
daisy_chain_variables=daisy_chain_variables,
ps_devices=ps_devices(all_workers=all_workers))
|
python
|
def data_parallelism(daisy_chain_variables=True,
all_workers=False,
ps_replicas=0,
ps_job="/job:ps",
ps_gpu=0,
schedule="continuous_train_and_eval",
sync=False,
worker_gpu=1,
worker_replicas=1,
worker_id=0,
gpu_order="",
worker_job="/job:localhost",
no_data_parallelism=False):
"""See data_parallelism_from_flags."""
tf.logging.info("schedule=%s" % schedule)
tf.logging.info("worker_gpu=%s" % worker_gpu)
tf.logging.info("sync=%s" % sync)
def _ps_replicas(all_workers=False):
if all_workers:
return list(range(ps_replicas))
# Worker K will be using replicas {0,...n-1} + K*n if we have n replicas.
num_replicas = ps_replicas // worker_replicas
return [d + worker_id * num_replicas for d in range(num_replicas)]
def _gpu_order(num_gpus):
if gpu_order:
ret = [int(s) for s in gpu_order.split(" ")]
if len(ret) == num_gpus:
return ret
return list(range(num_gpus))
def _ps_gpus(all_workers=False):
ps_gpus = []
for d in _ps_replicas(all_workers=all_workers):
ps_gpus.extend([(d, gpu) for gpu in _gpu_order(ps_gpu)])
return ps_gpus
def ps_devices(all_workers=False):
"""List of ps devices (where to put the experts).
Args:
all_workers: whether the list is for all async workers or just this one.
Returns:
a list of device names
"""
if ps_replicas > 0:
if ps_gpu > 0:
return [
ps_job + "/task:%d/GPU:%d" % (d, gpu)
for (d, gpu) in _ps_gpus(all_workers=all_workers)
]
else:
return [
ps_job + "/task:%d" % d
for d in _ps_replicas(all_workers=all_workers)
]
else:
if worker_gpu > 0:
return ["gpu:%d" % d for d in _gpu_order(worker_gpu)]
else:
return [""]
def _replica_device_setter(worker_device):
if ps_replicas == 0:
return worker_device
return tf.train.replica_device_setter(
worker_device=worker_device,
ps_tasks=ps_replicas,
ps_device=ps_job + "/GPU:0" if ps_gpu > 0 else ps_job)
is_single_machine = ps_replicas == 0 and worker_replicas == 1
if no_data_parallelism:
datashard_devices = [""]
caching_devices = None
elif is_single_machine:
tf.logging.warn(
"Schedule=%s. Assuming that training is running on a single machine.",
schedule)
datashard_devices = ["gpu:%d" % d for d in _gpu_order(worker_gpu)]
if worker_gpu < 1:
datashard_devices += ["cpu:0"]
caching_devices = None
elif sync and ps_replicas > 0:
# compute on ps
datashard_devices = [
_replica_device_setter(d) for d in ps_devices(all_workers=all_workers)
]
if ps_gpu > 0 and ps_replicas > 1:
caching_devices = [
ps_job + "/task:%d/cpu:0" % d
for (d, _) in _ps_gpus(all_workers=all_workers)
]
else:
caching_devices = None
else:
# compute on worker - this is either a single-worker setup or asynchronous
# with parameter servers.
if worker_gpu > 1:
datashard_devices = [
_replica_device_setter(worker_job + "/GPU:%d" % d)
for d in _gpu_order(worker_gpu)
]
caching_devices = None
else:
datashard_devices = [_replica_device_setter(worker_job)]
caching_devices = None
tf.logging.info("datashard_devices: %s", datashard_devices)
tf.logging.info("caching_devices: %s", caching_devices)
tf.logging.info("ps_devices: %s", ps_devices(all_workers=all_workers))
return eu.Parallelism(
datashard_devices,
caching_devices=caching_devices,
daisy_chain_variables=daisy_chain_variables,
ps_devices=ps_devices(all_workers=all_workers))
|
[
"def",
"data_parallelism",
"(",
"daisy_chain_variables",
"=",
"True",
",",
"all_workers",
"=",
"False",
",",
"ps_replicas",
"=",
"0",
",",
"ps_job",
"=",
"\"/job:ps\"",
",",
"ps_gpu",
"=",
"0",
",",
"schedule",
"=",
"\"continuous_train_and_eval\"",
",",
"sync",
"=",
"False",
",",
"worker_gpu",
"=",
"1",
",",
"worker_replicas",
"=",
"1",
",",
"worker_id",
"=",
"0",
",",
"gpu_order",
"=",
"\"\"",
",",
"worker_job",
"=",
"\"/job:localhost\"",
",",
"no_data_parallelism",
"=",
"False",
")",
":",
"tf",
".",
"logging",
".",
"info",
"(",
"\"schedule=%s\"",
"%",
"schedule",
")",
"tf",
".",
"logging",
".",
"info",
"(",
"\"worker_gpu=%s\"",
"%",
"worker_gpu",
")",
"tf",
".",
"logging",
".",
"info",
"(",
"\"sync=%s\"",
"%",
"sync",
")",
"def",
"_ps_replicas",
"(",
"all_workers",
"=",
"False",
")",
":",
"if",
"all_workers",
":",
"return",
"list",
"(",
"range",
"(",
"ps_replicas",
")",
")",
"# Worker K will be using replicas {0,...n-1} + K*n if we have n replicas.",
"num_replicas",
"=",
"ps_replicas",
"//",
"worker_replicas",
"return",
"[",
"d",
"+",
"worker_id",
"*",
"num_replicas",
"for",
"d",
"in",
"range",
"(",
"num_replicas",
")",
"]",
"def",
"_gpu_order",
"(",
"num_gpus",
")",
":",
"if",
"gpu_order",
":",
"ret",
"=",
"[",
"int",
"(",
"s",
")",
"for",
"s",
"in",
"gpu_order",
".",
"split",
"(",
"\" \"",
")",
"]",
"if",
"len",
"(",
"ret",
")",
"==",
"num_gpus",
":",
"return",
"ret",
"return",
"list",
"(",
"range",
"(",
"num_gpus",
")",
")",
"def",
"_ps_gpus",
"(",
"all_workers",
"=",
"False",
")",
":",
"ps_gpus",
"=",
"[",
"]",
"for",
"d",
"in",
"_ps_replicas",
"(",
"all_workers",
"=",
"all_workers",
")",
":",
"ps_gpus",
".",
"extend",
"(",
"[",
"(",
"d",
",",
"gpu",
")",
"for",
"gpu",
"in",
"_gpu_order",
"(",
"ps_gpu",
")",
"]",
")",
"return",
"ps_gpus",
"def",
"ps_devices",
"(",
"all_workers",
"=",
"False",
")",
":",
"\"\"\"List of ps devices (where to put the experts).\n\n Args:\n all_workers: whether the list is for all async workers or just this one.\n\n Returns:\n a list of device names\n \"\"\"",
"if",
"ps_replicas",
">",
"0",
":",
"if",
"ps_gpu",
">",
"0",
":",
"return",
"[",
"ps_job",
"+",
"\"/task:%d/GPU:%d\"",
"%",
"(",
"d",
",",
"gpu",
")",
"for",
"(",
"d",
",",
"gpu",
")",
"in",
"_ps_gpus",
"(",
"all_workers",
"=",
"all_workers",
")",
"]",
"else",
":",
"return",
"[",
"ps_job",
"+",
"\"/task:%d\"",
"%",
"d",
"for",
"d",
"in",
"_ps_replicas",
"(",
"all_workers",
"=",
"all_workers",
")",
"]",
"else",
":",
"if",
"worker_gpu",
">",
"0",
":",
"return",
"[",
"\"gpu:%d\"",
"%",
"d",
"for",
"d",
"in",
"_gpu_order",
"(",
"worker_gpu",
")",
"]",
"else",
":",
"return",
"[",
"\"\"",
"]",
"def",
"_replica_device_setter",
"(",
"worker_device",
")",
":",
"if",
"ps_replicas",
"==",
"0",
":",
"return",
"worker_device",
"return",
"tf",
".",
"train",
".",
"replica_device_setter",
"(",
"worker_device",
"=",
"worker_device",
",",
"ps_tasks",
"=",
"ps_replicas",
",",
"ps_device",
"=",
"ps_job",
"+",
"\"/GPU:0\"",
"if",
"ps_gpu",
">",
"0",
"else",
"ps_job",
")",
"is_single_machine",
"=",
"ps_replicas",
"==",
"0",
"and",
"worker_replicas",
"==",
"1",
"if",
"no_data_parallelism",
":",
"datashard_devices",
"=",
"[",
"\"\"",
"]",
"caching_devices",
"=",
"None",
"elif",
"is_single_machine",
":",
"tf",
".",
"logging",
".",
"warn",
"(",
"\"Schedule=%s. Assuming that training is running on a single machine.\"",
",",
"schedule",
")",
"datashard_devices",
"=",
"[",
"\"gpu:%d\"",
"%",
"d",
"for",
"d",
"in",
"_gpu_order",
"(",
"worker_gpu",
")",
"]",
"if",
"worker_gpu",
"<",
"1",
":",
"datashard_devices",
"+=",
"[",
"\"cpu:0\"",
"]",
"caching_devices",
"=",
"None",
"elif",
"sync",
"and",
"ps_replicas",
">",
"0",
":",
"# compute on ps",
"datashard_devices",
"=",
"[",
"_replica_device_setter",
"(",
"d",
")",
"for",
"d",
"in",
"ps_devices",
"(",
"all_workers",
"=",
"all_workers",
")",
"]",
"if",
"ps_gpu",
">",
"0",
"and",
"ps_replicas",
">",
"1",
":",
"caching_devices",
"=",
"[",
"ps_job",
"+",
"\"/task:%d/cpu:0\"",
"%",
"d",
"for",
"(",
"d",
",",
"_",
")",
"in",
"_ps_gpus",
"(",
"all_workers",
"=",
"all_workers",
")",
"]",
"else",
":",
"caching_devices",
"=",
"None",
"else",
":",
"# compute on worker - this is either a single-worker setup or asynchronous",
"# with parameter servers.",
"if",
"worker_gpu",
">",
"1",
":",
"datashard_devices",
"=",
"[",
"_replica_device_setter",
"(",
"worker_job",
"+",
"\"/GPU:%d\"",
"%",
"d",
")",
"for",
"d",
"in",
"_gpu_order",
"(",
"worker_gpu",
")",
"]",
"caching_devices",
"=",
"None",
"else",
":",
"datashard_devices",
"=",
"[",
"_replica_device_setter",
"(",
"worker_job",
")",
"]",
"caching_devices",
"=",
"None",
"tf",
".",
"logging",
".",
"info",
"(",
"\"datashard_devices: %s\"",
",",
"datashard_devices",
")",
"tf",
".",
"logging",
".",
"info",
"(",
"\"caching_devices: %s\"",
",",
"caching_devices",
")",
"tf",
".",
"logging",
".",
"info",
"(",
"\"ps_devices: %s\"",
",",
"ps_devices",
"(",
"all_workers",
"=",
"all_workers",
")",
")",
"return",
"eu",
".",
"Parallelism",
"(",
"datashard_devices",
",",
"caching_devices",
"=",
"caching_devices",
",",
"daisy_chain_variables",
"=",
"daisy_chain_variables",
",",
"ps_devices",
"=",
"ps_devices",
"(",
"all_workers",
"=",
"all_workers",
")",
")"
] |
See data_parallelism_from_flags.
|
[
"See",
"data_parallelism_from_flags",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/utils/devices.py#L62-L177
|
train
|
Returns a list of data_parallelism_from_flags.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1G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1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(512 - 464) + chr(0b1101111) + '\061' + chr(0b110000) + chr(50), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(51) + '\x37' + chr(0b110011), 6559 - 6551), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x33' + chr(48) + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b100 + 0o153) + '\x31' + chr(0b110110) + chr(1550 - 1500), 0b1000), ehT0Px3KOsy9(chr(0b10111 + 0o31) + chr(0b1010101 + 0o32) + '\063' + chr(0b101101 + 0o5) + chr(54), 34918 - 34910), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\066' + '\x34', ord("\x08")), ehT0Px3KOsy9(chr(331 - 283) + chr(0b1101111) + chr(0b110101), 44001 - 43993), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x32' + chr(0b110000 + 0o0), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(51) + chr(0b0 + 0o61) + chr(54), 42859 - 42851), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\061' + '\062', 16637 - 16629), ehT0Px3KOsy9(chr(0b110000) + chr(0b1000 + 0o147) + chr(2510 - 2459) + chr(0b10110 + 0o40) + chr(0b10 + 0o64), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110100) + chr(0b110110), 23578 - 23570), ehT0Px3KOsy9(chr(213 - 165) + '\x6f' + '\061' + '\060', 45160 - 45152), ehT0Px3KOsy9(chr(2038 - 1990) + chr(111) + chr(0b11000 + 0o34) + chr(53), 0o10), ehT0Px3KOsy9(chr(0b101000 + 0o10) + '\x6f' + chr(2351 - 2300) + chr(1955 - 1906) + chr(2163 - 2108), 0b1000), ehT0Px3KOsy9(chr(1351 - 1303) + chr(0b1101111) + chr(49) + '\x37', 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110011) + chr(0b110010) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110011) + '\x33' + '\064', 17508 - 17500), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b11101 + 0o25) + '\x34' + '\x37', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\061' + chr(0b101000 + 0o14) + chr(53), 0o10), ehT0Px3KOsy9(chr(0b1100 + 0o44) + chr(0b1101111) + chr(0b110001) + chr(201 - 152) + '\x34', 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(378 - 328) + chr(2111 - 2059) + '\063', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b100111 + 0o110) + '\063' + chr(53) + chr(181 - 132), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x31' + '\066' + chr(1164 - 1112), 47341 - 47333), ehT0Px3KOsy9('\x30' + chr(0b110 + 0o151) + chr(49) + chr(0b100011 + 0o16) + chr(0b100001 + 0o22), 0b1000), ehT0Px3KOsy9(chr(2240 - 2192) + '\157' + '\061' + chr(54) + chr(0b110010), 8), ehT0Px3KOsy9(chr(0b0 + 0o60) + chr(0b1000100 + 0o53) + '\x31' + chr(0b110111) + '\x35', 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + '\062' + '\062' + chr(52), 0b1000), ehT0Px3KOsy9(chr(1082 - 1034) + chr(0b1101111) + chr(0b101 + 0o54) + chr(0b1010 + 0o55) + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b101101 + 0o102) + '\x31' + chr(0b1110 + 0o44), 8), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(54), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110001) + chr(0b100 + 0o63) + chr(55), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(50) + chr(0b110010) + chr(0b100001 + 0o22), 0b1000), ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(0b1101111) + chr(0b110010) + chr(0b110100) + chr(49), 8193 - 8185), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b100110 + 0o14) + chr(0b11010 + 0o26) + '\063', 0o10), ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(0b100110 + 0o111) + '\x31' + '\063' + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(48) + chr(3473 - 3362) + chr(49) + chr(0b1111 + 0o47) + chr(0b110010), 8), ehT0Px3KOsy9('\060' + chr(5253 - 5142) + chr(49) + chr(52) + '\061', ord("\x08")), ehT0Px3KOsy9(chr(0b10 + 0o56) + chr(6218 - 6107) + chr(0b110010) + chr(0b1 + 0o62) + chr(0b11101 + 0o24), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1000001 + 0o56) + chr(0b11111 + 0o23) + chr(0b101001 + 0o16) + '\x32', 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(0b1001 + 0o146) + chr(753 - 700) + '\x30', 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'l'), chr(100) + chr(0b1100101) + chr(0b1100011) + chr(111) + chr(0b1100100 + 0o0) + chr(6098 - 5997))(chr(117) + '\164' + chr(0b1000011 + 0o43) + '\x2d' + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def iP4ZSqFqAOG_(m812svkc5bkk=ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110001), 0b1000), oVx_JuZw9z5G=ehT0Px3KOsy9('\060' + chr(111) + chr(0b110000), 0b1000), FxTcw4hdTCz5=ehT0Px3KOsy9(chr(607 - 559) + chr(0b1010111 + 0o30) + chr(0b110000), 8), oLSYTDD4mLyy=xafqLlk3kkUe(SXOLrMavuUCe(b'm\x91\xad\x10\xecDv'), chr(7402 - 7302) + chr(0b1100101) + chr(0b1100011) + chr(0b1000000 + 0o57) + chr(0b1100100) + chr(0b1100101))(chr(0b1110101) + '\164' + '\x66' + chr(1722 - 1677) + chr(0b111000)), Z3DGfLevW2iR=ehT0Px3KOsy9(chr(0b100100 + 0o14) + chr(111) + chr(48), 8), UAGQwjlXRoHO=xafqLlk3kkUe(SXOLrMavuUCe(b"!\x94\xac\x06\xbfZp\x7f\xbby\xa9RzD\xa6a\x8c\xbd\xc9\x01\x13\xc6\x9f\x15'"), chr(100) + chr(0b1000000 + 0o45) + chr(6800 - 6701) + chr(111) + chr(0b10011 + 0o121) + chr(0b1100101))(chr(117) + '\x74' + '\146' + chr(45) + chr(56)), OLWAJrKMaq_U=ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(1686 - 1638), 8), PuUgdbTDfM5R=ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\061', 8), WliVXXDhyaO6=ehT0Px3KOsy9(chr(427 - 379) + chr(5236 - 5125) + '\061', 8), LPBkMz6QzyaB=ehT0Px3KOsy9('\x30' + chr(111) + chr(48), 8), HAd4wfFhlIz7=xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(100) + '\x65' + '\143' + chr(7107 - 6996) + chr(2089 - 1989) + chr(0b1100101))('\165' + chr(0b1110100) + '\146' + '\x2d' + '\x38'), rrM_5p2Pq7Qu=xafqLlk3kkUe(SXOLrMavuUCe(b'm\x91\xad\x10\xecXjs\xaff\x9eI{Q'), chr(0b1001010 + 0o32) + '\145' + chr(0b110110 + 0o55) + '\157' + chr(0b1100100) + '\x65')('\165' + '\x74' + chr(0b1100110) + '\x2d' + chr(56)), ahN6YYm9NJTr=ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\060', 8)):
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b"\x11\xcc\x8a\n\xa3Wb'\xa4f\xacM"), chr(100) + '\145' + '\143' + '\x6f' + chr(100) + chr(0b1100101))('\x75' + chr(0b100110 + 0o116) + '\146' + chr(45) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'1\x98\xaa\x17\xb2Aiu\xf3/\x85'), '\144' + chr(0b1100101) + '\143' + '\x6f' + '\x64' + chr(0b11100 + 0o111))(chr(117) + chr(7498 - 7382) + chr(0b1100110) + chr(0b101101) + '\x38') % UAGQwjlXRoHO)
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b"\x11\xcc\x8a\n\xa3Wb'\xa4f\xacM"), chr(687 - 587) + chr(0b110101 + 0o60) + chr(99) + '\157' + chr(0b1010 + 0o132) + '\145')(chr(0b1110101) + '\164' + '\x66' + chr(0b11111 + 0o16) + chr(705 - 649)))(xafqLlk3kkUe(SXOLrMavuUCe(b'5\x94\xb0\x19\xb3FZw\xbe\x7f\xcb\x03{'), chr(0b1000101 + 0o37) + chr(0b111010 + 0o53) + chr(0b110111 + 0o54) + chr(1944 - 1833) + chr(0b1100100) + chr(9634 - 9533))('\165' + chr(0b1110100) + chr(102) + chr(45) + '\070') % PuUgdbTDfM5R)
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b"\x11\xcc\x8a\n\xa3Wb'\xa4f\xacM"), '\144' + chr(0b1000001 + 0o44) + chr(0b1001100 + 0o27) + '\157' + chr(0b1000101 + 0o37) + chr(0b1100101))('\x75' + chr(0b111011 + 0o71) + chr(0b1100110) + '\055' + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'1\x82\xac\x11\xeb\x11v'), chr(0b1100100) + chr(9426 - 9325) + chr(2793 - 2694) + chr(0b1101111) + chr(0b110100 + 0o60) + '\x65')('\165' + '\164' + chr(102) + chr(1610 - 1565) + chr(56)) % OLWAJrKMaq_U)
def Fkz7D8w4sOPq(oVx_JuZw9z5G=ehT0Px3KOsy9('\060' + '\157' + chr(0b10 + 0o56), 8)):
if oVx_JuZw9z5G:
return YyaZ4tpXu4lf(vQr8gNKaIaWE(FxTcw4hdTCz5))
OWaOBDwJktEd = FxTcw4hdTCz5 // WliVXXDhyaO6
return [pd3lxn9vqWxp + LPBkMz6QzyaB * OWaOBDwJktEd for pd3lxn9vqWxp in vQr8gNKaIaWE(OWaOBDwJktEd)]
def ua5uTX56il2Q(zcNH1ym8cZBx):
if HAd4wfFhlIz7:
VHn4CV4Ymrei = [ehT0Px3KOsy9(vGrByMSYMp9h) for vGrByMSYMp9h in HAd4wfFhlIz7.split(xafqLlk3kkUe(SXOLrMavuUCe(b'b'), '\144' + chr(6257 - 6156) + '\x63' + chr(111) + '\x64' + chr(0b101011 + 0o72))(chr(0b1101011 + 0o12) + chr(0b1110100) + chr(0b1100110) + chr(0b101 + 0o50) + chr(56)))]
if c2A0yzQpDQB3(VHn4CV4Ymrei) == zcNH1ym8cZBx:
return VHn4CV4Ymrei
return YyaZ4tpXu4lf(vQr8gNKaIaWE(zcNH1ym8cZBx))
def GpA1FZ6jGUO1(oVx_JuZw9z5G=ehT0Px3KOsy9('\060' + '\x6f' + chr(0b10 + 0o56), 8)):
UNtEG7_pvWvV = []
for pd3lxn9vqWxp in Fkz7D8w4sOPq(all_workers=oVx_JuZw9z5G):
xafqLlk3kkUe(UNtEG7_pvWvV, xafqLlk3kkUe(SXOLrMavuUCe(b"'\x83\xb6\x17\xb8P"), chr(0b10011 + 0o121) + chr(0b110011 + 0o62) + chr(0b1100011) + chr(10601 - 10490) + '\144' + chr(0b1100101))(chr(6252 - 6135) + '\164' + chr(0b100101 + 0o101) + chr(1062 - 1017) + chr(56)))([(pd3lxn9vqWxp, q042LNsZ6EiE) for q042LNsZ6EiE in ua5uTX56il2Q(Z3DGfLevW2iR)])
return UNtEG7_pvWvV
def lNg3GMZVgnPj(oVx_JuZw9z5G=ehT0Px3KOsy9('\060' + '\157' + '\060', 8)):
if FxTcw4hdTCz5 > ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110000), 8):
if Z3DGfLevW2iR > ehT0Px3KOsy9(chr(508 - 460) + '\157' + '\x30', 8):
return [oLSYTDD4mLyy + xafqLlk3kkUe(SXOLrMavuUCe(b'm\x8f\xa3\x01\xbd\x0e t\xe1M\xa6s2\x00\xab'), chr(0b1100100) + '\145' + chr(0b1100001 + 0o2) + '\x6f' + chr(0b1100100) + chr(8454 - 8353))('\165' + chr(116) + chr(102) + '\x2d' + '\x38') % (pd3lxn9vqWxp, q042LNsZ6EiE) for (pd3lxn9vqWxp, q042LNsZ6EiE) in GpA1FZ6jGUO1(all_workers=oVx_JuZw9z5G)]
else:
return [oLSYTDD4mLyy + xafqLlk3kkUe(SXOLrMavuUCe(b'm\x8f\xa3\x01\xbd\x0e t'), '\144' + chr(0b1100101) + chr(0b1100011) + '\157' + chr(1058 - 958) + chr(0b1000011 + 0o42))(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + chr(45) + chr(56)) % pd3lxn9vqWxp for pd3lxn9vqWxp in Fkz7D8w4sOPq(all_workers=oVx_JuZw9z5G)]
elif PuUgdbTDfM5R > ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(48), 8):
return [xafqLlk3kkUe(SXOLrMavuUCe(b'%\x8b\xb7H\xf3P'), chr(100) + '\x65' + chr(99) + chr(430 - 319) + chr(2716 - 2616) + '\145')('\165' + chr(0b101110 + 0o106) + '\x66' + '\055' + '\070') % pd3lxn9vqWxp for pd3lxn9vqWxp in ua5uTX56il2Q(PuUgdbTDfM5R)]
else:
return [xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(100) + '\145' + chr(0b101001 + 0o72) + chr(111) + chr(0b1100100) + chr(7706 - 7605))(chr(117) + chr(0b1110100) + chr(0b1100110) + chr(0b101101) + chr(56))]
def ixOIBsAdkw9x(S8roUJoWyIV8):
if FxTcw4hdTCz5 == ehT0Px3KOsy9('\x30' + chr(111) + chr(48), 8):
return S8roUJoWyIV8
return xafqLlk3kkUe(IDJ2eXGCBCDu.train, xafqLlk3kkUe(SXOLrMavuUCe(b'0\x9e\xb2\x1e\xbfWdO\xaao\x80Ok@\x90|\xb6\xa8\xd3\x00>'), chr(0b1001101 + 0o27) + chr(0b1011 + 0o132) + chr(99) + chr(0b1101111) + '\x64' + chr(0b1100101))('\165' + '\164' + chr(7129 - 7027) + '\055' + '\x38'))(worker_device=S8roUJoWyIV8, ps_tasks=FxTcw4hdTCz5, ps_device=oLSYTDD4mLyy + xafqLlk3kkUe(SXOLrMavuUCe(b"m\xbc\x92'\xec\x04"), chr(100) + chr(0b1100101) + chr(99) + '\x6f' + chr(3214 - 3114) + chr(4444 - 4343))(chr(0b101111 + 0o106) + chr(13043 - 12927) + chr(0b1100110) + '\055' + chr(3088 - 3032)) if Z3DGfLevW2iR > ehT0Px3KOsy9(chr(1490 - 1442) + '\157' + chr(48), 8) else oLSYTDD4mLyy)
x9Asn26mpxZC = FxTcw4hdTCz5 == ehT0Px3KOsy9(chr(0b10011 + 0o35) + chr(111) + chr(2215 - 2167), 8) and WliVXXDhyaO6 == ehT0Px3KOsy9(chr(943 - 895) + '\x6f' + chr(0b110001), 8)
if ahN6YYm9NJTr:
DkKh_ngvPH2i = [xafqLlk3kkUe(SXOLrMavuUCe(b''), '\x64' + chr(0b1010 + 0o133) + chr(0b1100011) + chr(7908 - 7797) + '\144' + '\145')(chr(9342 - 9225) + chr(0b1110100) + '\x66' + chr(1261 - 1216) + chr(1734 - 1678))]
TIt00UYgDnKK = None
elif x9Asn26mpxZC:
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b',\xbf\x87\x1c\x98vdr\x88D\xbdK'), chr(0b11111 + 0o105) + chr(7153 - 7052) + chr(846 - 747) + chr(111) + '\144' + chr(0b1100101))(chr(0b11100 + 0o131) + '\164' + chr(0b11000 + 0o116) + chr(45) + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x11\x98\xaa\x17\xb2Aiu\xf3/\x85\x08(d\xbc|\xa6\xb1\xce\x0b+\x83\x9d\x1c*\x06]\xe0\x08ko\x11\xfa\xcf\xe4\x7f\x1b\x12\xb9\xc87\x95\xac\x1b\xb8S%\x7f\xa0*\x97\x06{L\xa1h\xbf\xb9\x87\x08-\xc0\x81\x1d%\x17S'), '\x64' + chr(101) + chr(99) + '\157' + '\144' + '\x65')(chr(117) + chr(8921 - 8805) + '\146' + '\055' + chr(0b110011 + 0o5)), UAGQwjlXRoHO)
DkKh_ngvPH2i = [xafqLlk3kkUe(SXOLrMavuUCe(b'%\x8b\xb7H\xf3P'), chr(3483 - 3383) + chr(101) + chr(1233 - 1134) + chr(111) + chr(0b1010010 + 0o22) + chr(0b1100101))('\165' + chr(10879 - 10763) + chr(0b101101 + 0o71) + '\x2d' + chr(0b111000)) % pd3lxn9vqWxp for pd3lxn9vqWxp in ua5uTX56il2Q(PuUgdbTDfM5R)]
if PuUgdbTDfM5R < ehT0Px3KOsy9(chr(428 - 380) + '\157' + chr(49), 8):
DkKh_ngvPH2i += [xafqLlk3kkUe(SXOLrMavuUCe(b'!\x8b\xb7H\xe6'), '\x64' + chr(101) + '\143' + chr(0b1101111) + chr(9812 - 9712) + chr(101))(chr(10860 - 10743) + '\164' + chr(0b1100110) + chr(0b11010 + 0o23) + chr(270 - 214))]
TIt00UYgDnKK = None
elif OLWAJrKMaq_U and FxTcw4hdTCz5 > ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(0b1101111) + chr(0b1011 + 0o45), 8):
DkKh_ngvPH2i = [ixOIBsAdkw9x(pd3lxn9vqWxp) for pd3lxn9vqWxp in lNg3GMZVgnPj(all_workers=oVx_JuZw9z5G)]
if Z3DGfLevW2iR > ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110000), 8) and FxTcw4hdTCz5 > ehT0Px3KOsy9('\060' + chr(6134 - 6023) + chr(0b110001), 8):
TIt00UYgDnKK = [oLSYTDD4mLyy + xafqLlk3kkUe(SXOLrMavuUCe(b'm\x8f\xa3\x01\xbd\x0e t\xe1i\x86S2\x15'), chr(100) + chr(0b111010 + 0o53) + chr(99) + chr(9829 - 9718) + chr(0b1100100) + '\145')('\165' + chr(0b10011 + 0o141) + chr(621 - 519) + '\x2d' + chr(253 - 197)) % pd3lxn9vqWxp for (pd3lxn9vqWxp, VNGQdHSFPrso) in GpA1FZ6jGUO1(all_workers=oVx_JuZw9z5G)]
else:
TIt00UYgDnKK = None
elif PuUgdbTDfM5R > ehT0Px3KOsy9(chr(48) + chr(0b101110 + 0o101) + chr(0b1111 + 0o42), 8):
DkKh_ngvPH2i = [ixOIBsAdkw9x(rrM_5p2Pq7Qu + xafqLlk3kkUe(SXOLrMavuUCe(b"m\xbc\x92'\xec\x11a"), chr(7006 - 6906) + chr(0b1100101) + chr(0b1100011) + '\157' + chr(100) + '\x65')(chr(117) + chr(116) + chr(102) + '\055' + chr(56)) % pd3lxn9vqWxp) for pd3lxn9vqWxp in ua5uTX56il2Q(PuUgdbTDfM5R)]
TIt00UYgDnKK = None
else:
DkKh_ngvPH2i = [ixOIBsAdkw9x(rrM_5p2Pq7Qu)]
TIt00UYgDnKK = None
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b"\x11\xcc\x8a\n\xa3Wb'\xa4f\xacM"), '\144' + '\x65' + chr(0b1001000 + 0o33) + chr(0b1010010 + 0o35) + chr(0b1100100) + '\x65')('\x75' + chr(6191 - 6075) + '\146' + chr(0b101101) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'&\x9a\xb6\x13\xa5\\db\xaaU\x92C~L\xacj\xa0\xe6\x87@?'), '\x64' + chr(0b101111 + 0o66) + '\143' + chr(3800 - 3689) + chr(100) + chr(101))('\x75' + chr(0b1110100) + chr(0b1100110) + chr(45) + chr(0b111000)), DkKh_ngvPH2i)
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b"\x11\xcc\x8a\n\xa3Wb'\xa4f\xacM"), chr(0b1011011 + 0o11) + chr(0b1100101) + chr(0b1100 + 0o127) + '\157' + chr(0b1100100) + '\145')(chr(12317 - 12200) + chr(5817 - 5701) + chr(917 - 815) + chr(45) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'!\x9a\xa1\x1a\xbfZbO\xaao\x80Ok@\xbc5\xf3\xf9\xd4'), chr(5151 - 5051) + chr(9241 - 9140) + '\143' + chr(0b1101111) + chr(2987 - 2887) + chr(0b1100101))(chr(0b1110101) + chr(0b1110100) + '\x66' + chr(45) + chr(0b111000)), TIt00UYgDnKK)
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b"\x11\xcc\x8a\n\xa3Wb'\xa4f\xacM"), '\144' + chr(0b1100101) + chr(99) + chr(111) + chr(0b10000 + 0o124) + '\145')(chr(117) + chr(343 - 227) + chr(4981 - 4879) + chr(45) + chr(473 - 417)))(xafqLlk3kkUe(SXOLrMavuUCe(b'2\x88\x9d\x16\xb3Bls\xaby\xcc\x06-V'), chr(0b101100 + 0o70) + chr(101) + chr(0b1100011) + chr(111) + chr(1033 - 933) + '\x65')(chr(12196 - 12079) + '\x74' + chr(0b1100110) + chr(1877 - 1832) + chr(0b1010 + 0o56)), lNg3GMZVgnPj(all_workers=oVx_JuZw9z5G))
return xafqLlk3kkUe(szcq37AdAR6Z, xafqLlk3kkUe(SXOLrMavuUCe(b'\x12\x9a\xb0\x13\xbaX`|\xa7y\x9b'), chr(100) + chr(101) + chr(0b1100011) + chr(0b1101111) + '\x64' + chr(0b1100101))(chr(0b10011 + 0o142) + chr(0b1110100) + '\146' + chr(0b10111 + 0o26) + '\x38'))(DkKh_ngvPH2i, caching_devices=TIt00UYgDnKK, daisy_chain_variables=m812svkc5bkk, ps_devices=lNg3GMZVgnPj(all_workers=oVx_JuZw9z5G))
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/wiki_lm.py
|
concat_generator
|
def concat_generator(filename, up_threshold, low_threshold=10):
"""Generate concatenated lines from file upto up_threshold characters."""
txt = ""
for line in tf.gfile.Open(filename):
line = line.strip()
if len(txt) + len(line) + 1 >= up_threshold:
ret = txt
txt = ""
# We don't yield very short long parts to prevent noisy examples.
if len(ret) > low_threshold and len(ret) < up_threshold:
yield {"targets": ret}
if not txt:
txt = line
else:
txt = " ".join([txt, line])
|
python
|
def concat_generator(filename, up_threshold, low_threshold=10):
"""Generate concatenated lines from file upto up_threshold characters."""
txt = ""
for line in tf.gfile.Open(filename):
line = line.strip()
if len(txt) + len(line) + 1 >= up_threshold:
ret = txt
txt = ""
# We don't yield very short long parts to prevent noisy examples.
if len(ret) > low_threshold and len(ret) < up_threshold:
yield {"targets": ret}
if not txt:
txt = line
else:
txt = " ".join([txt, line])
|
[
"def",
"concat_generator",
"(",
"filename",
",",
"up_threshold",
",",
"low_threshold",
"=",
"10",
")",
":",
"txt",
"=",
"\"\"",
"for",
"line",
"in",
"tf",
".",
"gfile",
".",
"Open",
"(",
"filename",
")",
":",
"line",
"=",
"line",
".",
"strip",
"(",
")",
"if",
"len",
"(",
"txt",
")",
"+",
"len",
"(",
"line",
")",
"+",
"1",
">=",
"up_threshold",
":",
"ret",
"=",
"txt",
"txt",
"=",
"\"\"",
"# We don't yield very short long parts to prevent noisy examples.",
"if",
"len",
"(",
"ret",
")",
">",
"low_threshold",
"and",
"len",
"(",
"ret",
")",
"<",
"up_threshold",
":",
"yield",
"{",
"\"targets\"",
":",
"ret",
"}",
"if",
"not",
"txt",
":",
"txt",
"=",
"line",
"else",
":",
"txt",
"=",
"\" \"",
".",
"join",
"(",
"[",
"txt",
",",
"line",
"]",
")"
] |
Generate concatenated lines from file upto up_threshold characters.
|
[
"Generate",
"concatenated",
"lines",
"from",
"file",
"upto",
"up_threshold",
"characters",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/wiki_lm.py#L33-L48
|
train
|
Generate concatenated lines from file upto up_threshold characters.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjf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k3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x33' + '\061' + chr(0b101110 + 0o7), 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(49) + chr(0b101010 + 0o12) + chr(0b110011), 13260 - 13252), ehT0Px3KOsy9(chr(1506 - 1458) + '\x6f' + chr(50) + chr(88 - 39) + chr(50), 0o10), ehT0Px3KOsy9(chr(0b101001 + 0o7) + '\157' + chr(0b110011) + '\063' + chr(51), 0b1000), ehT0Px3KOsy9('\060' + '\157' + '\062' + chr(2373 - 2321), ord("\x08")), ehT0Px3KOsy9(chr(60 - 12) + '\x6f' + '\x30', 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110001) + chr(48) + chr(0b101010 + 0o10), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(49) + chr(0b110101) + chr(1691 - 1637), 10003 - 9995), ehT0Px3KOsy9('\060' + '\157' + chr(0b101000 + 0o12) + '\061' + chr(0b110001), ord("\x08")), ehT0Px3KOsy9(chr(368 - 320) + chr(111) + chr(49) + chr(0b110000) + chr(0b110110), 44166 - 44158), ehT0Px3KOsy9(chr(397 - 349) + chr(0b1101111) + chr(1038 - 989) + chr(48) + chr(0b110010), 8), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110110) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(320 - 209) + chr(49) + chr(0b110100) + chr(0b110010 + 0o5), 0b1000), ehT0Px3KOsy9('\060' + '\157' + '\x31' + chr(2318 - 2263) + '\066', 0b1000), ehT0Px3KOsy9(chr(0b100 + 0o54) + '\x6f' + '\061' + '\x32' + '\x36', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110010) + chr(0b10111 + 0o31) + chr(50), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110011) + chr(0b110001) + '\063', 60841 - 60833), ehT0Px3KOsy9(chr(48) + '\157' + chr(1763 - 1713) + chr(2202 - 2149) + '\066', 42494 - 42486), ehT0Px3KOsy9('\x30' + chr(0b1101011 + 0o4) + '\x32' + chr(0b100000 + 0o26) + '\x37', 0b1000), ehT0Px3KOsy9(chr(692 - 644) + '\157' + '\061' + chr(436 - 387) + chr(51), 25714 - 25706), ehT0Px3KOsy9(chr(0b110000) + chr(4085 - 3974) + chr(50) + chr(1224 - 1176) + chr(1433 - 1384), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(0b11101 + 0o24) + chr(55) + '\065', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(1325 - 1274), ord("\x08")), ehT0Px3KOsy9(chr(0b10 + 0o56) + chr(2897 - 2786) + chr(0b100111 + 0o13) + chr(0b110100) + chr(49), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\062' + '\x32' + chr(0b110000 + 0o5), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110001) + chr(1999 - 1950) + chr(49), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b100010 + 0o115) + '\061' + '\x34' + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b10000 + 0o137) + chr(0b110011) + '\x33' + chr(2509 - 2454), 44898 - 44890), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(2098 - 2047) + chr(52), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + '\x32' + chr(903 - 855) + chr(49), 8), ehT0Px3KOsy9(chr(0b10110 + 0o32) + '\x6f' + chr(51) + chr(57 - 4) + '\x32', 0o10), ehT0Px3KOsy9('\x30' + chr(11052 - 10941) + chr(0b10 + 0o61) + chr(49) + chr(52), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\063' + chr(55) + chr(55), 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(50) + chr(53) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(5400 - 5289) + chr(0b101111 + 0o2) + '\x34' + chr(49), 57647 - 57639), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b1001 + 0o56) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(2378 - 2325) + '\x30', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(127 - 16) + '\x32' + chr(51) + '\062', 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(51) + chr(54), 1934 - 1926), ehT0Px3KOsy9(chr(1875 - 1827) + chr(0b1101100 + 0o3) + '\062' + '\060' + chr(0b110010), 8)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(0b1001011 + 0o44) + '\x35' + chr(0b110000), 8)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xe3'), chr(0b10 + 0o142) + '\x65' + chr(6464 - 6365) + '\157' + chr(5015 - 4915) + chr(2136 - 2035))(chr(0b111110 + 0o67) + '\164' + '\x66' + chr(0b101101) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def VjDYeBL6G6Aa(xw4DsBfIJ22E, FSjH5JpwFJTu, sPSlO9sdtGKz=ehT0Px3KOsy9('\060' + '\x6f' + '\x31' + chr(50), 0b1000)):
O5_whZSUsK22 = xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(5887 - 5787) + '\145' + chr(0b1100011) + chr(0b10111 + 0o130) + '\144' + chr(0b10000 + 0o125))(chr(117) + '\x74' + chr(102) + chr(0b1110 + 0o37) + chr(1556 - 1500))
for LycYkDpyelF6 in xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\x82\x13\xef\xb5'), chr(0b1100100) + '\145' + '\x63' + chr(0b101111 + 0o100) + chr(100) + chr(2645 - 2544))(chr(0b1000 + 0o155) + chr(116) + chr(7586 - 7484) + chr(0b101101) + chr(751 - 695)))(xw4DsBfIJ22E):
LycYkDpyelF6 = LycYkDpyelF6.strip()
if c2A0yzQpDQB3(O5_whZSUsK22) + c2A0yzQpDQB3(LycYkDpyelF6) + ehT0Px3KOsy9(chr(48) + chr(749 - 638) + chr(0b10000 + 0o41), 0o10) >= FSjH5JpwFJTu:
VHn4CV4Ymrei = O5_whZSUsK22
O5_whZSUsK22 = xafqLlk3kkUe(SXOLrMavuUCe(b''), '\144' + '\x65' + chr(2901 - 2802) + chr(5371 - 5260) + '\x64' + '\145')(chr(117) + chr(116) + chr(3662 - 3560) + chr(45) + chr(0b111000))
if c2A0yzQpDQB3(VHn4CV4Ymrei) > sPSlO9sdtGKz and c2A0yzQpDQB3(VHn4CV4Ymrei) < FSjH5JpwFJTu:
yield {xafqLlk3kkUe(SXOLrMavuUCe(b'\xb9\x02\xf8\xbcqt1'), '\x64' + chr(0b110110 + 0o57) + chr(0b1100011) + chr(0b1100101 + 0o12) + '\x64' + chr(0b1001011 + 0o32))(chr(0b111100 + 0o71) + chr(999 - 883) + chr(3392 - 3290) + chr(1494 - 1449) + '\x38'): VHn4CV4Ymrei}
if not O5_whZSUsK22:
O5_whZSUsK22 = LycYkDpyelF6
else:
O5_whZSUsK22 = xafqLlk3kkUe(SXOLrMavuUCe(b'\xed'), '\x64' + '\x65' + chr(0b1100011) + chr(0b111100 + 0o63) + chr(100) + '\145')('\165' + chr(9672 - 9556) + chr(102) + chr(0b101101) + chr(0b111000)).join([O5_whZSUsK22, LycYkDpyelF6])
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/wiki_lm.py
|
mix_generators
|
def mix_generators(generator_list):
"""Given python generators, generate from one, then from another, etc."""
i = 0
l = len(generator_list)
stopiters_seen = 0
while stopiters_seen <= l:
try:
yield six.next(generator_list[i % l])
i += 1
stopiters_seen = 0
except StopIteration:
i += 1
stopiters_seen += 1
|
python
|
def mix_generators(generator_list):
"""Given python generators, generate from one, then from another, etc."""
i = 0
l = len(generator_list)
stopiters_seen = 0
while stopiters_seen <= l:
try:
yield six.next(generator_list[i % l])
i += 1
stopiters_seen = 0
except StopIteration:
i += 1
stopiters_seen += 1
|
[
"def",
"mix_generators",
"(",
"generator_list",
")",
":",
"i",
"=",
"0",
"l",
"=",
"len",
"(",
"generator_list",
")",
"stopiters_seen",
"=",
"0",
"while",
"stopiters_seen",
"<=",
"l",
":",
"try",
":",
"yield",
"six",
".",
"next",
"(",
"generator_list",
"[",
"i",
"%",
"l",
"]",
")",
"i",
"+=",
"1",
"stopiters_seen",
"=",
"0",
"except",
"StopIteration",
":",
"i",
"+=",
"1",
"stopiters_seen",
"+=",
"1"
] |
Given python generators, generate from one, then from another, etc.
|
[
"Given",
"python",
"generators",
"generate",
"from",
"one",
"then",
"from",
"another",
"etc",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/wiki_lm.py#L51-L63
|
train
|
Given python generators generate from one then from another etc.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNBHlx,ZsDPvpP4xdo3,cW7yQuyEnJ6E,KOHQGQ8qLDWm,NE1Yam2HHroQ,ygAzbDzrvRMh,SBRjvOU1ufVC,hOkXjmluKZfJ,q1QCh3W88sgk,TLbJ60djyws0,rIcPej9ZqMqV,WTxpD_zsEOh2,LgE_IO_tHXvM,Kk1hd194VKEC,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0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b100000 + 0o20) + '\x6f' + chr(53), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(346 - 296) + chr(0b110110) + chr(0b1111 + 0o44), 0o10), ehT0Px3KOsy9(chr(48) + chr(6465 - 6354) + chr(2209 - 2159) + chr(0b10001 + 0o46) + chr(100 - 47), ord("\x08")), ehT0Px3KOsy9(chr(658 - 610) + '\x6f' + chr(49) + chr(80 - 32) + '\x37', 0o10), ehT0Px3KOsy9(chr(48) + chr(11919 - 11808) + chr(0b11110 + 0o24) + '\x30' + '\066', 37345 - 37337), ehT0Px3KOsy9('\x30' + '\157' + chr(0b1100 + 0o46) + '\063' + chr(2536 - 2482), ord("\x08")), ehT0Px3KOsy9(chr(0b1011 + 0o45) + chr(0b1101111) + '\x33' + '\063', 50408 - 50400), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b111 + 0o53) + chr(0b110010) + chr(0b101110 + 0o3), 65179 - 65171), ehT0Px3KOsy9(chr(48) + chr(1334 - 1223) + chr(0b101001 + 0o11) + chr(0b1000 + 0o54) + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(7262 - 7151) + '\066', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(11320 - 11209) + chr(1558 - 1509) + '\x35' + chr(53), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\061' + chr(0b110100) + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(92 - 44) + chr(0b1101111) + chr(0b100000 + 0o23) + '\x37' + '\065', 0o10), ehT0Px3KOsy9(chr(0b100001 + 0o17) + chr(111) + chr(50) + chr(0b100001 + 0o25), 55677 - 55669), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x31' + '\x31', 13035 - 13027), ehT0Px3KOsy9(chr(48) + chr(9924 - 9813) + chr(49) + chr(50) + chr(0b11000 + 0o33), 50823 - 50815), ehT0Px3KOsy9('\x30' + '\157' + chr(136 - 86) + chr(0b100110 + 0o16) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(1394 - 1346) + chr(0b1101111) + chr(49) + chr(773 - 720) + chr(1535 - 1481), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(11908 - 11797) + chr(51) + '\x36', 60703 - 60695), ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(0b1101111 + 0o0) + '\062' + '\062' + '\x31', 8), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110010) + chr(0b1001 + 0o51) + chr(0b110001), 8), ehT0Px3KOsy9('\x30' + chr(392 - 281) + chr(53) + chr(54), 0b1000), ehT0Px3KOsy9(chr(1827 - 1779) + '\x6f' + '\x36' + '\062', 41830 - 41822), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b101000 + 0o11) + chr(0b101011 + 0o6) + chr(50), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(8756 - 8645) + chr(0b1100 + 0o46) + '\062' + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(50) + chr(1371 - 1323) + chr(48), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(50) + '\x30' + chr(0b11110 + 0o25), 39757 - 39749), ehT0Px3KOsy9(chr(0b1100 + 0o44) + chr(111) + chr(50) + chr(1386 - 1338) + chr(377 - 322), 49110 - 49102), ehT0Px3KOsy9('\x30' + chr(0b1110 + 0o141) + chr(0b110010) + chr(49) + chr(0b101001 + 0o12), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + '\x34' + '\x36', 10268 - 10260), ehT0Px3KOsy9(chr(223 - 175) + '\157' + '\061' + '\x33' + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(791 - 743) + chr(7527 - 7416) + chr(50) + chr(0b110100 + 0o0) + '\x33', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\062' + '\x36' + chr(0b11000 + 0o36), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110010) + '\060' + chr(52), 0b1000), ehT0Px3KOsy9('\060' + chr(0b111000 + 0o67) + '\x33' + '\x34' + chr(55), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\067' + '\060', 36821 - 36813), ehT0Px3KOsy9(chr(0b10111 + 0o31) + '\x6f' + chr(51) + '\064' + '\x34', 37944 - 37936), ehT0Px3KOsy9(chr(0b1111 + 0o41) + chr(0b1000001 + 0o56) + '\x36' + chr(51), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(51) + '\x36' + '\x33', 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b101000 + 0o12) + chr(55) + chr(0b110010), ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110010 + 0o3) + chr(0b110000), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'+'), chr(6367 - 6267) + chr(0b1100101) + chr(0b1100011) + '\157' + '\x64' + chr(0b10000 + 0o125))(chr(117) + chr(3145 - 3029) + chr(0b1100110) + chr(0b101101) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def HCfYhrMzBcvd(r4ieNPT6lxRe):
WVxHKyX45z_L = ehT0Px3KOsy9(chr(999 - 951) + chr(0b1101111) + chr(0b11110 + 0o22), ord("\x08"))
aLoH_Mt0dzwO = c2A0yzQpDQB3(r4ieNPT6lxRe)
nvfg6qBALPei = ehT0Px3KOsy9(chr(432 - 384) + chr(111) + '\x30', 8)
while nvfg6qBALPei <= aLoH_Mt0dzwO:
try:
yield xafqLlk3kkUe(sYby0kpfssd4, xafqLlk3kkUe(SXOLrMavuUCe(b'k\xe0\xca0\xce\xdb~\xdc\x95e\x15('), '\144' + chr(0b110100 + 0o61) + chr(99) + chr(111) + chr(4430 - 4330) + '\x65')(chr(11892 - 11775) + chr(116) + '\x66' + chr(45) + chr(0b1100 + 0o54)))(r4ieNPT6lxRe[WVxHKyX45z_L % aLoH_Mt0dzwO])
WVxHKyX45z_L += ehT0Px3KOsy9(chr(48) + '\157' + '\x31', 0o10)
nvfg6qBALPei = ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(317 - 269), 8)
except hr2QaoivbFQ2:
WVxHKyX45z_L += ehT0Px3KOsy9(chr(0b10010 + 0o36) + '\x6f' + chr(0b10101 + 0o34), 8)
nvfg6qBALPei += ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x31', 8)
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/translate.py
|
compute_bleu_summaries
|
def compute_bleu_summaries(hook_args):
"""Compute BLEU core summaries using the decoder output.
Args:
hook_args: DecodeHookArgs namedtuple
Returns:
A list of tf.Summary values if hook_args.hparams contains the
reference file and the translated file.
"""
decode_hparams = hook_args.decode_hparams
if not (decode_hparams.decode_reference and decode_hparams.decode_to_file):
return None
values = []
bleu = 100 * bleu_hook.bleu_wrapper(
decode_hparams.decode_reference, decode_hparams.decode_to_file)
values.append(tf.Summary.Value(tag="BLEU", simple_value=bleu))
tf.logging.info("%s: BLEU = %6.2f" % (decode_hparams.decode_to_file, bleu))
if hook_args.hparams.mlperf_mode:
current_step = decode_hparams.mlperf_decode_step
mlperf_log.transformer_print(
key=mlperf_log.EVAL_TARGET, value=decode_hparams.mlperf_threshold)
mlperf_log.transformer_print(
key=mlperf_log.EVAL_ACCURACY,
value={
"epoch": max(current_step // decode_hparams.iterations_per_loop - 1,
0),
"value": bleu
})
mlperf_log.transformer_print(key=mlperf_log.EVAL_STOP)
if bleu >= decode_hparams.mlperf_threshold:
decode_hparams.set_hparam("mlperf_success", True)
return values
|
python
|
def compute_bleu_summaries(hook_args):
"""Compute BLEU core summaries using the decoder output.
Args:
hook_args: DecodeHookArgs namedtuple
Returns:
A list of tf.Summary values if hook_args.hparams contains the
reference file and the translated file.
"""
decode_hparams = hook_args.decode_hparams
if not (decode_hparams.decode_reference and decode_hparams.decode_to_file):
return None
values = []
bleu = 100 * bleu_hook.bleu_wrapper(
decode_hparams.decode_reference, decode_hparams.decode_to_file)
values.append(tf.Summary.Value(tag="BLEU", simple_value=bleu))
tf.logging.info("%s: BLEU = %6.2f" % (decode_hparams.decode_to_file, bleu))
if hook_args.hparams.mlperf_mode:
current_step = decode_hparams.mlperf_decode_step
mlperf_log.transformer_print(
key=mlperf_log.EVAL_TARGET, value=decode_hparams.mlperf_threshold)
mlperf_log.transformer_print(
key=mlperf_log.EVAL_ACCURACY,
value={
"epoch": max(current_step // decode_hparams.iterations_per_loop - 1,
0),
"value": bleu
})
mlperf_log.transformer_print(key=mlperf_log.EVAL_STOP)
if bleu >= decode_hparams.mlperf_threshold:
decode_hparams.set_hparam("mlperf_success", True)
return values
|
[
"def",
"compute_bleu_summaries",
"(",
"hook_args",
")",
":",
"decode_hparams",
"=",
"hook_args",
".",
"decode_hparams",
"if",
"not",
"(",
"decode_hparams",
".",
"decode_reference",
"and",
"decode_hparams",
".",
"decode_to_file",
")",
":",
"return",
"None",
"values",
"=",
"[",
"]",
"bleu",
"=",
"100",
"*",
"bleu_hook",
".",
"bleu_wrapper",
"(",
"decode_hparams",
".",
"decode_reference",
",",
"decode_hparams",
".",
"decode_to_file",
")",
"values",
".",
"append",
"(",
"tf",
".",
"Summary",
".",
"Value",
"(",
"tag",
"=",
"\"BLEU\"",
",",
"simple_value",
"=",
"bleu",
")",
")",
"tf",
".",
"logging",
".",
"info",
"(",
"\"%s: BLEU = %6.2f\"",
"%",
"(",
"decode_hparams",
".",
"decode_to_file",
",",
"bleu",
")",
")",
"if",
"hook_args",
".",
"hparams",
".",
"mlperf_mode",
":",
"current_step",
"=",
"decode_hparams",
".",
"mlperf_decode_step",
"mlperf_log",
".",
"transformer_print",
"(",
"key",
"=",
"mlperf_log",
".",
"EVAL_TARGET",
",",
"value",
"=",
"decode_hparams",
".",
"mlperf_threshold",
")",
"mlperf_log",
".",
"transformer_print",
"(",
"key",
"=",
"mlperf_log",
".",
"EVAL_ACCURACY",
",",
"value",
"=",
"{",
"\"epoch\"",
":",
"max",
"(",
"current_step",
"//",
"decode_hparams",
".",
"iterations_per_loop",
"-",
"1",
",",
"0",
")",
",",
"\"value\"",
":",
"bleu",
"}",
")",
"mlperf_log",
".",
"transformer_print",
"(",
"key",
"=",
"mlperf_log",
".",
"EVAL_STOP",
")",
"if",
"bleu",
">=",
"decode_hparams",
".",
"mlperf_threshold",
":",
"decode_hparams",
".",
"set_hparam",
"(",
"\"mlperf_success\"",
",",
"True",
")",
"return",
"values"
] |
Compute BLEU core summaries using the decoder output.
Args:
hook_args: DecodeHookArgs namedtuple
Returns:
A list of tf.Summary values if hook_args.hparams contains the
reference file and the translated file.
|
[
"Compute",
"BLEU",
"core",
"summaries",
"using",
"the",
"decoder",
"output",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/translate.py#L83-L118
|
train
|
Compute BLEU core summaries using the decoder output.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQ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X,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + chr(3611 - 3500) + '\061' + chr(55) + chr(1149 - 1101), 0b1000), ehT0Px3KOsy9(chr(0b100110 + 0o12) + chr(0b1010011 + 0o34) + '\063' + chr(51) + '\063', ord("\x08")), ehT0Px3KOsy9('\060' + chr(1226 - 1115) + chr(2434 - 2381) + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(0b101000 + 0o10) + chr(111) + chr(1782 - 1731) + chr(55), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101000 + 0o7) + chr(0b110010) + '\063' + chr(0b11100 + 0o31), 0o10), ehT0Px3KOsy9(chr(1514 - 1466) + chr(0b111 + 0o150) + chr(0b100001 + 0o20) + chr(0b100111 + 0o20) + '\064', 14043 - 14035), ehT0Px3KOsy9('\x30' + chr(6614 - 6503) + chr(0b110101) + chr(0b101101 + 0o4), ord("\x08")), ehT0Px3KOsy9(chr(162 - 114) + chr(0b1101111) + chr(0b100001 + 0o25), 0b1000), ehT0Px3KOsy9(chr(0b10100 + 0o34) + chr(889 - 778) + chr(0b110001) + '\064' + chr(0b110010), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\x32' + '\061' + chr(53), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(10078 - 9967) + chr(51) + chr(0b110001) + chr(53), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1010000 + 0o37) + '\x33' + chr(0b110011) + chr(50), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1100110 + 0o11) + chr(0b110001) + chr(0b110000) + chr(53), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1011010 + 0o25) + chr(1587 - 1537) + '\066' + chr(1407 - 1357), 33686 - 33678), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(0b1101111) + chr(0b110010) + '\x33' + chr(2782 - 2728), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b11001 + 0o32) + chr(1748 - 1696) + '\x34', 0b1000), ehT0Px3KOsy9(chr(48) + chr(8161 - 8050) + '\x32' + chr(0b110110) + chr(0b11 + 0o62), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b110101 + 0o72) + chr(1335 - 1285) + chr(0b110100) + chr(0b101010 + 0o14), 0o10), ehT0Px3KOsy9(chr(2245 - 2197) + chr(4336 - 4225) + chr(0b101000 + 0o12) + chr(49) + chr(1870 - 1819), 35988 - 35980), ehT0Px3KOsy9('\x30' + chr(0b1001010 + 0o45) + chr(49) + '\x37' + chr(52), 8), ehT0Px3KOsy9(chr(0b11010 + 0o26) + chr(4077 - 3966) + '\063' + '\x34' + chr(0b110010 + 0o1), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(2063 - 2013) + chr(0b111 + 0o57) + '\066', 38432 - 38424), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110010) + '\064' + chr(0b110001 + 0o3), 0b1000), ehT0Px3KOsy9('\060' + chr(3873 - 3762) + '\x32' + chr(0b110010) + chr(0b110001), 22969 - 22961), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(1213 - 1163) + '\x30', 0o10), ehT0Px3KOsy9(chr(0b10100 + 0o34) + chr(111) + chr(0b1000 + 0o51) + chr(0b110101) + chr(0b1010 + 0o47), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(1499 - 1448) + chr(0b110111) + chr(277 - 228), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x33' + chr(0b110001 + 0o2) + chr(0b110101), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(262 - 213) + '\066' + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(0b10 + 0o56) + '\x6f' + chr(50) + chr(54) + chr(0b10110 + 0o35), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(50) + chr(48) + chr(54), 37505 - 37497), ehT0Px3KOsy9(chr(1939 - 1891) + chr(0b1101111) + '\x32' + chr(1333 - 1283) + chr(2138 - 2089), 8), ehT0Px3KOsy9(chr(1938 - 1890) + chr(0b1101001 + 0o6) + '\x34' + chr(51), 0o10), ehT0Px3KOsy9('\060' + chr(0b1100010 + 0o15) + '\062' + chr(49) + chr(2251 - 2203), 0b1000), ehT0Px3KOsy9(chr(0b100001 + 0o17) + '\x6f' + chr(0b1111 + 0o44) + chr(50) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(0b100110 + 0o12) + '\x6f' + chr(0b11101 + 0o26) + chr(0b110110) + chr(1426 - 1376), ord("\x08")), ehT0Px3KOsy9(chr(1406 - 1358) + '\x6f' + chr(0b11010 + 0o30) + '\063', 58492 - 58484), ehT0Px3KOsy9(chr(48) + chr(5258 - 5147) + chr(123 - 73) + '\x33' + chr(0b101111 + 0o4), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110001), 0o10), ehT0Px3KOsy9('\060' + chr(4723 - 4612) + chr(0b110011) + chr(49), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + '\x6f' + '\x35' + chr(0b110000), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'V'), chr(100) + chr(0b10100 + 0o121) + '\143' + chr(111) + '\144' + chr(4978 - 4877))(chr(0b11101 + 0o130) + chr(116) + '\146' + chr(0b11000 + 0o25) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def S64CkGur8F7w(OqN47Dvl9DWy):
LrQSWg3uwmK8 = OqN47Dvl9DWy.decode_hparams
if not (xafqLlk3kkUe(LrQSWg3uwmK8, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c\xbeIp\xf9\x19vt\x07\xeb\xa8\xa8 \xdc\xfd\x81'), chr(0b1100100) + '\x65' + chr(0b1100011) + chr(0b1101111) + chr(2180 - 2080) + chr(801 - 700))(chr(117) + chr(116) + chr(0b1001010 + 0o34) + chr(0b1101 + 0o40) + chr(0b111000))) and xafqLlk3kkUe(LrQSWg3uwmK8, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c\xbeIp\xf9\x19vr\r\xd2\xab\xb3)\xd7'), '\x64' + chr(0b1100101 + 0o0) + '\143' + '\157' + chr(0b11011 + 0o111) + chr(0b1100101))('\x75' + chr(0b1110100) + chr(0b1100110) + chr(283 - 238) + chr(2921 - 2865)))):
return None
SPnCNu54H1db = []
mhxooG4aO82H = ehT0Px3KOsy9(chr(0b110000 + 0o0) + '\157' + chr(0b110001) + chr(756 - 704) + chr(0b111 + 0o55), 0b1000) * uoC8aQYndBvQ.bleu_wrapper(LrQSWg3uwmK8.decode_reference, LrQSWg3uwmK8.decode_to_file)
xafqLlk3kkUe(SPnCNu54H1db, xafqLlk3kkUe(SXOLrMavuUCe(b'\x19\xabZz\xf3\x18'), '\x64' + '\x65' + chr(0b1100011) + chr(111) + chr(100) + chr(0b100010 + 0o103))(chr(0b1110101) + chr(0b1110100) + chr(102) + chr(0b101101) + chr(730 - 674)))(xafqLlk3kkUe(IDJ2eXGCBCDu.Summary, xafqLlk3kkUe(SXOLrMavuUCe(b'.\xbaFj\xf8'), chr(9524 - 9424) + chr(0b1100101) + '\x63' + chr(3506 - 3395) + chr(100) + chr(1759 - 1658))(chr(117) + chr(4587 - 4471) + chr(0b0 + 0o146) + chr(639 - 594) + chr(0b101110 + 0o12)))(tag=xafqLlk3kkUe(SXOLrMavuUCe(b':\x97oJ'), chr(100) + '\x65' + '\143' + chr(9939 - 9828) + chr(0b10100 + 0o120) + '\145')(chr(0b1000 + 0o155) + chr(12816 - 12700) + '\146' + chr(94 - 49) + chr(0b100000 + 0o30)), simple_value=mhxooG4aO82H))
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b'+\xecbg\xe8\x1fN1\x08\xe1\x97\xb1'), '\x64' + chr(0b1000110 + 0o37) + chr(0b101011 + 0o70) + '\157' + chr(100) + '\x65')(chr(2290 - 2173) + '\164' + chr(0b11 + 0o143) + chr(0b101101) + chr(2473 - 2417)))(xafqLlk3kkUe(SXOLrMavuUCe(b']\xa8\x10?\xdf0lSB\xb0\xed\xffs\x9c\xac\x82'), chr(100) + chr(9678 - 9577) + chr(0b1100011) + chr(0b101111 + 0o100) + '\144' + '\145')(chr(0b1110101) + chr(116) + chr(5271 - 5169) + chr(1024 - 979) + '\070') % (xafqLlk3kkUe(LrQSWg3uwmK8, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c\xbeIp\xf9\x19vr\r\xd2\xab\xb3)\xd7'), chr(100) + chr(0b1100101) + chr(0b1100011) + chr(8966 - 8855) + chr(0b1100100) + chr(0b1100011 + 0o2))('\165' + chr(5251 - 5135) + chr(5438 - 5336) + '\x2d' + '\070')), mhxooG4aO82H))
if xafqLlk3kkUe(OqN47Dvl9DWy.hparams, xafqLlk3kkUe(SXOLrMavuUCe(b'\x15\xb7Zz\xef\x1avk\r\xe9\xa8'), chr(0b1100100) + chr(0b1100101) + chr(99) + chr(0b1010111 + 0o30) + '\x64' + chr(101))(chr(117) + chr(0b111011 + 0o71) + chr(0b1100110) + chr(45) + '\x38')):
YmvhiZqIb4MX = LrQSWg3uwmK8.mlperf_decode_step
xafqLlk3kkUe(mcP9wB7s3wV8, xafqLlk3kkUe(SXOLrMavuUCe(b'\x0c\xa9Kq\xee\x1aFt\x0f\xe8\xbf\x855\xc0\xf7\x8a\xc1'), '\x64' + chr(3575 - 3474) + chr(5238 - 5139) + chr(11564 - 11453) + '\144' + chr(0b101100 + 0o71))(chr(117) + '\164' + '\x66' + chr(0b101101) + chr(2328 - 2272)))(key=xafqLlk3kkUe(mcP9wB7s3wV8, xafqLlk3kkUe(SXOLrMavuUCe(b'=\x8dkS\xc2(hT%\xc8\x99'), chr(100) + chr(0b111011 + 0o52) + chr(99) + '\x6f' + chr(0b1001110 + 0o26) + chr(101))('\165' + chr(116) + chr(102) + '\x2d' + chr(0b111000))), value=xafqLlk3kkUe(LrQSWg3uwmK8, xafqLlk3kkUe(SXOLrMavuUCe(b'\x15\xb7Zz\xef\x1avr\n\xff\xa8\xa9-\xdd\xf2\x80'), chr(100) + '\145' + chr(5533 - 5434) + chr(0b1101111) + chr(7550 - 7450) + chr(4699 - 4598))(chr(117) + chr(0b111011 + 0o71) + chr(102) + '\x2d' + '\070')))
xafqLlk3kkUe(mcP9wB7s3wV8, xafqLlk3kkUe(SXOLrMavuUCe(b'\x0c\xa9Kq\xee\x1aFt\x0f\xe8\xbf\x855\xc0\xf7\x8a\xc1'), chr(5968 - 5868) + chr(0b1100101) + chr(99) + '\x6f' + '\x64' + chr(3133 - 3032))('\x75' + chr(116) + chr(102) + chr(711 - 666) + chr(0b1101 + 0o53)))(key=xafqLlk3kkUe(mcP9wB7s3wV8, xafqLlk3kkUe(SXOLrMavuUCe(b'=\x8dkS\xc2=jE7\xdf\x8c\x99\x1c'), chr(3291 - 3191) + chr(101) + '\143' + chr(9410 - 9299) + '\144' + '\x65')(chr(0b1110101) + chr(0b1110100) + chr(102) + chr(0b101101) + '\x38')), value={xafqLlk3kkUe(SXOLrMavuUCe(b'\x1d\xabE|\xf5'), chr(8705 - 8605) + chr(3155 - 3054) + '\x63' + chr(733 - 622) + chr(1979 - 1879) + '\145')('\165' + '\164' + '\x66' + '\055' + '\070'): tsdjvlgh9gDP(YmvhiZqIb4MX // xafqLlk3kkUe(LrQSWg3uwmK8, xafqLlk3kkUe(SXOLrMavuUCe(b'\x11\xafOm\xfc\x08@i\x0c\xfe\x92\xaa \xc0\xc1\x88\xda\xc9\xfb'), chr(8620 - 8520) + chr(0b1100101) + '\143' + chr(111) + chr(5088 - 4988) + chr(101))(chr(13168 - 13051) + chr(0b1101000 + 0o14) + chr(0b100101 + 0o101) + chr(0b101101) + chr(2569 - 2513))) - ehT0Px3KOsy9(chr(1085 - 1037) + '\x6f' + chr(191 - 142), 8), ehT0Px3KOsy9('\x30' + '\157' + chr(0b100001 + 0o17), 0o10)), xafqLlk3kkUe(SXOLrMavuUCe(b'\x0e\xbaFj\xf8'), chr(0b10101 + 0o117) + '\145' + chr(0b1100011) + '\157' + '\x64' + '\x65')(chr(0b1011010 + 0o33) + chr(116) + chr(0b1010010 + 0o24) + chr(111 - 66) + chr(0b101100 + 0o14)): mhxooG4aO82H})
xafqLlk3kkUe(mcP9wB7s3wV8, xafqLlk3kkUe(SXOLrMavuUCe(b'\x0c\xa9Kq\xee\x1aFt\x0f\xe8\xbf\x855\xc0\xf7\x8a\xc1'), chr(7295 - 7195) + chr(5322 - 5221) + chr(99) + chr(0b1101111) + chr(0b1100100) + chr(8355 - 8254))(chr(6019 - 5902) + chr(0b111000 + 0o74) + chr(102) + chr(45) + '\x38'))(key=xafqLlk3kkUe(mcP9wB7s3wV8, xafqLlk3kkUe(SXOLrMavuUCe(b'=\x8dkS\xc2/}I2'), chr(0b1100100) + chr(0b1100101) + chr(3954 - 3855) + '\157' + chr(0b1100100) + '\x65')(chr(1428 - 1311) + chr(0b1100101 + 0o17) + chr(102) + '\055' + '\070')))
if mhxooG4aO82H >= xafqLlk3kkUe(LrQSWg3uwmK8, xafqLlk3kkUe(SXOLrMavuUCe(b'\x15\xb7Zz\xef\x1avr\n\xff\xa8\xa9-\xdd\xf2\x80'), chr(0b1100100) + chr(6565 - 6464) + chr(99) + chr(0b101010 + 0o105) + chr(0b1011010 + 0o12) + chr(0b1100101))(chr(0b1110101) + '\164' + '\146' + '\x2d' + '\070')):
xafqLlk3kkUe(LrQSWg3uwmK8, xafqLlk3kkUe(SXOLrMavuUCe(b'\x0b\xbe^@\xf5\x0cHt\x03\xe0'), '\144' + chr(4290 - 4189) + chr(99) + '\157' + '\144' + '\145')(chr(117) + chr(116) + chr(0b110110 + 0o60) + chr(1786 - 1741) + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x15\xb7Zz\xef\x1avu\x17\xee\xae\xbf6\xc1'), chr(100) + chr(101) + chr(2514 - 2415) + '\157' + chr(9246 - 9146) + chr(0b111101 + 0o50))(chr(0b111001 + 0o74) + '\x74' + chr(0b100111 + 0o77) + chr(45) + '\070'), ehT0Px3KOsy9(chr(494 - 446) + '\157' + chr(0b110001), 8))
return SPnCNu54H1db
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/translate.py
|
_preprocess_sgm
|
def _preprocess_sgm(line, is_sgm):
"""Preprocessing to strip tags in SGM files."""
if not is_sgm:
return line
# In SGM files, remove <srcset ...>, <p>, <doc ...> lines.
if line.startswith("<srcset") or line.startswith("</srcset"):
return ""
if line.startswith("<doc") or line.startswith("</doc"):
return ""
if line.startswith("<p>") or line.startswith("</p>"):
return ""
# Strip <seg> tags.
line = line.strip()
if line.startswith("<seg") and line.endswith("</seg>"):
i = line.index(">")
return line[i + 1:-6]
|
python
|
def _preprocess_sgm(line, is_sgm):
"""Preprocessing to strip tags in SGM files."""
if not is_sgm:
return line
# In SGM files, remove <srcset ...>, <p>, <doc ...> lines.
if line.startswith("<srcset") or line.startswith("</srcset"):
return ""
if line.startswith("<doc") or line.startswith("</doc"):
return ""
if line.startswith("<p>") or line.startswith("</p>"):
return ""
# Strip <seg> tags.
line = line.strip()
if line.startswith("<seg") and line.endswith("</seg>"):
i = line.index(">")
return line[i + 1:-6]
|
[
"def",
"_preprocess_sgm",
"(",
"line",
",",
"is_sgm",
")",
":",
"if",
"not",
"is_sgm",
":",
"return",
"line",
"# In SGM files, remove <srcset ...>, <p>, <doc ...> lines.",
"if",
"line",
".",
"startswith",
"(",
"\"<srcset\"",
")",
"or",
"line",
".",
"startswith",
"(",
"\"</srcset\"",
")",
":",
"return",
"\"\"",
"if",
"line",
".",
"startswith",
"(",
"\"<doc\"",
")",
"or",
"line",
".",
"startswith",
"(",
"\"</doc\"",
")",
":",
"return",
"\"\"",
"if",
"line",
".",
"startswith",
"(",
"\"<p>\"",
")",
"or",
"line",
".",
"startswith",
"(",
"\"</p>\"",
")",
":",
"return",
"\"\"",
"# Strip <seg> tags.",
"line",
"=",
"line",
".",
"strip",
"(",
")",
"if",
"line",
".",
"startswith",
"(",
"\"<seg\"",
")",
"and",
"line",
".",
"endswith",
"(",
"\"</seg>\"",
")",
":",
"i",
"=",
"line",
".",
"index",
"(",
"\">\"",
")",
"return",
"line",
"[",
"i",
"+",
"1",
":",
"-",
"6",
"]"
] |
Preprocessing to strip tags in SGM files.
|
[
"Preprocessing",
"to",
"strip",
"tags",
"in",
"SGM",
"files",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/translate.py#L121-L136
|
train
|
Preprocessing to strip tags in SGM files.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TT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rp8,tzcpInYwBvYW,iDQ_gSK8V7h0,Rurm1zTRfSmY,reqGiMiVQ77y,bsS9P6_LpdIe,sbGAZlkZOtyh,Cf_Qef15s3_F,eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(111) + chr(0b1111 + 0o43) + chr(0b110111) + chr(49), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\061' + chr(50), 50234 - 50226), ehT0Px3KOsy9('\x30' + chr(2690 - 2579) + chr(51) + chr(52) + chr(0b101110 + 0o6), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(50), 0o10), ehT0Px3KOsy9(chr(2214 - 2166) + chr(111) + chr(0b110001) + '\067' + '\062', 0b1000), ehT0Px3KOsy9(chr(0b10101 + 0o33) + chr(2252 - 2141) + chr(0b1100 + 0o47) + chr(52) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(3838 - 3727) + chr(0b11010 + 0o27) + chr(0b11100 + 0o27) + chr(909 - 860), 0b1000), ehT0Px3KOsy9(chr(48) + chr(9774 - 9663) + chr(2456 - 2406) + chr(2509 - 2456), 0b1000), ehT0Px3KOsy9(chr(314 - 266) + chr(111) + '\062' + '\x32' + chr(52), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x32' + chr(0b110 + 0o57) + chr(55), 0b1000), ehT0Px3KOsy9(chr(583 - 535) + chr(111) + '\067' + chr(516 - 467), ord("\x08")), ehT0Px3KOsy9(chr(1258 - 1210) + '\157' + chr(0b1010 + 0o47) + '\065' + '\x33', 26610 - 26602), ehT0Px3KOsy9(chr(66 - 18) + chr(111) + '\062' + chr(0b1001 + 0o47) + chr(52), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110010) + chr(0b0 + 0o61), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x32' + chr(0b110100) + chr(0b110011), 11991 - 11983), ehT0Px3KOsy9('\060' + chr(0b1010 + 0o145) + '\x33' + chr(0b110001) + '\061', 11164 - 11156), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(50) + chr(727 - 672) + '\x37', 0o10), ehT0Px3KOsy9(chr(0b101 + 0o53) + '\x6f' + chr(0b100001 + 0o20) + chr(0b100010 + 0o24) + '\061', 51738 - 51730), ehT0Px3KOsy9(chr(0b110000) + chr(2039 - 1928) + '\062' + '\x32', 0b1000), ehT0Px3KOsy9(chr(1314 - 1266) + '\x6f' + chr(1961 - 1910) + '\x32', 45133 - 45125), ehT0Px3KOsy9(chr(48) + chr(1425 - 1314) + chr(0b100001 + 0o21) + chr(2130 - 2080) + chr(0b10011 + 0o35), ord("\x08")), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(0b100011 + 0o114) + chr(0b110001) + chr(2727 - 2673) + '\x31', 8), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b101010 + 0o10) + chr(0b110001 + 0o4) + chr(929 - 876), 32347 - 32339), ehT0Px3KOsy9(chr(868 - 820) + chr(111) + chr(0b110000 + 0o3) + chr(2367 - 2313) + chr(54), 0b1000), ehT0Px3KOsy9(chr(48) + chr(637 - 526) + chr(49) + '\x33', 19607 - 19599), ehT0Px3KOsy9(chr(48) + '\157' + chr(53) + chr(0b11111 + 0o24), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b110111 + 0o70) + chr(915 - 862), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b101110 + 0o5) + '\x33', ord("\x08")), ehT0Px3KOsy9(chr(362 - 314) + chr(111) + chr(0b110011) + '\063' + chr(55), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(2970 - 2859) + chr(50) + chr(0b100001 + 0o22) + chr(0b110110), 18887 - 18879), ehT0Px3KOsy9(chr(232 - 184) + '\x6f' + '\066' + '\060', 5136 - 5128), ehT0Px3KOsy9('\060' + '\157' + '\x34' + chr(52), 62283 - 62275), ehT0Px3KOsy9(chr(0b1101 + 0o43) + chr(111) + chr(0b110001) + chr(660 - 606) + chr(0b11100 + 0o31), 8328 - 8320), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\061' + chr(0b110000) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\063' + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(2220 - 2172) + chr(0b1101111) + chr(2290 - 2241) + chr(0b1110 + 0o46) + chr(55), 15425 - 15417), ehT0Px3KOsy9(chr(0b101011 + 0o5) + chr(111) + '\061' + '\x31' + chr(621 - 570), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\063' + '\064' + '\063', 0o10), ehT0Px3KOsy9(chr(1394 - 1346) + chr(3909 - 3798) + chr(0b110001) + chr(0b110100) + '\x30', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(2321 - 2271) + chr(1860 - 1810) + chr(53), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(111) + chr(53) + '\x30', ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x97'), chr(8231 - 8131) + chr(0b1100101) + chr(0b1010000 + 0o23) + chr(0b1100001 + 0o16) + '\144' + '\145')(chr(117) + chr(0b1110100) + '\146' + chr(0b10011 + 0o32) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def AVkpx_UvIT2j(LycYkDpyelF6, dio0YPNcWRRb):
if not dio0YPNcWRRb:
return LycYkDpyelF6
if xafqLlk3kkUe(LycYkDpyelF6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xca~\x85p\x0e\x91.|\xe0\xc7'), '\144' + chr(0b1100101) + chr(99) + '\157' + '\144' + chr(459 - 358))('\165' + chr(116) + '\x66' + '\x2d' + chr(2971 - 2915)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x85y\x96a\t\x87-'), chr(0b1100100) + chr(459 - 358) + chr(0b1100011) + '\x6f' + '\144' + '\145')('\x75' + '\164' + '\146' + chr(0b1000 + 0o45) + chr(0b111000))) or xafqLlk3kkUe(LycYkDpyelF6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xca~\x85p\x0e\x91.|\xe0\xc7'), '\x64' + chr(101) + chr(0b1100000 + 0o3) + chr(0b1101 + 0o142) + '\144' + chr(0b1100101))(chr(12299 - 12182) + chr(0b1110100) + chr(0b1110 + 0o130) + chr(45) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x85%\x97p\x19\x91<a'), '\x64' + chr(0b1011011 + 0o12) + chr(0b110111 + 0o54) + chr(0b1110 + 0o141) + chr(0b1100100) + chr(5026 - 4925))(chr(0b1110101) + chr(116) + chr(0b1100110) + '\x2d' + chr(0b110110 + 0o2))):
return xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(0b1100100) + chr(0b1100101) + chr(99) + chr(111) + '\x64' + '\x65')('\x75' + chr(116) + '\x66' + chr(0b100 + 0o51) + chr(0b0 + 0o70))
if xafqLlk3kkUe(LycYkDpyelF6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xca~\x85p\x0e\x91.|\xe0\xc7'), chr(0b1100100) + chr(0b1100101) + chr(99) + '\x6f' + chr(0b1100100) + chr(0b1001011 + 0o32))(chr(10447 - 10330) + '\164' + chr(0b1000000 + 0o46) + chr(45 - 0) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x85n\x8ba'), chr(100) + chr(101) + chr(0b1100011) + chr(111) + '\x64' + chr(101))(chr(12555 - 12438) + chr(116) + '\x66' + chr(45) + chr(2003 - 1947))) or xafqLlk3kkUe(LycYkDpyelF6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xca~\x85p\x0e\x91.|\xe0\xc7'), chr(0b1100100) + chr(101) + '\143' + chr(1179 - 1068) + '\x64' + chr(0b101111 + 0o66))(chr(117) + chr(10961 - 10845) + '\146' + chr(45) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x85%\x80m\x19'), chr(4607 - 4507) + '\x65' + chr(0b111100 + 0o47) + chr(111) + '\x64' + chr(0b1100101))(chr(117) + '\x74' + chr(659 - 557) + '\055' + chr(0b11001 + 0o37))):
return xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(0b10101 + 0o117) + '\x65' + '\143' + chr(0b11010 + 0o125) + chr(100) + chr(101))('\165' + chr(116) + chr(102) + '\x2d' + chr(56))
if xafqLlk3kkUe(LycYkDpyelF6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xca~\x85p\x0e\x91.|\xe0\xc7'), '\144' + '\x65' + chr(4231 - 4132) + chr(0b1101111) + chr(0b1100100) + '\x65')(chr(0b1110101) + '\164' + chr(0b1100110) + '\055' + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x85z\xda'), chr(100) + chr(6667 - 6566) + '\143' + chr(7594 - 7483) + chr(0b1100100) + chr(8542 - 8441))(chr(117) + chr(0b1110100) + chr(0b110010 + 0o64) + chr(833 - 788) + chr(0b111000))) or xafqLlk3kkUe(LycYkDpyelF6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xca~\x85p\x0e\x91.|\xe0\xc7'), chr(0b1100100) + chr(0b11010 + 0o113) + '\x63' + chr(111) + chr(0b1000000 + 0o44) + '\145')(chr(9244 - 9127) + chr(0b1110100) + '\x66' + '\055' + chr(1291 - 1235)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x85%\x94<'), chr(0b1010100 + 0o20) + chr(101) + chr(1335 - 1236) + chr(0b101111 + 0o100) + '\144' + '\145')(chr(3271 - 3154) + '\x74' + chr(0b1100110) + chr(45) + chr(1247 - 1191))):
return xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(2973 - 2873) + chr(7042 - 6941) + chr(0b1100011) + '\157' + '\144' + chr(101))('\x75' + chr(116) + chr(0b10110 + 0o120) + '\x2d' + '\x38')
LycYkDpyelF6 = LycYkDpyelF6.strip()
if xafqLlk3kkUe(LycYkDpyelF6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xca~\x85p\x0e\x91.|\xe0\xc7'), chr(1595 - 1495) + '\145' + chr(0b1000111 + 0o34) + chr(0b1101111) + chr(0b1100011 + 0o1) + '\145')(chr(0b1110101) + chr(7772 - 7656) + '\x66' + '\055' + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x85y\x81e'), '\x64' + chr(6984 - 6883) + chr(586 - 487) + '\x6f' + '\144' + chr(101))(chr(12692 - 12575) + chr(0b10011 + 0o141) + chr(0b1100110) + chr(94 - 49) + chr(56))) and xafqLlk3kkUe(LycYkDpyelF6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xdcd\x80q\r\x8b-}'), '\144' + chr(0b1100101) + '\143' + chr(0b100 + 0o153) + chr(0b0 + 0o144) + chr(101))(chr(0b1100100 + 0o21) + '\x74' + chr(0b1100110) + chr(0b1000 + 0o45) + chr(94 - 38)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x85%\x97g\x1d\xdc'), chr(6132 - 6032) + chr(0b1100101) + chr(8299 - 8200) + '\x6f' + chr(100) + '\x65')(chr(117) + chr(8376 - 8260) + chr(4932 - 4830) + chr(727 - 682) + chr(0b111000))):
WVxHKyX45z_L = LycYkDpyelF6.XdowRbJKZWL9(xafqLlk3kkUe(SXOLrMavuUCe(b'\x87'), chr(0b1100100) + chr(0b1100101) + chr(0b111000 + 0o53) + chr(0b1101111) + chr(6438 - 6338) + '\x65')('\165' + chr(116) + '\x66' + '\x2d' + '\070'))
return LycYkDpyelF6[WVxHKyX45z_L + ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110001), 0b1000):-ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b100 + 0o62), 0b1000)]
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/translate.py
|
compile_data
|
def compile_data(tmp_dir, datasets, filename, datatypes_to_clean=None):
"""Concatenates all `datasets` and saves to `filename`."""
datatypes_to_clean = datatypes_to_clean or []
filename = os.path.join(tmp_dir, filename)
lang1_fname = filename + ".lang1"
lang2_fname = filename + ".lang2"
if tf.gfile.Exists(lang1_fname) and tf.gfile.Exists(lang2_fname):
tf.logging.info("Skipping compile data, found files:\n%s\n%s", lang1_fname,
lang2_fname)
return filename
with tf.gfile.GFile(lang1_fname, mode="w") as lang1_resfile:
with tf.gfile.GFile(lang2_fname, mode="w") as lang2_resfile:
for dataset in datasets:
url = dataset[0]
compressed_filename = os.path.basename(url)
compressed_filepath = os.path.join(tmp_dir, compressed_filename)
if url.startswith("http"):
generator_utils.maybe_download(tmp_dir, compressed_filename, url)
if dataset[1][0] == "tmx":
cleaning_requested = "tmx" in datatypes_to_clean
tmx_filename = os.path.join(tmp_dir, dataset[1][1])
if tmx_filename.endswith(".gz"):
with gzip.open(tmx_filename, "rb") as tmx_file:
_tmx_to_source_target(tmx_file, lang1_resfile, lang2_resfile,
do_cleaning=cleaning_requested)
else:
with tf.gfile.Open(tmx_filename) as tmx_file:
_tmx_to_source_target(tmx_file, lang1_resfile, lang2_resfile,
do_cleaning=cleaning_requested)
elif dataset[1][0] == "tsv":
_, src_column, trg_column, glob_pattern = dataset[1]
filenames = tf.gfile.Glob(os.path.join(tmp_dir, glob_pattern))
if not filenames:
# Capture *.tgz and *.tar.gz too.
mode = "r:gz" if compressed_filepath.endswith("gz") else "r"
with tarfile.open(compressed_filepath, mode) as corpus_tar:
corpus_tar.extractall(tmp_dir)
filenames = tf.gfile.Glob(os.path.join(tmp_dir, glob_pattern))
for tsv_filename in filenames:
if tsv_filename.endswith(".gz"):
new_filename = tsv_filename.strip(".gz")
generator_utils.gunzip_file(tsv_filename, new_filename)
tsv_filename = new_filename
with tf.gfile.Open(tsv_filename) as tsv_file:
for line in tsv_file:
if line and "\t" in line:
parts = line.split("\t")
source, target = parts[src_column], parts[trg_column]
source, target = source.strip(), target.strip()
clean_pairs = [(source, target)]
if "tsv" in datatypes_to_clean:
clean_pairs = cleaner_en_xx.clean_en_xx_pairs(clean_pairs)
for source, target in clean_pairs:
if source and target:
lang1_resfile.write(source)
lang1_resfile.write("\n")
lang2_resfile.write(target)
lang2_resfile.write("\n")
else:
lang1_filename, lang2_filename = dataset[1]
lang1_filepath = os.path.join(tmp_dir, lang1_filename)
lang2_filepath = os.path.join(tmp_dir, lang2_filename)
is_sgm = (
lang1_filename.endswith("sgm") and lang2_filename.endswith("sgm"))
if not (tf.gfile.Exists(lang1_filepath) and
tf.gfile.Exists(lang2_filepath)):
# For .tar.gz and .tgz files, we read compressed.
mode = "r:gz" if compressed_filepath.endswith("gz") else "r"
with tarfile.open(compressed_filepath, mode) as corpus_tar:
corpus_tar.extractall(tmp_dir)
if lang1_filepath.endswith(".gz"):
new_filepath = lang1_filepath.strip(".gz")
generator_utils.gunzip_file(lang1_filepath, new_filepath)
lang1_filepath = new_filepath
if lang2_filepath.endswith(".gz"):
new_filepath = lang2_filepath.strip(".gz")
generator_utils.gunzip_file(lang2_filepath, new_filepath)
lang2_filepath = new_filepath
for example in text_problems.text2text_txt_iterator(
lang1_filepath, lang2_filepath):
line1res = _preprocess_sgm(example["inputs"], is_sgm)
line2res = _preprocess_sgm(example["targets"], is_sgm)
clean_pairs = [(line1res, line2res)]
if "txt" in datatypes_to_clean:
clean_pairs = cleaner_en_xx.clean_en_xx_pairs(clean_pairs)
for line1res, line2res in clean_pairs:
if line1res and line2res:
lang1_resfile.write(line1res)
lang1_resfile.write("\n")
lang2_resfile.write(line2res)
lang2_resfile.write("\n")
return filename
|
python
|
def compile_data(tmp_dir, datasets, filename, datatypes_to_clean=None):
"""Concatenates all `datasets` and saves to `filename`."""
datatypes_to_clean = datatypes_to_clean or []
filename = os.path.join(tmp_dir, filename)
lang1_fname = filename + ".lang1"
lang2_fname = filename + ".lang2"
if tf.gfile.Exists(lang1_fname) and tf.gfile.Exists(lang2_fname):
tf.logging.info("Skipping compile data, found files:\n%s\n%s", lang1_fname,
lang2_fname)
return filename
with tf.gfile.GFile(lang1_fname, mode="w") as lang1_resfile:
with tf.gfile.GFile(lang2_fname, mode="w") as lang2_resfile:
for dataset in datasets:
url = dataset[0]
compressed_filename = os.path.basename(url)
compressed_filepath = os.path.join(tmp_dir, compressed_filename)
if url.startswith("http"):
generator_utils.maybe_download(tmp_dir, compressed_filename, url)
if dataset[1][0] == "tmx":
cleaning_requested = "tmx" in datatypes_to_clean
tmx_filename = os.path.join(tmp_dir, dataset[1][1])
if tmx_filename.endswith(".gz"):
with gzip.open(tmx_filename, "rb") as tmx_file:
_tmx_to_source_target(tmx_file, lang1_resfile, lang2_resfile,
do_cleaning=cleaning_requested)
else:
with tf.gfile.Open(tmx_filename) as tmx_file:
_tmx_to_source_target(tmx_file, lang1_resfile, lang2_resfile,
do_cleaning=cleaning_requested)
elif dataset[1][0] == "tsv":
_, src_column, trg_column, glob_pattern = dataset[1]
filenames = tf.gfile.Glob(os.path.join(tmp_dir, glob_pattern))
if not filenames:
# Capture *.tgz and *.tar.gz too.
mode = "r:gz" if compressed_filepath.endswith("gz") else "r"
with tarfile.open(compressed_filepath, mode) as corpus_tar:
corpus_tar.extractall(tmp_dir)
filenames = tf.gfile.Glob(os.path.join(tmp_dir, glob_pattern))
for tsv_filename in filenames:
if tsv_filename.endswith(".gz"):
new_filename = tsv_filename.strip(".gz")
generator_utils.gunzip_file(tsv_filename, new_filename)
tsv_filename = new_filename
with tf.gfile.Open(tsv_filename) as tsv_file:
for line in tsv_file:
if line and "\t" in line:
parts = line.split("\t")
source, target = parts[src_column], parts[trg_column]
source, target = source.strip(), target.strip()
clean_pairs = [(source, target)]
if "tsv" in datatypes_to_clean:
clean_pairs = cleaner_en_xx.clean_en_xx_pairs(clean_pairs)
for source, target in clean_pairs:
if source and target:
lang1_resfile.write(source)
lang1_resfile.write("\n")
lang2_resfile.write(target)
lang2_resfile.write("\n")
else:
lang1_filename, lang2_filename = dataset[1]
lang1_filepath = os.path.join(tmp_dir, lang1_filename)
lang2_filepath = os.path.join(tmp_dir, lang2_filename)
is_sgm = (
lang1_filename.endswith("sgm") and lang2_filename.endswith("sgm"))
if not (tf.gfile.Exists(lang1_filepath) and
tf.gfile.Exists(lang2_filepath)):
# For .tar.gz and .tgz files, we read compressed.
mode = "r:gz" if compressed_filepath.endswith("gz") else "r"
with tarfile.open(compressed_filepath, mode) as corpus_tar:
corpus_tar.extractall(tmp_dir)
if lang1_filepath.endswith(".gz"):
new_filepath = lang1_filepath.strip(".gz")
generator_utils.gunzip_file(lang1_filepath, new_filepath)
lang1_filepath = new_filepath
if lang2_filepath.endswith(".gz"):
new_filepath = lang2_filepath.strip(".gz")
generator_utils.gunzip_file(lang2_filepath, new_filepath)
lang2_filepath = new_filepath
for example in text_problems.text2text_txt_iterator(
lang1_filepath, lang2_filepath):
line1res = _preprocess_sgm(example["inputs"], is_sgm)
line2res = _preprocess_sgm(example["targets"], is_sgm)
clean_pairs = [(line1res, line2res)]
if "txt" in datatypes_to_clean:
clean_pairs = cleaner_en_xx.clean_en_xx_pairs(clean_pairs)
for line1res, line2res in clean_pairs:
if line1res and line2res:
lang1_resfile.write(line1res)
lang1_resfile.write("\n")
lang2_resfile.write(line2res)
lang2_resfile.write("\n")
return filename
|
[
"def",
"compile_data",
"(",
"tmp_dir",
",",
"datasets",
",",
"filename",
",",
"datatypes_to_clean",
"=",
"None",
")",
":",
"datatypes_to_clean",
"=",
"datatypes_to_clean",
"or",
"[",
"]",
"filename",
"=",
"os",
".",
"path",
".",
"join",
"(",
"tmp_dir",
",",
"filename",
")",
"lang1_fname",
"=",
"filename",
"+",
"\".lang1\"",
"lang2_fname",
"=",
"filename",
"+",
"\".lang2\"",
"if",
"tf",
".",
"gfile",
".",
"Exists",
"(",
"lang1_fname",
")",
"and",
"tf",
".",
"gfile",
".",
"Exists",
"(",
"lang2_fname",
")",
":",
"tf",
".",
"logging",
".",
"info",
"(",
"\"Skipping compile data, found files:\\n%s\\n%s\"",
",",
"lang1_fname",
",",
"lang2_fname",
")",
"return",
"filename",
"with",
"tf",
".",
"gfile",
".",
"GFile",
"(",
"lang1_fname",
",",
"mode",
"=",
"\"w\"",
")",
"as",
"lang1_resfile",
":",
"with",
"tf",
".",
"gfile",
".",
"GFile",
"(",
"lang2_fname",
",",
"mode",
"=",
"\"w\"",
")",
"as",
"lang2_resfile",
":",
"for",
"dataset",
"in",
"datasets",
":",
"url",
"=",
"dataset",
"[",
"0",
"]",
"compressed_filename",
"=",
"os",
".",
"path",
".",
"basename",
"(",
"url",
")",
"compressed_filepath",
"=",
"os",
".",
"path",
".",
"join",
"(",
"tmp_dir",
",",
"compressed_filename",
")",
"if",
"url",
".",
"startswith",
"(",
"\"http\"",
")",
":",
"generator_utils",
".",
"maybe_download",
"(",
"tmp_dir",
",",
"compressed_filename",
",",
"url",
")",
"if",
"dataset",
"[",
"1",
"]",
"[",
"0",
"]",
"==",
"\"tmx\"",
":",
"cleaning_requested",
"=",
"\"tmx\"",
"in",
"datatypes_to_clean",
"tmx_filename",
"=",
"os",
".",
"path",
".",
"join",
"(",
"tmp_dir",
",",
"dataset",
"[",
"1",
"]",
"[",
"1",
"]",
")",
"if",
"tmx_filename",
".",
"endswith",
"(",
"\".gz\"",
")",
":",
"with",
"gzip",
".",
"open",
"(",
"tmx_filename",
",",
"\"rb\"",
")",
"as",
"tmx_file",
":",
"_tmx_to_source_target",
"(",
"tmx_file",
",",
"lang1_resfile",
",",
"lang2_resfile",
",",
"do_cleaning",
"=",
"cleaning_requested",
")",
"else",
":",
"with",
"tf",
".",
"gfile",
".",
"Open",
"(",
"tmx_filename",
")",
"as",
"tmx_file",
":",
"_tmx_to_source_target",
"(",
"tmx_file",
",",
"lang1_resfile",
",",
"lang2_resfile",
",",
"do_cleaning",
"=",
"cleaning_requested",
")",
"elif",
"dataset",
"[",
"1",
"]",
"[",
"0",
"]",
"==",
"\"tsv\"",
":",
"_",
",",
"src_column",
",",
"trg_column",
",",
"glob_pattern",
"=",
"dataset",
"[",
"1",
"]",
"filenames",
"=",
"tf",
".",
"gfile",
".",
"Glob",
"(",
"os",
".",
"path",
".",
"join",
"(",
"tmp_dir",
",",
"glob_pattern",
")",
")",
"if",
"not",
"filenames",
":",
"# Capture *.tgz and *.tar.gz too.",
"mode",
"=",
"\"r:gz\"",
"if",
"compressed_filepath",
".",
"endswith",
"(",
"\"gz\"",
")",
"else",
"\"r\"",
"with",
"tarfile",
".",
"open",
"(",
"compressed_filepath",
",",
"mode",
")",
"as",
"corpus_tar",
":",
"corpus_tar",
".",
"extractall",
"(",
"tmp_dir",
")",
"filenames",
"=",
"tf",
".",
"gfile",
".",
"Glob",
"(",
"os",
".",
"path",
".",
"join",
"(",
"tmp_dir",
",",
"glob_pattern",
")",
")",
"for",
"tsv_filename",
"in",
"filenames",
":",
"if",
"tsv_filename",
".",
"endswith",
"(",
"\".gz\"",
")",
":",
"new_filename",
"=",
"tsv_filename",
".",
"strip",
"(",
"\".gz\"",
")",
"generator_utils",
".",
"gunzip_file",
"(",
"tsv_filename",
",",
"new_filename",
")",
"tsv_filename",
"=",
"new_filename",
"with",
"tf",
".",
"gfile",
".",
"Open",
"(",
"tsv_filename",
")",
"as",
"tsv_file",
":",
"for",
"line",
"in",
"tsv_file",
":",
"if",
"line",
"and",
"\"\\t\"",
"in",
"line",
":",
"parts",
"=",
"line",
".",
"split",
"(",
"\"\\t\"",
")",
"source",
",",
"target",
"=",
"parts",
"[",
"src_column",
"]",
",",
"parts",
"[",
"trg_column",
"]",
"source",
",",
"target",
"=",
"source",
".",
"strip",
"(",
")",
",",
"target",
".",
"strip",
"(",
")",
"clean_pairs",
"=",
"[",
"(",
"source",
",",
"target",
")",
"]",
"if",
"\"tsv\"",
"in",
"datatypes_to_clean",
":",
"clean_pairs",
"=",
"cleaner_en_xx",
".",
"clean_en_xx_pairs",
"(",
"clean_pairs",
")",
"for",
"source",
",",
"target",
"in",
"clean_pairs",
":",
"if",
"source",
"and",
"target",
":",
"lang1_resfile",
".",
"write",
"(",
"source",
")",
"lang1_resfile",
".",
"write",
"(",
"\"\\n\"",
")",
"lang2_resfile",
".",
"write",
"(",
"target",
")",
"lang2_resfile",
".",
"write",
"(",
"\"\\n\"",
")",
"else",
":",
"lang1_filename",
",",
"lang2_filename",
"=",
"dataset",
"[",
"1",
"]",
"lang1_filepath",
"=",
"os",
".",
"path",
".",
"join",
"(",
"tmp_dir",
",",
"lang1_filename",
")",
"lang2_filepath",
"=",
"os",
".",
"path",
".",
"join",
"(",
"tmp_dir",
",",
"lang2_filename",
")",
"is_sgm",
"=",
"(",
"lang1_filename",
".",
"endswith",
"(",
"\"sgm\"",
")",
"and",
"lang2_filename",
".",
"endswith",
"(",
"\"sgm\"",
")",
")",
"if",
"not",
"(",
"tf",
".",
"gfile",
".",
"Exists",
"(",
"lang1_filepath",
")",
"and",
"tf",
".",
"gfile",
".",
"Exists",
"(",
"lang2_filepath",
")",
")",
":",
"# For .tar.gz and .tgz files, we read compressed.",
"mode",
"=",
"\"r:gz\"",
"if",
"compressed_filepath",
".",
"endswith",
"(",
"\"gz\"",
")",
"else",
"\"r\"",
"with",
"tarfile",
".",
"open",
"(",
"compressed_filepath",
",",
"mode",
")",
"as",
"corpus_tar",
":",
"corpus_tar",
".",
"extractall",
"(",
"tmp_dir",
")",
"if",
"lang1_filepath",
".",
"endswith",
"(",
"\".gz\"",
")",
":",
"new_filepath",
"=",
"lang1_filepath",
".",
"strip",
"(",
"\".gz\"",
")",
"generator_utils",
".",
"gunzip_file",
"(",
"lang1_filepath",
",",
"new_filepath",
")",
"lang1_filepath",
"=",
"new_filepath",
"if",
"lang2_filepath",
".",
"endswith",
"(",
"\".gz\"",
")",
":",
"new_filepath",
"=",
"lang2_filepath",
".",
"strip",
"(",
"\".gz\"",
")",
"generator_utils",
".",
"gunzip_file",
"(",
"lang2_filepath",
",",
"new_filepath",
")",
"lang2_filepath",
"=",
"new_filepath",
"for",
"example",
"in",
"text_problems",
".",
"text2text_txt_iterator",
"(",
"lang1_filepath",
",",
"lang2_filepath",
")",
":",
"line1res",
"=",
"_preprocess_sgm",
"(",
"example",
"[",
"\"inputs\"",
"]",
",",
"is_sgm",
")",
"line2res",
"=",
"_preprocess_sgm",
"(",
"example",
"[",
"\"targets\"",
"]",
",",
"is_sgm",
")",
"clean_pairs",
"=",
"[",
"(",
"line1res",
",",
"line2res",
")",
"]",
"if",
"\"txt\"",
"in",
"datatypes_to_clean",
":",
"clean_pairs",
"=",
"cleaner_en_xx",
".",
"clean_en_xx_pairs",
"(",
"clean_pairs",
")",
"for",
"line1res",
",",
"line2res",
"in",
"clean_pairs",
":",
"if",
"line1res",
"and",
"line2res",
":",
"lang1_resfile",
".",
"write",
"(",
"line1res",
")",
"lang1_resfile",
".",
"write",
"(",
"\"\\n\"",
")",
"lang2_resfile",
".",
"write",
"(",
"line2res",
")",
"lang2_resfile",
".",
"write",
"(",
"\"\\n\"",
")",
"return",
"filename"
] |
Concatenates all `datasets` and saves to `filename`.
|
[
"Concatenates",
"all",
"datasets",
"and",
"saves",
"to",
"filename",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/translate.py#L158-L255
|
train
|
Concatenates all datasets and saves to filename.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,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LUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b10010 + 0o40) + chr(0b110110) + chr(2139 - 2091), 28253 - 28245), ehT0Px3KOsy9('\x30' + chr(111) + chr(51) + '\060' + chr(0b110010), 60498 - 60490), ehT0Px3KOsy9('\x30' + '\157' + '\063' + '\x34' + chr(0b110011), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\061' + chr(0b110010) + chr(0b101111 + 0o2), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(50) + chr(430 - 377) + '\064', ord("\x08")), ehT0Px3KOsy9(chr(54 - 6) + chr(111) + chr(1797 - 1746) + chr(50) + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(0b100001 + 0o17) + '\157' + chr(869 - 816) + chr(1402 - 1354), 0b1000), ehT0Px3KOsy9(chr(0b11001 + 0o27) + '\157' + chr(0b11010 + 0o34) + chr(386 - 331), 0b1000), ehT0Px3KOsy9(chr(205 - 157) + chr(8635 - 8524) + chr(50) + chr(0b100111 + 0o14) + chr(0b110111), 29044 - 29036), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(111) + chr(50) + chr(1126 - 1074) + chr(50), 54144 - 54136), ehT0Px3KOsy9(chr(48) + chr(0b11100 + 0o123) + chr(0b110001) + chr(0b10110 + 0o32) + chr(0b110010), 9291 - 9283), ehT0Px3KOsy9(chr(48) + chr(3246 - 3135) + chr(1193 - 1143) + '\066' + '\062', 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(1312 - 1261) + '\066' + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(0b100001 + 0o17) + chr(0b111101 + 0o62) + chr(0b11010 + 0o30) + chr(719 - 667) + chr(0b100 + 0o63), 0o10), ehT0Px3KOsy9('\x30' + chr(0b101100 + 0o103) + chr(0b110 + 0o55) + '\x31' + chr(52), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110100) + chr(48), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x33' + chr(1154 - 1106) + chr(1402 - 1350), 57178 - 57170), ehT0Px3KOsy9('\x30' + chr(111) + chr(793 - 744) + chr(0b110100) + chr(48), 0o10), ehT0Px3KOsy9('\x30' + chr(9144 - 9033) + chr(51) + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(50) + '\x37' + '\x35', 36486 - 36478), ehT0Px3KOsy9('\x30' + chr(0b1101101 + 0o2) + chr(0b11100 + 0o27) + chr(49) + chr(1852 - 1798), 0o10), ehT0Px3KOsy9(chr(0b11011 + 0o25) + chr(9432 - 9321) + chr(0b110001) + '\064' + chr(2566 - 2513), ord("\x08")), ehT0Px3KOsy9(chr(0b100010 + 0o16) + chr(0b11 + 0o154) + chr(0b101010 + 0o14) + '\x37', 8), ehT0Px3KOsy9(chr(648 - 600) + chr(8642 - 8531) + chr(129 - 79) + chr(48) + chr(51), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(51) + '\x35' + chr(0b110011 + 0o1), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(1067 - 956) + '\x36' + '\x36', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1562 - 1511) + chr(0b110101) + chr(1142 - 1092), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(1480 - 1429) + chr(1440 - 1390) + chr(668 - 620), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(11855 - 11744) + chr(907 - 857) + chr(0b110111) + chr(150 - 96), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(49) + chr(0b1000 + 0o55) + chr(53), 0b1000), ehT0Px3KOsy9('\060' + chr(0b110 + 0o151) + chr(0b11101 + 0o25) + '\x34' + '\062', 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110011 + 0o1) + '\061', ord("\x08")), ehT0Px3KOsy9(chr(1387 - 1339) + chr(111) + '\x31' + '\066' + chr(0b110010), 0o10), ehT0Px3KOsy9(chr(188 - 140) + chr(8424 - 8313) + chr(449 - 398) + '\x30' + '\x30', 47112 - 47104), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\061' + chr(0b110000 + 0o1) + chr(0b110110), 0o10), ehT0Px3KOsy9(chr(48) + chr(8322 - 8211) + chr(0b110010) + '\062', ord("\x08")), ehT0Px3KOsy9(chr(2212 - 2164) + chr(0b1101111) + chr(0b1011 + 0o50) + '\x31', ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110011) + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(9672 - 9561) + '\x31' + chr(0b110000) + chr(54), 0b1000), ehT0Px3KOsy9(chr(1455 - 1407) + '\157' + chr(49) + chr(2177 - 2127) + chr(1548 - 1500), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(10145 - 10034) + '\065' + chr(0b101000 + 0o10), 8)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e'), '\144' + chr(5182 - 5081) + chr(1116 - 1017) + chr(0b1101111) + chr(100) + chr(816 - 715))(chr(117) + chr(8396 - 8280) + chr(0b1000111 + 0o37) + chr(0b11100 + 0o21) + chr(0b11000 + 0o40)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def NojZnGOqRmqW(JsZ36NJUqtml, yFP4suyTsK4d, xw4DsBfIJ22E, jFg9UxdSsGsW=None):
jFg9UxdSsGsW = jFg9UxdSsGsW or []
xw4DsBfIJ22E = oqhJDdMJfuwx.path.join(JsZ36NJUqtml, xw4DsBfIJ22E)
zOehta4g1Il_ = xw4DsBfIJ22E + xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e\xae\x82?\xcb\xe0'), chr(100) + chr(7828 - 7727) + chr(6100 - 6001) + chr(0b1011100 + 0o23) + chr(0b1011010 + 0o12) + chr(0b100001 + 0o104))('\165' + '\x74' + '\x66' + chr(96 - 51) + chr(56))
LIdVBWJRWQGK = xw4DsBfIJ22E + xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e\xae\x82?\xcb\xe3'), chr(6762 - 6662) + chr(101) + chr(6422 - 6323) + chr(111) + chr(100) + chr(101))(chr(0b110010 + 0o103) + '\164' + chr(0b111 + 0o137) + chr(0b101101) + '\070')
if xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf5\xba\x8a"\xd8\xa2'), chr(0b1100100) + chr(0b101011 + 0o72) + chr(0b1100011) + chr(0b1101111) + chr(100) + chr(8205 - 8104))(chr(6727 - 6610) + chr(1171 - 1055) + chr(0b1001100 + 0o32) + chr(1178 - 1133) + chr(56)))(zOehta4g1Il_) and xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf5\xba\x8a"\xd8\xa2'), chr(8616 - 8516) + '\145' + chr(8164 - 8065) + '\x6f' + '\144' + chr(101))('\165' + chr(116) + chr(102) + chr(147 - 102) + chr(0b111000)))(LIdVBWJRWQGK):
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe3\xf5\xab)\xd9\xb2O\x00\xf5\xce\x18\xd9'), chr(0b1010001 + 0o23) + chr(0b100010 + 0o103) + chr(99) + '\x6f' + chr(100) + chr(0b1000111 + 0o36))('\165' + chr(0b1110100) + chr(102) + chr(45) + chr(1131 - 1075)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xe3\xa9\x8a!\xdc\xb8FP\xbf\xc1-\xdf\x80\xce\xa0E\xe4\x04\x7f\xc9\xafI\x17\xe5\x83C\x84\xb4\x9e\x0b\xcbM\x17\xb3t\x18<oLu\xc3'), chr(0b10001 + 0o123) + '\145' + chr(0b110110 + 0o55) + '\157' + chr(0b1100100) + chr(0b1000 + 0o135))(chr(0b111101 + 0o70) + '\x74' + chr(9918 - 9816) + chr(0b101101) + chr(0b111000)), zOehta4g1Il_, LIdVBWJRWQGK)
return xw4DsBfIJ22E
with xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf7\x84\x8a=\xc9'), chr(100) + '\145' + chr(0b1001110 + 0o25) + chr(0b1001110 + 0o41) + chr(100) + chr(0b1100101))(chr(0b1110101) + '\x74' + '\x66' + '\x2d' + '\x38'))(zOehta4g1Il_, mode=xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7'), '\144' + chr(3765 - 3664) + '\x63' + chr(0b111010 + 0o65) + '\x64' + chr(101))('\165' + chr(7394 - 7278) + chr(0b1000000 + 0o46) + '\055' + chr(0b111000))) as xrp8vLsuQh6P:
with xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf7\x84\x8a=\xc9'), '\x64' + chr(101) + '\143' + '\157' + chr(0b1001 + 0o133) + chr(0b10100 + 0o121))('\165' + chr(116) + chr(0b1100110) + chr(0b100010 + 0o13) + '\x38'))(LIdVBWJRWQGK, mode=xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7'), chr(0b1100100) + chr(7804 - 7703) + chr(99) + '\157' + '\144' + '\145')('\165' + chr(0b110101 + 0o77) + '\146' + '\x2d' + chr(1415 - 1359))) as oqysDDGoOKTw:
for xQt6gV9VfTO3 in yFP4suyTsK4d:
CYCr3xzMHl4K = xQt6gV9VfTO3[ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110000), 3799 - 3791)]
HWZSnB9tEy67 = oqhJDdMJfuwx.path.basename(CYCr3xzMHl4K)
kLDY7zEPTscL = oqhJDdMJfuwx.path.join(JsZ36NJUqtml, HWZSnB9tEy67)
if xafqLlk3kkUe(CYCr3xzMHl4K, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc3\xb6\x82#\xd8\xa2_^\xeb\xca'), chr(100) + chr(0b1011 + 0o132) + chr(5602 - 5503) + chr(0b1101 + 0o142) + '\144' + '\145')(chr(0b1101111 + 0o6) + chr(4713 - 4597) + chr(102) + chr(45) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xd8\xb6\x97!'), '\144' + chr(101) + '\x63' + chr(0b11100 + 0o123) + chr(0b1100100) + chr(1746 - 1645))('\x75' + chr(0b1100100 + 0o20) + chr(102) + chr(2012 - 1967) + chr(1840 - 1784))):
xafqLlk3kkUe(g1Z_RG9zP4cD, xafqLlk3kkUe(SXOLrMavuUCe(b'\xdd\xa3\x9a3\xc9\x8eLX\xe8\xcc.\xdd\x91\xc3'), chr(100) + chr(4860 - 4759) + '\143' + chr(688 - 577) + chr(100) + chr(0b1100101))('\x75' + chr(0b1110100) + chr(102) + chr(0b101101) + chr(56)))(JsZ36NJUqtml, HWZSnB9tEy67, CYCr3xzMHl4K)
if xQt6gV9VfTO3[ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(921 - 872), 0o10)][ehT0Px3KOsy9(chr(0b110000) + '\157' + '\060', 8)] == xafqLlk3kkUe(SXOLrMavuUCe(b'\xc4\xaf\x9b'), '\144' + chr(4906 - 4805) + '\x63' + chr(0b100110 + 0o111) + chr(100) + chr(101))(chr(117) + '\164' + chr(8962 - 8860) + chr(0b101101) + '\070'):
TPrf931KSf3q = xafqLlk3kkUe(SXOLrMavuUCe(b'\xc4\xaf\x9b'), chr(0b1011011 + 0o11) + chr(0b1100001 + 0o4) + chr(0b1010111 + 0o14) + '\157' + chr(6359 - 6259) + chr(0b1100101))('\x75' + chr(116) + '\146' + chr(45) + chr(331 - 275)) in jFg9UxdSsGsW
mHK_DRQQglJT = oqhJDdMJfuwx.path.join(JsZ36NJUqtml, xQt6gV9VfTO3[ehT0Px3KOsy9(chr(0b10111 + 0o31) + '\157' + chr(0b100101 + 0o14), 8)][ehT0Px3KOsy9('\060' + chr(111) + chr(49), 8)])
if xafqLlk3kkUe(mHK_DRQQglJT, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd5\xac\x87"\xdb\xb8\\_'), chr(3086 - 2986) + chr(101) + chr(0b1010100 + 0o17) + chr(0b110110 + 0o71) + '\x64' + '\145')(chr(0b1110101 + 0o0) + chr(116) + chr(9244 - 9142) + '\x2d' + chr(1321 - 1265)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e\xa5\x99'), chr(100) + chr(8050 - 7949) + chr(99) + chr(0b1101111) + '\144' + '\x65')(chr(0b1110101) + chr(116) + '\146' + chr(0b0 + 0o55) + chr(0b11100 + 0o34))):
with xafqLlk3kkUe(Sl9BQg7umixy, xafqLlk3kkUe(SXOLrMavuUCe(b'\xdf\xb2\x86?'), '\144' + chr(101) + '\143' + chr(111) + chr(100) + '\x65')('\x75' + '\164' + '\146' + chr(45) + chr(2133 - 2077)))(mHK_DRQQglJT, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc2\xa0'), '\x64' + '\145' + '\x63' + '\x6f' + '\x64' + chr(0b1100101))('\165' + chr(0b1110100) + chr(0b1100110) + chr(0b101001 + 0o4) + '\x38')) as rv_B9G4WafXE:
KQOFxufkRXsB(rv_B9G4WafXE, xrp8vLsuQh6P, oqysDDGoOKTw, do_cleaning=TPrf931KSf3q)
else:
with xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\xff\xb2\x86?'), chr(0b1011101 + 0o7) + chr(0b1100101) + chr(0b1100011) + chr(111) + chr(100) + chr(0b1111 + 0o126))(chr(0b1110101) + chr(0b1110100) + '\146' + chr(0b101101) + '\x38'))(mHK_DRQQglJT) as rv_B9G4WafXE:
KQOFxufkRXsB(rv_B9G4WafXE, xrp8vLsuQh6P, oqysDDGoOKTw, do_cleaning=TPrf931KSf3q)
elif xQt6gV9VfTO3[ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(0b1101111) + '\x31', 8)][ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b101001 + 0o7), 8)] == xafqLlk3kkUe(SXOLrMavuUCe(b'\xc4\xb1\x95'), chr(0b1100100) + '\145' + '\x63' + chr(0b1010010 + 0o35) + '\x64' + chr(10048 - 9947))('\x75' + chr(11698 - 11582) + '\x66' + chr(1701 - 1656) + chr(0b101010 + 0o16)):
(VNGQdHSFPrso, SiiDRLLRHpO4, kj428YpMx13L, FhRL1w7nUBYQ) = xQt6gV9VfTO3[ehT0Px3KOsy9(chr(0b1011 + 0o45) + '\157' + chr(0b101001 + 0o10), 8)]
Xs6zu3BFE2Ws = IDJ2eXGCBCDu.gfile.Glob(oqhJDdMJfuwx.path.join(JsZ36NJUqtml, FhRL1w7nUBYQ))
if not Xs6zu3BFE2Ws:
holLFgwB7vsP = xafqLlk3kkUe(SXOLrMavuUCe(b'\xc2\xf8\x84+'), chr(0b101011 + 0o71) + chr(0b1010110 + 0o17) + chr(0b110100 + 0o57) + chr(0b11001 + 0o126) + '\x64' + chr(101))(chr(2668 - 2551) + chr(0b1110100) + chr(102) + chr(45) + chr(56)) if kLDY7zEPTscL.endswith(xafqLlk3kkUe(SXOLrMavuUCe(b'\xd7\xb8'), '\144' + chr(101) + chr(0b1001011 + 0o30) + chr(111) + '\144' + chr(0b1100101))(chr(214 - 97) + chr(116) + '\146' + '\055' + chr(0b111000))) else xafqLlk3kkUe(SXOLrMavuUCe(b'\xc2'), chr(8982 - 8882) + chr(7998 - 7897) + '\x63' + '\157' + '\144' + '\x65')(chr(117) + '\x74' + chr(0b1001100 + 0o32) + '\x2d' + chr(56))
with xafqLlk3kkUe(RxqDt8LqC5Ns, xafqLlk3kkUe(SXOLrMavuUCe(b'\xdf\xb2\x86?'), chr(522 - 422) + '\x65' + chr(0b10110 + 0o115) + '\157' + chr(100) + chr(0b1100101))(chr(0b1110101) + '\164' + '\146' + chr(1863 - 1818) + chr(56)))(kLDY7zEPTscL, holLFgwB7vsP) as nzUckwk81aug:
xafqLlk3kkUe(nzUckwk81aug, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd5\xba\x97#\xcd\xb2\\V\xf3\xce'), '\x64' + chr(4665 - 4564) + chr(0b1100011) + chr(3905 - 3794) + chr(6648 - 6548) + '\x65')(chr(117) + chr(116) + chr(0b1010000 + 0o26) + chr(45) + chr(0b111000)))(JsZ36NJUqtml)
Xs6zu3BFE2Ws = IDJ2eXGCBCDu.gfile.Glob(oqhJDdMJfuwx.path.join(JsZ36NJUqtml, FhRL1w7nUBYQ))
for MuuzTQTHRZey in Xs6zu3BFE2Ws:
if xafqLlk3kkUe(MuuzTQTHRZey, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd5\xac\x87"\xdb\xb8\\_'), chr(0b1100100) + chr(0b1100101) + '\143' + chr(1340 - 1229) + chr(100) + chr(8413 - 8312))('\165' + chr(116) + '\146' + '\x2d' + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e\xa5\x99'), chr(0b1100100) + '\x65' + chr(99) + chr(10912 - 10801) + '\144' + '\x65')('\165' + chr(0b101 + 0o157) + chr(9214 - 9112) + '\055' + chr(0b111000))):
oZee3RC8ZNoa = MuuzTQTHRZey.strip(xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e\xa5\x99'), chr(461 - 361) + chr(0b1100101) + chr(0b111100 + 0o47) + '\x6f' + '\144' + chr(693 - 592))('\x75' + chr(116) + chr(102) + chr(829 - 784) + chr(0b110110 + 0o2)))
xafqLlk3kkUe(g1Z_RG9zP4cD, xafqLlk3kkUe(SXOLrMavuUCe(b"\xd7\xb7\x8d+\xc5\xa1wQ\xf6\xce'"), chr(0b1000111 + 0o35) + chr(0b101011 + 0o72) + chr(0b101110 + 0o65) + '\x6f' + chr(8754 - 8654) + chr(0b11110 + 0o107))(chr(117) + chr(4509 - 4393) + chr(102) + '\x2d' + chr(0b111000)))(MuuzTQTHRZey, oZee3RC8ZNoa)
MuuzTQTHRZey = oZee3RC8ZNoa
with xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\xff\xb2\x86?'), chr(0b101111 + 0o65) + chr(101) + chr(0b1011101 + 0o6) + chr(584 - 473) + '\x64' + chr(101))(chr(0b10111 + 0o136) + '\164' + chr(102) + chr(1366 - 1321) + chr(0b111000)))(MuuzTQTHRZey) as K7wQD5g5Nc6F:
for LycYkDpyelF6 in K7wQD5g5Nc6F:
if LycYkDpyelF6 and xafqLlk3kkUe(SXOLrMavuUCe(b'\xb9'), chr(9816 - 9716) + chr(0b1100101) + chr(0b1100011) + '\157' + chr(0b1100000 + 0o4) + chr(0b11101 + 0o110))(chr(0b11001 + 0o134) + chr(3169 - 3053) + chr(102) + chr(0b11111 + 0o16) + chr(184 - 128)) in LycYkDpyelF6:
gIfWK5W_pmM4 = LycYkDpyelF6.split(xafqLlk3kkUe(SXOLrMavuUCe(b'\xb9'), chr(8942 - 8842) + chr(101) + chr(0b110001 + 0o62) + chr(0b1101111) + '\x64' + '\x65')(chr(0b1110101) + chr(0b10000 + 0o144) + chr(4402 - 4300) + chr(0b101101) + chr(1379 - 1323)))
(Qas9W3D0Xbzi, GR1581dR5rDS) = (gIfWK5W_pmM4[SiiDRLLRHpO4], gIfWK5W_pmM4[kj428YpMx13L])
(Qas9W3D0Xbzi, GR1581dR5rDS) = (Qas9W3D0Xbzi.strip(), GR1581dR5rDS.strip())
rRsWHB7U5Mpc = [(Qas9W3D0Xbzi, GR1581dR5rDS)]
if xafqLlk3kkUe(SXOLrMavuUCe(b'\xc4\xb1\x95'), chr(0b110010 + 0o62) + chr(0b110001 + 0o64) + chr(0b1000101 + 0o36) + '\x6f' + '\x64' + '\145')('\x75' + '\164' + '\146' + chr(0b101101) + chr(0b1110 + 0o52)) in jFg9UxdSsGsW:
rRsWHB7U5Mpc = VuWVAGm81HfT.clean_en_xx_pairs(rRsWHB7U5Mpc)
for (Qas9W3D0Xbzi, GR1581dR5rDS) in rRsWHB7U5Mpc:
if Qas9W3D0Xbzi and GR1581dR5rDS:
xafqLlk3kkUe(xrp8vLsuQh6P, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7\xb0\x8a%\xc9'), chr(6700 - 6600) + '\145' + '\x63' + '\x6f' + chr(0b1100100) + chr(0b101101 + 0o70))('\165' + '\164' + '\x66' + chr(45) + chr(0b111000)))(Qas9W3D0Xbzi)
xafqLlk3kkUe(xrp8vLsuQh6P, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7\xb0\x8a%\xc9'), '\x64' + chr(7802 - 7701) + chr(0b1100011) + chr(205 - 94) + chr(0b1100100) + chr(0b1100101))('\165' + chr(0b1110100) + chr(0b1010111 + 0o17) + '\055' + chr(0b110001 + 0o7)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xba'), '\144' + '\x65' + '\143' + chr(0b1101111) + chr(0b1100100) + chr(0b1100101))(chr(117) + chr(0b1110100) + chr(0b1100110) + chr(0b101101) + chr(56)))
xafqLlk3kkUe(oqysDDGoOKTw, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7\xb0\x8a%\xc9'), chr(100) + chr(885 - 784) + chr(0b1100011) + chr(0b1101111) + chr(824 - 724) + chr(0b1100010 + 0o3))(chr(117) + chr(116) + chr(3588 - 3486) + '\055' + chr(56)))(GR1581dR5rDS)
xafqLlk3kkUe(oqysDDGoOKTw, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7\xb0\x8a%\xc9'), '\x64' + chr(101) + '\143' + chr(0b111000 + 0o67) + chr(0b101111 + 0o65) + chr(101))(chr(1001 - 884) + chr(0b100111 + 0o115) + '\x66' + chr(0b101101) + chr(0b11000 + 0o40)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xba'), chr(7769 - 7669) + '\145' + chr(0b11000 + 0o113) + chr(6899 - 6788) + chr(100) + chr(0b1100101))(chr(0b1100110 + 0o17) + '\164' + chr(0b101110 + 0o70) + chr(45) + chr(422 - 366)))
else:
(uyLJiiMjx7ab, tydrkkHygiaj) = xQt6gV9VfTO3[ehT0Px3KOsy9(chr(0b11010 + 0o26) + chr(0b1101111) + chr(0b110001), 8)]
A6iWtJ9yG9fJ = oqhJDdMJfuwx.path.join(JsZ36NJUqtml, uyLJiiMjx7ab)
glProQA0P9X1 = oqhJDdMJfuwx.path.join(JsZ36NJUqtml, tydrkkHygiaj)
dio0YPNcWRRb = uyLJiiMjx7ab.endswith(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc3\xa5\x8e'), chr(100) + chr(6446 - 6345) + '\143' + chr(0b1101111) + chr(0b1100100) + chr(101))(chr(0b100000 + 0o125) + chr(0b1010010 + 0o42) + '\146' + chr(0b101101) + chr(56))) and tydrkkHygiaj.endswith(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc3\xa5\x8e'), chr(4842 - 4742) + '\x65' + chr(0b11001 + 0o112) + chr(0b1101111) + chr(0b1100100) + '\x65')('\165' + chr(116) + '\x66' + '\055' + chr(0b111000)))
if not (xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf5\xba\x8a"\xd8\xa2'), '\144' + '\x65' + chr(5363 - 5264) + chr(0b1101111) + '\x64' + '\145')(chr(117) + chr(116) + chr(102) + chr(568 - 523) + '\070'))(A6iWtJ9yG9fJ) and xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf5\xba\x8a"\xd8\xa2'), '\x64' + '\145' + chr(99) + chr(0b1101111) + chr(100) + chr(101))('\x75' + chr(0b10101 + 0o137) + '\x66' + chr(1250 - 1205) + '\x38'))(glProQA0P9X1)):
holLFgwB7vsP = xafqLlk3kkUe(SXOLrMavuUCe(b'\xc2\xf8\x84+'), chr(100) + '\x65' + chr(7609 - 7510) + '\x6f' + chr(3848 - 3748) + chr(7828 - 7727))('\x75' + chr(116) + chr(0b0 + 0o146) + chr(0b101101) + chr(1858 - 1802)) if kLDY7zEPTscL.endswith(xafqLlk3kkUe(SXOLrMavuUCe(b'\xd7\xb8'), chr(0b10111 + 0o115) + chr(176 - 75) + '\143' + chr(0b1011110 + 0o21) + chr(0b1100100) + chr(101))(chr(0b1110101) + '\164' + '\146' + chr(0b101101) + chr(56))) else xafqLlk3kkUe(SXOLrMavuUCe(b'\xc2'), chr(100) + chr(0b1100101) + chr(0b1100011) + '\x6f' + chr(0b1100100) + chr(0b1100 + 0o131))('\x75' + chr(0b1110100) + '\x66' + '\x2d' + chr(0b111000))
with xafqLlk3kkUe(RxqDt8LqC5Ns, xafqLlk3kkUe(SXOLrMavuUCe(b'\xdf\xb2\x86?'), chr(0b11011 + 0o111) + chr(101) + '\x63' + chr(111) + '\x64' + chr(8530 - 8429))(chr(117) + chr(0b100010 + 0o122) + '\x66' + chr(45) + chr(0b10100 + 0o44)))(kLDY7zEPTscL, holLFgwB7vsP) as nzUckwk81aug:
xafqLlk3kkUe(nzUckwk81aug, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd5\xba\x97#\xcd\xb2\\V\xf3\xce'), '\x64' + chr(101) + chr(0b1100011) + '\x6f' + '\x64' + '\x65')(chr(0b1110101) + '\x74' + '\x66' + '\055' + chr(0b111000)))(JsZ36NJUqtml)
if xafqLlk3kkUe(A6iWtJ9yG9fJ, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd5\xac\x87"\xdb\xb8\\_'), chr(100) + chr(0b110100 + 0o61) + chr(0b10 + 0o141) + chr(0b1101111) + chr(0b1100100) + chr(0b10111 + 0o116))(chr(0b100111 + 0o116) + chr(0b1110100) + chr(0b110011 + 0o63) + chr(0b101101) + chr(268 - 212)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e\xa5\x99'), chr(100) + '\145' + '\x63' + chr(111) + chr(0b1100100) + '\145')('\165' + chr(10762 - 10646) + chr(0b1100110) + chr(0b11001 + 0o24) + '\070')):
PHFa6QusoMeg = A6iWtJ9yG9fJ.strip(xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e\xa5\x99'), chr(9541 - 9441) + '\145' + '\143' + chr(0b110010 + 0o75) + '\144' + chr(101))('\165' + chr(0b1110100) + chr(0b10011 + 0o123) + chr(797 - 752) + chr(0b100101 + 0o23)))
xafqLlk3kkUe(g1Z_RG9zP4cD, xafqLlk3kkUe(SXOLrMavuUCe(b"\xd7\xb7\x8d+\xc5\xa1wQ\xf6\xce'"), chr(6818 - 6718) + chr(101) + chr(0b1100011) + '\157' + '\144' + '\145')(chr(10403 - 10286) + chr(116) + '\146' + chr(1259 - 1214) + chr(56)))(A6iWtJ9yG9fJ, PHFa6QusoMeg)
A6iWtJ9yG9fJ = PHFa6QusoMeg
if xafqLlk3kkUe(glProQA0P9X1, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd5\xac\x87"\xdb\xb8\\_'), '\x64' + '\145' + '\143' + chr(111) + chr(6783 - 6683) + '\145')(chr(0b1110101) + '\164' + '\146' + chr(45) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e\xa5\x99'), chr(9418 - 9318) + '\x65' + chr(0b1100011) + chr(6583 - 6472) + chr(100) + chr(0b1100101))(chr(9728 - 9611) + chr(5909 - 5793) + chr(0b1001010 + 0o34) + chr(1768 - 1723) + chr(0b1110 + 0o52))):
PHFa6QusoMeg = glProQA0P9X1.strip(xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e\xa5\x99'), '\144' + chr(0b1100101) + chr(0b11101 + 0o106) + '\157' + '\144' + chr(0b1000110 + 0o37))(chr(0b1010101 + 0o40) + chr(12420 - 12304) + '\x66' + '\055' + '\070'))
xafqLlk3kkUe(g1Z_RG9zP4cD, xafqLlk3kkUe(SXOLrMavuUCe(b"\xd7\xb7\x8d+\xc5\xa1wQ\xf6\xce'"), chr(0b1010100 + 0o20) + '\x65' + chr(0b1100011) + '\x6f' + chr(7232 - 7132) + '\x65')('\165' + chr(0b10100 + 0o140) + chr(0b1100110) + '\x2d' + chr(0b110000 + 0o10)))(glProQA0P9X1, PHFa6QusoMeg)
glProQA0P9X1 = PHFa6QusoMeg
for kP4qaKv0ZkGv in xafqLlk3kkUe(GkH56QMxhclz, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc4\xa7\x9b%\x9e\xa5MO\xeb\xfd6\xca\x84\xf8\xa5T\xa1\x12\x7f\xc9\xa1\x17'), chr(0b1100100) + '\x65' + '\x63' + chr(0b1101111) + chr(100) + '\x65')('\165' + chr(0b100000 + 0o124) + chr(0b10101 + 0o121) + '\x2d' + chr(0b1101 + 0o53)))(A6iWtJ9yG9fJ, glProQA0P9X1):
Suv8em7pfhXP = AVkpx_UvIT2j(kP4qaKv0ZkGv[xafqLlk3kkUe(SXOLrMavuUCe(b'\xd9\xac\x93$\xd8\xa2'), chr(3681 - 3581) + chr(0b1011011 + 0o12) + chr(0b1100011) + chr(0b1000101 + 0o52) + chr(0b1000101 + 0o37) + '\145')(chr(0b1110101) + chr(0b1000000 + 0o64) + '\x66' + chr(0b101101) + '\x38')], dio0YPNcWRRb)
TFCsF0An_D5P = AVkpx_UvIT2j(kP4qaKv0ZkGv[xafqLlk3kkUe(SXOLrMavuUCe(b'\xc4\xa3\x916\xc9\xa5['), chr(0b1001 + 0o133) + chr(5335 - 5234) + chr(4856 - 4757) + chr(0b1101111) + '\144' + chr(0b1100101))(chr(0b1110101) + '\164' + chr(7513 - 7411) + chr(661 - 616) + '\070')], dio0YPNcWRRb)
rRsWHB7U5Mpc = [(Suv8em7pfhXP, TFCsF0An_D5P)]
if xafqLlk3kkUe(SXOLrMavuUCe(b'\xc4\xba\x97'), '\144' + chr(0b1100101) + chr(99) + chr(4363 - 4252) + chr(0b10100 + 0o120) + chr(9081 - 8980))(chr(0b1110101) + chr(0b1011001 + 0o33) + chr(479 - 377) + chr(0b100000 + 0o15) + chr(706 - 650)) in jFg9UxdSsGsW:
rRsWHB7U5Mpc = VuWVAGm81HfT.clean_en_xx_pairs(rRsWHB7U5Mpc)
for (Suv8em7pfhXP, TFCsF0An_D5P) in rRsWHB7U5Mpc:
if Suv8em7pfhXP and TFCsF0An_D5P:
xafqLlk3kkUe(xrp8vLsuQh6P, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7\xb0\x8a%\xc9'), chr(0b1100100) + '\x65' + chr(0b10110 + 0o115) + chr(111) + chr(0b1100100) + '\x65')('\x75' + chr(116) + chr(2158 - 2056) + chr(387 - 342) + chr(56)))(Suv8em7pfhXP)
xafqLlk3kkUe(xrp8vLsuQh6P, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7\xb0\x8a%\xc9'), '\x64' + '\x65' + '\x63' + chr(0b110000 + 0o77) + chr(100) + chr(0b100011 + 0o102))('\165' + '\164' + chr(0b1011000 + 0o16) + '\055' + chr(1640 - 1584)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xba'), chr(1053 - 953) + '\145' + chr(8734 - 8635) + chr(111) + chr(100) + chr(101))(chr(5529 - 5412) + '\164' + chr(0b1100110) + '\x2d' + '\070'))
xafqLlk3kkUe(oqysDDGoOKTw, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7\xb0\x8a%\xc9'), chr(100) + '\x65' + chr(99) + chr(0b1011000 + 0o27) + chr(7389 - 7289) + chr(0b100000 + 0o105))(chr(0b111111 + 0o66) + chr(116) + chr(0b110111 + 0o57) + '\x2d' + chr(901 - 845)))(TFCsF0An_D5P)
xafqLlk3kkUe(oqysDDGoOKTw, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7\xb0\x8a%\xc9'), chr(0b1010111 + 0o15) + chr(1858 - 1757) + '\x63' + '\x6f' + chr(0b100001 + 0o103) + chr(8740 - 8639))('\165' + chr(116) + '\x66' + chr(45) + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xba'), chr(100) + chr(3656 - 3555) + '\143' + chr(0b1101111) + chr(0b1100100) + chr(0b1100101))(chr(0b1110101) + '\x74' + '\146' + chr(0b101001 + 0o4) + '\070'))
return xw4DsBfIJ22E
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/translate.py
|
TranslateDistillProblem.get_or_create_vocab
|
def get_or_create_vocab(self, data_dir, tmp_dir, force_get=False):
"""Get vocab for distill problems."""
# We assume that vocab file is present in data_dir directory where the
# data generated will be stored.
vocab_filepath = os.path.join(data_dir, self.vocab_filename)
encoder = text_encoder.SubwordTextEncoder(vocab_filepath)
return encoder
|
python
|
def get_or_create_vocab(self, data_dir, tmp_dir, force_get=False):
"""Get vocab for distill problems."""
# We assume that vocab file is present in data_dir directory where the
# data generated will be stored.
vocab_filepath = os.path.join(data_dir, self.vocab_filename)
encoder = text_encoder.SubwordTextEncoder(vocab_filepath)
return encoder
|
[
"def",
"get_or_create_vocab",
"(",
"self",
",",
"data_dir",
",",
"tmp_dir",
",",
"force_get",
"=",
"False",
")",
":",
"# We assume that vocab file is present in data_dir directory where the",
"# data generated will be stored.",
"vocab_filepath",
"=",
"os",
".",
"path",
".",
"join",
"(",
"data_dir",
",",
"self",
".",
"vocab_filename",
")",
"encoder",
"=",
"text_encoder",
".",
"SubwordTextEncoder",
"(",
"vocab_filepath",
")",
"return",
"encoder"
] |
Get vocab for distill problems.
|
[
"Get",
"vocab",
"for",
"distill",
"problems",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/translate.py#L278-L284
|
train
|
Get or create the vocab for distill problems.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6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ectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + chr(0b1011111 + 0o20) + '\x31' + '\x30' + '\x34', 19558 - 19550), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(51) + '\x31', 0b1000), ehT0Px3KOsy9(chr(0b10011 + 0o35) + chr(0b1101111) + '\x33' + '\x34' + chr(0b1010 + 0o54), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b1011 + 0o46) + '\x31', 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + '\062' + '\x31' + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(2460 - 2410) + '\063', 33546 - 33538), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b100001 + 0o20) + '\060' + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b101111 + 0o2) + '\067' + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(0b101010 + 0o6) + chr(5823 - 5712) + chr(51) + chr(0b110111) + '\x33', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(291 - 180) + chr(0b110001) + '\062' + chr(53), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b101111 + 0o100) + '\063' + '\x33' + chr(0b100 + 0o62), 0o10), ehT0Px3KOsy9(chr(1164 - 1116) + chr(0b110011 + 0o74) + chr(53) + '\061', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + '\x32' + chr(0b101001 + 0o16) + '\x35', 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + '\062' + chr(0b10110 + 0o32) + '\x37', 28010 - 28002), ehT0Px3KOsy9(chr(48) + chr(0b1001101 + 0o42) + chr(49) + chr(0b100010 + 0o24) + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(0b101011 + 0o5) + chr(111) + chr(0b101111 + 0o3) + chr(90 - 39) + chr(0b11010 + 0o34), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(1452 - 1398) + chr(0b110010), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(50) + '\x35' + chr(0b110101 + 0o1), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x32' + chr(0b101100 + 0o6) + '\x30', 0o10), ehT0Px3KOsy9(chr(1161 - 1113) + chr(2285 - 2174) + chr(1724 - 1673) + chr(0b10 + 0o63) + '\x35', 2657 - 2649), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\062' + '\063' + chr(0b1111 + 0o45), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110001) + '\x30' + '\x33', 64337 - 64329), ehT0Px3KOsy9('\060' + chr(111) + chr(0b1000 + 0o51) + chr(54) + chr(1104 - 1052), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b101010 + 0o10) + chr(0b100110 + 0o12), ord("\x08")), ehT0Px3KOsy9(chr(1425 - 1377) + chr(0b1101111) + chr(1671 - 1620) + chr(51) + chr(0b1010 + 0o52), ord("\x08")), ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(4086 - 3975) + '\x32' + '\061', 13829 - 13821), ehT0Px3KOsy9('\x30' + '\157' + chr(270 - 219) + chr(48) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(318 - 268) + chr(0b110111) + chr(0b110100), 0o10), ehT0Px3KOsy9('\060' + chr(9213 - 9102) + '\x31' + '\x35' + chr(55), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + '\062' + '\x31' + chr(0b110010 + 0o0), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b1110 + 0o43) + '\062' + chr(53), 8), ehT0Px3KOsy9('\060' + '\x6f' + '\061' + chr(0b100001 + 0o24) + chr(0b11101 + 0o23), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(185 - 134) + chr(49) + chr(54), 0o10), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(111) + chr(0b10 + 0o57) + chr(0b100111 + 0o17), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1001 + 0o146) + chr(55) + '\062', 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(51) + chr(0b10100 + 0o40) + '\067', 0o10), ehT0Px3KOsy9('\060' + '\157' + chr(49) + chr(1763 - 1713) + chr(0b1000 + 0o53), ord("\x08")), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(0b10 + 0o155) + chr(0b10111 + 0o32) + '\x36' + '\067', 0b1000), ehT0Px3KOsy9(chr(0b10011 + 0o35) + chr(111) + chr(0b1101 + 0o46) + '\x34', 0o10), ehT0Px3KOsy9(chr(1458 - 1410) + chr(0b1101111) + chr(51) + chr(0b11 + 0o60) + chr(880 - 831), ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + chr(111) + chr(0b11010 + 0o33) + chr(0b110000), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'j'), chr(100) + chr(0b1100101) + chr(7253 - 7154) + '\157' + chr(0b11011 + 0o111) + chr(0b1100101))(chr(7717 - 7600) + '\x74' + chr(7967 - 7865) + chr(45) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def lRgVAO3dEMYz(oVre8I6UXc3b, kVFRD544hi_1, JsZ36NJUqtml, rDSi8XxaEwzm=ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b0 + 0o60), 0b1000)):
fZzpj6eSosQ9 = oqhJDdMJfuwx.path.join(kVFRD544hi_1, oVre8I6UXc3b.vocab_filename)
hoK3K1TwFlkr = nCRDzZ_Is9fz.SubwordTextEncoder(fZzpj6eSosQ9)
return hoK3K1TwFlkr
|
tensorflow/tensor2tensor
|
tensor2tensor/bin/t2t_trainer.py
|
set_hparams_from_args
|
def set_hparams_from_args(args):
"""Set hparams overrides from unparsed args list."""
if not args:
return
hp_prefix = "--hp_"
tf.logging.info("Found unparsed command-line arguments. Checking if any "
"start with %s and interpreting those as hparams "
"settings.", hp_prefix)
pairs = []
i = 0
while i < len(args):
arg = args[i]
if arg.startswith(hp_prefix):
pairs.append((arg[len(hp_prefix):], args[i+1]))
i += 2
else:
tf.logging.warn("Found unknown flag: %s", arg)
i += 1
as_hparams = ",".join(["%s=%s" % (key, val) for key, val in pairs])
if FLAGS.hparams:
as_hparams = "," + as_hparams
FLAGS.hparams += as_hparams
|
python
|
def set_hparams_from_args(args):
"""Set hparams overrides from unparsed args list."""
if not args:
return
hp_prefix = "--hp_"
tf.logging.info("Found unparsed command-line arguments. Checking if any "
"start with %s and interpreting those as hparams "
"settings.", hp_prefix)
pairs = []
i = 0
while i < len(args):
arg = args[i]
if arg.startswith(hp_prefix):
pairs.append((arg[len(hp_prefix):], args[i+1]))
i += 2
else:
tf.logging.warn("Found unknown flag: %s", arg)
i += 1
as_hparams = ",".join(["%s=%s" % (key, val) for key, val in pairs])
if FLAGS.hparams:
as_hparams = "," + as_hparams
FLAGS.hparams += as_hparams
|
[
"def",
"set_hparams_from_args",
"(",
"args",
")",
":",
"if",
"not",
"args",
":",
"return",
"hp_prefix",
"=",
"\"--hp_\"",
"tf",
".",
"logging",
".",
"info",
"(",
"\"Found unparsed command-line arguments. Checking if any \"",
"\"start with %s and interpreting those as hparams \"",
"\"settings.\"",
",",
"hp_prefix",
")",
"pairs",
"=",
"[",
"]",
"i",
"=",
"0",
"while",
"i",
"<",
"len",
"(",
"args",
")",
":",
"arg",
"=",
"args",
"[",
"i",
"]",
"if",
"arg",
".",
"startswith",
"(",
"hp_prefix",
")",
":",
"pairs",
".",
"append",
"(",
"(",
"arg",
"[",
"len",
"(",
"hp_prefix",
")",
":",
"]",
",",
"args",
"[",
"i",
"+",
"1",
"]",
")",
")",
"i",
"+=",
"2",
"else",
":",
"tf",
".",
"logging",
".",
"warn",
"(",
"\"Found unknown flag: %s\"",
",",
"arg",
")",
"i",
"+=",
"1",
"as_hparams",
"=",
"\",\"",
".",
"join",
"(",
"[",
"\"%s=%s\"",
"%",
"(",
"key",
",",
"val",
")",
"for",
"key",
",",
"val",
"in",
"pairs",
"]",
")",
"if",
"FLAGS",
".",
"hparams",
":",
"as_hparams",
"=",
"\",\"",
"+",
"as_hparams",
"FLAGS",
".",
"hparams",
"+=",
"as_hparams"
] |
Set hparams overrides from unparsed args list.
|
[
"Set",
"hparams",
"overrides",
"from",
"unparsed",
"args",
"list",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/bin/t2t_trainer.py#L138-L162
|
train
|
Set hparams overrides from unparsed command - line arguments.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNBHlx,ZsDPvpP4xdo3,cW7yQuy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VpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + '\157' + chr(0b100000 + 0o22) + chr(0b111 + 0o52) + chr(53 - 5), 53949 - 53941), ehT0Px3KOsy9('\x30' + chr(0b1 + 0o156) + chr(131 - 81) + chr(0b110010) + chr(0b110101), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\062' + chr(260 - 211) + chr(0b101101 + 0o6), 10780 - 10772), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(0b1100101 + 0o12) + '\062' + chr(53) + chr(0b110010), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\063' + '\x31' + '\063', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + '\x32' + '\061' + chr(0b101100 + 0o7), 8), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b1101111) + chr(449 - 399) + chr(48) + chr(2289 - 2236), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b101 + 0o152) + chr(0b110001) + chr(0b110100) + '\067', 32919 - 32911), ehT0Px3KOsy9(chr(1379 - 1331) + chr(4260 - 4149) + chr(50) + chr(50) + '\063', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(50) + chr(0b110110) + chr(0b1010 + 0o47), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(3340 - 3229) + chr(0b110011) + '\x34' + '\x34', 41841 - 41833), ehT0Px3KOsy9('\060' + '\157' + '\061' + '\x30' + '\x36', 28378 - 28370), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110011) + '\067' + chr(51), 0b1000), ehT0Px3KOsy9(chr(692 - 644) + '\157' + chr(0b10101 + 0o35) + chr(0b101000 + 0o17) + chr(1040 - 992), 0o10), ehT0Px3KOsy9('\060' + chr(0b1000010 + 0o55) + chr(0b110011) + '\x36' + chr(0b100 + 0o56), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(4276 - 4165) + '\062' + chr(0b110000) + chr(0b1 + 0o66), 0o10), ehT0Px3KOsy9(chr(1606 - 1558) + chr(0b1101111) + chr(0b110010) + '\066' + chr(0b11000 + 0o35), 0b1000), ehT0Px3KOsy9('\060' + chr(0b110110 + 0o71) + chr(0b110010) + '\x30' + chr(52), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + '\x33' + chr(0b1 + 0o62) + '\x34', 32908 - 32900), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(1082 - 1031) + chr(0b100000 + 0o26) + '\066', 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(782 - 732) + chr(0b110111) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b111111 + 0o60) + '\x33' + chr(0b110110) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(634 - 586) + chr(3351 - 3240) + chr(0b110011) + chr(0b101010 + 0o14) + chr(52), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110111), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1010111 + 0o30) + chr(0b110001) + chr(55), 0o10), ehT0Px3KOsy9(chr(0b11011 + 0o25) + '\x6f' + '\061' + chr(0b100001 + 0o26) + '\x30', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(11795 - 11684) + '\x32' + chr(0b110000 + 0o6) + '\x31', 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110001) + '\062' + chr(49), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(10271 - 10160) + chr(1291 - 1241) + '\x33' + '\x36', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(51) + chr(0b110010) + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(1514 - 1466) + chr(0b111001 + 0o66) + '\063' + chr(0b110010) + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(717 - 669) + chr(9758 - 9647) + chr(50) + chr(0b11101 + 0o31) + chr(0b11001 + 0o30), 8), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\064' + chr(1708 - 1653), 0o10), ehT0Px3KOsy9(chr(0b1101 + 0o43) + chr(0b10001 + 0o136) + '\x31' + chr(0b1010 + 0o46) + '\063', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(2042 - 1991) + chr(48) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(1686 - 1638) + '\157' + '\x31' + chr(0b100100 + 0o23) + chr(0b110000), 8), ehT0Px3KOsy9(chr(0b100001 + 0o17) + chr(2607 - 2496) + chr(50) + '\064' + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(0b100011 + 0o15) + chr(4220 - 4109) + chr(51) + '\062' + chr(0b0 + 0o67), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\062' + chr(0b11010 + 0o35) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(0b10101 + 0o33) + chr(0b1101111) + '\062' + '\060', 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(53) + chr(0b110000), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xa6'), '\x64' + '\145' + '\143' + '\x6f' + chr(100) + chr(6504 - 6403))(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + chr(0b101101) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def g3pVysrTe5yP(kJDRfRhcZHjS):
if not kJDRfRhcZHjS:
return
XT3739hUKB2r = xafqLlk3kkUe(SXOLrMavuUCe(b'\xa5\xb8\xe3\xda\x94'), chr(8597 - 8497) + '\145' + chr(8046 - 7947) + chr(0b101010 + 0o105) + chr(0b1011001 + 0o13) + chr(101))(chr(0b1000 + 0o155) + '\x74' + chr(0b111000 + 0o56) + '\055' + chr(0b100010 + 0o26))
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b'\xdb\xa2\xc3\xd2\xbe\xe8\xe2P\xf9\xdd\xbe-'), chr(6886 - 6786) + '\145' + '\x63' + chr(0b10001 + 0o136) + chr(100) + chr(0b1100101))(chr(0b1110101) + '\164' + chr(4527 - 4425) + chr(0b101101) + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xce\xfa\xfe\xc4\xaf\xab\xf0\t\xe3\xd0\x965\x9e\xdc\xd2\xe4\xda\xe9\xb1\x97\xd0\x97\xd9kf\x16\xd4q\xff\xa0\xb7\xc4J&\xa9\x0c\xd2\xf9\x9fS\xe0\xf0\xe8\xc1\xa2\xe5\xe2G\xfa\xd7\xc4\'\x95\xc1\xd2\xf4\xc1\xe5\xae\x82\x9e\x84\x9dsgX\x94"\xbe\xb3\xbe\xd5\x07*\xa9\x0c\xc4\xa5\xcfb\xed\xe1\xe2\xc4\xac\xab\xf1\x0f\xfc\xc2\x81f\x9a\xcb\xd2\xef\xc5\xe5\xae\x97\xd3\x80\xd4tj\x0c\xc58\xf0\xb5\xa3\x9f'), chr(0b1100100) + '\145' + chr(4890 - 4791) + chr(0b1001100 + 0o43) + chr(0b1001001 + 0o33) + chr(0b110010 + 0o63))(chr(5780 - 5663) + '\164' + chr(0b1010111 + 0o17) + chr(514 - 469) + '\070'), XT3739hUKB2r)
JcPsqTZgKo43 = []
WVxHKyX45z_L = ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(48), 0b1000)
while WVxHKyX45z_L < c2A0yzQpDQB3(kJDRfRhcZHjS):
LTE9MPUbqSos = kJDRfRhcZHjS[WVxHKyX45z_L]
if xafqLlk3kkUe(LTE9MPUbqSos, xafqLlk3kkUe(SXOLrMavuUCe(b'\xfb\xe1\xea\xd8\xbf\xf8\xf2\x0e\xe7\xd9'), chr(0b1110 + 0o126) + chr(0b111010 + 0o53) + chr(0b1100011) + chr(0b1101111) + chr(0b1100100) + chr(0b10101 + 0o120))(chr(10019 - 9902) + '\164' + chr(102) + '\055' + chr(0b111000)))(XT3739hUKB2r):
xafqLlk3kkUe(JcPsqTZgKo43, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe9\xe5\xfb\xcf\xa5\xef'), chr(0b1100100) + chr(0b1100101) + '\143' + chr(0b10011 + 0o134) + chr(6690 - 6590) + '\145')(chr(0b101001 + 0o114) + chr(0b1001000 + 0o54) + chr(7935 - 7833) + chr(45) + chr(2646 - 2590)))((LTE9MPUbqSos[c2A0yzQpDQB3(XT3739hUKB2r):], kJDRfRhcZHjS[WVxHKyX45z_L + ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(11877 - 11766) + chr(0b110001), 0b1000)]))
WVxHKyX45z_L += ehT0Px3KOsy9('\060' + chr(111) + chr(0b110010), ord("\x08"))
else:
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe6\xd1\xce\xc4\x85\xc9\xe4\x05\xd5\xff\xaf+'), '\144' + chr(9238 - 9137) + chr(0b1100011) + chr(3069 - 2958) + chr(0b1100100) + chr(0b1100101))(chr(0b1010000 + 0o45) + chr(0b111110 + 0o66) + chr(1136 - 1034) + chr(103 - 58) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xce\xfa\xfe\xc4\xaf\xab\xf0\t\xf8\xdf\x8b1\x95\x98\x94\xeb\xd4\xe3\xe6\xd6\x9b\x80'), '\144' + chr(0b1001100 + 0o31) + chr(99) + chr(11875 - 11764) + '\144' + '\x65')(chr(0b1110101) + chr(11162 - 11046) + chr(0b1100110) + chr(304 - 259) + '\070'), LTE9MPUbqSos)
WVxHKyX45z_L += ehT0Px3KOsy9('\x30' + '\x6f' + '\x31', 8)
O9l43197cAvN = xafqLlk3kkUe(SXOLrMavuUCe(b'\xa4'), chr(0b111101 + 0o47) + '\145' + chr(99) + '\x6f' + '\x64' + chr(10035 - 9934))('\165' + chr(0b1110100) + '\146' + chr(0b10100 + 0o31) + '\070').join([xafqLlk3kkUe(SXOLrMavuUCe(b'\xad\xe6\xb6\x8f\xb8'), '\144' + chr(101) + chr(99) + chr(8125 - 8014) + chr(0b1100100) + chr(0b1100101))('\165' + chr(12425 - 12309) + chr(0b1100110) + chr(0b10000 + 0o35) + chr(0b100111 + 0o21)) % (K3J4ZwSlE0sT, pQxH2D_k9sXQ) for (K3J4ZwSlE0sT, pQxH2D_k9sXQ) in JcPsqTZgKo43])
if xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe0\xe5\xea\xd8\xaa\xe6\xf6'), chr(0b1100100) + chr(7735 - 7634) + chr(0b1010010 + 0o21) + chr(111) + chr(4471 - 4371) + chr(101))('\x75' + chr(0b10000 + 0o144) + chr(2997 - 2895) + chr(0b101101) + chr(2758 - 2702))):
O9l43197cAvN = xafqLlk3kkUe(SXOLrMavuUCe(b'\xa4'), chr(0b1100100) + chr(1065 - 964) + chr(879 - 780) + '\x6f' + chr(0b111000 + 0o54) + '\145')(chr(3450 - 3333) + chr(8852 - 8736) + chr(3174 - 3072) + chr(0b101101) + chr(0b100000 + 0o30)) + O9l43197cAvN
vUTZFbqN0o8F.n4ljua2gi1Pr += O9l43197cAvN
|
tensorflow/tensor2tensor
|
tensor2tensor/bin/t2t_trainer.py
|
create_hparams
|
def create_hparams():
"""Create hparams."""
if FLAGS.use_tpu and "tpu" not in FLAGS.hparams_set:
tf.logging.warn("Not all hyperparameter sets work on TPU. "
"Prefer hparams_sets with a '_tpu' suffix, "
"e.g. transformer_tpu, if available for your model.")
hparams_path = os.path.join(FLAGS.output_dir, "hparams.json")
return trainer_lib.create_hparams(FLAGS.hparams_set, FLAGS.hparams,
hparams_path=hparams_path)
|
python
|
def create_hparams():
"""Create hparams."""
if FLAGS.use_tpu and "tpu" not in FLAGS.hparams_set:
tf.logging.warn("Not all hyperparameter sets work on TPU. "
"Prefer hparams_sets with a '_tpu' suffix, "
"e.g. transformer_tpu, if available for your model.")
hparams_path = os.path.join(FLAGS.output_dir, "hparams.json")
return trainer_lib.create_hparams(FLAGS.hparams_set, FLAGS.hparams,
hparams_path=hparams_path)
|
[
"def",
"create_hparams",
"(",
")",
":",
"if",
"FLAGS",
".",
"use_tpu",
"and",
"\"tpu\"",
"not",
"in",
"FLAGS",
".",
"hparams_set",
":",
"tf",
".",
"logging",
".",
"warn",
"(",
"\"Not all hyperparameter sets work on TPU. \"",
"\"Prefer hparams_sets with a '_tpu' suffix, \"",
"\"e.g. transformer_tpu, if available for your model.\"",
")",
"hparams_path",
"=",
"os",
".",
"path",
".",
"join",
"(",
"FLAGS",
".",
"output_dir",
",",
"\"hparams.json\"",
")",
"return",
"trainer_lib",
".",
"create_hparams",
"(",
"FLAGS",
".",
"hparams_set",
",",
"FLAGS",
".",
"hparams",
",",
"hparams_path",
"=",
"hparams_path",
")"
] |
Create hparams.
|
[
"Create",
"hparams",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/bin/t2t_trainer.py#L165-L173
|
train
|
Create hparams.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0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,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(5682 - 5571) + chr(1105 - 1055) + chr(2302 - 2254) + '\x35', 64215 - 64207), ehT0Px3KOsy9(chr(48) + chr(0b11110 + 0o121) + chr(0b110011) + chr(101 - 53) + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(485 - 437) + chr(111) + chr(0b100010 + 0o17) + chr(0b1000 + 0o56) + chr(0b100010 + 0o23), 43489 - 43481), ehT0Px3KOsy9('\060' + chr(0b10100 + 0o133) + chr(0b100110 + 0o14) + chr(0b100000 + 0o24) + chr(0b1000 + 0o51), 0o10), ehT0Px3KOsy9(chr(0b11010 + 0o26) + chr(7815 - 7704) + '\x35' + chr(705 - 650), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(387 - 337) + '\x31' + chr(0b11110 + 0o24), 47238 - 47230), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\062' + chr(2214 - 2164) + chr(51), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(9947 - 9836) + '\067' + '\066', 0b1000), ehT0Px3KOsy9(chr(365 - 317) + chr(7325 - 7214) + '\x31' + chr(55) + chr(0b110000 + 0o0), 21537 - 21529), ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(0b1110 + 0o141) + chr(0b110010) + '\x36' + chr(51), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(950 - 901) + chr(0b100010 + 0o24) + '\x33', 37113 - 37105), ehT0Px3KOsy9(chr(135 - 87) + chr(8178 - 8067) + chr(1129 - 1079) + chr(0b1011 + 0o46) + '\062', 8), ehT0Px3KOsy9('\x30' + chr(0b111 + 0o150) + chr(51) + chr(0b100010 + 0o16), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + '\x32' + chr(218 - 166), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(50) + chr(51) + chr(0b110001), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110100) + chr(0b100101 + 0o22), 0o10), ehT0Px3KOsy9('\060' + '\157' + chr(630 - 581) + chr(0b110010), 0o10), ehT0Px3KOsy9(chr(1658 - 1610) + chr(6698 - 6587) + chr(425 - 375), 39300 - 39292), ehT0Px3KOsy9(chr(0b10110 + 0o32) + '\x6f' + '\x35', 21202 - 21194), ehT0Px3KOsy9(chr(0b1010 + 0o46) + chr(5122 - 5011) + chr(0b110010) + chr(0b110001) + chr(0b10101 + 0o36), 28608 - 28600), ehT0Px3KOsy9('\060' + chr(111) + '\062' + chr(2186 - 2132) + chr(55), 54706 - 54698), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(51) + chr(0b110001) + chr(54), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1010001 + 0o36) + chr(0b100110 + 0o13) + chr(0b100100 + 0o17) + chr(1566 - 1518), 0o10), ehT0Px3KOsy9(chr(701 - 653) + chr(0b1100011 + 0o14) + '\061' + '\064' + chr(1455 - 1403), 0b1000), ehT0Px3KOsy9(chr(1415 - 1367) + chr(0b111111 + 0o60) + chr(0b110100) + '\x32', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b101010 + 0o11) + chr(48) + '\x30', 0b1000), ehT0Px3KOsy9(chr(48) + chr(6885 - 6774) + '\061' + chr(1149 - 1100) + chr(268 - 215), 45838 - 45830), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110011 + 0o3) + chr(371 - 317), ord("\x08")), ehT0Px3KOsy9(chr(1608 - 1560) + chr(0b1010000 + 0o37) + '\063' + chr(0b110101) + chr(819 - 765), 0b1000), ehT0Px3KOsy9('\x30' + chr(2360 - 2249) + chr(1753 - 1699) + '\060', 0o10), ehT0Px3KOsy9(chr(316 - 268) + chr(0b1101111) + chr(2365 - 2314) + '\x35' + chr(2183 - 2131), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(9047 - 8936) + chr(1880 - 1829) + '\062' + chr(564 - 509), 0b1000), ehT0Px3KOsy9(chr(0b100111 + 0o11) + chr(0b111100 + 0o63) + chr(1502 - 1452) + '\x37' + '\065', ord("\x08")), ehT0Px3KOsy9(chr(1343 - 1295) + chr(111) + chr(0b1001 + 0o51) + '\067' + chr(51), 37422 - 37414), ehT0Px3KOsy9(chr(0b110000) + chr(0b1011101 + 0o22) + '\x31' + chr(49) + chr(0b101101 + 0o6), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b101 + 0o55) + chr(0b100 + 0o55) + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110011) + '\067' + chr(51), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + '\061' + chr(1561 - 1513) + chr(0b110001), 0b1000), ehT0Px3KOsy9('\060' + chr(2151 - 2040) + '\062' + '\067', 25856 - 25848), ehT0Px3KOsy9(chr(0b1010 + 0o46) + chr(111) + chr(0b110010) + '\x36', ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + '\x6f' + '\065' + '\x30', ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xab'), chr(0b1100100) + '\145' + chr(7289 - 7190) + chr(6500 - 6389) + chr(100) + chr(2396 - 2295))(chr(117) + chr(0b1110100) + '\146' + '\055' + chr(662 - 606)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def FPakHinFMgZb():
if xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf0\xb5\x10\xfe[\xfa\xe6'), chr(0b1010101 + 0o17) + chr(0b1000001 + 0o44) + chr(2946 - 2847) + '\157' + chr(4839 - 4739) + chr(101))(chr(117) + '\164' + chr(7453 - 7351) + chr(0b10 + 0o53) + chr(0b111000))) and xafqLlk3kkUe(SXOLrMavuUCe(b'\xf1\xb6\x00'), chr(0b1001001 + 0o33) + '\145' + chr(0b100011 + 0o100) + '\157' + chr(0b1011111 + 0o5) + chr(101))('\x75' + chr(0b1001011 + 0o51) + chr(0b101 + 0o141) + chr(0b101101) + chr(0b111000)) not in xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xed\xb6\x14\xd3N\xe7\xe0a\x0b\xd6\x07'), '\x64' + chr(7723 - 7622) + chr(1651 - 1552) + chr(0b1100011 + 0o14) + chr(3394 - 3294) + '\145')('\165' + chr(12419 - 12303) + chr(0b1100 + 0o132) + '\055' + chr(0b111000))):
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b'\xeb\x820\xcfa\xc8\xf2\\>\xfd8\xe7'), chr(4527 - 4427) + chr(9872 - 9771) + chr(5802 - 5703) + chr(0b111000 + 0o67) + chr(6763 - 6663) + '\x65')('\165' + '\164' + chr(0b1100110) + '\055' + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b"\xcb\xa9\x01\x81N\xe6\xff\x1e\x10\xca\x03\xefjd\xf8Uko`\xff\xd2\xbcx\x17G\xb4>\x16\x99_\x9e\xbc\x9d\xd4%\xa9\xaf\x11B8\xa5\x96\x07\xc4I\xef\xe1\x1e\x10\xc3\x12\xf8yy\xeaxygq\xf8\x97\xb91\x10J\xe0,\x16\xc9o\x98\xa7\xc8\x9ck\xfa\x8e'q\x7f\xfd\xeaU\xc4\x01\xed\xbd\x1e\x0c\xc1\x12\xe4kr\xf6Uggw\xd4\xc3\xbe-H\x02\xa9+\x16\x8fF\x8d\xbe\xd1\xda)\xe5\x9eaqy\xf7\xe6\x0c\xceZ\xf8\xb3S\x17\xd7\x16\xe66"), chr(100) + chr(3095 - 2994) + chr(0b1001 + 0o132) + chr(111) + chr(0b111111 + 0o45) + chr(437 - 336))('\x75' + '\x74' + chr(0b1100110) + '\055' + chr(0b111 + 0o61)))
TNoWNk9tqizq = oqhJDdMJfuwx.path.join(vUTZFbqN0o8F.output_dir, xafqLlk3kkUe(SXOLrMavuUCe(b'\xed\xb6\x14\xd3N\xe7\xe0\x10\x12\xc0\x1c\xe4'), chr(100) + chr(0b11100 + 0o111) + chr(0b1100011) + chr(0b1101 + 0o142) + '\x64' + '\145')(chr(0b1110101) + chr(0b10010 + 0o142) + '\146' + '\055' + chr(0b1000 + 0o60)))
return xafqLlk3kkUe(KvtIAVGi33Ty, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe6\xb4\x10\xc0[\xef\xccV\x08\xd2\x01\xebug'), '\x64' + '\x65' + '\143' + chr(111) + chr(0b1100100) + '\x65')(chr(0b1110101) + chr(116) + chr(102) + chr(0b101101) + chr(56)))(xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xed\xb6\x14\xd3N\xe7\xe0a\x0b\xd6\x07'), '\144' + chr(6322 - 6221) + chr(0b1100011) + '\157' + chr(0b1000010 + 0o42) + chr(0b11001 + 0o114))(chr(3285 - 3168) + chr(0b1000011 + 0o61) + chr(9404 - 9302) + chr(45) + chr(410 - 354))), xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xeb\xf2\x19\xcbZ\xeb\xa1Y\x11\x82#\xf8'), '\x64' + chr(0b1100101) + chr(99) + chr(11704 - 11593) + chr(0b10100 + 0o120) + '\145')(chr(0b1110101) + '\164' + chr(0b110011 + 0o63) + chr(45) + chr(56))), hparams_path=TNoWNk9tqizq)
|
tensorflow/tensor2tensor
|
tensor2tensor/bin/t2t_trainer.py
|
create_run_config
|
def create_run_config(hp, output_dir=None):
"""Create a run config.
Args:
hp: model hyperparameters
output_dir: model's output directory, defaults to output_dir flag.
Returns:
a run config
"""
save_ckpt_steps = max(FLAGS.iterations_per_loop, FLAGS.local_eval_frequency)
save_ckpt_secs = FLAGS.save_checkpoints_secs or None
if save_ckpt_secs:
save_ckpt_steps = None
assert FLAGS.output_dir or FLAGS.checkpoint_path
tpu_config_extra_kwargs = {}
if FLAGS.tpu_job_name is not None:
tpu_config_extra_kwargs["tpu_job_name"] = FLAGS.tpu_job_name
if getattr(hp, "mtf_mode", False):
save_ckpt_steps = None # Disable the default saver
save_ckpt_secs = None # Disable the default saver
tpu_config_extra_kwargs = {
"num_cores_per_replica": 1,
"per_host_input_for_training": tpu_config.InputPipelineConfig.BROADCAST,
}
# the various custom getters we have written do not play well together yet.
# TODO(noam): ask rsepassi for help here.
daisy_chain_variables = (
hp.daisy_chain_variables and
hp.activation_dtype == "float32" and
hp.weight_dtype == "float32")
return trainer_lib.create_run_config(
model_name=FLAGS.model,
model_dir=output_dir or os.path.expanduser(FLAGS.output_dir),
master=FLAGS.master,
iterations_per_loop=FLAGS.iterations_per_loop,
num_shards=FLAGS.tpu_num_shards,
log_device_placement=FLAGS.log_device_placement,
save_checkpoints_steps=save_ckpt_steps,
save_checkpoints_secs=save_ckpt_secs,
keep_checkpoint_max=FLAGS.keep_checkpoint_max,
keep_checkpoint_every_n_hours=FLAGS.keep_checkpoint_every_n_hours,
num_gpus=FLAGS.worker_gpu,
gpu_order=FLAGS.gpu_order,
num_async_replicas=FLAGS.worker_replicas,
gpu_mem_fraction=FLAGS.worker_gpu_memory_fraction,
enable_graph_rewriter=FLAGS.enable_graph_rewriter,
use_tpu=FLAGS.use_tpu,
use_tpu_estimator=FLAGS.use_tpu_estimator,
xla_jit_level=FLAGS.xla_jit_level,
schedule=FLAGS.schedule,
no_data_parallelism=hp.no_data_parallelism,
optionally_use_dist_strat=FLAGS.optionally_use_dist_strat,
daisy_chain_variables=daisy_chain_variables,
ps_replicas=FLAGS.ps_replicas,
ps_job=FLAGS.ps_job,
ps_gpu=FLAGS.ps_gpu,
sync=FLAGS.sync,
worker_id=FLAGS.worker_id,
worker_job=FLAGS.worker_job,
random_seed=FLAGS.random_seed,
tpu_infeed_sleep_secs=FLAGS.tpu_infeed_sleep_secs,
inter_op_parallelism_threads=FLAGS.inter_op_parallelism_threads,
log_step_count_steps=FLAGS.log_step_count_steps,
intra_op_parallelism_threads=FLAGS.intra_op_parallelism_threads,
tpu_config_extra_kwargs=tpu_config_extra_kwargs,
cloud_tpu_name=FLAGS.cloud_tpu_name)
|
python
|
def create_run_config(hp, output_dir=None):
"""Create a run config.
Args:
hp: model hyperparameters
output_dir: model's output directory, defaults to output_dir flag.
Returns:
a run config
"""
save_ckpt_steps = max(FLAGS.iterations_per_loop, FLAGS.local_eval_frequency)
save_ckpt_secs = FLAGS.save_checkpoints_secs or None
if save_ckpt_secs:
save_ckpt_steps = None
assert FLAGS.output_dir or FLAGS.checkpoint_path
tpu_config_extra_kwargs = {}
if FLAGS.tpu_job_name is not None:
tpu_config_extra_kwargs["tpu_job_name"] = FLAGS.tpu_job_name
if getattr(hp, "mtf_mode", False):
save_ckpt_steps = None # Disable the default saver
save_ckpt_secs = None # Disable the default saver
tpu_config_extra_kwargs = {
"num_cores_per_replica": 1,
"per_host_input_for_training": tpu_config.InputPipelineConfig.BROADCAST,
}
# the various custom getters we have written do not play well together yet.
# TODO(noam): ask rsepassi for help here.
daisy_chain_variables = (
hp.daisy_chain_variables and
hp.activation_dtype == "float32" and
hp.weight_dtype == "float32")
return trainer_lib.create_run_config(
model_name=FLAGS.model,
model_dir=output_dir or os.path.expanduser(FLAGS.output_dir),
master=FLAGS.master,
iterations_per_loop=FLAGS.iterations_per_loop,
num_shards=FLAGS.tpu_num_shards,
log_device_placement=FLAGS.log_device_placement,
save_checkpoints_steps=save_ckpt_steps,
save_checkpoints_secs=save_ckpt_secs,
keep_checkpoint_max=FLAGS.keep_checkpoint_max,
keep_checkpoint_every_n_hours=FLAGS.keep_checkpoint_every_n_hours,
num_gpus=FLAGS.worker_gpu,
gpu_order=FLAGS.gpu_order,
num_async_replicas=FLAGS.worker_replicas,
gpu_mem_fraction=FLAGS.worker_gpu_memory_fraction,
enable_graph_rewriter=FLAGS.enable_graph_rewriter,
use_tpu=FLAGS.use_tpu,
use_tpu_estimator=FLAGS.use_tpu_estimator,
xla_jit_level=FLAGS.xla_jit_level,
schedule=FLAGS.schedule,
no_data_parallelism=hp.no_data_parallelism,
optionally_use_dist_strat=FLAGS.optionally_use_dist_strat,
daisy_chain_variables=daisy_chain_variables,
ps_replicas=FLAGS.ps_replicas,
ps_job=FLAGS.ps_job,
ps_gpu=FLAGS.ps_gpu,
sync=FLAGS.sync,
worker_id=FLAGS.worker_id,
worker_job=FLAGS.worker_job,
random_seed=FLAGS.random_seed,
tpu_infeed_sleep_secs=FLAGS.tpu_infeed_sleep_secs,
inter_op_parallelism_threads=FLAGS.inter_op_parallelism_threads,
log_step_count_steps=FLAGS.log_step_count_steps,
intra_op_parallelism_threads=FLAGS.intra_op_parallelism_threads,
tpu_config_extra_kwargs=tpu_config_extra_kwargs,
cloud_tpu_name=FLAGS.cloud_tpu_name)
|
[
"def",
"create_run_config",
"(",
"hp",
",",
"output_dir",
"=",
"None",
")",
":",
"save_ckpt_steps",
"=",
"max",
"(",
"FLAGS",
".",
"iterations_per_loop",
",",
"FLAGS",
".",
"local_eval_frequency",
")",
"save_ckpt_secs",
"=",
"FLAGS",
".",
"save_checkpoints_secs",
"or",
"None",
"if",
"save_ckpt_secs",
":",
"save_ckpt_steps",
"=",
"None",
"assert",
"FLAGS",
".",
"output_dir",
"or",
"FLAGS",
".",
"checkpoint_path",
"tpu_config_extra_kwargs",
"=",
"{",
"}",
"if",
"FLAGS",
".",
"tpu_job_name",
"is",
"not",
"None",
":",
"tpu_config_extra_kwargs",
"[",
"\"tpu_job_name\"",
"]",
"=",
"FLAGS",
".",
"tpu_job_name",
"if",
"getattr",
"(",
"hp",
",",
"\"mtf_mode\"",
",",
"False",
")",
":",
"save_ckpt_steps",
"=",
"None",
"# Disable the default saver",
"save_ckpt_secs",
"=",
"None",
"# Disable the default saver",
"tpu_config_extra_kwargs",
"=",
"{",
"\"num_cores_per_replica\"",
":",
"1",
",",
"\"per_host_input_for_training\"",
":",
"tpu_config",
".",
"InputPipelineConfig",
".",
"BROADCAST",
",",
"}",
"# the various custom getters we have written do not play well together yet.",
"# TODO(noam): ask rsepassi for help here.",
"daisy_chain_variables",
"=",
"(",
"hp",
".",
"daisy_chain_variables",
"and",
"hp",
".",
"activation_dtype",
"==",
"\"float32\"",
"and",
"hp",
".",
"weight_dtype",
"==",
"\"float32\"",
")",
"return",
"trainer_lib",
".",
"create_run_config",
"(",
"model_name",
"=",
"FLAGS",
".",
"model",
",",
"model_dir",
"=",
"output_dir",
"or",
"os",
".",
"path",
".",
"expanduser",
"(",
"FLAGS",
".",
"output_dir",
")",
",",
"master",
"=",
"FLAGS",
".",
"master",
",",
"iterations_per_loop",
"=",
"FLAGS",
".",
"iterations_per_loop",
",",
"num_shards",
"=",
"FLAGS",
".",
"tpu_num_shards",
",",
"log_device_placement",
"=",
"FLAGS",
".",
"log_device_placement",
",",
"save_checkpoints_steps",
"=",
"save_ckpt_steps",
",",
"save_checkpoints_secs",
"=",
"save_ckpt_secs",
",",
"keep_checkpoint_max",
"=",
"FLAGS",
".",
"keep_checkpoint_max",
",",
"keep_checkpoint_every_n_hours",
"=",
"FLAGS",
".",
"keep_checkpoint_every_n_hours",
",",
"num_gpus",
"=",
"FLAGS",
".",
"worker_gpu",
",",
"gpu_order",
"=",
"FLAGS",
".",
"gpu_order",
",",
"num_async_replicas",
"=",
"FLAGS",
".",
"worker_replicas",
",",
"gpu_mem_fraction",
"=",
"FLAGS",
".",
"worker_gpu_memory_fraction",
",",
"enable_graph_rewriter",
"=",
"FLAGS",
".",
"enable_graph_rewriter",
",",
"use_tpu",
"=",
"FLAGS",
".",
"use_tpu",
",",
"use_tpu_estimator",
"=",
"FLAGS",
".",
"use_tpu_estimator",
",",
"xla_jit_level",
"=",
"FLAGS",
".",
"xla_jit_level",
",",
"schedule",
"=",
"FLAGS",
".",
"schedule",
",",
"no_data_parallelism",
"=",
"hp",
".",
"no_data_parallelism",
",",
"optionally_use_dist_strat",
"=",
"FLAGS",
".",
"optionally_use_dist_strat",
",",
"daisy_chain_variables",
"=",
"daisy_chain_variables",
",",
"ps_replicas",
"=",
"FLAGS",
".",
"ps_replicas",
",",
"ps_job",
"=",
"FLAGS",
".",
"ps_job",
",",
"ps_gpu",
"=",
"FLAGS",
".",
"ps_gpu",
",",
"sync",
"=",
"FLAGS",
".",
"sync",
",",
"worker_id",
"=",
"FLAGS",
".",
"worker_id",
",",
"worker_job",
"=",
"FLAGS",
".",
"worker_job",
",",
"random_seed",
"=",
"FLAGS",
".",
"random_seed",
",",
"tpu_infeed_sleep_secs",
"=",
"FLAGS",
".",
"tpu_infeed_sleep_secs",
",",
"inter_op_parallelism_threads",
"=",
"FLAGS",
".",
"inter_op_parallelism_threads",
",",
"log_step_count_steps",
"=",
"FLAGS",
".",
"log_step_count_steps",
",",
"intra_op_parallelism_threads",
"=",
"FLAGS",
".",
"intra_op_parallelism_threads",
",",
"tpu_config_extra_kwargs",
"=",
"tpu_config_extra_kwargs",
",",
"cloud_tpu_name",
"=",
"FLAGS",
".",
"cloud_tpu_name",
")"
] |
Create a run config.
Args:
hp: model hyperparameters
output_dir: model's output directory, defaults to output_dir flag.
Returns:
a run config
|
[
"Create",
"a",
"run",
"config",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/bin/t2t_trainer.py#L207-L275
|
train
|
Create a run config.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9Flfzs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2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + '\157' + '\062' + '\x33' + chr(0b110010), ord("\x08")), ehT0Px3KOsy9(chr(110 - 62) + chr(7302 - 7191) + chr(0b101010 + 0o11) + '\063' + chr(0b110011), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b11100 + 0o25) + '\061' + chr(2254 - 2201), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\x31' + '\063' + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(684 - 636) + '\x6f' + '\061' + chr(0b11 + 0o56) + '\x36', 0o10), ehT0Px3KOsy9(chr(48) + chr(5485 - 5374) + chr(0b110011) + chr(0b100111 + 0o17) + chr(0b101110 + 0o2), 0o10), ehT0Px3KOsy9('\x30' + chr(940 - 829) + chr(213 - 164) + chr(2129 - 2074) + chr(909 - 861), 8335 - 8327), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b11 + 0o57) + chr(0b110011) + '\064', 0o10), ehT0Px3KOsy9(chr(141 - 93) + '\x6f' + '\x36', 35510 - 35502), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(111) + chr(0b100110 + 0o13) + '\065' + '\x31', 27390 - 27382), ehT0Px3KOsy9('\x30' + chr(3304 - 3193) + '\x32' + chr(54) + chr(50), 0b1000), ehT0Px3KOsy9(chr(2144 - 2096) + chr(0b111010 + 0o65) + chr(1682 - 1633) + '\065' + '\x33', 0b1000), ehT0Px3KOsy9('\x30' + chr(432 - 321) + chr(0b100010 + 0o20) + chr(0b110101) + chr(52), 35145 - 35137), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b100110 + 0o14) + '\x33' + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(1974 - 1926) + '\157' + chr(0b101100 + 0o6) + chr(446 - 393) + '\066', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\067' + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(0b11100 + 0o24) + chr(0b1101111) + chr(52) + chr(1120 - 1072), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110011) + chr(692 - 637) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1010000 + 0o37) + chr(0b110011) + chr(1321 - 1269) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(51) + chr(154 - 100) + '\066', ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(1443 - 1394) + chr(0b110001) + '\067', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(51) + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(0b10000 + 0o40) + '\157' + chr(51) + '\066' + '\064', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110010) + chr(55) + chr(0b100110 + 0o13), 20154 - 20146), ehT0Px3KOsy9('\x30' + chr(1236 - 1125) + '\x33' + '\x36' + '\061', 16416 - 16408), ehT0Px3KOsy9(chr(0b110000) + chr(10895 - 10784) + '\062' + chr(0b101101 + 0o10) + chr(656 - 602), 8), ehT0Px3KOsy9('\060' + '\x6f' + chr(50) + chr(220 - 170) + '\x34', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\061' + '\060' + chr(0b10100 + 0o41), 14721 - 14713), ehT0Px3KOsy9(chr(0b11 + 0o55) + '\157' + chr(0b110010) + chr(51) + chr(0b110010), 8), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x31' + '\x36' + chr(0b110100), 0o10), ehT0Px3KOsy9(chr(228 - 180) + chr(111) + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x31' + '\x35' + chr(53), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(49) + '\064' + '\067', 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(59 - 10) + chr(54) + chr(0b110011), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1000 + 0o147) + chr(0b100 + 0o56) + '\x36' + chr(0b110100), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(7962 - 7851) + chr(52) + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1011100 + 0o23) + chr(0b110010) + chr(1657 - 1606) + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b1010 + 0o51) + '\x31' + chr(53), 0b1000), ehT0Px3KOsy9(chr(0b10111 + 0o31) + chr(4494 - 4383) + '\062' + '\065', 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(1837 - 1788) + chr(0b10010 + 0o36) + chr(0b110111), ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b10010 + 0o36) + '\x6f' + '\065' + chr(0b110000), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xb4'), chr(0b1100100) + chr(101) + chr(99) + chr(0b1101111) + '\x64' + chr(0b1100101))(chr(290 - 173) + chr(116) + chr(0b1100110) + chr(1531 - 1486) + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def asaTNmDUGEcT(ny6shRSJO9Wm, nd0OX_BS6_o4=None):
vBObAzLMsHeu = tsdjvlgh9gDP(vUTZFbqN0o8F.iterations_per_loop, vUTZFbqN0o8F.local_eval_frequency)
TOWMxle4LTiM = vUTZFbqN0o8F.save_checkpoints_secs or None
if TOWMxle4LTiM:
vBObAzLMsHeu = None
assert xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b"\xf5\xae9);\x84'\xf8o\x1b"), chr(0b1100100) + chr(4126 - 4025) + '\143' + chr(0b1000001 + 0o56) + chr(0b1100100) + chr(3770 - 3669))(chr(117) + '\x74' + chr(0b1100110) + chr(1559 - 1514) + chr(0b1111 + 0o51))) or xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf9\xb3(:%\x80\x17\xf5h\x1d\xed\x1b\xcd\xed\xc6'), chr(0b11111 + 0o105) + chr(9618 - 9517) + chr(5585 - 5486) + '\x6f' + chr(0b1100100) + '\145')('\x75' + chr(0b1000111 + 0o55) + chr(2018 - 1916) + chr(0b101101) + chr(0b10011 + 0o45)))
wBRs59oAVOdJ = {}
if xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xee\xab8\x06$\x9f\x1a\xc3h\x08\xdf\x0e'), '\144' + chr(101) + chr(0b111000 + 0o53) + chr(0b11 + 0o154) + chr(2244 - 2144) + chr(0b1011111 + 0o6))(chr(1548 - 1431) + chr(683 - 567) + chr(102) + chr(45) + '\070')) is not None:
wBRs59oAVOdJ[xafqLlk3kkUe(SXOLrMavuUCe(b'\xee\xab8\x06$\x9f\x1a\xc3h\x08\xdf\x0e'), chr(0b11001 + 0o113) + chr(4661 - 4560) + chr(99) + chr(0b10101 + 0o132) + '\144' + chr(0b111100 + 0o51))(chr(117) + '\164' + '\146' + chr(0b1101 + 0o40) + chr(56))] = vUTZFbqN0o8F.tpu_job_name
if xafqLlk3kkUe(ny6shRSJO9Wm, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf7\xaf+\x06#\x9f\x1c\xf9'), chr(100) + '\x65' + chr(1971 - 1872) + chr(111) + '\x64' + chr(3124 - 3023))(chr(0b100110 + 0o117) + chr(0b1111 + 0o145) + chr(8339 - 8237) + chr(1579 - 1534) + chr(56)), ehT0Px3KOsy9('\x30' + chr(0b10101 + 0o132) + chr(1707 - 1659), 9844 - 9836)):
vBObAzLMsHeu = None
TOWMxle4LTiM = None
wBRs59oAVOdJ = {xafqLlk3kkUe(SXOLrMavuUCe(b'\xf4\xae \x06-\x9f\n\xf9u6\xc2\x0e\xde\xc6\xdc]P\x91\x89\x95.'), chr(0b10101 + 0o117) + chr(3538 - 3437) + '\x63' + '\x6f' + chr(0b100101 + 0o77) + '\145')(chr(117) + chr(11662 - 11546) + chr(0b1011110 + 0o10) + chr(1457 - 1412) + chr(861 - 805)): ehT0Px3KOsy9(chr(0b10101 + 0o33) + chr(5599 - 5488) + chr(0b100 + 0o55), 8), xafqLlk3kkUe(SXOLrMavuUCe(b'\xea\xbe?\x06&\x9f\x0b\xe8Y\x00\xdc\x1b\xd9\xed\xf1^O\x8f\xbf\x82=y\x9d\xd7\x98\xc0\xf3'), chr(0b1100100) + chr(101) + '\143' + chr(0b1010100 + 0o33) + chr(100) + chr(0b1100101))(chr(0b10110 + 0o137) + chr(0b1110100) + '\146' + '\x2d' + chr(56)): Ghj8YXKiaKb5.InputPipelineConfig.BROADCAST}
m812svkc5bkk = ny6shRSJO9Wm.daisy_chain_variables and ny6shRSJO9Wm.n6ZCgJ7AKd3U == xafqLlk3kkUe(SXOLrMavuUCe(b'\xfc\xb7"8:\xc3J'), chr(0b100010 + 0o102) + chr(0b110011 + 0o62) + chr(0b1100011) + '\157' + '\x64' + chr(101))(chr(11166 - 11049) + chr(0b1011101 + 0o27) + '\x66' + '\055' + chr(0b111000)) and (ny6shRSJO9Wm.weight_dtype == xafqLlk3kkUe(SXOLrMavuUCe(b'\xfc\xb7"8:\xc3J'), chr(0b100001 + 0o103) + chr(0b101001 + 0o74) + chr(99) + chr(0b10000 + 0o137) + chr(224 - 124) + chr(101))(chr(10578 - 10461) + chr(116) + '\x66' + chr(0b101101) + chr(0b111000)))
return xafqLlk3kkUe(KvtIAVGi33Ty, xafqLlk3kkUe(SXOLrMavuUCe(b"\xf9\xa9(8:\x95'\xees\x07\xed\x08\xc3\xf7\xc8QG"), chr(0b1010001 + 0o23) + chr(101) + chr(8700 - 8601) + chr(5172 - 5061) + chr(100) + '\145')(chr(0b1110101) + '\164' + chr(102) + '\055' + chr(0b111000)))(model_name=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xdc\x90}/?\x8a"\xa9a9\xfc]'), chr(0b1100100) + chr(1261 - 1160) + chr(0b10110 + 0o115) + chr(0b1100 + 0o143) + '\x64' + chr(0b1100101))(chr(0b1110101) + chr(0b1001111 + 0o45) + '\146' + chr(45) + chr(56))), model_dir=nd0OX_BS6_o4 or xafqLlk3kkUe(oqhJDdMJfuwx.path, xafqLlk3kkUe(SXOLrMavuUCe(b'\xff\xa3=8 \x94\r\xefc\x1b'), '\x64' + '\145' + '\x63' + chr(111) + '\144' + '\x65')('\165' + chr(0b1110100) + '\146' + chr(0b101101) + chr(0b101 + 0o63)))(xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b"\xf5\xae9);\x84'\xf8o\x1b"), '\x64' + chr(0b1010 + 0o133) + '\x63' + chr(0b1101111) + chr(5223 - 5123) + chr(101))(chr(117) + chr(8668 - 8552) + chr(0b1100110) + chr(0b101101) + '\070'))), master=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf7\xba>-+\x82'), '\144' + '\x65' + chr(0b1100011) + '\x6f' + chr(0b1010110 + 0o16) + chr(5540 - 5439))('\165' + chr(9262 - 9146) + '\x66' + '\055' + chr(648 - 592))), iterations_per_loop=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf3\xaf(+/\x84\x11\xf3h\x1a\xed\x1b\xc9\xeb\xf1TO\x92\x90'), chr(0b1100100) + '\x65' + '\143' + '\x6f' + '\x64' + chr(101))('\165' + '\x74' + chr(102) + chr(0b101101) + '\070')), num_shards=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xee\xab8\x06 \x85\x15\xc3u\x01\xd3\x19\xc8\xea'), chr(0b1000010 + 0o42) + chr(0b1100101) + chr(0b1100011) + chr(6460 - 6349) + chr(0b1100100) + '\x65')('\165' + chr(0b1110100) + chr(0b1100110) + chr(0b101101) + '\x38')), log_device_placement=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6\xb4*\x06*\x95\x0e\xf5e\x0c\xed\x1b\xc0\xf8\xcd]M\x98\x8e\x82'), chr(0b1100100) + '\145' + '\x63' + chr(0b1101111) + '\144' + chr(101))(chr(117) + chr(10214 - 10098) + chr(0b1100110) + chr(0b101101) + chr(1931 - 1875))), save_checkpoints_steps=vBObAzLMsHeu, save_checkpoints_secs=TOWMxle4LTiM, keep_checkpoint_max=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf1\xbe()\x11\x93\x10\xf9e\x02\xc2\x04\xc5\xf7\xdagM\x9c\x98'), '\x64' + '\x65' + '\143' + '\x6f' + '\x64' + '\x65')(chr(0b1110000 + 0o5) + chr(0b11100 + 0o130) + chr(0b101000 + 0o76) + '\x2d' + chr(56))), keep_checkpoint_every_n_hours=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf1\xbe()\x11\x93\x10\xf9e\x02\xc2\x04\xc5\xf7\xdagE\x8b\x85\x846G\x9a\xe6\x99\xc1\xe17\xe9'), chr(0b110 + 0o136) + '\x65' + chr(99) + '\157' + chr(0b1100100) + '\145')(chr(0b1000100 + 0o61) + '\x74' + chr(8636 - 8534) + chr(0b101101) + chr(0b111000))), num_gpus=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b"\xed\xb4?2+\x82'\xfbv\x1c"), chr(5801 - 5701) + '\145' + chr(0b1100011) + chr(0b100001 + 0o116) + chr(6307 - 6207) + chr(0b101110 + 0o67))('\x75' + chr(0b1110100) + chr(9567 - 9465) + chr(45) + '\x38')), gpu_order=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xfd\xab8\x06!\x82\x1c\xf9t'), '\x64' + '\145' + '\x63' + '\x6f' + chr(0b1001011 + 0o31) + chr(0b1100101))('\x75' + chr(116) + '\146' + chr(0b101101) + chr(0b101111 + 0o11))), num_async_replicas=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b"\xed\xb4?2+\x82'\xeec\x19\xde\x02\xcf\xf8\xdd"), '\144' + chr(0b1000111 + 0o36) + chr(4615 - 4516) + chr(111) + chr(0b100 + 0o140) + chr(3324 - 3223))(chr(117) + chr(0b1110100) + chr(3253 - 3151) + '\x2d' + '\x38')), gpu_mem_fraction=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b"\xed\xb4?2+\x82'\xfbv\x1c\xed\x06\xc9\xf4\xc1JY\xa2\x86\x84.{\x80\xd0\x9e\xc0"), chr(0b1100100) + '\x65' + chr(0b1100011) + chr(0b1101111) + chr(100) + chr(101))(chr(0b1110101) + '\x74' + chr(0b111110 + 0o50) + chr(1965 - 1920) + chr(0b111000))), enable_graph_rewriter=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xff\xb5,;"\x95\'\xfbt\x08\xc2\x03\xf3\xeb\xcbOR\x94\x94\x93='), chr(0b1100100) + chr(101) + chr(0b1100011) + '\157' + chr(100) + chr(101))('\165' + '\164' + '\x66' + chr(0b101101) + chr(0b111000))), use_tpu=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xef\xa8(\x06:\x80\r'), chr(100) + chr(101) + chr(0b1100011) + chr(111) + chr(100) + '\145')('\x75' + '\x74' + '\146' + chr(45) + '\070')), use_tpu_estimator=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xef\xa8(\x06:\x80\r\xc3c\x1a\xc6\x02\xc1\xf8\xdaWR'), chr(0b101110 + 0o66) + '\145' + chr(99) + '\157' + chr(712 - 612) + chr(0b110 + 0o137))(chr(5344 - 5227) + chr(0b1010000 + 0o44) + chr(0b10001 + 0o125) + chr(1219 - 1174) + '\x38')), xla_jit_level=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2\xb7,\x06$\x99\x0c\xc3j\x0c\xc4\x0e\xc0'), chr(100) + chr(0b1100101) + chr(0b1100011) + '\x6f' + chr(0b1100100) + '\x65')(chr(0b1110101) + '\x74' + chr(0b1010011 + 0o23) + chr(0b1 + 0o54) + chr(0b0 + 0o70))), schedule=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe9\xb8%<*\x85\x14\xf9'), chr(100) + '\145' + chr(0b1100011) + chr(6378 - 6267) + '\x64' + chr(101))('\x75' + chr(7419 - 7303) + '\x66' + chr(414 - 369) + chr(0b111000))), no_data_parallelism=xafqLlk3kkUe(ny6shRSJO9Wm, xafqLlk3kkUe(SXOLrMavuUCe(b'\xfb\xb3\x03o\x17\xa9\x15\xa5H#\xe6\x19'), '\x64' + chr(0b1100101) + chr(0b101010 + 0o71) + chr(111) + chr(0b1010110 + 0o16) + '\145')(chr(0b101100 + 0o111) + chr(0b1110100) + chr(0b1011100 + 0o12) + chr(45) + '\x38')), optionally_use_dist_strat=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf5\xab90!\x9e\x19\xf0j\x10\xed\x1e\xdf\xfc\xf1\\I\x8e\x94\xa9<l\x86\xd8\x85'), chr(100) + '\x65' + chr(4544 - 4445) + chr(0b1011101 + 0o22) + '\x64' + chr(0b1100101))('\165' + '\164' + '\146' + chr(0b101101) + chr(0b111000))), daisy_chain_variables=m812svkc5bkk, ps_replicas=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xea\xa8\x12++\x80\x14\xf5e\x08\xc1'), chr(3016 - 2916) + '\145' + chr(3445 - 3346) + chr(10566 - 10455) + chr(0b1100100) + chr(1364 - 1263))(chr(0b1110101) + chr(116) + '\x66' + chr(0b101 + 0o50) + chr(0b111000))), ps_job=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xea\xa8\x123!\x92'), chr(100) + chr(0b1000101 + 0o40) + chr(0b100100 + 0o77) + chr(0b1101111) + chr(0b1100100) + '\x65')(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + '\055' + chr(0b111000))), ps_gpu=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xea\xa8\x12>>\x85'), chr(746 - 646) + chr(0b111001 + 0o54) + chr(0b1100011) + chr(6373 - 6262) + chr(5275 - 5175) + '\145')('\x75' + chr(116) + chr(102) + chr(735 - 690) + chr(1354 - 1298))), sync=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe9\xa2#:'), '\144' + chr(5471 - 5370) + chr(99) + chr(1573 - 1462) + chr(7289 - 7189) + chr(0b111110 + 0o47))('\165' + '\164' + chr(8105 - 8003) + chr(45) + '\x38')), worker_id=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b"\xed\xb4?2+\x82'\xf5b"), '\144' + chr(0b1100101) + chr(99) + '\x6f' + chr(8613 - 8513) + chr(3557 - 3456))(chr(0b1110101) + chr(11088 - 10972) + chr(102) + chr(0b101101) + chr(56))), worker_job=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b"\xed\xb4?2+\x82'\xf6i\x0b"), chr(0b1100100) + chr(0b1100101) + '\x63' + '\x6f' + chr(5615 - 5515) + '\x65')(chr(0b1110101 + 0o0) + chr(0b1110100) + chr(5099 - 4997) + '\055' + '\x38')), random_seed=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b"\xe8\xba#=!\x9d'\xefc\x0c\xd6"), chr(100) + chr(0b1001101 + 0o30) + chr(0b1100011) + chr(0b100110 + 0o111) + chr(100) + chr(0b1000100 + 0o41))(chr(5800 - 5683) + '\x74' + chr(0b1100110) + chr(0b100010 + 0o13) + chr(0b101100 + 0o14))), tpu_infeed_sleep_secs=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b"\xee\xab8\x06'\x9e\x1e\xf9c\r\xed\x18\xc0\xfc\xcbH\x7f\x8e\x85\x95<"), chr(100) + chr(101) + chr(0b1100011) + chr(0b1101111) + chr(0b1001110 + 0o26) + chr(0b1100101))(chr(117) + chr(8275 - 8159) + '\x66' + '\055' + '\070')), inter_op_parallelism_threads=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf3\xb59<<\xaf\x17\xecY\x19\xd3\x19\xcd\xf5\xc2]L\x94\x93\x9b\x10l\x9c\xcb\x94\xcf\xf06'), '\144' + '\145' + '\x63' + '\157' + chr(0b1100100) + chr(0b1101 + 0o130))(chr(117) + chr(0b110111 + 0o75) + chr(102) + chr(0b101101) + chr(802 - 746))), log_step_count_steps=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6\xb4*\x06=\x84\x1d\xecY\n\xdd\x1e\xc2\xed\xf1KT\x98\x90\x85'), '\144' + '\145' + chr(99) + chr(7983 - 7872) + '\144' + chr(0b1100101))(chr(0b1110101) + chr(116) + '\x66' + chr(0b11 + 0o52) + chr(0b11 + 0o65))), intra_op_parallelism_threads=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf3\xb59+/\xaf\x17\xecY\x19\xd3\x19\xcd\xf5\xc2]L\x94\x93\x9b\x10l\x9c\xcb\x94\xcf\xf06'), chr(100) + chr(0b1100101) + '\x63' + chr(0b1101111 + 0o0) + '\x64' + chr(0b1100101))(chr(0b11110 + 0o127) + '\164' + chr(0b1100110) + chr(0b101101) + chr(56))), tpu_config_extra_kwargs=wBRs59oAVOdJ, cloud_tpu_name=xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf9\xb7",*\xaf\x0c\xecs6\xdc\n\xc1\xfc'), chr(0b1100100) + chr(0b1100101) + chr(0b1001001 + 0o32) + '\x6f' + '\144' + chr(4821 - 4720))(chr(117) + '\164' + chr(0b1011001 + 0o15) + chr(0b101101) + chr(0b11 + 0o65))))
|
tensorflow/tensor2tensor
|
tensor2tensor/bin/t2t_trainer.py
|
save_metadata
|
def save_metadata(hparams):
"""Saves FLAGS and hparams to output_dir."""
output_dir = os.path.expanduser(FLAGS.output_dir)
if not tf.gfile.Exists(output_dir):
tf.gfile.MakeDirs(output_dir)
# Save FLAGS in txt file
if hasattr(FLAGS, "flags_into_string"):
flags_str = FLAGS.flags_into_string()
t2t_flags_str = "\n".join([
"--%s=%s" % (f.name, f.value)
for f in FLAGS.flags_by_module_dict()["tensor2tensor.utils.flags"]
])
else:
flags_dict = FLAGS.__dict__["__flags"]
flags_str = "\n".join(
["--%s=%s" % (name, str(f)) for (name, f) in flags_dict.items()])
t2t_flags_str = None
flags_txt = os.path.join(output_dir, "flags.txt")
with tf.gfile.Open(flags_txt, "w") as f:
f.write(flags_str)
if t2t_flags_str:
t2t_flags_txt = os.path.join(output_dir, "flags_t2t.txt")
with tf.gfile.Open(t2t_flags_txt, "w") as f:
f.write(t2t_flags_str)
# Save hparams as hparams.json
new_hparams = hparams_lib.copy_hparams(hparams)
# Modality class is not JSON serializable so remove.
new_hparams.del_hparam("modality")
hparams_fname = os.path.join(output_dir, "hparams.json")
with tf.gfile.Open(hparams_fname, "w") as f:
f.write(new_hparams.to_json(indent=0, sort_keys=True))
|
python
|
def save_metadata(hparams):
"""Saves FLAGS and hparams to output_dir."""
output_dir = os.path.expanduser(FLAGS.output_dir)
if not tf.gfile.Exists(output_dir):
tf.gfile.MakeDirs(output_dir)
# Save FLAGS in txt file
if hasattr(FLAGS, "flags_into_string"):
flags_str = FLAGS.flags_into_string()
t2t_flags_str = "\n".join([
"--%s=%s" % (f.name, f.value)
for f in FLAGS.flags_by_module_dict()["tensor2tensor.utils.flags"]
])
else:
flags_dict = FLAGS.__dict__["__flags"]
flags_str = "\n".join(
["--%s=%s" % (name, str(f)) for (name, f) in flags_dict.items()])
t2t_flags_str = None
flags_txt = os.path.join(output_dir, "flags.txt")
with tf.gfile.Open(flags_txt, "w") as f:
f.write(flags_str)
if t2t_flags_str:
t2t_flags_txt = os.path.join(output_dir, "flags_t2t.txt")
with tf.gfile.Open(t2t_flags_txt, "w") as f:
f.write(t2t_flags_str)
# Save hparams as hparams.json
new_hparams = hparams_lib.copy_hparams(hparams)
# Modality class is not JSON serializable so remove.
new_hparams.del_hparam("modality")
hparams_fname = os.path.join(output_dir, "hparams.json")
with tf.gfile.Open(hparams_fname, "w") as f:
f.write(new_hparams.to_json(indent=0, sort_keys=True))
|
[
"def",
"save_metadata",
"(",
"hparams",
")",
":",
"output_dir",
"=",
"os",
".",
"path",
".",
"expanduser",
"(",
"FLAGS",
".",
"output_dir",
")",
"if",
"not",
"tf",
".",
"gfile",
".",
"Exists",
"(",
"output_dir",
")",
":",
"tf",
".",
"gfile",
".",
"MakeDirs",
"(",
"output_dir",
")",
"# Save FLAGS in txt file",
"if",
"hasattr",
"(",
"FLAGS",
",",
"\"flags_into_string\"",
")",
":",
"flags_str",
"=",
"FLAGS",
".",
"flags_into_string",
"(",
")",
"t2t_flags_str",
"=",
"\"\\n\"",
".",
"join",
"(",
"[",
"\"--%s=%s\"",
"%",
"(",
"f",
".",
"name",
",",
"f",
".",
"value",
")",
"for",
"f",
"in",
"FLAGS",
".",
"flags_by_module_dict",
"(",
")",
"[",
"\"tensor2tensor.utils.flags\"",
"]",
"]",
")",
"else",
":",
"flags_dict",
"=",
"FLAGS",
".",
"__dict__",
"[",
"\"__flags\"",
"]",
"flags_str",
"=",
"\"\\n\"",
".",
"join",
"(",
"[",
"\"--%s=%s\"",
"%",
"(",
"name",
",",
"str",
"(",
"f",
")",
")",
"for",
"(",
"name",
",",
"f",
")",
"in",
"flags_dict",
".",
"items",
"(",
")",
"]",
")",
"t2t_flags_str",
"=",
"None",
"flags_txt",
"=",
"os",
".",
"path",
".",
"join",
"(",
"output_dir",
",",
"\"flags.txt\"",
")",
"with",
"tf",
".",
"gfile",
".",
"Open",
"(",
"flags_txt",
",",
"\"w\"",
")",
"as",
"f",
":",
"f",
".",
"write",
"(",
"flags_str",
")",
"if",
"t2t_flags_str",
":",
"t2t_flags_txt",
"=",
"os",
".",
"path",
".",
"join",
"(",
"output_dir",
",",
"\"flags_t2t.txt\"",
")",
"with",
"tf",
".",
"gfile",
".",
"Open",
"(",
"t2t_flags_txt",
",",
"\"w\"",
")",
"as",
"f",
":",
"f",
".",
"write",
"(",
"t2t_flags_str",
")",
"# Save hparams as hparams.json",
"new_hparams",
"=",
"hparams_lib",
".",
"copy_hparams",
"(",
"hparams",
")",
"# Modality class is not JSON serializable so remove.",
"new_hparams",
".",
"del_hparam",
"(",
"\"modality\"",
")",
"hparams_fname",
"=",
"os",
".",
"path",
".",
"join",
"(",
"output_dir",
",",
"\"hparams.json\"",
")",
"with",
"tf",
".",
"gfile",
".",
"Open",
"(",
"hparams_fname",
",",
"\"w\"",
")",
"as",
"f",
":",
"f",
".",
"write",
"(",
"new_hparams",
".",
"to_json",
"(",
"indent",
"=",
"0",
",",
"sort_keys",
"=",
"True",
")",
")"
] |
Saves FLAGS and hparams to output_dir.
|
[
"Saves",
"FLAGS",
"and",
"hparams",
"to",
"output_dir",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2t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VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + chr(111) + chr(893 - 844) + '\065' + chr(0b100111 + 0o14), 0b1000), ehT0Px3KOsy9('\060' + chr(6916 - 6805) + chr(0b110010) + chr(0b110011) + chr(0b11001 + 0o30), 0o10), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b1101111) + chr(0b110010) + chr(0b100011 + 0o24) + chr(0b10111 + 0o40), 0b1000), ehT0Px3KOsy9(chr(443 - 395) + '\157' + '\063' + chr(0b110111) + '\x37', 0o10), ehT0Px3KOsy9('\060' + chr(0b1101100 + 0o3) + '\063' + '\067', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b110001 + 0o76) + '\061' + chr(0b10010 + 0o40) + chr(0b110101), 4011 - 4003), ehT0Px3KOsy9('\060' + chr(8342 - 8231) + chr(0b1100 + 0o46) + chr(0b110001) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b1011 + 0o46) + chr(115 - 64), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110001), ord("\x08")), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(111) + '\061' + chr(54) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(49) + chr(2304 - 2250) + '\065', ord("\x08")), ehT0Px3KOsy9(chr(0b1010 + 0o46) + '\157' + '\063' + '\066' + chr(0b1111 + 0o44), ord("\x08")), ehT0Px3KOsy9(chr(0b1101 + 0o43) + '\x6f' + chr(54) + chr(0b110011), 52402 - 52394), ehT0Px3KOsy9('\x30' + chr(10178 - 10067) + '\x33' + chr(0b110100) + chr(443 - 392), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\x32' + chr(0b110111) + chr(0b100101 + 0o20), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + '\061' + '\x30' + chr(0b10101 + 0o36), ord("\x08")), ehT0Px3KOsy9(chr(1325 - 1277) + chr(0b1010101 + 0o32) + '\061' + chr(48) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(1366 - 1318) + chr(0b1010101 + 0o32) + '\066' + chr(53), 43312 - 43304), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110010) + '\x35' + chr(0b10011 + 0o36), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\x33' + chr(55), 8), ehT0Px3KOsy9('\060' + '\157' + '\x32' + chr(0b110111) + chr(55), 8), ehT0Px3KOsy9(chr(708 - 660) + '\x6f' + chr(0b100001 + 0o21) + chr(0b110000) + chr(52), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(0b1000 + 0o52) + chr(889 - 841) + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110011) + '\061' + chr(54), 0b1000), ehT0Px3KOsy9(chr(1204 - 1156) + chr(0b1101111) + '\062' + chr(0b101000 + 0o14) + chr(49), 0o10), ehT0Px3KOsy9(chr(377 - 329) + chr(0b10011 + 0o134) + chr(370 - 320) + chr(54) + '\064', 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(1622 - 1573) + '\062' + chr(0b111 + 0o51), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + '\x31' + '\x31' + chr(0b101011 + 0o5), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + '\062' + chr(48), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(49) + '\067' + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(0b1011 + 0o45) + '\157' + '\x32' + '\x34' + '\064', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(401 - 351) + chr(0b10101 + 0o42), ord("\x08")), ehT0Px3KOsy9(chr(1154 - 1106) + '\157' + '\061' + chr(371 - 320) + '\067', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(1608 - 1557) + chr(2484 - 2434), 24060 - 24052), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b100001 + 0o24) + '\062', 0b1000), ehT0Px3KOsy9('\x30' + chr(9655 - 9544) + chr(1177 - 1128) + '\x35' + '\067', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(6056 - 5945) + '\064' + chr(0b110111), 32593 - 32585), ehT0Px3KOsy9(chr(0b101000 + 0o10) + '\x6f' + chr(0b110010) + chr(0b110110) + chr(0b11 + 0o61), 8), ehT0Px3KOsy9(chr(0b11110 + 0o22) + '\x6f' + '\x31' + chr(2396 - 2341) + '\066', 0b1000), ehT0Px3KOsy9(chr(411 - 363) + chr(111) + chr(51) + '\x36' + chr(1527 - 1479), 29158 - 29150)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110101) + chr(48), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'E'), chr(100) + chr(0b11001 + 0o114) + chr(0b1001111 + 0o24) + chr(0b10110 + 0o131) + chr(0b1010011 + 0o21) + chr(0b101 + 0o140))(chr(852 - 735) + chr(0b101010 + 0o112) + chr(102) + chr(0b101101) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def FVYzr6XVmQ1E(n4ljua2gi1Pr):
nd0OX_BS6_o4 = oqhJDdMJfuwx.path.expanduser(vUTZFbqN0o8F.output_dir)
if not xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'.\xe1\xd6\x8ck&'), '\x64' + chr(101) + chr(0b10010 + 0o121) + chr(0b1101111) + '\144' + chr(0b110000 + 0o65))('\x75' + chr(8117 - 8001) + '\x66' + chr(0b10101 + 0o30) + '\x38'))(nd0OX_BS6_o4):
xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'&\xf8\xd4\x9a[<\xfdx'), chr(100) + chr(8778 - 8677) + '\x63' + chr(9333 - 9222) + '\144' + chr(0b1100101))(chr(0b1110101) + '\164' + chr(4137 - 4035) + chr(0b11010 + 0o23) + chr(56)))(nd0OX_BS6_o4)
if lot1PSoAwYhj(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'\r\xf5\xde\x98l\n\xe6eu\x1d*\x80G\x91\xd4- '), chr(100) + chr(0b1100 + 0o131) + chr(0b1100011) + '\157' + chr(0b1100100) + chr(3276 - 3175))('\x75' + '\164' + '\146' + chr(2010 - 1965) + chr(0b111000))):
iliRv9qdslii = vUTZFbqN0o8F.flags_into_string()
zRXfpRAzEqYi = xafqLlk3kkUe(SXOLrMavuUCe(b'a'), '\144' + chr(0b1100101) + '\143' + '\157' + chr(0b1001000 + 0o34) + chr(0b1011010 + 0o13))('\165' + '\164' + chr(0b1100110) + chr(0b101101) + chr(56)).join([xafqLlk3kkUe(SXOLrMavuUCe(b'F\xb4\x9a\x8c"p\xfc'), chr(0b111111 + 0o45) + chr(3345 - 3244) + chr(99) + '\x6f' + '\x64' + '\145')('\x75' + '\x74' + '\x66' + '\x2d' + chr(1063 - 1007)) % (EGyt1xfPT1P6.AIvJRzLdDfgF, EGyt1xfPT1P6.QmmgWUB13VCJ) for EGyt1xfPT1P6 in vUTZFbqN0o8F.flags_by_module_dict()[xafqLlk3kkUe(SXOLrMavuUCe(b"\x1f\xfc\xd1\x8cp'\xbd\x7fd\x1c\x06\x9cA\xcd\xc87.Y\xda1\xd9\xe8\xe7\xa9\xd2"), '\144' + chr(5475 - 5374) + chr(6589 - 6490) + '\157' + chr(100) + '\145')(chr(0b1110101) + chr(0b1110100) + chr(102) + chr(45) + chr(827 - 771))]])
else:
AaLv5oiWAUYl = vUTZFbqN0o8F.uKB5Y2EEqIKI[xafqLlk3kkUe(SXOLrMavuUCe(b'4\xc6\xd9\x93~2\xfc'), '\x64' + '\145' + '\x63' + chr(0b110000 + 0o77) + chr(4860 - 4760) + chr(8471 - 8370))('\165' + chr(0b1110100) + chr(5558 - 5456) + chr(45) + chr(0b101110 + 0o12))]
iliRv9qdslii = xafqLlk3kkUe(SXOLrMavuUCe(b'a'), '\x64' + '\145' + '\143' + chr(111) + chr(100) + chr(0b10000 + 0o125))(chr(0b100000 + 0o125) + chr(7187 - 7071) + '\x66' + chr(0b101101) + '\x38').join([xafqLlk3kkUe(SXOLrMavuUCe(b'F\xb4\x9a\x8c"p\xfc'), '\x64' + chr(101) + chr(6212 - 6113) + chr(0b1010 + 0o145) + '\x64' + chr(2222 - 2121))(chr(0b1001111 + 0o46) + chr(0b1110100) + '\146' + '\055' + chr(3022 - 2966)) % (AIvJRzLdDfgF, M8_cKLkHVB2V(EGyt1xfPT1P6)) for (AIvJRzLdDfgF, EGyt1xfPT1P6) in AaLv5oiWAUYl.NzveIZ3IlSH9()])
zRXfpRAzEqYi = None
OAho2JjVdGCV = oqhJDdMJfuwx.path.join(nd0OX_BS6_o4, xafqLlk3kkUe(SXOLrMavuUCe(b'\r\xf5\xde\x98l{\xfbsu'), '\144' + '\x65' + '\143' + chr(11414 - 11303) + chr(0b10010 + 0o122) + chr(0b111100 + 0o51))(chr(117) + '\x74' + chr(0b1100110) + '\x2d' + chr(56)))
with xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'$\xe9\xda\x91'), chr(7632 - 7532) + chr(0b1000100 + 0o41) + chr(6364 - 6265) + chr(0b1100110 + 0o11) + chr(0b1001001 + 0o33) + '\145')('\165' + chr(116) + '\x66' + '\055' + chr(1049 - 993)))(OAho2JjVdGCV, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c'), chr(8351 - 8251) + '\x65' + chr(99) + '\157' + '\x64' + chr(0b1100100 + 0o1))(chr(0b1110101) + chr(0b10001 + 0o143) + '\x66' + chr(45) + '\x38')) as EGyt1xfPT1P6:
xafqLlk3kkUe(EGyt1xfPT1P6, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c\xeb\xd6\x8bz'), '\144' + chr(3469 - 3368) + chr(99) + '\157' + chr(100) + chr(101))(chr(11682 - 11565) + '\x74' + chr(102) + chr(0b1010 + 0o43) + chr(0b111000)))(iliRv9qdslii)
if zRXfpRAzEqYi:
pkBsg1fQ094h = oqhJDdMJfuwx.path.join(nd0OX_BS6_o4, xafqLlk3kkUe(SXOLrMavuUCe(b'\r\xf5\xde\x98l\n\xfb9u\\\x01\x8bG'), chr(4136 - 4036) + '\x65' + chr(0b1001 + 0o132) + '\157' + chr(1848 - 1748) + chr(0b1001001 + 0o34))(chr(11857 - 11740) + chr(116) + chr(5056 - 4954) + chr(0b100001 + 0o14) + '\070'))
with xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'$\xe9\xda\x91'), chr(7334 - 7234) + chr(101) + chr(0b1100011) + chr(111) + chr(100) + chr(0b1001000 + 0o35))(chr(0b1110101) + chr(0b1110100) + chr(0b1010111 + 0o17) + '\x2d' + '\070'))(pkBsg1fQ094h, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c'), chr(0b1100100) + chr(0b110111 + 0o56) + chr(7435 - 7336) + '\x6f' + '\144' + chr(5413 - 5312))(chr(0b11011 + 0o132) + chr(116) + '\x66' + '\x2d' + '\070')) as EGyt1xfPT1P6:
xafqLlk3kkUe(EGyt1xfPT1P6, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c\xeb\xd6\x8bz'), chr(0b1000110 + 0o36) + '\145' + '\x63' + chr(0b1101111) + '\144' + '\145')(chr(117) + '\164' + chr(0b1100110) + chr(45) + chr(0b110011 + 0o5)))(zRXfpRAzEqYi)
f5ElP0H04QK4 = BMqTy4F2E1fh.copy_hparams(n4ljua2gi1Pr)
xafqLlk3kkUe(f5ElP0H04QK4, xafqLlk3kkUe(SXOLrMavuUCe(b'\x0f\xfc\xd3\xa0w%\xeey`\x1f'), chr(0b1100100) + chr(101) + chr(5362 - 5263) + chr(0b1101111) + chr(7888 - 7788) + '\145')(chr(0b101000 + 0o115) + chr(6731 - 6615) + '\x66' + chr(1062 - 1017) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x06\xf6\xdb\x9es<\xfbr'), '\144' + chr(2395 - 2294) + chr(275 - 176) + '\157' + '\x64' + chr(7068 - 6967))(chr(0b1110100 + 0o1) + chr(0b1001110 + 0o46) + chr(0b1100110) + chr(0b101101) + '\x38'))
EFPR7zel_kUt = oqhJDdMJfuwx.path.join(nd0OX_BS6_o4, xafqLlk3kkUe(SXOLrMavuUCe(b'\x03\xe9\xde\x8d~8\xfc%k\x01\x1a\x9d'), chr(0b1100100) + chr(101) + '\x63' + chr(1859 - 1748) + chr(5604 - 5504) + chr(0b1010110 + 0o17))(chr(0b1100100 + 0o21) + chr(116) + '\x66' + '\x2d' + '\x38'))
with xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'$\xe9\xda\x91'), '\144' + chr(0b1100101) + chr(99) + '\x6f' + chr(0b1100100) + chr(101))(chr(0b1011010 + 0o33) + chr(0b1110001 + 0o3) + '\x66' + '\055' + chr(0b1 + 0o67)))(EFPR7zel_kUt, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c'), '\144' + chr(5065 - 4964) + chr(0b11101 + 0o106) + chr(0b1101111) + chr(0b1100100) + chr(101))('\165' + chr(116) + '\146' + chr(944 - 899) + chr(2906 - 2850))) as EGyt1xfPT1P6:
xafqLlk3kkUe(EGyt1xfPT1P6, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c\xeb\xd6\x8bz'), chr(0b10001 + 0o123) + chr(101) + chr(0b1100011) + '\157' + chr(0b1100100) + chr(101))('\165' + chr(0b1001000 + 0o54) + chr(6217 - 6115) + chr(45) + '\070'))(xafqLlk3kkUe(f5ElP0H04QK4, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1f\xf6\xe0\x95l:\xe1'), chr(0b101111 + 0o65) + chr(2334 - 2233) + chr(3563 - 3464) + '\157' + '\144' + chr(0b1100101))(chr(117) + chr(488 - 372) + '\x66' + chr(367 - 322) + '\x38'))(indent=ehT0Px3KOsy9('\060' + chr(393 - 282) + chr(1790 - 1742), ord("\x08")), sort_keys=ehT0Px3KOsy9('\060' + chr(0b101 + 0o152) + chr(0b110001), 8)))
|
tensorflow/tensor2tensor
|
tensor2tensor/models/xception.py
|
residual_block
|
def residual_block(x, hparams):
"""A stack of convolution blocks with residual connection."""
k = (hparams.kernel_height, hparams.kernel_width)
dilations_and_kernels = [((1, 1), k) for _ in range(3)]
y = common_layers.subseparable_conv_block(
x,
hparams.hidden_size,
dilations_and_kernels,
padding="SAME",
separability=0,
name="residual_block")
x = common_layers.layer_norm(x + y, hparams.hidden_size, name="lnorm")
return tf.nn.dropout(x, 1.0 - hparams.dropout)
|
python
|
def residual_block(x, hparams):
"""A stack of convolution blocks with residual connection."""
k = (hparams.kernel_height, hparams.kernel_width)
dilations_and_kernels = [((1, 1), k) for _ in range(3)]
y = common_layers.subseparable_conv_block(
x,
hparams.hidden_size,
dilations_and_kernels,
padding="SAME",
separability=0,
name="residual_block")
x = common_layers.layer_norm(x + y, hparams.hidden_size, name="lnorm")
return tf.nn.dropout(x, 1.0 - hparams.dropout)
|
[
"def",
"residual_block",
"(",
"x",
",",
"hparams",
")",
":",
"k",
"=",
"(",
"hparams",
".",
"kernel_height",
",",
"hparams",
".",
"kernel_width",
")",
"dilations_and_kernels",
"=",
"[",
"(",
"(",
"1",
",",
"1",
")",
",",
"k",
")",
"for",
"_",
"in",
"range",
"(",
"3",
")",
"]",
"y",
"=",
"common_layers",
".",
"subseparable_conv_block",
"(",
"x",
",",
"hparams",
".",
"hidden_size",
",",
"dilations_and_kernels",
",",
"padding",
"=",
"\"SAME\"",
",",
"separability",
"=",
"0",
",",
"name",
"=",
"\"residual_block\"",
")",
"x",
"=",
"common_layers",
".",
"layer_norm",
"(",
"x",
"+",
"y",
",",
"hparams",
".",
"hidden_size",
",",
"name",
"=",
"\"lnorm\"",
")",
"return",
"tf",
".",
"nn",
".",
"dropout",
"(",
"x",
",",
"1.0",
"-",
"hparams",
".",
"dropout",
")"
] |
A stack of convolution blocks with residual connection.
|
[
"A",
"stack",
"of",
"convolution",
"blocks",
"with",
"residual",
"connection",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/xception.py#L33-L45
|
train
|
A stack of convolution blocks with residual connection.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG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hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + '\157' + chr(50) + chr(49) + chr(771 - 722), ord("\x08")), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(0b1101111) + chr(0b110010) + chr(0b11011 + 0o27) + chr(1970 - 1918), 0o10), ehT0Px3KOsy9(chr(0b1 + 0o57) + '\157' + '\x37' + chr(2281 - 2233), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b101101 + 0o4) + chr(2586 - 2534) + chr(2052 - 2000), 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(0b100101 + 0o16) + chr(918 - 866) + chr(0b1101 + 0o46), ord("\x08")), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(0b1010100 + 0o33) + chr(51) + chr(0b110111) + chr(49), 20561 - 20553), ehT0Px3KOsy9(chr(752 - 704) + chr(5850 - 5739) + '\063' + chr(0b10101 + 0o36) + chr(0b110011), 20045 - 20037), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110010) + '\x36' + chr(0b1100 + 0o45), 55374 - 55366), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b100000 + 0o20), 51119 - 51111), ehT0Px3KOsy9('\x30' + chr(111) + '\x31' + chr(0b11101 + 0o31) + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(53) + chr(0b110110), 0b1000), ehT0Px3KOsy9('\x30' + chr(5131 - 5020) + '\062' + '\x35' + '\064', ord("\x08")), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(0b100111 + 0o110) + '\x32' + chr(1096 - 1044) + '\x34', ord("\x08")), ehT0Px3KOsy9(chr(1139 - 1091) + chr(0b100011 + 0o114) + chr(0b101001 + 0o14) + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(984 - 933) + '\067' + chr(1427 - 1375), 29954 - 29946), ehT0Px3KOsy9('\x30' + chr(610 - 499) + chr(0b1 + 0o60) + '\x36' + chr(0b110011), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(50) + chr(0b110000) + '\x35', ord("\x08")), ehT0Px3KOsy9(chr(293 - 245) + chr(0b100010 + 0o115) + '\x31' + chr(243 - 193) + chr(48), 0o10), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(9251 - 9140) + '\061' + chr(1839 - 1787) + chr(52), 8), ehT0Px3KOsy9(chr(1208 - 1160) + '\157' + '\x32', 63244 - 63236), ehT0Px3KOsy9('\060' + '\157' + chr(1358 - 1308) + chr(1084 - 1036) + '\x33', ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(859 - 809) + '\x33' + chr(54), 43376 - 43368), ehT0Px3KOsy9(chr(48) + chr(652 - 541) + chr(191 - 141) + '\x34' + chr(0b110100), 8), ehT0Px3KOsy9(chr(48) + chr(0b1011101 + 0o22) + chr(51) + '\062' + chr(0b10 + 0o60), 0b1000), ehT0Px3KOsy9(chr(1161 - 1113) + '\157' + '\x37' + chr(0b11000 + 0o33), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b100110 + 0o111) + chr(0b110010) + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101011 + 0o4) + chr(0b110010) + '\065' + chr(0b11011 + 0o33), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\064' + chr(1887 - 1838), 0o10), ehT0Px3KOsy9(chr(2021 - 1973) + chr(111) + chr(0b110011) + chr(1574 - 1519) + chr(794 - 744), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110011) + chr(0b110110) + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(51) + chr(697 - 647) + chr(52), 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(2326 - 2276) + '\x30' + chr(391 - 342), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(49) + chr(48) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(5145 - 5034) + chr(749 - 699) + '\064' + chr(0b110110), 43404 - 43396), ehT0Px3KOsy9(chr(0b10111 + 0o31) + chr(111) + chr(2433 - 2382) + '\066' + '\x30', 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b100100 + 0o113) + chr(0b11 + 0o60) + chr(0b110101) + chr(0b1000 + 0o55), 26143 - 26135), ehT0Px3KOsy9(chr(0b1101 + 0o43) + '\x6f' + chr(0b110000 + 0o2) + chr(1484 - 1434) + chr(2339 - 2290), 207 - 199), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(111) + chr(0b111 + 0o54) + '\067' + chr(0b110101), 12085 - 12077), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\061' + chr(0b110011) + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b101100 + 0o5) + chr(0b110001) + '\x34', 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(53) + chr(0b11110 + 0o22), 18274 - 18266)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xa7'), chr(100) + chr(0b1100101) + chr(7033 - 6934) + chr(0b1010011 + 0o34) + chr(0b1100 + 0o130) + chr(0b1100 + 0o131))(chr(13276 - 13159) + chr(0b1000011 + 0o61) + chr(0b1100110) + '\x2d' + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def cZzlDzj_eOt4(OeWW0F1dBPRQ, n4ljua2gi1Pr):
OolUPRJhRaJd = (n4ljua2gi1Pr.aWtpZRO3JbHj, n4ljua2gi1Pr.xCDNMTg51zI4)
HfyTWMMIvuNz = [((ehT0Px3KOsy9(chr(48) + chr(8734 - 8623) + '\061', 58641 - 58633), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b0 + 0o61), 8)), OolUPRJhRaJd) for VNGQdHSFPrso in vQr8gNKaIaWE(ehT0Px3KOsy9(chr(48) + chr(0b101010 + 0o105) + chr(0b100111 + 0o14), 30086 - 30078))]
SqiSOtYOqOJH = jSKPaHwSAfVv.subseparable_conv_block(OeWW0F1dBPRQ, n4ljua2gi1Pr.qzoyXN3kdhDL, HfyTWMMIvuNz, padding=xafqLlk3kkUe(SXOLrMavuUCe(b'\xda\xd5u!'), chr(0b1010011 + 0o21) + '\x65' + chr(4020 - 3921) + chr(111) + '\x64' + '\145')(chr(0b11000 + 0o135) + '\164' + chr(5417 - 5315) + chr(1230 - 1185) + '\x38'), separability=ehT0Px3KOsy9('\060' + '\157' + '\x30', 8), name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xfb\xf1K\r\x87\x8c\xba\xdd_\x16B\xc3\xc7D'), '\x64' + chr(0b1100101) + '\x63' + chr(324 - 213) + '\x64' + chr(0b1001101 + 0o30))('\x75' + chr(0b1110100) + chr(0b1100001 + 0o5) + chr(1181 - 1136) + '\070'))
OeWW0F1dBPRQ = jSKPaHwSAfVv.layer_norm(OeWW0F1dBPRQ + SqiSOtYOqOJH, n4ljua2gi1Pr.qzoyXN3kdhDL, name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xe5\xfaW\x16\x8e'), '\x64' + chr(101) + chr(99) + '\x6f' + '\x64' + chr(0b1000110 + 0o37))(chr(0b1110101) + chr(1804 - 1688) + '\146' + chr(45) + chr(0b110 + 0o62)))
return xafqLlk3kkUe(IDJ2eXGCBCDu.nn, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe8\xf3\x08\t\x94\xbc\xbc\xe6z\x1ew\xda'), '\144' + chr(0b100000 + 0o105) + '\x63' + chr(5933 - 5822) + chr(0b1100100) + chr(101))('\165' + chr(116) + '\x66' + chr(115 - 70) + chr(0b111000)))(OeWW0F1dBPRQ, 1.0 - xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe8\xf3\x08\t\x94\xbc\xbc\xe6z\x1ew\xda'), chr(0b111000 + 0o54) + '\x65' + chr(1389 - 1290) + chr(0b1101111) + '\x64' + chr(0b1100101))(chr(0b1101 + 0o150) + '\164' + chr(0b1100 + 0o132) + chr(0b101101) + chr(0b1110 + 0o52))))
|
tensorflow/tensor2tensor
|
tensor2tensor/models/xception.py
|
xception_internal
|
def xception_internal(inputs, hparams):
"""Xception body."""
with tf.variable_scope("xception"):
cur = inputs
if cur.get_shape().as_list()[1] > 200:
# Large image, Xception entry flow
cur = xception_entry(cur, hparams.hidden_size)
else:
# Small image, conv
cur = common_layers.conv_block(
cur,
hparams.hidden_size, [((1, 1), (3, 3))],
first_relu=False,
padding="SAME",
force2d=True,
name="small_image_conv")
for i in range(hparams.num_hidden_layers):
with tf.variable_scope("layer_%d" % i):
cur = residual_block(cur, hparams)
return xception_exit(cur)
|
python
|
def xception_internal(inputs, hparams):
"""Xception body."""
with tf.variable_scope("xception"):
cur = inputs
if cur.get_shape().as_list()[1] > 200:
# Large image, Xception entry flow
cur = xception_entry(cur, hparams.hidden_size)
else:
# Small image, conv
cur = common_layers.conv_block(
cur,
hparams.hidden_size, [((1, 1), (3, 3))],
first_relu=False,
padding="SAME",
force2d=True,
name="small_image_conv")
for i in range(hparams.num_hidden_layers):
with tf.variable_scope("layer_%d" % i):
cur = residual_block(cur, hparams)
return xception_exit(cur)
|
[
"def",
"xception_internal",
"(",
"inputs",
",",
"hparams",
")",
":",
"with",
"tf",
".",
"variable_scope",
"(",
"\"xception\"",
")",
":",
"cur",
"=",
"inputs",
"if",
"cur",
".",
"get_shape",
"(",
")",
".",
"as_list",
"(",
")",
"[",
"1",
"]",
">",
"200",
":",
"# Large image, Xception entry flow",
"cur",
"=",
"xception_entry",
"(",
"cur",
",",
"hparams",
".",
"hidden_size",
")",
"else",
":",
"# Small image, conv",
"cur",
"=",
"common_layers",
".",
"conv_block",
"(",
"cur",
",",
"hparams",
".",
"hidden_size",
",",
"[",
"(",
"(",
"1",
",",
"1",
")",
",",
"(",
"3",
",",
"3",
")",
")",
"]",
",",
"first_relu",
"=",
"False",
",",
"padding",
"=",
"\"SAME\"",
",",
"force2d",
"=",
"True",
",",
"name",
"=",
"\"small_image_conv\"",
")",
"for",
"i",
"in",
"range",
"(",
"hparams",
".",
"num_hidden_layers",
")",
":",
"with",
"tf",
".",
"variable_scope",
"(",
"\"layer_%d\"",
"%",
"i",
")",
":",
"cur",
"=",
"residual_block",
"(",
"cur",
",",
"hparams",
")",
"return",
"xception_exit",
"(",
"cur",
")"
] |
Xception body.
|
[
"Xception",
"body",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/xception.py#L48-L70
|
train
|
Xception body.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd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OIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110011) + chr(54) + chr(0b11110 + 0o30), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(49) + chr(54), 55983 - 55975), ehT0Px3KOsy9(chr(48) + chr(6936 - 6825) + chr(1813 - 1759) + chr(402 - 348), 5142 - 5134), ehT0Px3KOsy9(chr(0b10101 + 0o33) + '\157' + chr(0b1000 + 0o53) + chr(0b110101) + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(0b1010 + 0o46) + '\157' + '\x31' + chr(868 - 815) + '\064', 0b1000), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(0b1101111) + chr(49) + chr(0b110111) + '\063', 0o10), ehT0Px3KOsy9('\060' + chr(6518 - 6407) + chr(0b101101 + 0o4) + chr(0b110001 + 0o0) + '\066', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1010111 + 0o30) + chr(51) + chr(0b110100) + chr(49), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(50) + chr(1636 - 1584), 0o10), ehT0Px3KOsy9(chr(0b100100 + 0o14) + chr(0b1101111) + '\x35' + chr(0b10101 + 0o35), 4095 - 4087), ehT0Px3KOsy9('\060' + '\x6f' + chr(49) + chr(0b110000) + chr(0b110101), 52300 - 52292), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x32' + '\061' + chr(0b110101), 40205 - 40197), ehT0Px3KOsy9('\x30' + '\x6f' + chr(50) + chr(338 - 288) + chr(0b110100), 0o10), ehT0Px3KOsy9(chr(48) + chr(7395 - 7284) + chr(2170 - 2119) + '\x36' + chr(0b10000 + 0o41), 19553 - 19545), ehT0Px3KOsy9(chr(48) + chr(0b1010110 + 0o31) + chr(778 - 729) + chr(54) + chr(0b110110), 60309 - 60301), ehT0Px3KOsy9('\060' + chr(0b100110 + 0o111) + chr(0b110010) + chr(0b110100) + chr(55), 0o10), ehT0Px3KOsy9(chr(1506 - 1458) + chr(0b1101111) + chr(0b110011) + chr(0b100101 + 0o16) + chr(1337 - 1287), 14567 - 14559), ehT0Px3KOsy9('\x30' + chr(0b100 + 0o153) + '\x31' + chr(52) + chr(0b110110), 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(1781 - 1727) + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(1562 - 1514) + chr(0b1101111) + '\061' + chr(52), 24150 - 24142), ehT0Px3KOsy9(chr(0b100101 + 0o13) + chr(3110 - 2999) + chr(1427 - 1377) + chr(51) + '\066', 49057 - 49049), ehT0Px3KOsy9('\x30' + '\157' + chr(2106 - 2054) + chr(1896 - 1848), 56597 - 56589), ehT0Px3KOsy9(chr(0b1000 + 0o50) + chr(111) + chr(0b1001 + 0o50) + chr(1017 - 967) + '\066', 46449 - 46441), ehT0Px3KOsy9('\060' + chr(10133 - 10022) + '\x33' + chr(705 - 653) + '\062', ord("\x08")), ehT0Px3KOsy9(chr(1068 - 1020) + chr(0b1101111) + chr(0b110011) + chr(54) + '\060', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b10000 + 0o137) + chr(50) + '\062' + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(582 - 534) + chr(3401 - 3290) + chr(51) + '\x32' + chr(49), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\062' + chr(0b11011 + 0o30) + chr(0b110101), 44511 - 44503), ehT0Px3KOsy9('\060' + chr(3899 - 3788) + chr(49) + chr(0b0 + 0o63), 3098 - 3090), ehT0Px3KOsy9(chr(0b10101 + 0o33) + '\x6f' + chr(1127 - 1077) + chr(0b110000) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(0b10100 + 0o34) + '\x6f' + chr(0b110011) + chr(51) + chr(52), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + '\061' + '\x30' + chr(0b10101 + 0o42), ord("\x08")), ehT0Px3KOsy9(chr(1586 - 1538) + chr(0b100111 + 0o110) + chr(1430 - 1381) + '\067' + chr(0b110011), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110010) + chr(0b101011 + 0o10) + chr(0b110101), 8), ehT0Px3KOsy9(chr(415 - 367) + chr(111) + chr(441 - 391) + chr(0b110010) + '\x34', 8), ehT0Px3KOsy9('\060' + chr(4438 - 4327) + chr(2417 - 2364) + chr(0b110101), 0o10), ehT0Px3KOsy9('\060' + chr(1132 - 1021) + chr(49) + chr(993 - 943) + chr(0b110110), 8), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b1000 + 0o53) + '\064' + '\064', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1001001 + 0o46) + chr(0b11110 + 0o23) + chr(1278 - 1228), 0b1000), ehT0Px3KOsy9(chr(0b111 + 0o51) + chr(8407 - 8296) + chr(0b110011) + '\x33' + chr(138 - 85), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(1730 - 1682) + chr(0b1101111) + chr(53) + chr(0b11001 + 0o27), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xd8'), chr(0b11 + 0o141) + '\x65' + chr(0b100010 + 0o101) + chr(0b10011 + 0o134) + chr(0b1100100) + chr(0b1100101))('\x75' + chr(0b1110100) + chr(0b111111 + 0o47) + chr(885 - 840) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def sNeBft6XLHIx(vXoupepMtCXU, n4ljua2gi1Pr):
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x80oD\x87\r\x19"\x84KY&\xe2\xe4\x94'), '\x64' + chr(0b100110 + 0o77) + '\143' + chr(6514 - 6403) + chr(100) + '\145')('\165' + chr(116) + '\x66' + '\055' + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x8emS\x9e\x18\x12!\x8f'), '\x64' + chr(0b1100101) + chr(99) + chr(0b100001 + 0o116) + '\144' + '\x65')(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + chr(0b101011 + 0o2) + chr(995 - 939))):
wL6S4kgnTowq = vXoupepMtCXU
if xafqLlk3kkUe(wL6S4kgnTowq.get_shape(), xafqLlk3kkUe(SXOLrMavuUCe(b'\x97}i\x82\x05\x08:'), '\x64' + chr(0b11110 + 0o107) + chr(9047 - 8948) + chr(0b1101111) + '\144' + '\145')(chr(117) + chr(9007 - 8891) + '\x66' + chr(1638 - 1593) + '\070'))()[ehT0Px3KOsy9('\060' + chr(7023 - 6912) + chr(49), 61600 - 61592)] > ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(1361 - 1310) + '\061' + chr(0b0 + 0o60), ord("\x08")):
wL6S4kgnTowq = OjUL2SkmmEKT(wL6S4kgnTowq, n4ljua2gi1Pr.qzoyXN3kdhDL)
else:
wL6S4kgnTowq = jSKPaHwSAfVv.conv_block(wL6S4kgnTowq, n4ljua2gi1Pr.qzoyXN3kdhDL, [((ehT0Px3KOsy9('\060' + '\x6f' + chr(49), 8), ehT0Px3KOsy9('\060' + chr(0b11000 + 0o127) + '\061', 8)), (ehT0Px3KOsy9(chr(923 - 875) + chr(0b1101111) + chr(0b0 + 0o63), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110011), 8)))], first_relu=ehT0Px3KOsy9(chr(0b11101 + 0o23) + '\x6f' + '\x30', 14780 - 14772), padding=xafqLlk3kkUe(SXOLrMavuUCe(b'\xa5O{\xab'), chr(0b1010101 + 0o17) + chr(101) + chr(237 - 138) + chr(0b1101111) + '\x64' + '\x65')(chr(117) + chr(0b1110100) + chr(0b1100110) + chr(0b101101) + chr(0b1101 + 0o53)), force2d=ehT0Px3KOsy9('\060' + '\157' + chr(0b110001), 8), name=xafqLlk3kkUe(SXOLrMavuUCe(b"\x85cW\x82\x00$'\x8cuM \xd2\xf7\x9e\x18\xd1"), '\144' + chr(0b1100101) + '\143' + '\x6f' + chr(0b1011110 + 0o6) + chr(0b1001001 + 0o34))(chr(1616 - 1499) + chr(0b1110100) + '\x66' + chr(0b10010 + 0o33) + chr(0b1010 + 0o56)))
for WVxHKyX45z_L in vQr8gNKaIaWE(xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x9cT^\xdb3\x0b\x02\xb4{e*\xd7'), '\144' + chr(9300 - 9199) + '\x63' + chr(0b1011001 + 0o26) + '\x64' + '\145')(chr(117) + chr(116) + chr(0b111011 + 0o53) + chr(709 - 664) + '\070'))):
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x80oD\x87\r\x19"\x84KY&\xe2\xe4\x94'), '\x64' + chr(0b1100101) + chr(0b110011 + 0o60) + '\x6f' + '\144' + chr(0b1011001 + 0o14))('\x75' + chr(116) + chr(0b1011011 + 0o13) + chr(0b10000 + 0o35) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x9aoO\x8b\x1e$k\x85'), chr(0b110 + 0o136) + chr(101) + '\143' + chr(111) + '\x64' + '\x65')('\165' + '\164' + chr(102) + chr(311 - 266) + chr(56)) % WVxHKyX45z_L):
wL6S4kgnTowq = cZzlDzj_eOt4(wL6S4kgnTowq, n4ljua2gi1Pr)
return Q5BTuICzwzhE(wL6S4kgnTowq)
|
tensorflow/tensor2tensor
|
tensor2tensor/models/xception.py
|
xception_entry
|
def xception_entry(inputs, hidden_dim):
"""Xception entry flow."""
with tf.variable_scope("xception_entry"):
def xnet_resblock(x, filters, res_relu, name):
"""Resblock."""
with tf.variable_scope(name):
y = common_layers.separable_conv_block(
x,
filters, [((1, 1), (3, 3)), ((1, 1), (3, 3))],
first_relu=True,
padding="SAME",
force2d=True,
name="sep_conv_block")
y = common_layers.pool(y, (3, 3), "MAX", "SAME", strides=(2, 2))
return y + common_layers.conv_block(
x,
filters, [((1, 1), (1, 1))],
padding="SAME",
strides=(2, 2),
first_relu=res_relu,
force2d=True,
name="res_conv0")
tf.summary.image("inputs", inputs, max_outputs=2)
x = common_layers.conv_block(
inputs,
32, [((1, 1), (3, 3))],
first_relu=False,
padding="SAME",
strides=(2, 2),
force2d=True,
name="conv0")
x = common_layers.conv_block(
x, 64, [((1, 1), (3, 3))], padding="SAME", force2d=True, name="conv1")
x = xnet_resblock(x, min(128, hidden_dim), True, "block0")
x = xnet_resblock(x, min(256, hidden_dim), False, "block1")
return xnet_resblock(x, hidden_dim, False, "block2")
|
python
|
def xception_entry(inputs, hidden_dim):
"""Xception entry flow."""
with tf.variable_scope("xception_entry"):
def xnet_resblock(x, filters, res_relu, name):
"""Resblock."""
with tf.variable_scope(name):
y = common_layers.separable_conv_block(
x,
filters, [((1, 1), (3, 3)), ((1, 1), (3, 3))],
first_relu=True,
padding="SAME",
force2d=True,
name="sep_conv_block")
y = common_layers.pool(y, (3, 3), "MAX", "SAME", strides=(2, 2))
return y + common_layers.conv_block(
x,
filters, [((1, 1), (1, 1))],
padding="SAME",
strides=(2, 2),
first_relu=res_relu,
force2d=True,
name="res_conv0")
tf.summary.image("inputs", inputs, max_outputs=2)
x = common_layers.conv_block(
inputs,
32, [((1, 1), (3, 3))],
first_relu=False,
padding="SAME",
strides=(2, 2),
force2d=True,
name="conv0")
x = common_layers.conv_block(
x, 64, [((1, 1), (3, 3))], padding="SAME", force2d=True, name="conv1")
x = xnet_resblock(x, min(128, hidden_dim), True, "block0")
x = xnet_resblock(x, min(256, hidden_dim), False, "block1")
return xnet_resblock(x, hidden_dim, False, "block2")
|
[
"def",
"xception_entry",
"(",
"inputs",
",",
"hidden_dim",
")",
":",
"with",
"tf",
".",
"variable_scope",
"(",
"\"xception_entry\"",
")",
":",
"def",
"xnet_resblock",
"(",
"x",
",",
"filters",
",",
"res_relu",
",",
"name",
")",
":",
"\"\"\"Resblock.\"\"\"",
"with",
"tf",
".",
"variable_scope",
"(",
"name",
")",
":",
"y",
"=",
"common_layers",
".",
"separable_conv_block",
"(",
"x",
",",
"filters",
",",
"[",
"(",
"(",
"1",
",",
"1",
")",
",",
"(",
"3",
",",
"3",
")",
")",
",",
"(",
"(",
"1",
",",
"1",
")",
",",
"(",
"3",
",",
"3",
")",
")",
"]",
",",
"first_relu",
"=",
"True",
",",
"padding",
"=",
"\"SAME\"",
",",
"force2d",
"=",
"True",
",",
"name",
"=",
"\"sep_conv_block\"",
")",
"y",
"=",
"common_layers",
".",
"pool",
"(",
"y",
",",
"(",
"3",
",",
"3",
")",
",",
"\"MAX\"",
",",
"\"SAME\"",
",",
"strides",
"=",
"(",
"2",
",",
"2",
")",
")",
"return",
"y",
"+",
"common_layers",
".",
"conv_block",
"(",
"x",
",",
"filters",
",",
"[",
"(",
"(",
"1",
",",
"1",
")",
",",
"(",
"1",
",",
"1",
")",
")",
"]",
",",
"padding",
"=",
"\"SAME\"",
",",
"strides",
"=",
"(",
"2",
",",
"2",
")",
",",
"first_relu",
"=",
"res_relu",
",",
"force2d",
"=",
"True",
",",
"name",
"=",
"\"res_conv0\"",
")",
"tf",
".",
"summary",
".",
"image",
"(",
"\"inputs\"",
",",
"inputs",
",",
"max_outputs",
"=",
"2",
")",
"x",
"=",
"common_layers",
".",
"conv_block",
"(",
"inputs",
",",
"32",
",",
"[",
"(",
"(",
"1",
",",
"1",
")",
",",
"(",
"3",
",",
"3",
")",
")",
"]",
",",
"first_relu",
"=",
"False",
",",
"padding",
"=",
"\"SAME\"",
",",
"strides",
"=",
"(",
"2",
",",
"2",
")",
",",
"force2d",
"=",
"True",
",",
"name",
"=",
"\"conv0\"",
")",
"x",
"=",
"common_layers",
".",
"conv_block",
"(",
"x",
",",
"64",
",",
"[",
"(",
"(",
"1",
",",
"1",
")",
",",
"(",
"3",
",",
"3",
")",
")",
"]",
",",
"padding",
"=",
"\"SAME\"",
",",
"force2d",
"=",
"True",
",",
"name",
"=",
"\"conv1\"",
")",
"x",
"=",
"xnet_resblock",
"(",
"x",
",",
"min",
"(",
"128",
",",
"hidden_dim",
")",
",",
"True",
",",
"\"block0\"",
")",
"x",
"=",
"xnet_resblock",
"(",
"x",
",",
"min",
"(",
"256",
",",
"hidden_dim",
")",
",",
"False",
",",
"\"block1\"",
")",
"return",
"xnet_resblock",
"(",
"x",
",",
"hidden_dim",
",",
"False",
",",
"\"block2\"",
")"
] |
Xception entry flow.
|
[
"Xception",
"entry",
"flow",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/xception.py#L73-L110
|
train
|
Xception entry flow.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0h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S9P6_LpdIe,sbGAZlkZOtyh,Cf_Qef15s3_F,eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\062' + '\x34' + '\x35', 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110001) + chr(55) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(1107 - 1059) + '\157' + chr(49) + '\x31' + chr(0b110000), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(374 - 323) + chr(0b101110 + 0o10) + '\x31', 27471 - 27463), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b1100 + 0o46) + chr(48) + chr(0b101000 + 0o11), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1001110 + 0o41) + '\x37' + chr(53), 46018 - 46010), ehT0Px3KOsy9(chr(48) + '\157' + '\065' + '\067', 0o10), ehT0Px3KOsy9(chr(2032 - 1984) + chr(0b1101111) + '\061' + '\064', 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110011) + '\064', ord("\x08")), ehT0Px3KOsy9(chr(1356 - 1308) + chr(0b1101111) + chr(0b101110 + 0o5) + chr(0b110001) + '\066', 60433 - 60425), ehT0Px3KOsy9('\x30' + '\157' + chr(540 - 487) + '\066', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b1010 + 0o47), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\x33' + '\x31' + chr(0b11101 + 0o32), 0o10), ehT0Px3KOsy9(chr(0b100110 + 0o12) + '\157' + '\061' + '\x32' + chr(0b11100 + 0o30), 0b1000), ehT0Px3KOsy9('\x30' + chr(4060 - 3949) + chr(0b0 + 0o63) + chr(890 - 842) + chr(1674 - 1619), ord("\x08")), ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(111) + chr(602 - 552) + chr(0b110011) + chr(0b11111 + 0o27), ord("\x08")), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(0b110110 + 0o71) + chr(0b110010) + chr(0b110100), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(49) + chr(52) + chr(55), 56206 - 56198), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(49) + '\063' + chr(972 - 917), 59162 - 59154), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110011) + chr(53) + chr(0b11110 + 0o27), 64439 - 64431), ehT0Px3KOsy9('\x30' + chr(8227 - 8116) + '\x33' + '\065' + chr(53), 8), ehT0Px3KOsy9(chr(0b10101 + 0o33) + '\x6f' + chr(0b1010 + 0o47) + chr(0b1100 + 0o46) + chr(0b1110 + 0o43), 20372 - 20364), ehT0Px3KOsy9('\x30' + chr(7441 - 7330) + '\x31' + '\x36' + chr(0b100000 + 0o25), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(51) + '\x30' + chr(0b110111), 8), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(51) + chr(0b110001) + '\x36', 8), ehT0Px3KOsy9('\060' + chr(111) + chr(50) + chr(0b101110 + 0o6) + '\x33', 0b1000), ehT0Px3KOsy9(chr(1980 - 1932) + chr(111) + '\061' + '\x31' + '\x36', 9164 - 9156), ehT0Px3KOsy9(chr(1743 - 1695) + '\x6f' + '\x33' + chr(1490 - 1441) + chr(0b110110), 8), ehT0Px3KOsy9(chr(0b10111 + 0o31) + chr(8627 - 8516) + '\063' + chr(0b10100 + 0o34) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b11001 + 0o126) + chr(0b110011) + chr(54) + '\x32', 0o10), ehT0Px3KOsy9(chr(0b101111 + 0o1) + '\157' + '\062' + chr(0b10001 + 0o43) + chr(53), 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\062' + chr(0b110111) + chr(0b1011 + 0o54), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110011) + chr(0b110111) + '\062', 25271 - 25263), ehT0Px3KOsy9('\x30' + chr(0b1011010 + 0o25) + chr(49) + chr(0b110011) + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(1971 - 1923) + '\x6f' + chr(1150 - 1099) + chr(0b1011 + 0o50) + chr(50), 0o10), ehT0Px3KOsy9(chr(2114 - 2066) + chr(0b1101111) + chr(0b110011) + chr(51) + chr(0b100000 + 0o21), 0o10), ehT0Px3KOsy9(chr(0b11010 + 0o26) + '\157' + chr(0b110001) + chr(55) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + '\x32' + chr(0b101111 + 0o3), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x31' + chr(0b100001 + 0o26) + chr(0b1000 + 0o50), 8), ehT0Px3KOsy9(chr(437 - 389) + '\x6f' + chr(474 - 423) + chr(49) + chr(0b110000), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(258 - 210) + '\x6f' + '\x35' + '\x30', 30292 - 30284)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x8b'), chr(0b1010000 + 0o24) + chr(0b1100101) + chr(99) + chr(0b1101111) + chr(0b1011100 + 0o10) + chr(0b110001 + 0o64))('\165' + chr(0b11101 + 0o127) + chr(0b1000100 + 0o42) + chr(45) + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def OjUL2SkmmEKT(vXoupepMtCXU, CQFa_cRh0Tor):
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd3\x19:\x98\xe0_CiC\xbdMn\xbf1'), '\144' + chr(7936 - 7835) + chr(8865 - 8766) + '\x6f' + '\144' + '\145')(chr(9246 - 9129) + chr(116) + chr(0b101111 + 0o67) + chr(0b101101) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xdd\x1b-\x81\xf5T@bC\xab@u\xbd-'), '\144' + '\x65' + '\x63' + chr(0b1101111) + '\x64' + chr(0b1100101))(chr(0b1010000 + 0o45) + chr(1638 - 1522) + '\x66' + '\x2d' + chr(56))):
def k5DKvlNpTmW6(OeWW0F1dBPRQ, MErh319F3bgE, _g3xQX3jJAGu, AIvJRzLdDfgF):
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd3\x19:\x98\xe0_CiC\xbdMn\xbf1'), chr(0b1100100) + chr(1683 - 1582) + chr(7000 - 6901) + chr(111) + '\144' + '\145')(chr(117) + '\164' + chr(0b1011000 + 0o16) + '\055' + chr(0b10111 + 0o41)))(AIvJRzLdDfgF):
SqiSOtYOqOJH = jSKPaHwSAfVv.separable_conv_block(OeWW0F1dBPRQ, MErh319F3bgE, [((ehT0Px3KOsy9(chr(162 - 114) + chr(111) + '\061', 8), ehT0Px3KOsy9('\060' + chr(111) + chr(49), 8)), (ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110010 + 0o1), 21124 - 21116), ehT0Px3KOsy9('\x30' + '\157' + '\x33', 8))), ((ehT0Px3KOsy9(chr(0b100110 + 0o12) + '\157' + chr(1529 - 1480), 8), ehT0Px3KOsy9(chr(772 - 724) + chr(111) + chr(49), 8)), (ehT0Px3KOsy9(chr(48) + chr(0b1010000 + 0o37) + '\063', 8), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110011), 8)))], first_relu=ehT0Px3KOsy9(chr(0b110000) + chr(0b1100100 + 0o13) + chr(0b110001), 8), padding=xafqLlk3kkUe(SXOLrMavuUCe(b'\xf69\x05\xb4'), chr(0b1100100) + chr(0b1010110 + 0o17) + chr(1898 - 1799) + chr(6378 - 6267) + chr(0b1100100) + chr(0b1100101))(chr(117) + '\x74' + chr(0b1100110) + '\055' + chr(0b11101 + 0o33)), force2d=ehT0Px3KOsy9('\060' + chr(111) + chr(1195 - 1146), 8), name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xd6\x1d8\xae\xe2RAzC\xacBn\xac?'), '\144' + chr(5398 - 5297) + chr(99) + chr(111) + chr(0b1100100) + '\x65')('\165' + '\x74' + chr(7561 - 7459) + '\x2d' + chr(0b111000)))
SqiSOtYOqOJH = jSKPaHwSAfVv.pool(SqiSOtYOqOJH, (ehT0Px3KOsy9('\x30' + chr(7629 - 7518) + '\063', 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(51), 8)), xafqLlk3kkUe(SXOLrMavuUCe(b'\xe89\x10'), chr(0b110010 + 0o62) + chr(101) + '\143' + '\157' + chr(0b1100100) + chr(0b1001001 + 0o34))(chr(0b1101000 + 0o15) + '\164' + chr(102) + '\x2d' + chr(402 - 346)), xafqLlk3kkUe(SXOLrMavuUCe(b'\xf69\x05\xb4'), chr(0b1100100) + chr(7680 - 7579) + '\x63' + chr(0b1100011 + 0o14) + chr(0b1100100) + '\x65')('\x75' + '\164' + chr(102) + chr(339 - 294) + chr(0b100111 + 0o21)), strides=(ehT0Px3KOsy9('\060' + chr(0b1101111) + '\062', 0b1000), ehT0Px3KOsy9(chr(2210 - 2162) + chr(0b1101111) + chr(0b110010), 8)))
return SqiSOtYOqOJH + xafqLlk3kkUe(jSKPaHwSAfVv, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc6\x17&\x87\xde_Cc\x7f\xa5'), chr(9711 - 9611) + chr(101) + chr(1794 - 1695) + '\x6f' + '\x64' + chr(0b1100101))('\165' + chr(7163 - 7047) + '\x66' + '\x2d' + chr(56)))(OeWW0F1dBPRQ, MErh319F3bgE, [((ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x31', 8), ehT0Px3KOsy9(chr(1282 - 1234) + chr(0b101000 + 0o107) + chr(0b110001), 8)), (ehT0Px3KOsy9('\x30' + '\157' + '\061', 8), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b11011 + 0o26), 8)))], padding=xafqLlk3kkUe(SXOLrMavuUCe(b'\xf69\x05\xb4'), chr(0b10011 + 0o121) + '\145' + chr(0b1100011) + chr(111) + chr(0b1100100) + chr(0b1010111 + 0o16))(chr(11526 - 11409) + '\164' + chr(6447 - 6345) + chr(0b10101 + 0o30) + chr(0b10101 + 0o43)), strides=(ehT0Px3KOsy9(chr(1526 - 1478) + chr(0b1101111) + chr(50), 8), ehT0Px3KOsy9('\060' + '\157' + '\062', 8)), first_relu=_g3xQX3jJAGu, force2d=ehT0Px3KOsy9('\x30' + chr(111) + '\061', 8), name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xd7\x1d;\xae\xe2RAz,'), chr(3169 - 3069) + chr(0b1100101) + chr(0b1100011) + chr(0b110011 + 0o74) + chr(100) + chr(4725 - 4624))('\165' + '\x74' + '\x66' + chr(0b101101) + chr(56)))
xafqLlk3kkUe(IDJ2eXGCBCDu.summary, xafqLlk3kkUe(SXOLrMavuUCe(b'\xec\x1c%\xb0\xc9jIOm\xbc@q'), chr(4506 - 4406) + chr(0b1100101) + '\143' + '\x6f' + chr(0b1100100) + chr(101))(chr(117) + chr(0b1110011 + 0o1) + chr(3714 - 3612) + chr(0b101101) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xcc\x168\x84\xf5N'), '\144' + '\x65' + '\143' + '\x6f' + chr(100) + '\x65')(chr(0b1110101) + '\164' + chr(4449 - 4347) + '\055' + chr(0b11001 + 0o37)), vXoupepMtCXU, max_outputs=ehT0Px3KOsy9(chr(2113 - 2065) + chr(0b1101111) + chr(0b110010), 8))
OeWW0F1dBPRQ = jSKPaHwSAfVv.conv_block(vXoupepMtCXU, ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\064' + chr(48), 0b1000), [((ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(0b1101111) + '\061', 8), ehT0Px3KOsy9(chr(1005 - 957) + chr(0b1101111) + '\061', 8)), (ehT0Px3KOsy9(chr(48) + '\157' + chr(51), 8), ehT0Px3KOsy9(chr(0b0 + 0o60) + chr(0b1101111) + chr(2392 - 2341), 8)))], first_relu=ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110000), 14623 - 14615), padding=xafqLlk3kkUe(SXOLrMavuUCe(b'\xf69\x05\xb4'), chr(0b111010 + 0o52) + chr(9920 - 9819) + '\x63' + '\157' + chr(100) + '\x65')('\165' + chr(116) + chr(0b100110 + 0o100) + chr(0b100100 + 0o11) + chr(56)), strides=(ehT0Px3KOsy9('\060' + chr(9473 - 9362) + '\x32', 8), ehT0Px3KOsy9(chr(48) + chr(111) + chr(50), 8)), force2d=ehT0Px3KOsy9(chr(0b101010 + 0o6) + chr(0b1101111) + '\x31', 8), name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xc6\x17&\x87\xb1'), chr(0b1100100) + chr(101) + chr(8142 - 8043) + chr(0b1011110 + 0o21) + chr(100) + chr(0b1100101))(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + chr(0b101101) + '\x38'))
OeWW0F1dBPRQ = jSKPaHwSAfVv.conv_block(OeWW0F1dBPRQ, ehT0Px3KOsy9('\060' + '\157' + '\x31' + '\060' + '\060', 0b1000), [((ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(1121 - 1072), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110001), 8)), (ehT0Px3KOsy9(chr(774 - 726) + '\x6f' + chr(380 - 329), 8), ehT0Px3KOsy9(chr(48) + '\157' + '\063', 8)))], padding=xafqLlk3kkUe(SXOLrMavuUCe(b'\xf69\x05\xb4'), chr(100) + chr(0b1001000 + 0o35) + chr(4168 - 4069) + '\157' + '\144' + chr(4560 - 4459))(chr(0b1110101 + 0o0) + chr(0b1110100) + chr(10006 - 9904) + '\x2d' + chr(0b10000 + 0o50)), force2d=ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x31', 8), name=xafqLlk3kkUe(SXOLrMavuUCe(b'\xc6\x17&\x87\xb0'), chr(0b1100100) + chr(7486 - 7385) + chr(3575 - 3476) + chr(111) + chr(100) + chr(0b1100101))(chr(117) + chr(1438 - 1322) + chr(0b1100110) + chr(0b101101) + chr(0b11000 + 0o40)))
OeWW0F1dBPRQ = k5DKvlNpTmW6(OeWW0F1dBPRQ, Dx22bkKPdt5d(ehT0Px3KOsy9(chr(781 - 733) + '\x6f' + chr(261 - 211) + '\060' + chr(48), 0b1000), CQFa_cRh0Tor), ehT0Px3KOsy9('\x30' + chr(6946 - 6835) + chr(0b110 + 0o53), 8), xafqLlk3kkUe(SXOLrMavuUCe(b"\xc7\x14'\x92\xea\r"), chr(9890 - 9790) + '\145' + chr(8772 - 8673) + '\157' + chr(5711 - 5611) + chr(1219 - 1118))(chr(0b110000 + 0o105) + '\x74' + '\x66' + chr(0b10011 + 0o32) + chr(0b111000)))
OeWW0F1dBPRQ = k5DKvlNpTmW6(OeWW0F1dBPRQ, Dx22bkKPdt5d(ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110100) + '\060' + '\x30', 0b1000), CQFa_cRh0Tor), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(0b101101 + 0o102) + chr(0b110000), 8), xafqLlk3kkUe(SXOLrMavuUCe(b"\xc7\x14'\x92\xea\x0c"), chr(0b1100100) + chr(6055 - 5954) + '\143' + '\x6f' + '\144' + chr(101))('\x75' + chr(0b11 + 0o161) + '\146' + chr(45) + chr(0b111000)))
return k5DKvlNpTmW6(OeWW0F1dBPRQ, CQFa_cRh0Tor, ehT0Px3KOsy9('\x30' + '\x6f' + chr(48), 8), xafqLlk3kkUe(SXOLrMavuUCe(b"\xc7\x14'\x92\xea\x0f"), '\144' + '\145' + chr(6518 - 6419) + '\x6f' + chr(0b1001101 + 0o27) + chr(928 - 827))('\x75' + '\164' + '\x66' + chr(45) + '\x38'))
|
tensorflow/tensor2tensor
|
tensor2tensor/models/xception.py
|
xception_exit
|
def xception_exit(inputs):
"""Xception exit flow."""
with tf.variable_scope("xception_exit"):
x = inputs
x_shape = x.get_shape().as_list()
if x_shape[1] is None or x_shape[2] is None:
length_float = tf.to_float(tf.shape(x)[1])
length_float *= tf.to_float(tf.shape(x)[2])
spatial_dim_float = tf.sqrt(length_float)
spatial_dim = tf.to_int32(spatial_dim_float)
x_depth = x_shape[3]
x = tf.reshape(x, [-1, spatial_dim, spatial_dim, x_depth])
elif x_shape[1] != x_shape[2]:
spatial_dim = int(math.sqrt(float(x_shape[1] * x_shape[2])))
if spatial_dim * spatial_dim != x_shape[1] * x_shape[2]:
raise ValueError("Assumed inputs were square-able but they were "
"not. Shape: %s" % x_shape)
x = tf.reshape(x, [-1, spatial_dim, spatial_dim, x_depth])
x = common_layers.conv_block_downsample(x, (3, 3), (2, 2), "SAME")
return tf.nn.relu(x)
|
python
|
def xception_exit(inputs):
"""Xception exit flow."""
with tf.variable_scope("xception_exit"):
x = inputs
x_shape = x.get_shape().as_list()
if x_shape[1] is None or x_shape[2] is None:
length_float = tf.to_float(tf.shape(x)[1])
length_float *= tf.to_float(tf.shape(x)[2])
spatial_dim_float = tf.sqrt(length_float)
spatial_dim = tf.to_int32(spatial_dim_float)
x_depth = x_shape[3]
x = tf.reshape(x, [-1, spatial_dim, spatial_dim, x_depth])
elif x_shape[1] != x_shape[2]:
spatial_dim = int(math.sqrt(float(x_shape[1] * x_shape[2])))
if spatial_dim * spatial_dim != x_shape[1] * x_shape[2]:
raise ValueError("Assumed inputs were square-able but they were "
"not. Shape: %s" % x_shape)
x = tf.reshape(x, [-1, spatial_dim, spatial_dim, x_depth])
x = common_layers.conv_block_downsample(x, (3, 3), (2, 2), "SAME")
return tf.nn.relu(x)
|
[
"def",
"xception_exit",
"(",
"inputs",
")",
":",
"with",
"tf",
".",
"variable_scope",
"(",
"\"xception_exit\"",
")",
":",
"x",
"=",
"inputs",
"x_shape",
"=",
"x",
".",
"get_shape",
"(",
")",
".",
"as_list",
"(",
")",
"if",
"x_shape",
"[",
"1",
"]",
"is",
"None",
"or",
"x_shape",
"[",
"2",
"]",
"is",
"None",
":",
"length_float",
"=",
"tf",
".",
"to_float",
"(",
"tf",
".",
"shape",
"(",
"x",
")",
"[",
"1",
"]",
")",
"length_float",
"*=",
"tf",
".",
"to_float",
"(",
"tf",
".",
"shape",
"(",
"x",
")",
"[",
"2",
"]",
")",
"spatial_dim_float",
"=",
"tf",
".",
"sqrt",
"(",
"length_float",
")",
"spatial_dim",
"=",
"tf",
".",
"to_int32",
"(",
"spatial_dim_float",
")",
"x_depth",
"=",
"x_shape",
"[",
"3",
"]",
"x",
"=",
"tf",
".",
"reshape",
"(",
"x",
",",
"[",
"-",
"1",
",",
"spatial_dim",
",",
"spatial_dim",
",",
"x_depth",
"]",
")",
"elif",
"x_shape",
"[",
"1",
"]",
"!=",
"x_shape",
"[",
"2",
"]",
":",
"spatial_dim",
"=",
"int",
"(",
"math",
".",
"sqrt",
"(",
"float",
"(",
"x_shape",
"[",
"1",
"]",
"*",
"x_shape",
"[",
"2",
"]",
")",
")",
")",
"if",
"spatial_dim",
"*",
"spatial_dim",
"!=",
"x_shape",
"[",
"1",
"]",
"*",
"x_shape",
"[",
"2",
"]",
":",
"raise",
"ValueError",
"(",
"\"Assumed inputs were square-able but they were \"",
"\"not. Shape: %s\"",
"%",
"x_shape",
")",
"x",
"=",
"tf",
".",
"reshape",
"(",
"x",
",",
"[",
"-",
"1",
",",
"spatial_dim",
",",
"spatial_dim",
",",
"x_depth",
"]",
")",
"x",
"=",
"common_layers",
".",
"conv_block_downsample",
"(",
"x",
",",
"(",
"3",
",",
"3",
")",
",",
"(",
"2",
",",
"2",
")",
",",
"\"SAME\"",
")",
"return",
"tf",
".",
"nn",
".",
"relu",
"(",
"x",
")"
] |
Xception exit flow.
|
[
"Xception",
"exit",
"flow",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/xception.py#L113-L133
|
train
|
Xception exit flow.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,R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PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + '\157' + chr(1772 - 1721) + '\063' + chr(1299 - 1244), 0o10), ehT0Px3KOsy9('\x30' + chr(1760 - 1649) + chr(723 - 673) + '\063' + '\x33', 0o10), ehT0Px3KOsy9('\060' + '\157' + chr(0b110001) + '\061' + chr(0b11001 + 0o35), ord("\x08")), ehT0Px3KOsy9(chr(0b101101 + 0o3) + '\x6f' + chr(0b101010 + 0o14) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(0b1100 + 0o44) + '\157' + chr(2296 - 2247) + chr(0b110001) + chr(0b101111 + 0o4), 0b1000), ehT0Px3KOsy9(chr(1993 - 1945) + chr(0b1011100 + 0o23) + chr(0b110011) + chr(67 - 15) + chr(0b1001 + 0o47), 0o10), ehT0Px3KOsy9(chr(1659 - 1611) + chr(0b1010010 + 0o35) + '\062' + '\x37' + '\064', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(53) + '\064', ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + '\x33' + '\x37' + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + '\062' + '\065' + chr(0b110111), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b101 + 0o152) + chr(0b100011 + 0o24) + chr(50), 5791 - 5783), ehT0Px3KOsy9(chr(48) + '\157' + chr(1754 - 1704) + chr(48) + '\060', 11577 - 11569), ehT0Px3KOsy9(chr(1392 - 1344) + chr(0b1010010 + 0o35) + chr(0b100 + 0o56) + chr(795 - 747) + chr(55), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b1001 + 0o52) + '\060' + '\063', 0b1000), ehT0Px3KOsy9('\060' + '\157' + '\062' + chr(1317 - 1267) + '\061', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b110100 + 0o73) + chr(55), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(1240 - 1190) + '\x32' + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(1657 - 1609) + '\157' + chr(973 - 922) + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(1707 - 1659) + chr(0b1101100 + 0o3) + chr(0b1011 + 0o46) + chr(0b100010 + 0o21) + chr(684 - 634), 0o10), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(11307 - 11196) + chr(520 - 471) + '\x33' + chr(1988 - 1940), 52726 - 52718), ehT0Px3KOsy9(chr(533 - 485) + '\157' + chr(0b101011 + 0o6) + chr(0b100100 + 0o20) + chr(50), 51258 - 51250), ehT0Px3KOsy9('\060' + '\157' + chr(0b110001) + chr(50) + '\061', 46590 - 46582), ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(0b1101111) + chr(0b110010) + '\x31' + '\060', ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(0b110010) + '\x37', 9600 - 9592), ehT0Px3KOsy9(chr(0b100000 + 0o20) + '\x6f' + chr(0b1 + 0o62) + '\062' + chr(48), 21093 - 21085), ehT0Px3KOsy9(chr(1731 - 1683) + '\x6f' + chr(0b100 + 0o57) + chr(0b1011 + 0o51) + chr(1967 - 1919), 8), ehT0Px3KOsy9(chr(0b101101 + 0o3) + '\157' + chr(0b110001) + '\064' + '\061', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b100 + 0o57) + chr(0b101111 + 0o2) + chr(0b101000 + 0o10), 37093 - 37085), ehT0Px3KOsy9(chr(48) + '\157' + chr(2399 - 2349) + chr(55) + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(1724 - 1676) + chr(0b111111 + 0o60) + chr(1917 - 1866) + chr(0b110100) + chr(51), 7146 - 7138), ehT0Px3KOsy9(chr(2049 - 2001) + chr(0b1011010 + 0o25) + chr(0b10111 + 0o34) + chr(0b110111) + chr(1111 - 1061), 418 - 410), ehT0Px3KOsy9(chr(48) + '\157' + chr(50) + '\x34' + '\x30', 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(882 - 833) + chr(2010 - 1961) + '\065', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110001) + chr(805 - 754) + chr(53), 14491 - 14483), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(49) + '\060' + chr(2374 - 2324), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x32' + chr(0b110110) + '\063', 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110011) + chr(0b100010 + 0o17) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110011) + chr(48) + '\062', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x33' + chr(0b110001) + '\x36', 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + '\x31' + '\x34' + chr(0b110110), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b100001 + 0o24) + '\x30', 59481 - 59473)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xf1'), '\144' + chr(0b111111 + 0o46) + chr(0b1100011) + chr(111) + chr(0b1100100) + chr(0b1100101))(chr(0b11000 + 0o135) + '\164' + chr(0b1100110) + chr(0b101101) + chr(223 - 167)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def Q5BTuICzwzhE(vXoupepMtCXU):
with xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\xa9\xfa<^*\x82\xd0I\xa7\xdcY\xef\xf7\xa6'), chr(0b1100100) + chr(0b1011111 + 0o6) + '\x63' + chr(111) + chr(0b1100100) + chr(0b101010 + 0o73))(chr(0b1110101) + '\x74' + chr(0b10101 + 0o121) + chr(45) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xa7\xf8+G?\x89\xd3B\xa7\xcaB\xe9\xf3'), chr(100) + chr(0b11100 + 0o111) + chr(1525 - 1426) + chr(111) + chr(0b1100100) + chr(0b11111 + 0o106))('\x75' + chr(116) + chr(102) + chr(0b101101) + '\070')):
OeWW0F1dBPRQ = vXoupepMtCXU
QQEXXbdZyz6m = OeWW0F1dBPRQ.get_shape().as_list()
if QQEXXbdZyz6m[ehT0Px3KOsy9('\060' + chr(111) + chr(2136 - 2087), ord("\x08"))] is None or QQEXXbdZyz6m[ehT0Px3KOsy9(chr(0b110000) + chr(11658 - 11547) + chr(0b110010), 65052 - 65044)] is None:
QVuZElFpeQK_ = IDJ2eXGCBCDu.to_float(IDJ2eXGCBCDu.nauYfLglTpcb(OeWW0F1dBPRQ)[ehT0Px3KOsy9(chr(0b110000) + chr(6577 - 6466) + '\061', 8)])
QVuZElFpeQK_ *= IDJ2eXGCBCDu.to_float(IDJ2eXGCBCDu.nauYfLglTpcb(OeWW0F1dBPRQ)[ehT0Px3KOsy9('\x30' + chr(0b1100100 + 0o13) + chr(0b110010), 8)])
d1OJmiEKnpiE = IDJ2eXGCBCDu.sqrt(QVuZElFpeQK_)
_zBvckjW_WK6 = IDJ2eXGCBCDu.to_int32(d1OJmiEKnpiE)
F9eiQLMxgGax = QQEXXbdZyz6m[ehT0Px3KOsy9(chr(48) + chr(702 - 591) + '\x33', 0b1000)]
OeWW0F1dBPRQ = IDJ2eXGCBCDu.reshape(OeWW0F1dBPRQ, [-ehT0Px3KOsy9(chr(0b110000) + chr(0b1101 + 0o142) + '\x31', 8), _zBvckjW_WK6, _zBvckjW_WK6, F9eiQLMxgGax])
elif QQEXXbdZyz6m[ehT0Px3KOsy9('\060' + chr(6014 - 5903) + chr(49), 8)] != QQEXXbdZyz6m[ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b1111 + 0o43), 8)]:
_zBvckjW_WK6 = ehT0Px3KOsy9(yhiZVkosCjBm.sqrt(kkSX4ccExqw4(QQEXXbdZyz6m[ehT0Px3KOsy9(chr(0b100111 + 0o11) + '\157' + chr(49), 8)] * QQEXXbdZyz6m[ehT0Px3KOsy9(chr(0b110000) + chr(1695 - 1584) + chr(0b110010), 8)])))
if _zBvckjW_WK6 * _zBvckjW_WK6 != QQEXXbdZyz6m[ehT0Px3KOsy9('\060' + chr(111) + chr(49), 8)] * QQEXXbdZyz6m[ehT0Px3KOsy9(chr(2184 - 2136) + '\x6f' + '\x32', 8)]:
raise q1QCh3W88sgk(xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e\xe8=B&\x85\xd8\x0c\x91\xc1J\xf5\xf3\xb0\xb1p\xf1k?x\x11 \xfdv\xa2\x85L\xa9\xd8\x8f\x9f\x80/(6\x93\xbf\xaa\xab\x1f\xff\xec+E.\xc0\xd2C\x8c\x81\x1a\xd3\xef\xa2\xe1b\xae9\x7f+'), '\144' + '\x65' + '\x63' + chr(0b1101111) + chr(0b1100100) + chr(0b1010111 + 0o16))('\x75' + chr(0b1110100) + '\x66' + '\055' + chr(56)) % QQEXXbdZyz6m)
OeWW0F1dBPRQ = IDJ2eXGCBCDu.reshape(OeWW0F1dBPRQ, [-ehT0Px3KOsy9(chr(1268 - 1220) + '\x6f' + '\x31', 8), _zBvckjW_WK6, _zBvckjW_WK6, F9eiQLMxgGax])
OeWW0F1dBPRQ = jSKPaHwSAfVv.conv_block_downsample(OeWW0F1dBPRQ, (ehT0Px3KOsy9(chr(48) + '\157' + chr(0b100100 + 0o17), 8), ehT0Px3KOsy9(chr(2147 - 2099) + chr(4252 - 4141) + chr(0b110011), 8)), (ehT0Px3KOsy9(chr(0b100010 + 0o16) + '\157' + chr(0b100001 + 0o21), 8), ehT0Px3KOsy9(chr(0b10100 + 0o34) + chr(0b101100 + 0o103) + '\062', 8)), xafqLlk3kkUe(SXOLrMavuUCe(b'\x8c\xda\x03r'), '\144' + '\145' + chr(0b1011110 + 0o5) + chr(0b1100010 + 0o15) + chr(100) + chr(0b1100101))(chr(117) + '\164' + '\146' + chr(2003 - 1958) + chr(56)))
return xafqLlk3kkUe(IDJ2eXGCBCDu.nn, xafqLlk3kkUe(SXOLrMavuUCe(b'\xad\xfe"B'), '\144' + chr(101) + chr(0b1100011) + chr(3706 - 3595) + chr(1844 - 1744) + chr(0b1100101))(chr(0b1011001 + 0o34) + '\x74' + chr(0b1101 + 0o131) + '\055' + chr(0b111000)))(OeWW0F1dBPRQ)
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/wikisum/html.py
|
get_text_from_html
|
def get_text_from_html(html):
"""Returns a plaintext representation of HTML content."""
try:
soup = bs4.BeautifulSoup(html, "html.parser")
except: # pylint: disable=bare-except
# Some docs don't parse
return ""
# Remove script and style tags
for s in soup(["script", "style"]):
s.decompose()
return "\n".join([s for s in _soup_strings(soup)])
|
python
|
def get_text_from_html(html):
"""Returns a plaintext representation of HTML content."""
try:
soup = bs4.BeautifulSoup(html, "html.parser")
except: # pylint: disable=bare-except
# Some docs don't parse
return ""
# Remove script and style tags
for s in soup(["script", "style"]):
s.decompose()
return "\n".join([s for s in _soup_strings(soup)])
|
[
"def",
"get_text_from_html",
"(",
"html",
")",
":",
"try",
":",
"soup",
"=",
"bs4",
".",
"BeautifulSoup",
"(",
"html",
",",
"\"html.parser\"",
")",
"except",
":",
"# pylint: disable=bare-except",
"# Some docs don't parse",
"return",
"\"\"",
"# Remove script and style tags",
"for",
"s",
"in",
"soup",
"(",
"[",
"\"script\"",
",",
"\"style\"",
"]",
")",
":",
"s",
".",
"decompose",
"(",
")",
"return",
"\"\\n\"",
".",
"join",
"(",
"[",
"s",
"for",
"s",
"in",
"_soup_strings",
"(",
"soup",
")",
"]",
")"
] |
Returns a plaintext representation of HTML content.
|
[
"Returns",
"a",
"plaintext",
"representation",
"of",
"HTML",
"content",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/wikisum/html.py#L21-L32
|
train
|
Returns a plaintext representation of HTML content.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6L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3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x32' + chr(2770 - 2717) + '\x37', 0o10), ehT0Px3KOsy9(chr(0b10100 + 0o34) + chr(111) + chr(0b110001) + '\062' + '\067', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(5694 - 5583) + chr(0b1000 + 0o51) + chr(55) + '\066', 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110010) + '\x33' + chr(399 - 346), 0o10), ehT0Px3KOsy9(chr(0b1111 + 0o41) + chr(0b1000010 + 0o55) + chr(0b1010 + 0o51) + chr(0b100101 + 0o14) + chr(54), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x31' + chr(606 - 553) + '\x33', ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(983 - 933) + chr(0b110010) + chr(0b10111 + 0o35), ord("\x08")), ehT0Px3KOsy9(chr(732 - 684) + '\x6f' + '\063' + chr(1825 - 1774) + '\063', 65146 - 65138), ehT0Px3KOsy9('\060' + chr(4108 - 3997) + chr(0b1 + 0o62) + chr(0b110101) + chr(0b110100), 26445 - 26437), ehT0Px3KOsy9(chr(0b100111 + 0o11) + chr(8592 - 8481) + '\061' + chr(0b110001) + chr(0b110000), 29012 - 29004), ehT0Px3KOsy9(chr(0b11100 + 0o24) + chr(0b101100 + 0o103) + chr(0b110101) + '\066', ord("\x08")), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b110111 + 0o70) + chr(0b110010) + '\x35' + '\x33', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1100 + 0o143) + chr(341 - 292) + chr(0b101011 + 0o11) + '\065', 38114 - 38106), ehT0Px3KOsy9('\x30' + chr(9670 - 9559) + chr(0b11101 + 0o26) + '\062' + '\x35', 35660 - 35652), ehT0Px3KOsy9('\060' + chr(8156 - 8045) + chr(51) + '\x34' + chr(0b110111), 37190 - 37182), ehT0Px3KOsy9(chr(0b10111 + 0o31) + chr(111) + '\063' + '\063' + '\067', ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + '\062' + '\067' + chr(0b110110), 0o10), ehT0Px3KOsy9('\060' + chr(2690 - 2579) + '\x32' + '\066' + '\061', ord("\x08")), ehT0Px3KOsy9('\060' + chr(3387 - 3276) + '\x35' + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(561 - 513) + chr(0b1101111) + chr(2396 - 2345) + '\062' + chr(2679 - 2627), ord("\x08")), ehT0Px3KOsy9(chr(0b100 + 0o54) + '\157' + '\x34', ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(0b11111 + 0o22) + chr(54) + chr(0b101 + 0o61), 0b1000), ehT0Px3KOsy9(chr(977 - 929) + chr(0b1101111) + '\x35' + chr(717 - 664), 8), ehT0Px3KOsy9('\x30' + chr(0b1010 + 0o145) + chr(0b11110 + 0o24) + '\x30', 18215 - 18207), ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(7855 - 7744) + chr(1877 - 1828) + '\x37', 11440 - 11432), ehT0Px3KOsy9(chr(48) + chr(0b110110 + 0o71) + '\062' + chr(0b110001) + '\063', 25145 - 25137), ehT0Px3KOsy9(chr(1683 - 1635) + chr(8368 - 8257) + chr(806 - 757) + chr(843 - 792) + chr(0b110000 + 0o6), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + '\x32' + chr(0b110100) + chr(0b111 + 0o53), 63480 - 63472), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110010) + '\063' + chr(50), 29224 - 29216), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b1100 + 0o47) + chr(0b11101 + 0o26) + chr(0b101 + 0o56), 8), ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(0b1101111) + chr(49) + '\060' + chr(0b100 + 0o54), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(50) + chr(0b100101 + 0o14) + chr(0b10101 + 0o34), 10865 - 10857), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110011) + chr(0b110010) + '\064', 8), ehT0Px3KOsy9('\x30' + chr(111) + '\061' + '\067' + '\x37', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(926 - 872) + chr(1201 - 1152), 24780 - 24772), ehT0Px3KOsy9(chr(48) + chr(0b101111 + 0o100) + chr(0b101 + 0o55) + '\x35' + chr(55), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x31' + chr(50) + chr(1792 - 1739), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b111110 + 0o61) + '\x34' + '\x35', ord("\x08")), ehT0Px3KOsy9(chr(1668 - 1620) + chr(0b1101111) + chr(2037 - 1982) + chr(0b100100 + 0o22), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(1246 - 1196) + chr(54) + chr(1237 - 1189), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(1592 - 1544) + '\157' + '\065' + chr(0b100100 + 0o14), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x81'), chr(5082 - 4982) + chr(0b1 + 0o144) + chr(2944 - 2845) + chr(7889 - 7778) + '\x64' + chr(5505 - 5404))(chr(0b1110101) + '\x74' + '\x66' + chr(1919 - 1874) + chr(3108 - 3052)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def vjtjCP7HE96f(kK5tVZVlLKWY):
try:
AHeGGzU27gv8 = YxIZF_gKiU8w.BeautifulSoup(kK5tVZVlLKWY, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7#\x13\xf1\xe0\x1b\xf5\xa9\x9f-\\'), chr(9020 - 8920) + chr(101) + chr(0b10111 + 0o114) + '\157' + chr(0b1100100) + chr(5681 - 5580))('\x75' + chr(0b1110100) + '\x66' + chr(45) + chr(0b110101 + 0o3)))
except ZVWAAMjVVHHl:
return xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(100) + '\145' + '\x63' + chr(0b1000101 + 0o52) + chr(0b1100100) + chr(9327 - 9226))(chr(0b1110101) + '\x74' + chr(0b1100110) + chr(45) + '\070')
for vGrByMSYMp9h in AHeGGzU27gv8([xafqLlk3kkUe(SXOLrMavuUCe(b'\xdc4\x0c\xf4\xbe\x1f'), chr(0b0 + 0o144) + chr(0b1100101) + chr(0b1100011) + chr(0b1100101 + 0o12) + chr(0b1100100) + '\145')(chr(0b1110101) + chr(0b1110100) + chr(102) + chr(0b101101) + '\x38'), xafqLlk3kkUe(SXOLrMavuUCe(b'\xdc#\x07\xf1\xab'), chr(4519 - 4419) + chr(7137 - 7036) + chr(6290 - 6191) + chr(0b1011100 + 0o23) + chr(8040 - 7940) + chr(123 - 22))(chr(5784 - 5667) + chr(2859 - 2743) + chr(1318 - 1216) + chr(293 - 248) + chr(0b1000 + 0o60))]):
xafqLlk3kkUe(vGrByMSYMp9h, xafqLlk3kkUe(SXOLrMavuUCe(b'\xcb2\x1d\xf2\xa3\x1b\xfb\xa8\x89'), chr(5277 - 5177) + '\145' + chr(4215 - 4116) + '\157' + chr(4234 - 4134) + chr(0b111011 + 0o52))('\165' + '\x74' + '\x66' + chr(45) + chr(56)))()
return xafqLlk3kkUe(xafqLlk3kkUe(SXOLrMavuUCe(b'\xa5'), chr(100) + chr(0b1100101) + chr(0b1100011) + '\157' + '\x64' + chr(0b10011 + 0o122))(chr(117) + '\164' + '\x66' + chr(45) + '\070'), xafqLlk3kkUe(SXOLrMavuUCe(b'\xc58\x17\xf3'), chr(100) + '\x65' + chr(0b1001101 + 0o26) + '\x6f' + '\x64' + chr(0b1100101))('\x75' + chr(9041 - 8925) + chr(8222 - 8120) + chr(1318 - 1273) + '\x38'))([vGrByMSYMp9h for vGrByMSYMp9h in ibmZRtpX0TAe(AHeGGzU27gv8)])
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/wikisum/html.py
|
_soup_strings
|
def _soup_strings(soup):
"""Return text strings in soup."""
paragraph_tags = set([
"caption", "details", "h1", "h2", "h3", "h4", "h5", "h6", "li", "p", "td",
"div", "span"
])
skip_children = None
for descendant in soup.descendants:
# If we've treated a tag as a contiguous paragraph, don't re-emit the
# children (see below).
if skip_children is not None:
try:
in_skip = descendant in skip_children # pylint: disable=unsupported-membership-test
except RecursionError: # pylint: disable=undefined-variable
# Possible for this check to hit a nasty infinite recursion because of
# BeautifulSoup __eq__ checks.
in_skip = True
if in_skip:
continue
else:
skip_children = None
# Treat some tags as contiguous paragraphs, regardless of other tags nested
# inside (like <a> or <b>).
if isinstance(descendant, bs4.Tag):
if descendant.name in paragraph_tags:
if descendant.find_all(paragraph_tags):
# If there are nested paragraph tags, don't treat it as a single
# contiguous tag.
continue
skip_children = list(descendant.descendants)
text = " ".join(descendant.get_text(" ", strip=True).split())
if text:
yield text
continue
if (isinstance(descendant, bs4.Comment) or
not isinstance(descendant, bs4.NavigableString)):
continue
text = " ".join(descendant.strip().split())
if text:
yield text
|
python
|
def _soup_strings(soup):
"""Return text strings in soup."""
paragraph_tags = set([
"caption", "details", "h1", "h2", "h3", "h4", "h5", "h6", "li", "p", "td",
"div", "span"
])
skip_children = None
for descendant in soup.descendants:
# If we've treated a tag as a contiguous paragraph, don't re-emit the
# children (see below).
if skip_children is not None:
try:
in_skip = descendant in skip_children # pylint: disable=unsupported-membership-test
except RecursionError: # pylint: disable=undefined-variable
# Possible for this check to hit a nasty infinite recursion because of
# BeautifulSoup __eq__ checks.
in_skip = True
if in_skip:
continue
else:
skip_children = None
# Treat some tags as contiguous paragraphs, regardless of other tags nested
# inside (like <a> or <b>).
if isinstance(descendant, bs4.Tag):
if descendant.name in paragraph_tags:
if descendant.find_all(paragraph_tags):
# If there are nested paragraph tags, don't treat it as a single
# contiguous tag.
continue
skip_children = list(descendant.descendants)
text = " ".join(descendant.get_text(" ", strip=True).split())
if text:
yield text
continue
if (isinstance(descendant, bs4.Comment) or
not isinstance(descendant, bs4.NavigableString)):
continue
text = " ".join(descendant.strip().split())
if text:
yield text
|
[
"def",
"_soup_strings",
"(",
"soup",
")",
":",
"paragraph_tags",
"=",
"set",
"(",
"[",
"\"caption\"",
",",
"\"details\"",
",",
"\"h1\"",
",",
"\"h2\"",
",",
"\"h3\"",
",",
"\"h4\"",
",",
"\"h5\"",
",",
"\"h6\"",
",",
"\"li\"",
",",
"\"p\"",
",",
"\"td\"",
",",
"\"div\"",
",",
"\"span\"",
"]",
")",
"skip_children",
"=",
"None",
"for",
"descendant",
"in",
"soup",
".",
"descendants",
":",
"# If we've treated a tag as a contiguous paragraph, don't re-emit the",
"# children (see below).",
"if",
"skip_children",
"is",
"not",
"None",
":",
"try",
":",
"in_skip",
"=",
"descendant",
"in",
"skip_children",
"# pylint: disable=unsupported-membership-test",
"except",
"RecursionError",
":",
"# pylint: disable=undefined-variable",
"# Possible for this check to hit a nasty infinite recursion because of",
"# BeautifulSoup __eq__ checks.",
"in_skip",
"=",
"True",
"if",
"in_skip",
":",
"continue",
"else",
":",
"skip_children",
"=",
"None",
"# Treat some tags as contiguous paragraphs, regardless of other tags nested",
"# inside (like <a> or <b>).",
"if",
"isinstance",
"(",
"descendant",
",",
"bs4",
".",
"Tag",
")",
":",
"if",
"descendant",
".",
"name",
"in",
"paragraph_tags",
":",
"if",
"descendant",
".",
"find_all",
"(",
"paragraph_tags",
")",
":",
"# If there are nested paragraph tags, don't treat it as a single",
"# contiguous tag.",
"continue",
"skip_children",
"=",
"list",
"(",
"descendant",
".",
"descendants",
")",
"text",
"=",
"\" \"",
".",
"join",
"(",
"descendant",
".",
"get_text",
"(",
"\" \"",
",",
"strip",
"=",
"True",
")",
".",
"split",
"(",
")",
")",
"if",
"text",
":",
"yield",
"text",
"continue",
"if",
"(",
"isinstance",
"(",
"descendant",
",",
"bs4",
".",
"Comment",
")",
"or",
"not",
"isinstance",
"(",
"descendant",
",",
"bs4",
".",
"NavigableString",
")",
")",
":",
"continue",
"text",
"=",
"\" \"",
".",
"join",
"(",
"descendant",
".",
"strip",
"(",
")",
".",
"split",
"(",
")",
")",
"if",
"text",
":",
"yield",
"text"
] |
Return text strings in soup.
|
[
"Return",
"text",
"strings",
"in",
"soup",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/wikisum/html.py#L35-L78
|
train
|
Yields text strings in soup.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Q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hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(11671 - 11560) + chr(0b1110 + 0o51) + '\x34', ord("\x08")), ehT0Px3KOsy9(chr(49 - 1) + chr(0b100001 + 0o116) + chr(0b110011) + chr(48) + '\x30', 0b1000), ehT0Px3KOsy9(chr(0b101110 + 0o2) + '\157' + '\063' + '\x33' + '\067', ord("\x08")), ehT0Px3KOsy9(chr(1601 - 1553) + chr(8185 - 8074) + chr(737 - 686) + chr(530 - 477) + chr(0b110110), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1011101 + 0o22) + '\x33' + chr(51) + chr(0b10101 + 0o36), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(52 - 3) + '\067' + chr(485 - 435), 0o10), ehT0Px3KOsy9(chr(419 - 371) + '\157' + chr(1356 - 1305) + '\061' + '\x32', 27622 - 27614), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(312 - 263) + chr(320 - 271) + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(111) + chr(49) + chr(52), 8984 - 8976), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110011) + '\x32' + chr(0b110100), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\063' + chr(0b110010) + '\064', 8), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(50) + '\x32' + chr(54), 0b1000), ehT0Px3KOsy9(chr(1722 - 1674) + chr(0b101010 + 0o105) + chr(50) + chr(51), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(54) + chr(0b100111 + 0o11), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110010) + chr(0b110000 + 0o7) + chr(1493 - 1443), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b111001 + 0o66) + chr(0b110011) + chr(0b10000 + 0o42) + chr(2061 - 2010), ord("\x08")), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(0b111011 + 0o64) + '\062' + '\064' + '\x30', 7103 - 7095), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110001) + '\067' + chr(48), 3831 - 3823), ehT0Px3KOsy9(chr(48) + chr(11871 - 11760) + '\062' + chr(0b110100 + 0o0), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x31' + chr(0b100100 + 0o21) + chr(2282 - 2229), 0o10), ehT0Px3KOsy9('\060' + chr(0b1011000 + 0o27) + chr(1974 - 1923) + chr(55) + chr(0b10011 + 0o35), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(4947 - 4836) + chr(0b11 + 0o60) + chr(0b110010) + '\061', 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\066' + chr(55), 0o10), ehT0Px3KOsy9(chr(1719 - 1671) + chr(9734 - 9623) + chr(0b100110 + 0o21), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1001100 + 0o43) + chr(49) + '\066' + chr(0b101 + 0o55), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(1150 - 1101) + chr(0b101111 + 0o5), 8), ehT0Px3KOsy9(chr(0b10001 + 0o37) + chr(0b101111 + 0o100) + chr(0b100000 + 0o21) + chr(0b11101 + 0o26) + '\x33', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b100100 + 0o15) + chr(49) + '\x31', 63005 - 62997), ehT0Px3KOsy9(chr(48) + chr(0b11000 + 0o127) + chr(1040 - 991) + '\x31' + chr(48), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(50) + '\067' + chr(53), 50363 - 50355), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(1765 - 1716) + chr(48) + chr(49), 62212 - 62204), ehT0Px3KOsy9('\060' + chr(0b100 + 0o153) + '\062' + chr(274 - 221) + chr(0b110010), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(1904 - 1854) + '\064' + '\x36', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1011 + 0o144) + chr(0b1011 + 0o54) + chr(978 - 930), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(49) + '\066' + chr(48), 0o10), ehT0Px3KOsy9(chr(0b11 + 0o55) + '\x6f' + chr(0b110001) + '\x34' + chr(54), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110011) + chr(0b110010) + '\063', 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x31' + chr(0b11000 + 0o33), 63906 - 63898), ehT0Px3KOsy9('\060' + chr(111) + chr(50) + chr(0b110010) + chr(381 - 333), 42109 - 42101), ehT0Px3KOsy9('\060' + '\x6f' + '\x31' + '\066' + '\x30', 8)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(829 - 781) + chr(0b1101111) + '\x35' + chr(0b110000), 1324 - 1316)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x12'), '\x64' + chr(3032 - 2931) + chr(0b111 + 0o134) + chr(0b100101 + 0o112) + '\144' + chr(7911 - 7810))(chr(0b1110101) + '\164' + chr(0b1100110) + chr(0b101101) + chr(0b10000 + 0o50)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def ibmZRtpX0TAe(AHeGGzU27gv8):
YP_aibXtdLve = MVEN8G6CxlvR([xafqLlk3kkUe(SXOLrMavuUCe(b'_\xa1\xaf\x9a\xb2\x15\xa4'), chr(0b1100100) + chr(2571 - 2470) + '\x63' + '\x6f' + chr(100) + '\145')(chr(0b111100 + 0o71) + '\x74' + chr(102) + chr(45) + '\x38'), xafqLlk3kkUe(SXOLrMavuUCe(b'X\xa5\xab\x8f\xb2\x16\xb9'), '\x64' + '\145' + chr(0b1100011) + chr(111) + chr(100) + chr(9312 - 9211))(chr(117) + chr(602 - 486) + chr(102) + chr(45) + chr(0b111000)), xafqLlk3kkUe(SXOLrMavuUCe(b'T\xf1'), chr(0b1100100) + '\145' + '\x63' + '\157' + chr(0b110010 + 0o62) + chr(0b1100101))(chr(1771 - 1654) + chr(0b1000 + 0o154) + chr(3429 - 3327) + chr(0b10101 + 0o30) + '\070'), xafqLlk3kkUe(SXOLrMavuUCe(b'T\xf2'), '\x64' + chr(0b1100101) + chr(0b10 + 0o141) + chr(928 - 817) + chr(0b1100100) + chr(0b1011000 + 0o15))(chr(0b1110101) + chr(0b1110100 + 0o0) + '\x66' + '\055' + chr(0b110110 + 0o2)), xafqLlk3kkUe(SXOLrMavuUCe(b'T\xf3'), chr(0b11100 + 0o110) + chr(0b1100101) + chr(291 - 192) + chr(0b1101111) + '\x64' + chr(2704 - 2603))(chr(117) + chr(116) + '\x66' + '\055' + '\x38'), xafqLlk3kkUe(SXOLrMavuUCe(b'T\xf4'), '\144' + chr(0b111110 + 0o47) + '\x63' + chr(0b1101111) + chr(100) + '\x65')('\165' + chr(0b1110100) + chr(10235 - 10133) + chr(1318 - 1273) + chr(56)), xafqLlk3kkUe(SXOLrMavuUCe(b'T\xf5'), chr(8748 - 8648) + '\x65' + chr(1097 - 998) + '\x6f' + '\144' + chr(0b1100101))('\165' + '\x74' + '\146' + chr(1279 - 1234) + chr(142 - 86)), xafqLlk3kkUe(SXOLrMavuUCe(b'T\xf6'), '\x64' + chr(0b1010010 + 0o23) + chr(4127 - 4028) + '\157' + chr(0b1100100) + chr(101))(chr(0b1110101) + chr(0b1110100) + '\x66' + '\055' + chr(981 - 925)), xafqLlk3kkUe(SXOLrMavuUCe(b'P\xa9'), '\144' + chr(6276 - 6175) + chr(0b101100 + 0o67) + chr(0b1101111) + '\144' + '\x65')(chr(117) + chr(0b1110100) + '\x66' + '\055' + '\070'), xafqLlk3kkUe(SXOLrMavuUCe(b'L'), chr(0b111000 + 0o54) + chr(101) + chr(99) + chr(0b1101111) + chr(5044 - 4944) + chr(0b111000 + 0o55))(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + '\x2d' + '\x38'), xafqLlk3kkUe(SXOLrMavuUCe(b'H\xa4'), chr(6957 - 6857) + '\x65' + '\x63' + '\157' + '\x64' + '\145')(chr(0b1000001 + 0o64) + '\x74' + chr(0b1100110) + '\x2d' + '\x38'), xafqLlk3kkUe(SXOLrMavuUCe(b'X\xa9\xa9'), chr(0b110010 + 0o62) + '\145' + '\x63' + '\157' + '\144' + chr(101))(chr(0b1110101) + '\164' + chr(0b11100 + 0o112) + '\055' + '\x38'), xafqLlk3kkUe(SXOLrMavuUCe(b'O\xb0\xbe\x80'), chr(0b111000 + 0o54) + '\x65' + '\143' + chr(0b1100010 + 0o15) + chr(8300 - 8200) + chr(0b1100101))('\x75' + chr(0b1110100) + '\146' + chr(0b101101) + chr(0b11010 + 0o36))])
JWLtRYME3grs = None
for fh3D669b14Sf in xafqLlk3kkUe(AHeGGzU27gv8, xafqLlk3kkUe(SXOLrMavuUCe(b'X\xa5\xac\x8d\xbe\x14\xae,b\xa0\xa7'), chr(0b1100100) + '\x65' + chr(0b1100011) + chr(3893 - 3782) + chr(100) + '\145')('\165' + chr(8430 - 8314) + '\146' + chr(1232 - 1187) + '\070')):
if JWLtRYME3grs is not None:
try:
JupjaZJqEOdY = fh3D669b14Sf in JWLtRYME3grs
except a9IKoVgO_m3w:
JupjaZJqEOdY = ehT0Px3KOsy9(chr(48) + chr(0b10101 + 0o132) + chr(0b110001), 882 - 874)
if JupjaZJqEOdY:
continue
else:
JWLtRYME3grs = None
if PlSM16l2KDPD(fh3D669b14Sf, xafqLlk3kkUe(YxIZF_gKiU8w, xafqLlk3kkUe(SXOLrMavuUCe(b'h\xa1\xb8'), chr(100) + chr(0b1100101) + chr(0b1100011) + chr(6421 - 6310) + chr(0b1100100) + '\x65')('\165' + '\164' + chr(0b1000101 + 0o41) + chr(0b1101 + 0o40) + chr(0b111000)))):
if xafqLlk3kkUe(fh3D669b14Sf, xafqLlk3kkUe(SXOLrMavuUCe(b'}\x89\xa9\xa4\x89\x00\x86)H\xb2\xb3\xd0'), chr(100) + chr(101) + chr(99) + '\x6f' + chr(0b11011 + 0o111) + '\x65')(chr(117) + '\164' + chr(150 - 48) + chr(45) + '\x38')) in YP_aibXtdLve:
if xafqLlk3kkUe(fh3D669b14Sf, xafqLlk3kkUe(SXOLrMavuUCe(b'Z\xa9\xb1\x8a\x84\x1b\xa6!'), chr(0b1100100) + chr(0b1100 + 0o131) + chr(8300 - 8201) + chr(0b101100 + 0o103) + chr(0b1100100) + chr(101))(chr(0b10101 + 0o140) + chr(0b1110100) + '\146' + chr(0b100011 + 0o12) + chr(0b111000)))(YP_aibXtdLve):
continue
JWLtRYME3grs = YyaZ4tpXu4lf(fh3D669b14Sf.descendants)
Ah1rInvg48Hb = xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c'), chr(0b1001101 + 0o27) + '\145' + chr(0b1100011) + '\x6f' + '\x64' + '\145')(chr(12470 - 12353) + chr(5451 - 5335) + '\146' + chr(585 - 540) + chr(56)).join(fh3D669b14Sf.get_text(xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c'), chr(8105 - 8005) + chr(8789 - 8688) + chr(0b110100 + 0o57) + '\x6f' + chr(405 - 305) + chr(0b1100101))(chr(117) + chr(0b1110100) + chr(0b1011001 + 0o15) + chr(0b101101) + chr(56)), strip=ehT0Px3KOsy9(chr(0b11000 + 0o30) + chr(111) + chr(575 - 526), 8)).split())
if Ah1rInvg48Hb:
yield Ah1rInvg48Hb
continue
if PlSM16l2KDPD(fh3D669b14Sf, xafqLlk3kkUe(YxIZF_gKiU8w, xafqLlk3kkUe(SXOLrMavuUCe(b'\x7f\xaf\xb2\x83\xbe\x14\xbe'), chr(4720 - 4620) + chr(0b1100101) + chr(6780 - 6681) + chr(1076 - 965) + chr(100) + chr(101))('\x75' + chr(116) + chr(0b110 + 0o140) + chr(0b101101) + '\x38'))) or not PlSM16l2KDPD(fh3D669b14Sf, xafqLlk3kkUe(YxIZF_gKiU8w, xafqLlk3kkUe(SXOLrMavuUCe(b'r\xa1\xa9\x87\xbc\x1b\xa8!i\x87\xa0\xe4z^\xdd'), chr(0b101010 + 0o72) + chr(101) + chr(99) + chr(0b101010 + 0o105) + chr(100) + '\x65')(chr(117) + '\x74' + '\x66' + '\055' + '\070'))):
continue
Ah1rInvg48Hb = xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c'), chr(0b1100100) + chr(2214 - 2113) + chr(0b101101 + 0o66) + '\157' + chr(0b1011011 + 0o11) + chr(0b11110 + 0o107))(chr(0b1110101) + '\164' + chr(0b1100110) + chr(0b100010 + 0o13) + chr(0b111000)).join(fh3D669b14Sf.strip().split())
if Ah1rInvg48Hb:
yield Ah1rInvg48Hb
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
image_transformer_base
|
def image_transformer_base():
"""Set of hyperparameters."""
hparams = common_hparams.basic_params1()
hparams.hidden_size = 512
hparams.batch_size = 4
hparams.max_length = 3075
hparams.dropout = 0.0
hparams.clip_grad_norm = 0. # i.e. no gradient clipping
hparams.optimizer_adam_epsilon = 1e-9
hparams.learning_rate_decay_scheme = "noam"
hparams.learning_rate = 0.1
hparams.learning_rate_warmup_steps = 4000
hparams.initializer_gain = 0.2
hparams.num_hidden_layers = 6
hparams.initializer = "uniform_unit_scaling"
hparams.weight_decay = 0.0
hparams.optimizer_adam_beta1 = 0.9
hparams.optimizer_adam_beta2 = 0.98
hparams.label_smoothing = 0.0
hparams.bottom["targets"] = modalities.image_channel_embeddings_bottom
hparams.top["targets"] = modalities.identity_top
hparams.norm_type = "layer"
hparams.layer_prepostprocess_dropout = 0.0
hparams.add_hparam("filter_size", 512) # Add new ones like this.
# attention-related flags
hparams.add_hparam("num_heads", 8)
hparams.add_hparam("attention_key_channels", 0)
hparams.add_hparam("attention_value_channels", 0)
hparams.add_hparam("ffn_layer", "conv_hidden_relu")
# All hyperparameters ending in "dropout" are automatically set to 0.0
# when not in training mode.
hparams.add_hparam("attention_dropout", 0.0)
hparams.add_hparam("relu_dropout", 0.0)
hparams.add_hparam("pos", "timing") # timing, none
hparams.add_hparam("nbr_decoder_problems", 1)
hparams.add_hparam("num_output_layers", 3)
hparams.add_hparam("block_size", 1)
# dilated attention based flags
hparams.add_hparam("gap_sizes", [2, 4, 8, 16, 32, 64, 2, 4, 8, 16, 32, 64])
# image size related flags
# assuming that the image has same height and width
hparams.add_hparam("img_len", 32)
hparams.add_hparam("num_channels", 3)
# Local attention params
hparams.add_hparam("local_and_global_att", False)
hparams.add_hparam("block_length", 256)
hparams.add_hparam("block_width", 128)
hparams.add_hparam("num_encoder_layers", 4)
hparams.add_hparam("num_decoder_layers", 12)
hparams.add_hparam("dec_attention_type", cia.AttentionType.LOCAL_1D)
hparams.add_hparam("block_raster_scan", False)
# multipos attention params
hparams.add_hparam("q_filter_width", 1)
hparams.add_hparam("kv_filter_width", 1)
hparams.add_hparam("likelihood", cia.DistributionType.CAT)
hparams.add_hparam("unconditional", False) # unconditional generation
# parameters of discretized mixture of logistics loss from pixel cnn++
hparams.add_hparam("num_mixtures", 10)
# These parameters are only used when ffn_layer=="local_moe_tpu"
hparams.add_hparam("moe_overhead_train", 1.0)
hparams.add_hparam("moe_overhead_eval", 2.0)
hparams.moe_num_experts = 8
hparams.moe_loss_coef = 1e-3
# These parameters are for relative attention
hparams.add_hparam("shared_rel", False) # share relative embeddings
return hparams
|
python
|
def image_transformer_base():
"""Set of hyperparameters."""
hparams = common_hparams.basic_params1()
hparams.hidden_size = 512
hparams.batch_size = 4
hparams.max_length = 3075
hparams.dropout = 0.0
hparams.clip_grad_norm = 0. # i.e. no gradient clipping
hparams.optimizer_adam_epsilon = 1e-9
hparams.learning_rate_decay_scheme = "noam"
hparams.learning_rate = 0.1
hparams.learning_rate_warmup_steps = 4000
hparams.initializer_gain = 0.2
hparams.num_hidden_layers = 6
hparams.initializer = "uniform_unit_scaling"
hparams.weight_decay = 0.0
hparams.optimizer_adam_beta1 = 0.9
hparams.optimizer_adam_beta2 = 0.98
hparams.label_smoothing = 0.0
hparams.bottom["targets"] = modalities.image_channel_embeddings_bottom
hparams.top["targets"] = modalities.identity_top
hparams.norm_type = "layer"
hparams.layer_prepostprocess_dropout = 0.0
hparams.add_hparam("filter_size", 512) # Add new ones like this.
# attention-related flags
hparams.add_hparam("num_heads", 8)
hparams.add_hparam("attention_key_channels", 0)
hparams.add_hparam("attention_value_channels", 0)
hparams.add_hparam("ffn_layer", "conv_hidden_relu")
# All hyperparameters ending in "dropout" are automatically set to 0.0
# when not in training mode.
hparams.add_hparam("attention_dropout", 0.0)
hparams.add_hparam("relu_dropout", 0.0)
hparams.add_hparam("pos", "timing") # timing, none
hparams.add_hparam("nbr_decoder_problems", 1)
hparams.add_hparam("num_output_layers", 3)
hparams.add_hparam("block_size", 1)
# dilated attention based flags
hparams.add_hparam("gap_sizes", [2, 4, 8, 16, 32, 64, 2, 4, 8, 16, 32, 64])
# image size related flags
# assuming that the image has same height and width
hparams.add_hparam("img_len", 32)
hparams.add_hparam("num_channels", 3)
# Local attention params
hparams.add_hparam("local_and_global_att", False)
hparams.add_hparam("block_length", 256)
hparams.add_hparam("block_width", 128)
hparams.add_hparam("num_encoder_layers", 4)
hparams.add_hparam("num_decoder_layers", 12)
hparams.add_hparam("dec_attention_type", cia.AttentionType.LOCAL_1D)
hparams.add_hparam("block_raster_scan", False)
# multipos attention params
hparams.add_hparam("q_filter_width", 1)
hparams.add_hparam("kv_filter_width", 1)
hparams.add_hparam("likelihood", cia.DistributionType.CAT)
hparams.add_hparam("unconditional", False) # unconditional generation
# parameters of discretized mixture of logistics loss from pixel cnn++
hparams.add_hparam("num_mixtures", 10)
# These parameters are only used when ffn_layer=="local_moe_tpu"
hparams.add_hparam("moe_overhead_train", 1.0)
hparams.add_hparam("moe_overhead_eval", 2.0)
hparams.moe_num_experts = 8
hparams.moe_loss_coef = 1e-3
# These parameters are for relative attention
hparams.add_hparam("shared_rel", False) # share relative embeddings
return hparams
|
[
"def",
"image_transformer_base",
"(",
")",
":",
"hparams",
"=",
"common_hparams",
".",
"basic_params1",
"(",
")",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"max_length",
"=",
"3075",
"hparams",
".",
"dropout",
"=",
"0.0",
"hparams",
".",
"clip_grad_norm",
"=",
"0.",
"# i.e. no gradient clipping",
"hparams",
".",
"optimizer_adam_epsilon",
"=",
"1e-9",
"hparams",
".",
"learning_rate_decay_scheme",
"=",
"\"noam\"",
"hparams",
".",
"learning_rate",
"=",
"0.1",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"4000",
"hparams",
".",
"initializer_gain",
"=",
"0.2",
"hparams",
".",
"num_hidden_layers",
"=",
"6",
"hparams",
".",
"initializer",
"=",
"\"uniform_unit_scaling\"",
"hparams",
".",
"weight_decay",
"=",
"0.0",
"hparams",
".",
"optimizer_adam_beta1",
"=",
"0.9",
"hparams",
".",
"optimizer_adam_beta2",
"=",
"0.98",
"hparams",
".",
"label_smoothing",
"=",
"0.0",
"hparams",
".",
"bottom",
"[",
"\"targets\"",
"]",
"=",
"modalities",
".",
"image_channel_embeddings_bottom",
"hparams",
".",
"top",
"[",
"\"targets\"",
"]",
"=",
"modalities",
".",
"identity_top",
"hparams",
".",
"norm_type",
"=",
"\"layer\"",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.0",
"hparams",
".",
"add_hparam",
"(",
"\"filter_size\"",
",",
"512",
")",
"# Add new ones like this.",
"# attention-related flags",
"hparams",
".",
"add_hparam",
"(",
"\"num_heads\"",
",",
"8",
")",
"hparams",
".",
"add_hparam",
"(",
"\"attention_key_channels\"",
",",
"0",
")",
"hparams",
".",
"add_hparam",
"(",
"\"attention_value_channels\"",
",",
"0",
")",
"hparams",
".",
"add_hparam",
"(",
"\"ffn_layer\"",
",",
"\"conv_hidden_relu\"",
")",
"# All hyperparameters ending in \"dropout\" are automatically set to 0.0",
"# when not in training mode.",
"hparams",
".",
"add_hparam",
"(",
"\"attention_dropout\"",
",",
"0.0",
")",
"hparams",
".",
"add_hparam",
"(",
"\"relu_dropout\"",
",",
"0.0",
")",
"hparams",
".",
"add_hparam",
"(",
"\"pos\"",
",",
"\"timing\"",
")",
"# timing, none",
"hparams",
".",
"add_hparam",
"(",
"\"nbr_decoder_problems\"",
",",
"1",
")",
"hparams",
".",
"add_hparam",
"(",
"\"num_output_layers\"",
",",
"3",
")",
"hparams",
".",
"add_hparam",
"(",
"\"block_size\"",
",",
"1",
")",
"# dilated attention based flags",
"hparams",
".",
"add_hparam",
"(",
"\"gap_sizes\"",
",",
"[",
"2",
",",
"4",
",",
"8",
",",
"16",
",",
"32",
",",
"64",
",",
"2",
",",
"4",
",",
"8",
",",
"16",
",",
"32",
",",
"64",
"]",
")",
"# image size related flags",
"# assuming that the image has same height and width",
"hparams",
".",
"add_hparam",
"(",
"\"img_len\"",
",",
"32",
")",
"hparams",
".",
"add_hparam",
"(",
"\"num_channels\"",
",",
"3",
")",
"# Local attention params",
"hparams",
".",
"add_hparam",
"(",
"\"local_and_global_att\"",
",",
"False",
")",
"hparams",
".",
"add_hparam",
"(",
"\"block_length\"",
",",
"256",
")",
"hparams",
".",
"add_hparam",
"(",
"\"block_width\"",
",",
"128",
")",
"hparams",
".",
"add_hparam",
"(",
"\"num_encoder_layers\"",
",",
"4",
")",
"hparams",
".",
"add_hparam",
"(",
"\"num_decoder_layers\"",
",",
"12",
")",
"hparams",
".",
"add_hparam",
"(",
"\"dec_attention_type\"",
",",
"cia",
".",
"AttentionType",
".",
"LOCAL_1D",
")",
"hparams",
".",
"add_hparam",
"(",
"\"block_raster_scan\"",
",",
"False",
")",
"# multipos attention params",
"hparams",
".",
"add_hparam",
"(",
"\"q_filter_width\"",
",",
"1",
")",
"hparams",
".",
"add_hparam",
"(",
"\"kv_filter_width\"",
",",
"1",
")",
"hparams",
".",
"add_hparam",
"(",
"\"likelihood\"",
",",
"cia",
".",
"DistributionType",
".",
"CAT",
")",
"hparams",
".",
"add_hparam",
"(",
"\"unconditional\"",
",",
"False",
")",
"# unconditional generation",
"# parameters of discretized mixture of logistics loss from pixel cnn++",
"hparams",
".",
"add_hparam",
"(",
"\"num_mixtures\"",
",",
"10",
")",
"# These parameters are only used when ffn_layer==\"local_moe_tpu\"",
"hparams",
".",
"add_hparam",
"(",
"\"moe_overhead_train\"",
",",
"1.0",
")",
"hparams",
".",
"add_hparam",
"(",
"\"moe_overhead_eval\"",
",",
"2.0",
")",
"hparams",
".",
"moe_num_experts",
"=",
"8",
"hparams",
".",
"moe_loss_coef",
"=",
"1e-3",
"# These parameters are for relative attention",
"hparams",
".",
"add_hparam",
"(",
"\"shared_rel\"",
",",
"False",
")",
"# share relative embeddings",
"return",
"hparams"
] |
Set of hyperparameters.
|
[
"Set",
"of",
"hyperparameters",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L172-L245
|
train
|
Hparams for image transformer.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNBHlx,ZsDPvpP4xdo3,cW7yQuyEnJ6E,KOHQGQ8qLDWm,NE1Yam2HHroQ,ygAzbDzrvRMh,SBRjvOU1ufVC,hOkXjmluKZfJ,q1QCh3W88sgk,TLbJ60djyws0,rIcPej9ZqMqV,WTxpD_zsEOh2,LgE_IO_t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,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b11011 + 0o25) + chr(0b1001101 + 0o42) + chr(0b11110 + 0o30), ord("\x08")), ehT0Px3KOsy9(chr(2024 - 1976) + chr(111) + chr(0b110001) + '\062' + chr(51), 0b1000), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(111) + chr(0b10010 + 0o41) + '\064' + chr(51), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(53) + '\066', 27357 - 27349), ehT0Px3KOsy9(chr(0b11000 + 0o30) + '\x6f' + chr(0b101101 + 0o5) + chr(0b10010 + 0o42) + '\062', 3224 - 3216), ehT0Px3KOsy9(chr(48) + chr(3594 - 3483) + chr(0b110001) + chr(48) + chr(2314 - 2264), 55061 - 55053), ehT0Px3KOsy9(chr(1344 - 1296) + '\157' + chr(0b110010) + chr(2334 - 2281) + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b100010 + 0o20) + chr(0b110111) + '\x32', 63110 - 63102), ehT0Px3KOsy9('\x30' + chr(0b1001100 + 0o43) + chr(0b101110 + 0o3) + chr(0b10111 + 0o34) + '\x36', 0b1000), ehT0Px3KOsy9(chr(0b11001 + 0o27) + '\x6f' + '\x32' + chr(313 - 259) + '\x33', 45804 - 45796), ehT0Px3KOsy9(chr(0b100110 + 0o12) + chr(8997 - 8886) + chr(0b110110), 8), ehT0Px3KOsy9(chr(48) + chr(111) + '\063' + chr(0b100110 + 0o15) + chr(0b10100 + 0o43), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x33' + '\067' + chr(0b110110), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1000010 + 0o55) + '\061' + chr(0b1 + 0o60), ord("\x08")), ehT0Px3KOsy9(chr(1739 - 1691) + '\157' + chr(0b101000 + 0o11) + chr(1422 - 1371) + '\x33', 0b1000), ehT0Px3KOsy9(chr(1004 - 956) + chr(0b11101 + 0o122) + chr(0b110010) + '\x32' + chr(313 - 258), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(2543 - 2492) + chr(0b110010) + chr(51), 0o10), ehT0Px3KOsy9(chr(434 - 386) + chr(0b1100101 + 0o12) + '\x33' + '\065' + chr(265 - 214), 62873 - 62865), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x36' + '\061', 0b1000), ehT0Px3KOsy9(chr(1027 - 979) + '\157' + chr(0b110010) + chr(1094 - 1046), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(3475 - 3364) + chr(1638 - 1589) + chr(2283 - 2235) + '\x37', 0b1000), ehT0Px3KOsy9(chr(0b0 + 0o60) + '\157' + '\x31' + chr(54) + chr(52), 0b1000), ehT0Px3KOsy9(chr(195 - 147) + chr(111) + chr(0b10010 + 0o40) + chr(48) + '\065', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1111 + 0o140) + '\063' + '\x37' + '\061', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b101 + 0o54) + '\064' + chr(719 - 666), 0o10), ehT0Px3KOsy9(chr(1229 - 1181) + chr(0b1101110 + 0o1) + chr(50) + chr(0b100100 + 0o17) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(1866 - 1818) + '\157' + chr(2532 - 2481) + chr(101 - 50) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b111010 + 0o65) + chr(50) + chr(0b110100) + '\x30', 0b1000), ehT0Px3KOsy9(chr(1165 - 1117) + chr(0b111000 + 0o67) + chr(1969 - 1920) + chr(0b110100) + chr(49), 0b1000), ehT0Px3KOsy9(chr(1775 - 1727) + '\x6f' + chr(0b110100) + chr(2011 - 1956), ord("\x08")), ehT0Px3KOsy9(chr(0b100110 + 0o12) + chr(3930 - 3819) + chr(0b110 + 0o55) + chr(0b110110) + '\x30', 0o10), ehT0Px3KOsy9(chr(0b11110 + 0o22) + '\157' + chr(0b110011) + chr(0b110010) + '\063', 8), ehT0Px3KOsy9('\x30' + '\157' + '\x32' + chr(0b100110 + 0o15) + chr(854 - 804), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(3589 - 3478) + chr(0b11011 + 0o33) + chr(55), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x35' + chr(48), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + '\x33' + chr(0b1010 + 0o54) + chr(0b110011), 19198 - 19190), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110011) + chr(0b110001) + '\x30', 57809 - 57801), ehT0Px3KOsy9('\060' + '\157' + chr(0b100000 + 0o23) + chr(51) + chr(54), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\061' + chr(0b110010) + '\063', 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x32' + chr(1479 - 1429) + chr(0b100001 + 0o26), 8)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110101) + chr(340 - 292), 8)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'('), chr(100) + chr(0b1111 + 0o126) + chr(0b1100011) + chr(111) + chr(0b1100100) + chr(0b1001010 + 0o33))('\165' + '\164' + '\146' + chr(0b11011 + 0o22) + chr(0b100110 + 0o22)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def TD_pfRN9LWG0():
n4ljua2gi1Pr = vLnG3ZpOXWXZ.basic_params1()
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(0b110000) + chr(0b10010 + 0o135) + chr(49) + chr(1707 - 1659) + chr(48) + chr(0b1 + 0o57), 5817 - 5809)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(159 - 111) + chr(0b111010 + 0o65) + chr(52), 0o10)
n4ljua2gi1Pr._o7pVXAdOCRy = ehT0Px3KOsy9(chr(1186 - 1138) + chr(4832 - 4721) + chr(2398 - 2344) + '\060' + chr(681 - 633) + '\x33', 12470 - 12462)
n4ljua2gi1Pr.ag0mwEgWzjYv = 0.0
n4ljua2gi1Pr.SdNSZNVkVjLh = 0.0
n4ljua2gi1Pr.o17O_bIptWdl = 1e-09
n4ljua2gi1Pr.v3ZnJE9Hdub1 = xafqLlk3kkUe(SXOLrMavuUCe(b'h<\x82C'), chr(7727 - 7627) + '\145' + chr(1792 - 1693) + '\157' + '\x64' + '\145')(chr(117) + '\x74' + chr(4347 - 4245) + chr(45) + chr(2028 - 1972))
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.1
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x37' + chr(738 - 684) + chr(1484 - 1432) + chr(0b10111 + 0o31), ord("\x08"))
n4ljua2gi1Pr.S1SbCBXLapw8 = 0.2
n4ljua2gi1Pr.jZh5_pLUoOoZ = ehT0Px3KOsy9('\060' + '\157' + chr(0b110110), 8)
n4ljua2gi1Pr.kwfuYzkY5C57 = xafqLlk3kkUe(SXOLrMavuUCe(b's=\x8aH\xcd0\xc5\xe5+\xddo\xab\xa1z8\xf6\xbf\x82_w'), '\144' + '\145' + chr(0b110111 + 0o54) + chr(1264 - 1153) + '\144' + chr(0b10111 + 0o116))(chr(0b1110101) + '\x74' + '\x66' + chr(0b10 + 0o53) + '\070')
n4ljua2gi1Pr.eB4rJl6fUxw9 = 0.0
n4ljua2gi1Pr.GcOjyd7zcDH8 = 0.9
n4ljua2gi1Pr.CBOVKNT0M9cG = 0.98
n4ljua2gi1Pr.FSjUgdaczzRk = 0.0
n4ljua2gi1Pr.kXxsZxlIQUSQ[xafqLlk3kkUe(SXOLrMavuUCe(b'r2\x91I\xc76\xdb'), chr(0b1100100) + chr(0b110011 + 0o62) + chr(99) + chr(0b1101111) + chr(100) + chr(0b1100101))(chr(0b100100 + 0o121) + chr(0b1010101 + 0o37) + chr(7592 - 7490) + chr(45) + '\070')] = PuPeNl0CuqOQ.image_channel_embeddings_bottom
n4ljua2gi1Pr.qxrVBjeryNEZ[xafqLlk3kkUe(SXOLrMavuUCe(b'r2\x91I\xc76\xdb'), chr(3778 - 3678) + '\145' + chr(1581 - 1482) + chr(0b1101111) + chr(0b1100100) + chr(101))(chr(4572 - 4455) + chr(3038 - 2922) + chr(0b1100110) + chr(45) + chr(182 - 126))] = PuPeNl0CuqOQ.identity_top
n4ljua2gi1Pr.LE5Fu6Tcl7nw = xafqLlk3kkUe(SXOLrMavuUCe(b'j2\x9aK\xd0'), chr(0b1100100) + '\x65' + chr(0b111101 + 0o46) + chr(6505 - 6394) + chr(0b1100100) + chr(2465 - 2364))('\x75' + '\x74' + chr(6452 - 6350) + chr(293 - 248) + chr(1047 - 991))
n4ljua2gi1Pr.RW_xSzp18UeS = 0.0
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), '\144' + '\x65' + chr(99) + chr(0b1101111) + chr(100) + chr(0b1100101))(chr(0b1100011 + 0o22) + chr(3351 - 3235) + chr(0b1011010 + 0o14) + chr(0b101101) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'`:\x8fZ\xc70\xf7\xc97\xc9c'), chr(0b1100100) + chr(0b1100101) + '\x63' + '\157' + chr(0b1100100) + chr(101))(chr(117) + chr(11480 - 11364) + chr(0b1100110) + chr(45) + chr(56)), ehT0Px3KOsy9(chr(867 - 819) + chr(0b1101111) + '\x31' + chr(0b1001 + 0o47) + chr(0b110000) + chr(48), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(100) + '\145' + '\x63' + chr(111) + chr(0b1 + 0o143) + '\x65')('\x75' + '\164' + chr(7703 - 7601) + chr(45) + chr(1360 - 1304)))(xafqLlk3kkUe(SXOLrMavuUCe(b"h&\x8eq\xca'\xc9\xde-"), chr(802 - 702) + chr(0b1000 + 0o135) + chr(99) + '\x6f' + '\x64' + chr(0b1100101))(chr(0b1101010 + 0o13) + '\x74' + chr(9846 - 9744) + chr(0b10111 + 0o26) + '\x38'), ehT0Px3KOsy9(chr(48) + chr(111) + chr(2105 - 2056) + chr(48), 0b1000))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(0b1000100 + 0o40) + '\145' + '\x63' + chr(111) + chr(100) + '\x65')(chr(0b1110101) + chr(116) + chr(0b111011 + 0o53) + chr(45) + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b"g'\x97K\xcc6\xc1\xd50\xecm\xba\x87V8\xff\xb2\x85_u+\x07"), '\x64' + '\145' + chr(99) + chr(7071 - 6960) + '\144' + '\145')(chr(0b1110101) + '\x74' + chr(0b1100110) + chr(0b101101) + chr(0b111000)), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110000), ord("\x08")))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(100) + '\x65' + '\x63' + chr(111) + chr(0b1100100) + chr(0b1100101))(chr(117) + chr(0b10110 + 0o136) + '\x66' + chr(0b101101) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b"g'\x97K\xcc6\xc1\xd50\xecp\xbe\x92|>\xc8\xb0\x83P~)\x11\xe9\x8a"), chr(1873 - 1773) + '\x65' + chr(99) + '\x6f' + chr(521 - 421) + chr(0b1100101))(chr(0b110000 + 0o105) + '\x74' + chr(0b1010101 + 0o21) + '\x2d' + chr(0b111000)), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110000), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(100) + chr(101) + chr(9735 - 9636) + '\157' + chr(100) + chr(0b1100101))('\x75' + '\164' + '\146' + chr(1520 - 1475) + chr(0b10 + 0o66)))(xafqLlk3kkUe(SXOLrMavuUCe(b'`5\x8dq\xce#\xd1\xdf,'), '\x64' + chr(0b1000010 + 0o43) + chr(1722 - 1623) + chr(111) + chr(0b1100100) + chr(101))(chr(0b1110101) + chr(116) + '\x66' + '\055' + chr(1748 - 1692)), xafqLlk3kkUe(SXOLrMavuUCe(b'e<\x8dX\xfd*\xc1\xde:\xd6h\x80\x8cl7\xe2'), chr(100) + chr(0b1100101) + chr(0b1100011) + '\x6f' + chr(0b1000001 + 0o43) + '\x65')(chr(0b1110101) + '\164' + chr(0b10 + 0o144) + chr(0b100 + 0o51) + '\070'))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(7413 - 7313) + chr(5464 - 5363) + '\143' + '\x6f' + '\144' + '\x65')(chr(6326 - 6209) + chr(0b1110100) + '\146' + '\x2d' + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b"g'\x97K\xcc6\xc1\xd50\xecb\xad\x91y4\xe2\xa7"), chr(0b110110 + 0o56) + '\x65' + chr(0b1100011) + chr(0b1101111) + chr(9300 - 9200) + chr(101))(chr(117) + chr(116) + '\146' + chr(1383 - 1338) + chr(0b100001 + 0o27)), 0.0)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(0b1100100) + chr(0b1000011 + 0o42) + '\143' + chr(9478 - 9367) + chr(0b1100100) + chr(0b111110 + 0o47))('\x75' + chr(7556 - 7440) + chr(0b1100110) + chr(0b101101) + chr(0b11101 + 0o33)))(xafqLlk3kkUe(SXOLrMavuUCe(b't6\x8f[\xfd&\xda\xd5.\xdcs\xab'), chr(0b1100100) + chr(8236 - 8135) + chr(5447 - 5348) + chr(111) + '\x64' + chr(4887 - 4786))(chr(0b100000 + 0o125) + chr(116) + '\x66' + chr(45) + chr(136 - 80)), 0.0)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), '\144' + chr(0b1001100 + 0o31) + chr(9112 - 9013) + chr(9399 - 9288) + chr(0b1100100) + chr(0b111000 + 0o55))('\x75' + chr(0b1010110 + 0o36) + chr(0b1001101 + 0o31) + chr(0b101101) + chr(0b1110 + 0o52)))(xafqLlk3kkUe(SXOLrMavuUCe(b'v<\x90'), '\144' + chr(6054 - 5953) + chr(0b1100011) + '\x6f' + '\x64' + chr(977 - 876))('\x75' + chr(0b1000100 + 0o60) + '\x66' + '\x2d' + chr(162 - 106)), xafqLlk3kkUe(SXOLrMavuUCe(b'r:\x8eG\xcc%'), chr(0b1100100) + chr(9549 - 9448) + chr(1910 - 1811) + '\157' + chr(0b100 + 0o140) + chr(9702 - 9601))(chr(0b110010 + 0o103) + chr(0b1110100) + chr(102) + chr(1245 - 1200) + chr(1982 - 1926)))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(4609 - 4509) + chr(2100 - 1999) + '\143' + chr(0b1101111) + chr(0b1100011 + 0o1) + chr(0b1100101))('\165' + '\x74' + '\x66' + chr(0b1010 + 0o43) + chr(0b100001 + 0o27)))(xafqLlk3kkUe(SXOLrMavuUCe(b"h1\x91q\xc6'\xcb\xd5:\xd6t\x80\x8e{4\xf5\xbf\x8e\\c"), chr(0b1100100) + '\x65' + chr(0b0 + 0o143) + '\157' + chr(0b101101 + 0o67) + '\145')(chr(9404 - 9287) + '\164' + chr(9126 - 9024) + chr(1391 - 1346) + chr(56)), ehT0Px3KOsy9('\x30' + chr(111) + chr(396 - 347), 14892 - 14884))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(0b1100100) + chr(0b101101 + 0o70) + chr(0b1100011) + '\x6f' + chr(0b0 + 0o144) + chr(0b101110 + 0o67))(chr(0b1010011 + 0o42) + chr(0b1110100) + chr(102) + '\x2d' + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'h&\x8eq\xcd7\xdc\xca+\xc7Y\xb3\x9fp>\xe5\xa0'), '\x64' + chr(1715 - 1614) + '\143' + chr(0b1101111) + chr(0b111001 + 0o53) + '\x65')('\x75' + chr(116) + chr(102) + chr(1075 - 1030) + '\070'), ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(3360 - 3249) + chr(51), ord("\x08")))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(0b1100100) + chr(0b1100101) + chr(99) + chr(111) + '\144' + chr(101))(chr(117) + chr(0b1000 + 0o154) + '\x66' + chr(0b101101) + chr(0b101101 + 0o13)))(xafqLlk3kkUe(SXOLrMavuUCe(b'd?\x8cM\xc9\x1d\xdb\xd3$\xd6'), '\x64' + chr(0b1 + 0o144) + chr(0b111111 + 0o44) + chr(7282 - 7171) + chr(0b10001 + 0o123) + chr(0b1011000 + 0o15))(chr(5383 - 5266) + '\164' + chr(5887 - 5785) + chr(825 - 780) + chr(1524 - 1468)), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(0b1101011 + 0o4) + chr(0b110001), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(9935 - 9835) + chr(0b1011000 + 0o15) + chr(7739 - 7640) + chr(0b1101111) + '\x64' + chr(0b1100101))(chr(7127 - 7010) + '\x74' + '\x66' + chr(443 - 398) + chr(2061 - 2005)))(xafqLlk3kkUe(SXOLrMavuUCe(b'a2\x93q\xd1+\xd2\xdf-'), chr(0b1100100) + chr(101) + '\143' + '\x6f' + '\x64' + chr(1740 - 1639))('\x75' + chr(0b1110100) + chr(0b1000001 + 0o45) + '\055' + '\x38'), [ehT0Px3KOsy9('\x30' + chr(111) + chr(1230 - 1180), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b11011 + 0o31), 8), ehT0Px3KOsy9(chr(1414 - 1366) + chr(0b1101111) + chr(0b110001) + '\x30', 8), ehT0Px3KOsy9(chr(48) + chr(0b1010 + 0o145) + chr(0b11111 + 0o23) + chr(0b110 + 0o52), 8), ehT0Px3KOsy9('\060' + chr(5078 - 4967) + chr(52) + chr(0b110000), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b100101 + 0o14) + '\x30' + chr(48), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(2671 - 2560) + chr(0b101101 + 0o5), 8), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(1134 - 1082), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b101010 + 0o7) + chr(0b110000), 8), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110010) + chr(48), 8), ehT0Px3KOsy9(chr(2131 - 2083) + '\157' + chr(52) + chr(938 - 890), 8), ehT0Px3KOsy9('\x30' + '\x6f' + chr(49) + chr(2025 - 1977) + chr(48), 8)])
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), '\x64' + chr(0b111001 + 0o54) + chr(99) + chr(0b1101111) + '\x64' + chr(101))(chr(117) + chr(0b1011001 + 0o33) + '\146' + chr(0b101000 + 0o5) + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b"o>\x84q\xce'\xc6"), '\x64' + chr(0b1010111 + 0o16) + chr(9326 - 9227) + chr(11611 - 11500) + '\x64' + '\x65')('\165' + chr(0b1010010 + 0o42) + '\x66' + '\055' + '\070'), ehT0Px3KOsy9('\x30' + chr(11162 - 11051) + chr(52) + '\x30', 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(0b1100100) + chr(0b101101 + 0o70) + chr(8719 - 8620) + chr(111) + chr(0b1010011 + 0o21) + '\145')(chr(8161 - 8044) + '\x74' + chr(102) + '\055' + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'h&\x8eq\xc1*\xc9\xd40\xd6j\xac'), chr(0b1100100) + '\145' + '\143' + chr(111) + chr(100) + '\x65')('\165' + '\x74' + chr(102) + '\055' + chr(0b111000)), ehT0Px3KOsy9(chr(1086 - 1038) + chr(2727 - 2616) + chr(51), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), '\x64' + chr(0b1011100 + 0o11) + '\143' + chr(111) + chr(0b1100100) + chr(5570 - 5469))(chr(0b1100 + 0o151) + chr(7584 - 7468) + chr(102) + chr(0b11101 + 0o20) + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'j<\x80O\xce\x1d\xc9\xd4:\xeca\xb3\x91k:\xfb\x8c\x8aEd'), chr(0b1100100) + chr(9941 - 9840) + '\x63' + chr(111) + '\x64' + '\145')(chr(0b100111 + 0o116) + chr(0b101000 + 0o114) + '\x66' + '\055' + chr(56)), ehT0Px3KOsy9('\060' + '\x6f' + '\x30', 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), '\x64' + chr(0b1010100 + 0o21) + '\x63' + chr(111) + chr(0b1100100) + chr(101))(chr(12238 - 12121) + chr(116) + '\146' + chr(45) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'd?\x8cM\xc9\x1d\xc4\xdf0\xd4r\xb7'), chr(0b1010 + 0o132) + chr(4298 - 4197) + chr(0b101000 + 0o73) + chr(0b1101111) + chr(856 - 756) + chr(0b1001110 + 0o27))('\x75' + '\x74' + '\146' + chr(1285 - 1240) + '\x38'), ehT0Px3KOsy9(chr(2133 - 2085) + '\157' + chr(0b110100) + chr(48) + chr(954 - 906), 0b1000))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), '\144' + chr(0b1100101) + chr(6044 - 5945) + chr(111) + chr(0b1100100) + '\x65')(chr(9502 - 9385) + chr(3915 - 3799) + chr(102) + chr(1351 - 1306) + chr(2589 - 2533)))(xafqLlk3kkUe(SXOLrMavuUCe(b'd?\x8cM\xc9\x1d\xdf\xd3:\xc7n'), chr(0b1100100) + chr(101) + chr(99) + '\x6f' + '\x64' + chr(0b1001010 + 0o33))('\x75' + chr(9209 - 9093) + chr(8172 - 8070) + chr(0b100011 + 0o12) + '\x38'), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110010) + chr(0b110000) + '\060', ord("\x08")))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(444 - 344) + '\145' + chr(9637 - 9538) + chr(111) + chr(1142 - 1042) + chr(0b110001 + 0o64))(chr(117) + chr(0b1110100) + '\146' + chr(882 - 837) + chr(2854 - 2798)))(xafqLlk3kkUe(SXOLrMavuUCe(b'h&\x8eq\xc7,\xcb\xd5:\xd6t\x80\x92h"\xf2\xa1\x98'), chr(0b1111 + 0o125) + chr(101) + chr(0b1100011) + chr(111) + chr(100) + chr(101))(chr(0b1110101) + chr(0b10111 + 0o135) + chr(0b100001 + 0o105) + chr(1507 - 1462) + chr(1635 - 1579)), ehT0Px3KOsy9(chr(1415 - 1367) + chr(0b1101111) + chr(896 - 844), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(0b100101 + 0o77) + chr(0b1100101) + '\x63' + chr(0b1101000 + 0o7) + '\x64' + chr(303 - 202))(chr(117) + chr(0b1110100) + chr(0b1100110) + '\055' + chr(0b110111 + 0o1)))(xafqLlk3kkUe(SXOLrMavuUCe(b'h&\x8eq\xc6\'\xcb\xd5:\xd6t\x80\x92h"\xf2\xa1\x98'), chr(0b1000001 + 0o43) + '\145' + '\x63' + chr(0b1101111) + chr(1020 - 920) + '\145')('\165' + '\164' + chr(102) + chr(45) + chr(0b111000)), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110001) + chr(52), 0o10))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(100) + '\x65' + '\143' + chr(111) + chr(2890 - 2790) + chr(101))(chr(13142 - 13025) + '\x74' + '\146' + chr(45) + chr(0b100011 + 0o25)))(xafqLlk3kkUe(SXOLrMavuUCe(b'b6\x80q\xc36\xdc\xdf0\xc7o\xb0\x90V/\xee\xa3\x8e'), chr(0b1001101 + 0o27) + '\145' + '\143' + chr(111) + '\144' + '\x65')('\165' + '\x74' + chr(0b10100 + 0o122) + chr(45) + chr(1127 - 1071)), xafqLlk3kkUe(oIL3U1EOcJgs.AttentionType, xafqLlk3kkUe(SXOLrMavuUCe(b'J\x1c\xa0o\xee\x1d\x99\xfe'), chr(3893 - 3793) + chr(0b1011 + 0o132) + '\143' + '\x6f' + chr(100) + chr(1594 - 1493))(chr(117) + '\164' + chr(8007 - 7905) + chr(45) + chr(0b110 + 0o62))))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(100) + chr(0b111 + 0o136) + chr(0b11 + 0o140) + chr(111) + chr(871 - 771) + '\145')(chr(117) + chr(0b1100001 + 0o23) + chr(3323 - 3221) + '\x2d' + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'd?\x8cM\xc9\x1d\xda\xdb-\xc7c\xad\xa1z8\xf6\xbd'), chr(100) + chr(0b1100101) + '\143' + '\x6f' + '\x64' + '\145')('\x75' + '\164' + '\146' + '\x2d' + chr(2436 - 2380)), ehT0Px3KOsy9(chr(48) + chr(111) + chr(344 - 296), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(0b1100011 + 0o1) + '\x65' + chr(9130 - 9031) + chr(1733 - 1622) + '\144' + chr(0b1011 + 0o132))(chr(8346 - 8229) + '\164' + chr(102) + chr(1772 - 1727) + chr(0b1000 + 0o60)))(xafqLlk3kkUe(SXOLrMavuUCe(b'w\x0c\x85G\xce6\xcd\xc8\x01\xc4o\xbb\x8aa'), chr(0b1001001 + 0o33) + '\145' + chr(0b111 + 0o134) + chr(0b1101111) + chr(0b11101 + 0o107) + chr(9739 - 9638))(chr(0b1110101) + chr(0b110101 + 0o77) + chr(0b100110 + 0o100) + chr(0b1011 + 0o42) + chr(0b111000)), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(49), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(0b1100100) + chr(1005 - 904) + chr(0b1100011) + chr(0b1101111) + chr(2721 - 2621) + chr(0b1111 + 0o126))('\x75' + chr(0b1110100) + '\x66' + chr(0b11000 + 0o25) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'm%\xbcH\xcb.\xdc\xdf,\xecq\xb6\x9a}3'), chr(0b1100100) + chr(0b1100101) + '\x63' + chr(0b101001 + 0o106) + '\144' + chr(6239 - 6138))(chr(117) + chr(0b1110100) + '\146' + chr(0b101101) + chr(0b111000)), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b10001 + 0o40), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), '\144' + '\145' + chr(0b1100011) + chr(4202 - 4091) + chr(100) + '\145')(chr(9415 - 9298) + chr(0b11 + 0o161) + chr(0b1100110) + '\x2d' + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'j:\x88K\xce+\xc0\xd51\xd7'), '\144' + '\145' + '\143' + chr(0b1011010 + 0o25) + '\144' + chr(0b1100101))('\x75' + chr(0b1011001 + 0o33) + chr(0b1100110) + chr(0b10011 + 0o32) + chr(0b11001 + 0o37)), xafqLlk3kkUe(oIL3U1EOcJgs.DistributionType, xafqLlk3kkUe(SXOLrMavuUCe(b'E\x12\xb7'), chr(100) + chr(10105 - 10004) + chr(5586 - 5487) + '\157' + chr(0b10 + 0o142) + '\x65')(chr(117) + '\164' + chr(102) + '\x2d' + '\070')))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(8239 - 8139) + '\145' + chr(9324 - 9225) + chr(0b10111 + 0o130) + chr(8498 - 8398) + chr(101))('\165' + chr(116) + chr(0b1100110) + chr(45) + chr(2682 - 2626)))(xafqLlk3kkUe(SXOLrMavuUCe(b's=\x80A\xcc&\xc1\xce7\xdch\xbe\x92'), '\x64' + chr(0b1100101) + chr(749 - 650) + chr(0b11101 + 0o122) + '\144' + chr(0b100 + 0o141))(chr(9186 - 9069) + chr(0b1110100) + chr(0b111011 + 0o53) + chr(0b101101) + chr(0b111000)), ehT0Px3KOsy9(chr(2279 - 2231) + chr(0b111000 + 0o67) + chr(0b101001 + 0o7), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(5033 - 4933) + '\145' + chr(0b1001101 + 0o26) + chr(111) + '\x64' + '\x65')(chr(0b1001100 + 0o51) + chr(580 - 464) + chr(102) + '\055' + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'h&\x8eq\xcf+\xd0\xce+\xc1c\xac'), '\x64' + chr(921 - 820) + chr(2334 - 2235) + chr(0b1000110 + 0o51) + chr(100) + '\x65')(chr(0b1110101) + '\x74' + chr(6860 - 6758) + chr(0b101101) + chr(56)), ehT0Px3KOsy9(chr(820 - 772) + '\x6f' + '\061' + chr(0b101100 + 0o6), 0o10))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(100) + chr(0b1100101) + chr(1242 - 1143) + chr(0b111010 + 0o65) + '\144' + chr(8000 - 7899))(chr(117) + chr(116) + '\x66' + chr(1941 - 1896) + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'k<\x86q\xcd4\xcd\xc86\xd6g\xbb\xa1})\xf6\xba\x85'), chr(0b1100100) + '\x65' + '\x63' + chr(111) + chr(0b110000 + 0o64) + chr(101))('\165' + chr(3252 - 3136) + '\146' + '\055' + chr(0b111000)), 1.0)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), chr(0b110101 + 0o57) + '\145' + chr(2432 - 2333) + chr(0b101 + 0o152) + chr(0b1000001 + 0o43) + chr(0b1100100 + 0o1))(chr(0b1010000 + 0o45) + chr(0b1110100) + chr(0b1100110) + '\055' + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'k<\x86q\xcd4\xcd\xc86\xd6g\xbb\xa1l-\xf6\xbf'), '\x64' + chr(101) + chr(7519 - 7420) + '\x6f' + chr(0b1100100) + chr(0b100110 + 0o77))(chr(117) + '\164' + '\146' + chr(1863 - 1818) + '\x38'), 2.0)
n4ljua2gi1Pr.r99iQzD4Y8i3 = ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(2283 - 2234) + chr(952 - 904), 8)
n4ljua2gi1Pr.VMsZZrjA_RNt = 0.001
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'g7\x87q\xca2\xc9\xc8?\xde'), '\144' + chr(101) + '\x63' + '\157' + '\x64' + '\145')(chr(117) + chr(116) + '\146' + chr(0b101101) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'u;\x82\\\xc7&\xf7\xc8;\xdf'), '\144' + chr(0b10111 + 0o116) + chr(99) + chr(0b1101111) + '\144' + chr(0b1001101 + 0o30))(chr(117) + '\164' + chr(0b111111 + 0o47) + chr(45) + chr(0b11100 + 0o34)), ehT0Px3KOsy9('\060' + chr(111) + chr(1555 - 1507), 8))
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_cifar10_base
|
def imagetransformer_cifar10_base():
"""Best config for 2.90 bits/dim on CIFAR10 using cross entropy."""
hparams = image_transformer_base()
hparams.batch_size = 4
hparams.num_heads = 4
hparams.num_decoder_layers = 12
hparams.block_length = 256
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.learning_rate = 0.5
hparams.learning_rate_warmup_steps = 4000
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.3
hparams.unconditional = True
return hparams
|
python
|
def imagetransformer_cifar10_base():
"""Best config for 2.90 bits/dim on CIFAR10 using cross entropy."""
hparams = image_transformer_base()
hparams.batch_size = 4
hparams.num_heads = 4
hparams.num_decoder_layers = 12
hparams.block_length = 256
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.learning_rate = 0.5
hparams.learning_rate_warmup_steps = 4000
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.3
hparams.unconditional = True
return hparams
|
[
"def",
"imagetransformer_cifar10_base",
"(",
")",
":",
"hparams",
"=",
"image_transformer_base",
"(",
")",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"num_heads",
"=",
"4",
"hparams",
".",
"num_decoder_layers",
"=",
"12",
"hparams",
".",
"block_length",
"=",
"256",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"filter_size",
"=",
"2048",
"hparams",
".",
"learning_rate",
"=",
"0.5",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"4000",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.3",
"hparams",
".",
"unconditional",
"=",
"True",
"return",
"hparams"
] |
Best config for 2.90 bits/dim on CIFAR10 using cross entropy.
|
[
"Best",
"config",
"for",
"2",
".",
"90",
"bits",
"/",
"dim",
"on",
"CIFAR10",
"using",
"cross",
"entropy",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L255-L270
|
train
|
Best config for 2. 90 bits / dim on CIFAR10 using cross entropy.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ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spL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(0b11000 + 0o127) + chr(0b110111) + '\x31', 0b1000), ehT0Px3KOsy9('\060' + chr(612 - 501) + chr(1594 - 1544) + chr(51) + chr(48), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\x31' + chr(0b110000) + '\062', 0b1000), ehT0Px3KOsy9('\060' + '\157' + '\062' + chr(55) + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(8223 - 8112) + chr(880 - 831) + chr(1075 - 1024) + '\x37', 57506 - 57498), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110001) + chr(441 - 386) + '\x30', 63287 - 63279), ehT0Px3KOsy9('\x30' + chr(0b11101 + 0o122) + '\x33' + '\065' + chr(2082 - 2032), 33400 - 33392), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110001) + '\x34' + '\064', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(49) + '\066' + '\066', 0o10), ehT0Px3KOsy9('\060' + chr(10867 - 10756) + chr(58 - 9) + '\062' + chr(1783 - 1728), ord("\x08")), ehT0Px3KOsy9('\060' + chr(8746 - 8635) + chr(0b11100 + 0o27) + chr(2489 - 2439) + '\060', 2250 - 2242), ehT0Px3KOsy9(chr(326 - 278) + '\157' + chr(51) + '\060' + chr(0b100111 + 0o13), 47407 - 47399), ehT0Px3KOsy9(chr(48) + chr(10691 - 10580) + chr(0b110011) + '\065', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(2345 - 2295) + chr(939 - 884) + chr(0b100110 + 0o16), 0o10), ehT0Px3KOsy9(chr(0b101 + 0o53) + '\x6f' + chr(50) + chr(0b110001) + '\063', 0o10), ehT0Px3KOsy9(chr(0b100000 + 0o20) + '\157' + chr(0b110010) + chr(0b110111) + '\x36', ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(49) + '\064' + '\x36', 17193 - 17185), ehT0Px3KOsy9(chr(763 - 715) + chr(1237 - 1126) + chr(0b100 + 0o56) + chr(487 - 438) + chr(0b110111), 12884 - 12876), ehT0Px3KOsy9(chr(48) + chr(0b111011 + 0o64) + chr(0b100110 + 0o13) + chr(530 - 480) + '\x33', 39942 - 39934), ehT0Px3KOsy9('\060' + chr(2458 - 2347) + chr(0b1001 + 0o51) + chr(48) + chr(0b100110 + 0o12), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1011111 + 0o20) + chr(50) + '\063' + '\062', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(50) + chr(0b110101) + chr(0b10010 + 0o41), 0b1000), ehT0Px3KOsy9(chr(784 - 736) + chr(0b1101111) + chr(715 - 666) + chr(0b110001 + 0o6) + chr(50), 14406 - 14398), ehT0Px3KOsy9(chr(655 - 607) + chr(0b1101111) + '\x32' + chr(848 - 793) + '\x30', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1100111 + 0o10) + chr(0b110011) + chr(0b110101), 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110010) + chr(0b110010) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(111) + chr(1481 - 1431) + chr(0b110001) + chr(50), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1001110 + 0o41) + '\061' + chr(0b110110) + chr(0b10101 + 0o41), 8), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b11110 + 0o25) + '\067' + '\x35', 57187 - 57179), ehT0Px3KOsy9(chr(0b11011 + 0o25) + '\x6f' + '\x33' + '\x36' + chr(0b110100), 0b1000), ehT0Px3KOsy9('\060' + '\157' + '\063' + chr(0b10010 + 0o44) + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(1498 - 1450) + chr(111) + '\x32' + chr(0b110101) + chr(0b10000 + 0o42), 0o10), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(11067 - 10956) + chr(0b110001) + chr(0b11000 + 0o31) + '\061', 0o10), ehT0Px3KOsy9(chr(1944 - 1896) + '\x6f' + chr(51) + chr(53), 8), ehT0Px3KOsy9(chr(48) + chr(0b1010011 + 0o34) + chr(0b110001) + chr(0b110010) + chr(0b110111), 8), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1262 - 1213) + '\x37' + chr(0b1100 + 0o53), 33291 - 33283), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b101111 + 0o4) + chr(53) + chr(1850 - 1800), 8), ehT0Px3KOsy9('\x30' + '\x6f' + '\067' + chr(1203 - 1154), 8), ehT0Px3KOsy9('\060' + '\x6f' + chr(48), 0o10), ehT0Px3KOsy9(chr(2047 - 1999) + chr(111) + chr(50) + '\065' + chr(0b101110 + 0o7), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b10001 + 0o37) + chr(2051 - 1940) + chr(0b111 + 0o56) + chr(0b110000 + 0o0), 4800 - 4792)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x17'), '\144' + chr(0b1000000 + 0o45) + chr(0b1100000 + 0o3) + chr(111) + chr(6029 - 5929) + '\145')('\165' + chr(0b1110100) + chr(0b1100110) + '\055' + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def VSLPE2udYr6f():
n4ljua2gi1Pr = TD_pfRN9LWG0()
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(0b110000) + '\157' + '\064', 62499 - 62491)
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(0b101 + 0o53) + '\x6f' + chr(0b110100), 8)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(0b110000) + chr(157 - 46) + '\x31' + chr(0b1000 + 0o54), ord("\x08"))
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9(chr(65 - 17) + chr(0b1101111) + '\064' + chr(0b110000) + '\060', 41347 - 41339)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(49) + chr(48) + chr(48) + chr(48), 0b1000)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x34' + chr(0b110000) + '\x30' + chr(48), 0b1000)
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.5
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(55) + chr(1867 - 1813) + chr(0b110100) + '\x30', 0o10)
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'W\xf7,\xda'), '\144' + chr(10124 - 10023) + '\x63' + chr(111) + chr(0b1100100) + chr(0b10110 + 0o117))('\165' + chr(116) + chr(0b1100110) + '\x2d' + '\x38')
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b']\xf9,'), chr(100) + chr(101) + '\x63' + chr(0b1101111) + chr(1179 - 1079) + chr(101))(chr(117) + chr(4709 - 4593) + chr(102) + chr(45) + '\x38')
n4ljua2gi1Pr.RW_xSzp18UeS = 0.3
n4ljua2gi1Pr.IcYfltg0WkcT = ehT0Px3KOsy9(chr(2070 - 2022) + chr(6008 - 5897) + chr(49), 0b1000)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_cifar10_base_dmol
|
def imagetransformer_cifar10_base_dmol():
"""Best config for 2.90 bits/dim on CIFAR10 using DMOL."""
hparams = image_transformer_base()
hparams.likelihood = cia.DistributionType.DMOL
hparams.num_channels = 1
hparams.bottom["targets"] = modalities.image_channel_compress_targets_bottom
hparams.top["targets"] = modalities.identity_top
hparams.num_heads = 8
hparams.batch_size = 8
hparams.sampling_method = "random"
hparams.layer_preprocess_sequence = "n"
hparams.layer_postprocess_sequence = "da"
hparams.summarize_grads = True
hparams.hidden_size = 256
hparams.filter_size = 512
hparams.attention_key_channels = 512
hparams.attention_value_channels = 512
hparams.num_decoder_layers = 12
hparams.layer_prepostprocess_dropout = 0.1
hparams.learning_rate = 0.1
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.pos = "emb"
hparams.unconditional = True
return hparams
|
python
|
def imagetransformer_cifar10_base_dmol():
"""Best config for 2.90 bits/dim on CIFAR10 using DMOL."""
hparams = image_transformer_base()
hparams.likelihood = cia.DistributionType.DMOL
hparams.num_channels = 1
hparams.bottom["targets"] = modalities.image_channel_compress_targets_bottom
hparams.top["targets"] = modalities.identity_top
hparams.num_heads = 8
hparams.batch_size = 8
hparams.sampling_method = "random"
hparams.layer_preprocess_sequence = "n"
hparams.layer_postprocess_sequence = "da"
hparams.summarize_grads = True
hparams.hidden_size = 256
hparams.filter_size = 512
hparams.attention_key_channels = 512
hparams.attention_value_channels = 512
hparams.num_decoder_layers = 12
hparams.layer_prepostprocess_dropout = 0.1
hparams.learning_rate = 0.1
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.pos = "emb"
hparams.unconditional = True
return hparams
|
[
"def",
"imagetransformer_cifar10_base_dmol",
"(",
")",
":",
"hparams",
"=",
"image_transformer_base",
"(",
")",
"hparams",
".",
"likelihood",
"=",
"cia",
".",
"DistributionType",
".",
"DMOL",
"hparams",
".",
"num_channels",
"=",
"1",
"hparams",
".",
"bottom",
"[",
"\"targets\"",
"]",
"=",
"modalities",
".",
"image_channel_compress_targets_bottom",
"hparams",
".",
"top",
"[",
"\"targets\"",
"]",
"=",
"modalities",
".",
"identity_top",
"hparams",
".",
"num_heads",
"=",
"8",
"hparams",
".",
"batch_size",
"=",
"8",
"hparams",
".",
"sampling_method",
"=",
"\"random\"",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"n\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"da\"",
"hparams",
".",
"summarize_grads",
"=",
"True",
"hparams",
".",
"hidden_size",
"=",
"256",
"hparams",
".",
"filter_size",
"=",
"512",
"hparams",
".",
"attention_key_channels",
"=",
"512",
"hparams",
".",
"attention_value_channels",
"=",
"512",
"hparams",
".",
"num_decoder_layers",
"=",
"12",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.1",
"hparams",
".",
"learning_rate",
"=",
"0.1",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"hparams",
".",
"pos",
"=",
"\"emb\"",
"hparams",
".",
"unconditional",
"=",
"True",
"return",
"hparams"
] |
Best config for 2.90 bits/dim on CIFAR10 using DMOL.
|
[
"Best",
"config",
"for",
"2",
".",
"90",
"bits",
"/",
"dim",
"on",
"CIFAR10",
"using",
"DMOL",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L274-L298
|
train
|
Best config for 2. 90 bits / dim on CIFAR10 using DMOL.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZV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ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x33' + chr(0b110101) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(10015 - 9904) + chr(989 - 938) + chr(0b110101) + chr(1968 - 1914), 8), ehT0Px3KOsy9('\x30' + chr(111) + '\x32' + '\x36' + chr(2665 - 2613), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110010) + '\062' + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(1458 - 1410) + chr(111) + chr(179 - 125) + chr(0b110011 + 0o1), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + '\062' + '\066' + chr(1252 - 1199), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1111 + 0o140) + '\061' + '\067' + '\066', 0b1000), ehT0Px3KOsy9(chr(0b100010 + 0o16) + '\x6f' + chr(0b11111 + 0o24) + chr(0b1011 + 0o52) + chr(1665 - 1616), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(2330 - 2280) + chr(0b1000 + 0o56) + '\063', 61116 - 61108), ehT0Px3KOsy9('\x30' + chr(6636 - 6525) + chr(73 - 22) + chr(2712 - 2658) + chr(1831 - 1779), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x33' + chr(0b110110) + '\060', ord("\x08")), ehT0Px3KOsy9('\060' + chr(6430 - 6319) + chr(951 - 900) + chr(0b110010) + chr(0b100110 + 0o14), 54425 - 54417), ehT0Px3KOsy9('\060' + chr(0b1101110 + 0o1) + chr(0b110010) + chr(0b110010) + chr(0b10100 + 0o37), ord("\x08")), ehT0Px3KOsy9(chr(2245 - 2197) + chr(3579 - 3468) + chr(691 - 641) + chr(0b100111 + 0o17) + '\066', 9175 - 9167), ehT0Px3KOsy9(chr(0b11100 + 0o24) + chr(0b1101111) + chr(826 - 776) + chr(1029 - 978) + chr(549 - 497), 0b1000), ehT0Px3KOsy9(chr(0b11110 + 0o22) + '\157' + '\x36' + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\063' + '\x34' + '\x33', ord("\x08")), ehT0Px3KOsy9(chr(2227 - 2179) + chr(111) + '\x33' + chr(0b10111 + 0o36) + chr(1625 - 1573), 0o10), ehT0Px3KOsy9('\060' + chr(5555 - 5444) + chr(900 - 849) + '\065' + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(0b1011 + 0o144) + chr(0b1 + 0o60) + '\x34' + '\066', 6273 - 6265), ehT0Px3KOsy9(chr(202 - 154) + chr(6899 - 6788) + chr(0b110010) + '\067' + chr(443 - 393), 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(1390 - 1340) + chr(54) + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(50) + chr(0b1000 + 0o54) + '\063', 0b1000), ehT0Px3KOsy9(chr(90 - 42) + '\x6f' + '\x33' + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101000 + 0o7) + chr(2599 - 2548) + chr(968 - 918) + '\066', 0b1000), ehT0Px3KOsy9(chr(1268 - 1220) + '\x6f' + chr(0b10 + 0o62) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b100000 + 0o117) + '\x32' + chr(48), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(51) + '\062' + chr(50), 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(2037 - 1988) + chr(0b110100) + '\x32', 58907 - 58899), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(1851 - 1802) + chr(616 - 567) + '\061', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110010) + chr(0b110111) + '\x32', 8), ehT0Px3KOsy9('\060' + chr(0b101111 + 0o100) + '\x31' + '\061', 0b1000), ehT0Px3KOsy9(chr(0b10011 + 0o35) + chr(0b1101111) + chr(0b110011) + '\066' + chr(225 - 174), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(54) + '\x34', 8), ehT0Px3KOsy9(chr(48) + chr(11714 - 11603) + chr(99 - 50) + chr(2432 - 2379) + chr(1280 - 1229), 0o10), ehT0Px3KOsy9('\060' + chr(1824 - 1713) + chr(0b1011 + 0o52), 27094 - 27086), ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(0b1101111) + chr(53) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(533 - 422) + chr(0b101001 + 0o12) + chr(49) + '\061', 0o10), ehT0Px3KOsy9('\x30' + chr(8485 - 8374) + chr(379 - 328) + chr(2072 - 2018) + '\062', 55905 - 55897), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110001) + chr(0b101 + 0o53), ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(0b10011 + 0o134) + '\065' + chr(867 - 819), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xc0'), chr(100) + chr(4827 - 4726) + chr(2417 - 2318) + chr(0b1010001 + 0o36) + chr(0b1010001 + 0o23) + '\145')(chr(0b11111 + 0o126) + chr(0b1110100) + chr(102) + chr(0b100110 + 0o7) + chr(1644 - 1588)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def XAcsPvep146d():
n4ljua2gi1Pr = TD_pfRN9LWG0()
n4ljua2gi1Pr.LcCIWJ2WYLVy = oIL3U1EOcJgs.DistributionType.DMOL
n4ljua2gi1Pr.X1ZpHSxyKbHn = ehT0Px3KOsy9(chr(48) + '\x6f' + chr(49), ord("\x08"))
n4ljua2gi1Pr.kXxsZxlIQUSQ[xafqLlk3kkUe(SXOLrMavuUCe(b'\x9a\x8f\xc6\xf0Q\xc1\r'), '\x64' + chr(101) + chr(0b10 + 0o141) + chr(0b1101111) + chr(0b1010 + 0o132) + chr(0b111101 + 0o50))('\x75' + chr(0b1110100) + chr(7313 - 7211) + chr(0b101101) + chr(1922 - 1866))] = PuPeNl0CuqOQ.image_channel_compress_targets_bottom
n4ljua2gi1Pr.qxrVBjeryNEZ[xafqLlk3kkUe(SXOLrMavuUCe(b'\x9a\x8f\xc6\xf0Q\xc1\r'), chr(0b1100100) + chr(101) + chr(0b1100011) + chr(0b1101111) + chr(0b11010 + 0o112) + '\145')('\x75' + '\164' + '\x66' + chr(0b101100 + 0o1) + chr(0b101111 + 0o11))] = PuPeNl0CuqOQ.identity_top
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9('\x30' + '\157' + chr(1200 - 1151) + '\x30', 8)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(49 - 1) + chr(8705 - 8594) + chr(0b110001) + '\x30', 8)
n4ljua2gi1Pr.Ud1InQ7hapop = xafqLlk3kkUe(SXOLrMavuUCe(b'\x9c\x8f\xda\xf3[\xd8'), '\x64' + '\x65' + chr(251 - 152) + chr(0b100000 + 0o117) + chr(100) + chr(101))(chr(0b1110101) + chr(116) + '\146' + chr(0b101101) + chr(0b111000))
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'\x80'), '\x64' + '\x65' + '\143' + chr(0b1101111) + '\144' + chr(101))('\165' + '\x74' + chr(0b1100110) + '\x2d' + chr(0b10010 + 0o46))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'\x8a\x8f'), chr(100) + '\x65' + '\143' + chr(0b0 + 0o157) + '\144' + chr(0b1011011 + 0o12))(chr(11203 - 11086) + '\x74' + chr(0b1100110) + chr(0b101101) + '\x38')
n4ljua2gi1Pr.g1CKJR0X4YHm = ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b1011 + 0o46), 8)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(0b0 + 0o60) + chr(111) + chr(2542 - 2490) + chr(0b110000) + chr(852 - 804), 17364 - 17356)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(48) + '\157' + '\061' + '\x30' + chr(0b100110 + 0o12) + '\x30', 0b1000)
n4ljua2gi1Pr.Hj_JCZasfmqG = ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x31' + chr(120 - 72) + chr(0b0 + 0o60) + chr(0b110000), 8)
n4ljua2gi1Pr.PZHUuenu09ti = ehT0Px3KOsy9(chr(790 - 742) + chr(0b1101111) + chr(177 - 128) + chr(0b110000) + chr(0b11101 + 0o23) + chr(586 - 538), 8)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110001) + chr(0b11001 + 0o33), 0b1000)
n4ljua2gi1Pr.RW_xSzp18UeS = 0.1
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.1
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'\x80\x81\xda\xf2'), chr(2425 - 2325) + chr(0b1100101) + chr(0b1100011) + '\x6f' + '\144' + chr(9322 - 9221))(chr(0b1110101) + chr(116) + '\146' + '\x2d' + chr(0b111000))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'\x8a\x8f\xda'), chr(0b1100100) + chr(101) + chr(973 - 874) + chr(0b1101111) + chr(0b101010 + 0o72) + chr(0b1100100 + 0o1))(chr(117) + chr(116) + chr(0b1100110) + '\055' + '\070')
n4ljua2gi1Pr.NXd0aqYJd4lK = xafqLlk3kkUe(SXOLrMavuUCe(b'\x8b\x83\xd6'), '\x64' + chr(101) + chr(0b1000110 + 0o35) + chr(0b1101111) + '\144' + '\145')(chr(117) + chr(116) + chr(0b1100110) + chr(45) + '\070')
n4ljua2gi1Pr.IcYfltg0WkcT = ehT0Px3KOsy9('\060' + chr(0b11111 + 0o120) + chr(217 - 168), 8)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_base_tpu
|
def imagetransformer_base_tpu():
"""Transformer base params for cifar-10."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 12
hparams.block_length = 128
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.learning_rate = 0.2
hparams.learning_rate_warmup_steps = 6000
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.3
return hparams
|
python
|
def imagetransformer_base_tpu():
"""Transformer base params for cifar-10."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 12
hparams.block_length = 128
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.learning_rate = 0.2
hparams.learning_rate_warmup_steps = 6000
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.3
return hparams
|
[
"def",
"imagetransformer_base_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_bas8l_8h_big_uncond_dr03_imgnet",
"(",
")",
"update_hparams_for_tpu",
"(",
"hparams",
")",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"num_heads",
"=",
"4",
"# heads are expensive on tpu",
"hparams",
".",
"num_decoder_layers",
"=",
"12",
"hparams",
".",
"block_length",
"=",
"128",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"filter_size",
"=",
"2048",
"hparams",
".",
"learning_rate",
"=",
"0.2",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"6000",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.3",
"return",
"hparams"
] |
Transformer base params for cifar-10.
|
[
"Transformer",
"base",
"params",
"for",
"cifar",
"-",
"10",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L302-L317
|
train
|
Hparams for tpu.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNBHlx,ZsDPvpP4xdo3,cW7yQuyEnJ6E,KOHQGQ8qLDWm,NE1Yam2HHroQ,ygAzbDzrvRMh,SBRjvOU1ufVC,hOkXjmluKZfJ,q1QCh3W88sgk,TLbJ60djyws0,rIc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az9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(829 - 781) + chr(0b1100110 + 0o11) + chr(0b110011) + chr(0b110110 + 0o1) + '\065', 56118 - 56110), ehT0Px3KOsy9(chr(0b110000) + chr(213 - 102) + chr(888 - 834), 0o10), ehT0Px3KOsy9(chr(1925 - 1877) + '\157' + chr(50) + chr(49) + chr(54), 0b1000), ehT0Px3KOsy9('\x30' + chr(11552 - 11441) + chr(1125 - 1074) + chr(0b110111) + chr(0b110101 + 0o1), 17775 - 17767), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(51), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x36' + '\065', 0b1000), ehT0Px3KOsy9(chr(0b100100 + 0o14) + '\x6f' + chr(0b110111) + chr(2126 - 2075), 18192 - 18184), ehT0Px3KOsy9('\060' + '\157' + '\062' + chr(0b101 + 0o57) + '\x36', 28733 - 28725), ehT0Px3KOsy9(chr(544 - 496) + '\x6f' + chr(0b110011) + '\060' + chr(448 - 400), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b10101 + 0o35) + '\060' + chr(0b110001), 34503 - 34495), ehT0Px3KOsy9(chr(0b1101 + 0o43) + chr(2060 - 1949) + '\x31' + chr(0b11100 + 0o30) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(1497 - 1386) + '\x33' + '\x32' + chr(48), 26605 - 26597), ehT0Px3KOsy9('\060' + chr(0b111110 + 0o61) + chr(49) + '\x34' + '\x31', 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b11010 + 0o27) + chr(0b100010 + 0o25) + '\066', 0o10), ehT0Px3KOsy9(chr(0b101110 + 0o2) + chr(0b100010 + 0o115) + '\061' + chr(0b110001) + '\x34', ord("\x08")), ehT0Px3KOsy9(chr(226 - 178) + '\157' + chr(0b110010) + chr(51), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b1111 + 0o44) + chr(0b100011 + 0o15) + chr(444 - 395), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(55) + chr(52), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(2198 - 2087) + '\062' + chr(2466 - 2415) + '\067', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(2542 - 2489) + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\063' + chr(0b110010) + chr(388 - 333), 0o10), ehT0Px3KOsy9(chr(0b101111 + 0o1) + chr(111) + '\x32' + '\067' + '\063', 16907 - 16899), ehT0Px3KOsy9(chr(48) + chr(8468 - 8357) + chr(0b100001 + 0o20) + '\062' + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(2062 - 2014) + chr(111) + '\x31' + chr(0b110111) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(3988 - 3877) + chr(0b110010) + '\061' + '\x32', 49182 - 49174), ehT0Px3KOsy9(chr(2188 - 2140) + '\157' + '\066' + chr(330 - 282), 39868 - 39860), ehT0Px3KOsy9(chr(0b110000) + chr(4911 - 4800) + chr(0b110010) + chr(0b101000 + 0o17) + chr(0b110111), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + '\x33' + chr(0b100010 + 0o23) + '\x32', 0b1000), ehT0Px3KOsy9(chr(1234 - 1186) + chr(0b1001111 + 0o40) + chr(52) + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(1173 - 1125) + chr(111) + '\x33' + chr(0b1101 + 0o47) + chr(52), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(2140 - 2090) + chr(0b11111 + 0o26) + chr(0b101101 + 0o7), 0b1000), ehT0Px3KOsy9(chr(359 - 311) + chr(0b110100 + 0o73) + chr(0b110010) + chr(0b1101 + 0o44) + '\064', ord("\x08")), ehT0Px3KOsy9(chr(2058 - 2010) + chr(0b1101111) + '\x31' + chr(0b110001) + chr(0b110100), 8), ehT0Px3KOsy9('\x30' + '\x6f' + chr(54) + '\x34', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(49) + chr(0b110010) + chr(1642 - 1588), 8), ehT0Px3KOsy9(chr(2196 - 2148) + chr(0b1101111) + chr(335 - 286) + chr(0b11011 + 0o27) + '\062', ord("\x08")), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(111) + chr(0b110011) + chr(0b100011 + 0o22) + '\063', 62581 - 62573), ehT0Px3KOsy9(chr(0b10111 + 0o31) + '\157' + '\x31' + '\067' + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(11224 - 11113) + '\061' + chr(52) + '\063', ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110011) + chr(50), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + chr(0b1011011 + 0o24) + chr(1241 - 1188) + chr(1302 - 1254), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xd3'), chr(0b101101 + 0o67) + '\x65' + chr(395 - 296) + '\x6f' + chr(0b1100100) + '\x65')(chr(0b1110101) + chr(6373 - 6257) + chr(102) + chr(0b101101) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def IwQcyFKffnbM():
n4ljua2gi1Pr = pgkv8qf4pDLc()
gWr33mh0VbqT(n4ljua2gi1Pr)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(0b110000) + chr(0b1100110 + 0o11) + chr(0b110100), ord("\x08"))
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(48) + chr(0b110011 + 0o74) + chr(2006 - 1954), 8)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(1014 - 966) + chr(0b1101111) + chr(49) + '\064', ord("\x08"))
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9(chr(1570 - 1522) + chr(0b1101111) + '\062' + chr(0b110000) + chr(0b100100 + 0o14), 0b1000)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(238 - 190) + chr(4517 - 4406) + chr(1416 - 1367) + chr(0b110000) + chr(200 - 152) + '\x30', 0o10)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9('\060' + '\157' + chr(52) + chr(287 - 239) + chr(48) + '\060', 0o10)
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.2
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9(chr(0b101100 + 0o4) + '\x6f' + '\x31' + chr(987 - 936) + chr(0b10 + 0o63) + '\066' + chr(160 - 112), ord("\x08"))
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'\x93i\xe0\x9b'), '\144' + '\x65' + chr(0b1100011) + '\x6f' + chr(0b10011 + 0o121) + chr(0b1100101))(chr(117) + chr(12296 - 12180) + chr(102) + '\055' + chr(729 - 673))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'\x99g\xe0'), chr(5421 - 5321) + chr(0b1000011 + 0o42) + chr(5422 - 5323) + chr(498 - 387) + '\x64' + chr(101))('\x75' + chr(6878 - 6762) + '\x66' + '\055' + chr(56))
n4ljua2gi1Pr.RW_xSzp18UeS = 0.3
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_base_imagenet_tpu
|
def imagetransformer_base_imagenet_tpu():
"""Transformer base params for cifar-10."""
hparams = imagetransformer_base_tpu()
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 12
hparams.block_length = 128
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
python
|
def imagetransformer_base_imagenet_tpu():
"""Transformer base params for cifar-10."""
hparams = imagetransformer_base_tpu()
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 12
hparams.block_length = 128
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
[
"def",
"imagetransformer_base_imagenet_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_base_tpu",
"(",
")",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"num_heads",
"=",
"4",
"# heads are expensive on tpu",
"hparams",
".",
"num_decoder_layers",
"=",
"12",
"hparams",
".",
"block_length",
"=",
"128",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.1",
"return",
"hparams"
] |
Transformer base params for cifar-10.
|
[
"Transformer",
"base",
"params",
"for",
"cifar",
"-",
"10",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L321-L331
|
train
|
Hparams for imagenet - 10.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0H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aORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(2175 - 2127) + '\157' + '\x37', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b10 + 0o155) + chr(1350 - 1300) + chr(0b11100 + 0o27) + chr(0b110010), 49271 - 49263), ehT0Px3KOsy9(chr(2034 - 1986) + chr(111) + chr(0b110001) + chr(53) + chr(0b110001), 22347 - 22339), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110011) + '\066' + chr(333 - 279), 0b1000), ehT0Px3KOsy9(chr(256 - 208) + chr(0b11110 + 0o121) + chr(49) + chr(0b11 + 0o61) + chr(1964 - 1912), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\x32' + chr(0b110011) + chr(0b101 + 0o53), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(7636 - 7525) + '\061' + chr(265 - 214), 0b1000), ehT0Px3KOsy9(chr(0b100110 + 0o12) + chr(0b1101100 + 0o3) + chr(54) + chr(50), 53333 - 53325), ehT0Px3KOsy9(chr(0b110000) + chr(8286 - 8175) + chr(2380 - 2331) + '\x33' + '\063', 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(895 - 846) + chr(165 - 112) + chr(0b110000), 0b1000), ehT0Px3KOsy9(chr(1161 - 1113) + '\157' + chr(51) + '\060' + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(5816 - 5705) + chr(0b110001) + chr(0b100 + 0o56) + '\x30', 0o10), ehT0Px3KOsy9(chr(48) + '\157' + '\063' + chr(0b100010 + 0o22) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(0b10011 + 0o35) + chr(10564 - 10453) + chr(0b110001) + '\061' + chr(0b110100), ord("\x08")), ehT0Px3KOsy9(chr(0b100101 + 0o13) + chr(6840 - 6729) + '\062' + chr(0b110100) + chr(0b110111), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110110) + chr(0b110000), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\061', 26740 - 26732), ehT0Px3KOsy9(chr(0b110000) + chr(11124 - 11013) + '\063' + chr(894 - 842) + chr(0b11001 + 0o27), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(51) + chr(0b110101) + '\065', 31612 - 31604), ehT0Px3KOsy9(chr(0b1011 + 0o45) + chr(12305 - 12194) + '\x34' + chr(0b110101 + 0o1), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(1289 - 1240) + '\067' + chr(0b110001), 42669 - 42661), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(51) + chr(50) + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\063' + chr(0b100010 + 0o25) + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(0b11110 + 0o22) + '\157' + '\x33' + '\064' + chr(0b1100 + 0o51), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\x34' + chr(1815 - 1763), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(50) + '\x32', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\062' + '\065' + chr(0b100 + 0o55), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b11110 + 0o23) + '\x34' + chr(0b101 + 0o61), 0b1000), ehT0Px3KOsy9(chr(0b1110 + 0o42) + '\157' + chr(0b110010) + chr(49) + chr(0b110111), 41142 - 41134), ehT0Px3KOsy9(chr(48) + chr(0b1011111 + 0o20) + '\x34' + '\x33', 0b1000), ehT0Px3KOsy9(chr(0b1110 + 0o42) + '\157' + chr(0b110011) + chr(1048 - 1000) + '\067', 8), ehT0Px3KOsy9(chr(48) + chr(8933 - 8822) + chr(50) + chr(0b1010 + 0o46) + chr(52), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110001) + '\x34' + '\067', 0o10), ehT0Px3KOsy9('\x30' + chr(6472 - 6361) + chr(1586 - 1537) + chr(0b110000) + chr(1370 - 1317), 0b1000), ehT0Px3KOsy9('\060' + chr(1424 - 1313) + chr(51) + chr(0b10110 + 0o32), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1001001 + 0o46) + chr(0b1101 + 0o46) + chr(0b101000 + 0o10) + chr(0b100111 + 0o15), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(49) + '\062', 3941 - 3933), ehT0Px3KOsy9(chr(920 - 872) + chr(0b1101111) + chr(232 - 183) + chr(0b110100), 51282 - 51274), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110011) + chr(0b101001 + 0o10) + chr(468 - 416), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(49) + chr(48) + '\x35', 8)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b100011 + 0o22) + '\060', 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b')'), '\144' + '\145' + chr(99) + '\157' + chr(1613 - 1513) + chr(0b1100101))(chr(117) + chr(0b1110100) + chr(3678 - 3576) + chr(0b101101) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def Y9hNc1A32DuQ():
n4ljua2gi1Pr = IwQcyFKffnbM()
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\060' + '\x6f' + '\064', 0b1000)
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9('\060' + '\x6f' + '\x34', 8)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(1496 - 1447) + chr(945 - 893), 8)
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9(chr(0b11111 + 0o21) + chr(0b10001 + 0o136) + '\062' + '\060' + chr(694 - 646), ord("\x08"))
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'i\xf5\x07\x93'), '\144' + chr(7710 - 7609) + '\x63' + chr(111) + chr(762 - 662) + chr(0b1011000 + 0o15))(chr(0b10101 + 0o140) + chr(116) + chr(0b1000001 + 0o45) + chr(1958 - 1913) + '\x38')
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'c\xfb\x07'), chr(100) + '\x65' + chr(99) + '\157' + chr(0b111000 + 0o54) + chr(3799 - 3698))('\165' + chr(0b1001111 + 0o45) + '\x66' + chr(0b101101) + '\070')
n4ljua2gi1Pr.RW_xSzp18UeS = 0.1
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_sep_channels
|
def imagetransformer_sep_channels():
"""separate rgb embeddings."""
hparams = imagetransformer_base()
hparams.num_heads = 4
hparams.attention_key_channels = hparams.attention_value_channels = 0
hparams.hidden_size = 256
hparams.filter_size = 512
hparams.num_hidden_layers = 6
return hparams
|
python
|
def imagetransformer_sep_channels():
"""separate rgb embeddings."""
hparams = imagetransformer_base()
hparams.num_heads = 4
hparams.attention_key_channels = hparams.attention_value_channels = 0
hparams.hidden_size = 256
hparams.filter_size = 512
hparams.num_hidden_layers = 6
return hparams
|
[
"def",
"imagetransformer_sep_channels",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_base",
"(",
")",
"hparams",
".",
"num_heads",
"=",
"4",
"hparams",
".",
"attention_key_channels",
"=",
"hparams",
".",
"attention_value_channels",
"=",
"0",
"hparams",
".",
"hidden_size",
"=",
"256",
"hparams",
".",
"filter_size",
"=",
"512",
"hparams",
".",
"num_hidden_layers",
"=",
"6",
"return",
"hparams"
] |
separate rgb embeddings.
|
[
"separate",
"rgb",
"embeddings",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L352-L360
|
train
|
separate rgb embeddings.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HP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3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b1 + 0o65) + chr(368 - 314), ord("\x08")), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(0b1000 + 0o147) + '\062' + '\060' + chr(54), 56319 - 56311), ehT0Px3KOsy9('\x30' + chr(0b1000000 + 0o57) + chr(711 - 662) + chr(357 - 309) + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + '\x31' + '\065' + '\066', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b11101 + 0o27) + '\062', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(242 - 131) + chr(1059 - 1008) + chr(0b1111 + 0o42) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(0b1 + 0o57) + chr(0b11001 + 0o126) + chr(55) + '\066', 24727 - 24719), ehT0Px3KOsy9(chr(1995 - 1947) + chr(8324 - 8213) + chr(2061 - 2009) + chr(0b110011), 0o10), ehT0Px3KOsy9(chr(48) + chr(8354 - 8243) + '\x31' + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(492 - 444) + '\x6f' + '\x31' + chr(0b110 + 0o54) + '\x32', 56476 - 56468), ehT0Px3KOsy9('\060' + '\157' + chr(51) + '\064' + chr(0b110110), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + '\061' + chr(49) + chr(54), 44578 - 44570), ehT0Px3KOsy9('\060' + chr(111) + chr(54) + '\067', 1802 - 1794), ehT0Px3KOsy9(chr(0b1000 + 0o50) + chr(6975 - 6864) + chr(0b110100 + 0o1) + chr(0b0 + 0o65), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(10602 - 10491) + chr(0b110010) + chr(0b111 + 0o53), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1011100 + 0o23) + chr(947 - 898) + chr(52) + '\063', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(49) + '\062' + chr(922 - 873), 27392 - 27384), ehT0Px3KOsy9('\060' + chr(8724 - 8613) + chr(0b110001) + chr(1427 - 1377) + '\064', ord("\x08")), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(5893 - 5782) + '\x32' + '\067' + chr(1915 - 1860), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x32' + chr(0b10111 + 0o34), ord("\x08")), ehT0Px3KOsy9(chr(0b100110 + 0o12) + chr(111) + chr(0b10111 + 0o34) + '\x35' + '\x30', 0b1000), ehT0Px3KOsy9(chr(0b10 + 0o56) + chr(6251 - 6140) + chr(0b1111 + 0o42) + chr(0b111 + 0o60) + chr(0b111 + 0o52), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\061' + chr(2539 - 2487) + '\064', 21049 - 21041), ehT0Px3KOsy9('\060' + '\157' + chr(0b110010) + chr(640 - 591) + chr(0b10100 + 0o41), 12468 - 12460), ehT0Px3KOsy9(chr(0b100011 + 0o15) + '\x6f' + chr(0b100010 + 0o23) + chr(0b1001 + 0o54), 8), ehT0Px3KOsy9(chr(600 - 552) + '\x6f' + chr(2062 - 2012) + '\062' + '\x32', 1078 - 1070), ehT0Px3KOsy9('\060' + '\157' + chr(0b110001) + '\x33' + '\060', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b101011 + 0o7) + '\064' + chr(1381 - 1330), 0b1000), ehT0Px3KOsy9(chr(1506 - 1458) + chr(111) + '\x33' + chr(0b110111) + chr(55), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110011) + chr(0b110010) + '\x33', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\x32' + chr(51) + chr(50), ord("\x08")), ehT0Px3KOsy9(chr(1212 - 1164) + chr(0b1100 + 0o143) + chr(0b1101 + 0o51), 41684 - 41676), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\063' + chr(0b10010 + 0o45) + chr(2242 - 2190), 0b1000), ehT0Px3KOsy9(chr(2295 - 2247) + chr(111) + chr(2247 - 2198) + chr(51), 0o10), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(0b1100 + 0o143) + chr(0b1010 + 0o52) + chr(53), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1011010 + 0o25) + chr(0b110110) + chr(0b11111 + 0o21), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(352 - 299) + chr(55), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x32' + '\062' + '\x34', 17765 - 17757), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(625 - 575) + '\x35' + chr(0b110011), 60290 - 60282), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110011) + chr(0b111 + 0o55) + '\x37', ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + '\x6f' + chr(2363 - 2310) + '\060', 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x18'), '\144' + '\x65' + chr(0b1100011) + chr(111) + '\x64' + chr(0b1100101))('\x75' + chr(0b1000101 + 0o57) + chr(4212 - 4110) + chr(45) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def wpELjb2URkjU():
n4ljua2gi1Pr = qcOiVha39Kfr()
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(1466 - 1418) + chr(0b101100 + 0o103) + '\064', 0o10)
n4ljua2gi1Pr.Hj_JCZasfmqG = n4ljua2gi1Pr.PZHUuenu09ti = ehT0Px3KOsy9('\x30' + chr(8316 - 8205) + '\x30', ord("\x08"))
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(48) + chr(0b1010001 + 0o36) + '\064' + chr(0b110000) + chr(0b1001 + 0o47), 48257 - 48249)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(0b1101111) + chr(0b110001) + '\x30' + '\060' + chr(48), ord("\x08"))
n4ljua2gi1Pr.jZh5_pLUoOoZ = ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b100 + 0o62), 8)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_sep_channels_8l
|
def imagetransformer_sep_channels_8l():
"""separate rgb embeddings."""
hparams = imagetransformer_base()
hparams.num_heads = 4
hparams.attention_key_channels = hparams.attention_value_channels = 0
hparams.hidden_size = 256
hparams.filter_size = 256
hparams.num_hidden_layers = 8
hparams.sampling_method = "random"
return hparams
|
python
|
def imagetransformer_sep_channels_8l():
"""separate rgb embeddings."""
hparams = imagetransformer_base()
hparams.num_heads = 4
hparams.attention_key_channels = hparams.attention_value_channels = 0
hparams.hidden_size = 256
hparams.filter_size = 256
hparams.num_hidden_layers = 8
hparams.sampling_method = "random"
return hparams
|
[
"def",
"imagetransformer_sep_channels_8l",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_base",
"(",
")",
"hparams",
".",
"num_heads",
"=",
"4",
"hparams",
".",
"attention_key_channels",
"=",
"hparams",
".",
"attention_value_channels",
"=",
"0",
"hparams",
".",
"hidden_size",
"=",
"256",
"hparams",
".",
"filter_size",
"=",
"256",
"hparams",
".",
"num_hidden_layers",
"=",
"8",
"hparams",
".",
"sampling_method",
"=",
"\"random\"",
"return",
"hparams"
] |
separate rgb embeddings.
|
[
"separate",
"rgb",
"embeddings",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L364-L373
|
train
|
separate rgb embeddings.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVB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XBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + '\157' + '\065' + chr(1432 - 1378), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b101001 + 0o106) + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(0b11000 + 0o30) + '\x6f' + chr(50) + '\x34', 0o10), ehT0Px3KOsy9('\060' + '\157' + chr(0b10111 + 0o32) + chr(0b101111 + 0o10) + chr(53), 0o10), ehT0Px3KOsy9('\060' + '\157' + chr(890 - 841) + chr(0b110100), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(1093 - 1044) + '\061' + '\066', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110010) + '\x31', 31352 - 31344), ehT0Px3KOsy9('\060' + chr(0b1100101 + 0o12) + '\063' + chr(1081 - 1027) + chr(49), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\x32' + '\x33' + chr(0b110011), 36073 - 36065), ehT0Px3KOsy9(chr(0b110000) + chr(10899 - 10788) + chr(0b10110 + 0o37) + '\062', 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b101 + 0o56) + chr(2209 - 2157) + chr(0b110110), 31286 - 31278), ehT0Px3KOsy9(chr(48) + '\x6f' + '\062' + chr(1916 - 1864) + '\x33', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110001) + chr(49) + '\061', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b100111 + 0o110) + chr(50) + chr(0b110011 + 0o3) + '\x36', 0b1000), ehT0Px3KOsy9('\060' + chr(932 - 821) + chr(50) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(50) + '\063' + '\x37', 0b1000), ehT0Px3KOsy9(chr(401 - 353) + '\157' + '\x36' + chr(49), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b11000 + 0o31) + chr(0b110000) + chr(52), 33403 - 33395), ehT0Px3KOsy9(chr(48) + '\157' + chr(54) + chr(0b110111), 47755 - 47747), ehT0Px3KOsy9(chr(1001 - 953) + chr(3183 - 3072) + chr(49) + '\061' + chr(0b110100), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b1110 + 0o43) + chr(0b1001 + 0o50) + chr(0b110100), 8), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b10000 + 0o41) + chr(49) + '\066', 8), ehT0Px3KOsy9('\x30' + '\157' + '\063' + '\x34' + chr(53), 0b1000), ehT0Px3KOsy9('\060' + '\157' + '\062' + chr(0b101 + 0o53) + '\062', 19650 - 19642), ehT0Px3KOsy9('\060' + chr(0b11110 + 0o121) + chr(0b110010) + chr(1832 - 1784) + '\065', 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b10110 + 0o33) + chr(0b1111 + 0o47), 25697 - 25689), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(52) + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(1255 - 1207) + chr(0b110111 + 0o70) + '\x31' + '\065' + chr(567 - 515), ord("\x08")), ehT0Px3KOsy9(chr(1026 - 978) + chr(111) + chr(0b101100 + 0o7) + chr(2423 - 2369) + chr(0b100101 + 0o21), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(49) + chr(0b101101 + 0o11) + chr(1902 - 1847), 0b1000), ehT0Px3KOsy9(chr(438 - 390) + chr(0b1101111) + chr(2279 - 2229) + '\067' + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(1044 - 996) + '\157' + chr(0b110001) + '\x31', 0b1000), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(1794 - 1683) + chr(0b1001 + 0o51) + '\064' + '\060', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(11670 - 11559) + '\062' + chr(0b110001) + '\x31', 0o10), ehT0Px3KOsy9(chr(677 - 629) + '\x6f' + chr(0b110001) + '\x36' + chr(55), 8), ehT0Px3KOsy9(chr(0b10 + 0o56) + chr(0b100110 + 0o111) + chr(0b100010 + 0o21) + chr(0b101101 + 0o12) + chr(0b11011 + 0o30), 0b1000), ehT0Px3KOsy9(chr(400 - 352) + '\x6f' + chr(50) + chr(913 - 858) + chr(0b1111 + 0o47), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\061' + '\063' + '\x31', 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(1752 - 1703) + '\067' + '\x32', 63136 - 63128)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(1673 - 1625) + chr(0b1101111) + '\065' + chr(0b110000), 17200 - 17192)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x00'), chr(4712 - 4612) + chr(0b1100101) + '\143' + chr(10495 - 10384) + chr(100) + chr(6481 - 6380))(chr(117) + chr(0b1110100) + chr(0b1100 + 0o132) + '\055' + chr(830 - 774)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def g3k4ND1EpGdS():
n4ljua2gi1Pr = qcOiVha39Kfr()
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(701 - 653) + '\157' + chr(2485 - 2433), 8)
n4ljua2gi1Pr.Hj_JCZasfmqG = n4ljua2gi1Pr.PZHUuenu09ti = ehT0Px3KOsy9(chr(0b11000 + 0o30) + '\157' + chr(0b110000), 28025 - 28017)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(48) + '\157' + chr(52) + '\060' + '\060', 0b1000)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9('\060' + chr(5267 - 5156) + chr(52) + chr(1596 - 1548) + '\060', 8)
n4ljua2gi1Pr.jZh5_pLUoOoZ = ehT0Px3KOsy9('\060' + '\157' + '\061' + '\060', 20236 - 20228)
n4ljua2gi1Pr.Ud1InQ7hapop = xafqLlk3kkUe(SXOLrMavuUCe(b'\\`jp\x12a'), '\144' + chr(0b101110 + 0o67) + chr(0b1100011) + '\x6f' + chr(100) + '\145')('\x75' + chr(0b1010011 + 0o41) + chr(102) + chr(0b101101) + '\070')
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_base_8l_8h_big_cond_dr03_dan
|
def imagetransformer_base_8l_8h_big_cond_dr03_dan():
"""big 1d model for conditional image generation.2.99 on cifar10."""
hparams = imagetransformer_sep_channels_8l()
hparams.block_width = 256
hparams.block_length = 256
hparams.hidden_size = 512
hparams.num_heads = 8
hparams.filter_size = 2048
hparams.batch_size = 4
hparams.max_length = 3075
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.num_decoder_layers = 8
hparams.layer_prepostprocess_dropout = 0.3
return hparams
|
python
|
def imagetransformer_base_8l_8h_big_cond_dr03_dan():
"""big 1d model for conditional image generation.2.99 on cifar10."""
hparams = imagetransformer_sep_channels_8l()
hparams.block_width = 256
hparams.block_length = 256
hparams.hidden_size = 512
hparams.num_heads = 8
hparams.filter_size = 2048
hparams.batch_size = 4
hparams.max_length = 3075
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.num_decoder_layers = 8
hparams.layer_prepostprocess_dropout = 0.3
return hparams
|
[
"def",
"imagetransformer_base_8l_8h_big_cond_dr03_dan",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_sep_channels_8l",
"(",
")",
"hparams",
".",
"block_width",
"=",
"256",
"hparams",
".",
"block_length",
"=",
"256",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"num_heads",
"=",
"8",
"hparams",
".",
"filter_size",
"=",
"2048",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"max_length",
"=",
"3075",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"hparams",
".",
"num_decoder_layers",
"=",
"8",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.3",
"return",
"hparams"
] |
big 1d model for conditional image generation.2.99 on cifar10.
|
[
"big",
"1d",
"model",
"for",
"conditional",
"image",
"generation",
".",
"2",
".",
"99",
"on",
"cifar10",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L386-L400
|
train
|
big 1d model for conditional image generation. 2. 99 on cifar10.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcY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8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(2039 - 1991) + chr(111) + chr(50) + '\x32' + chr(0b110101), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b100100 + 0o15) + '\x31' + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(0b1100 + 0o44) + chr(0b1100111 + 0o10) + chr(2160 - 2110) + chr(1320 - 1270) + chr(0b10110 + 0o37), 8), ehT0Px3KOsy9('\x30' + '\157' + '\061' + chr(1494 - 1444) + chr(2188 - 2138), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(3092 - 2981) + chr(0b110011) + chr(48) + chr(0b1000 + 0o51), 26000 - 25992), ehT0Px3KOsy9('\x30' + chr(6669 - 6558) + chr(525 - 475) + chr(0b11101 + 0o25) + chr(0b101001 + 0o13), 0o10), ehT0Px3KOsy9(chr(1398 - 1350) + chr(116 - 5) + '\x33' + chr(0b11010 + 0o30), 0b1000), ehT0Px3KOsy9(chr(1202 - 1154) + chr(7982 - 7871) + chr(51) + chr(0b100110 + 0o16), 60503 - 60495), ehT0Px3KOsy9('\060' + chr(111) + '\062' + chr(2648 - 2594), 43042 - 43034), ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(0b1101111) + chr(0b1100 + 0o45) + chr(0b110111) + '\060', 0o10), ehT0Px3KOsy9(chr(1576 - 1528) + '\x6f' + '\062' + chr(0b0 + 0o66), 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x33' + '\x33' + chr(897 - 847), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110100) + '\x34', 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(49) + '\x35' + '\067', 10131 - 10123), ehT0Px3KOsy9(chr(1096 - 1048) + chr(0b1101111) + chr(1442 - 1393) + chr(0b100011 + 0o22) + chr(1222 - 1174), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110001) + chr(50) + '\063', 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110001) + chr(0b110010), 0b1000), ehT0Px3KOsy9('\060' + chr(9618 - 9507) + chr(50) + '\x37' + chr(0b1 + 0o64), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b101011 + 0o13), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\063' + chr(0b110100) + '\x32', 0o10), ehT0Px3KOsy9(chr(1466 - 1418) + chr(0b1101111) + chr(51) + '\x37' + chr(1030 - 980), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(10510 - 10399) + '\x32' + '\061' + chr(0b110101), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b11011 + 0o124) + chr(682 - 633) + '\x30' + '\060', 4602 - 4594), ehT0Px3KOsy9(chr(88 - 40) + chr(0b1101111) + '\061' + chr(49) + '\x36', 0b1000), ehT0Px3KOsy9(chr(2251 - 2203) + chr(0b10111 + 0o130) + '\065' + '\x35', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101100 + 0o3) + '\x36' + chr(2143 - 2094), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(7905 - 7794) + chr(0b11000 + 0o33) + chr(0b100010 + 0o25), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(150 - 100) + chr(2145 - 2093), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b111011 + 0o64) + chr(0b10011 + 0o36) + '\x34' + chr(0b110010), 49001 - 48993), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b100000 + 0o21) + chr(0b110001) + chr(2059 - 2009), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(0b100001 + 0o24) + '\x30', 25067 - 25059), ehT0Px3KOsy9('\x30' + chr(0b100101 + 0o112) + '\061' + '\x36' + chr(0b100101 + 0o20), ord("\x08")), ehT0Px3KOsy9(chr(1886 - 1838) + chr(10947 - 10836) + '\061' + chr(1449 - 1399) + chr(0b100111 + 0o15), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(49) + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(0b0 + 0o60) + '\157' + chr(51) + '\067' + chr(1191 - 1141), 8), ehT0Px3KOsy9(chr(2152 - 2104) + '\x6f' + chr(50) + chr(0b110000) + chr(50), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(51), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(1400 - 1351) + chr(0b110101) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110011) + chr(0b111 + 0o60) + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(0b100100 + 0o14) + chr(8861 - 8750) + chr(1840 - 1791) + chr(54) + chr(0b110000), 46346 - 46338)][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + chr(0b1001000 + 0o47) + chr(53) + '\x30', 8)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xbb'), chr(0b1100100) + '\145' + chr(99) + chr(2240 - 2129) + chr(7163 - 7063) + '\145')('\x75' + '\164' + chr(0b1100110) + chr(0b11 + 0o52) + chr(1811 - 1755)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def x0CHyP_lfSrD():
n4ljua2gi1Pr = g3k4ND1EpGdS()
n4ljua2gi1Pr.H_cF2TKAb4ed = ehT0Px3KOsy9('\x30' + '\x6f' + '\x34' + chr(0b110000) + '\x30', 0b1000)
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9(chr(0b101101 + 0o3) + '\157' + chr(0b110100) + chr(48) + chr(0b110000), 8)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9('\x30' + '\157' + '\x31' + chr(48) + '\x30' + '\060', 0o10)
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(1205 - 1157) + '\x6f' + chr(232 - 183) + chr(48), 0o10)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9('\x30' + '\x6f' + chr(52) + '\060' + chr(1499 - 1451) + chr(1995 - 1947), 0b1000)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(0b101000 + 0o10) + chr(0b1101111) + '\x34', 0o10)
n4ljua2gi1Pr._o7pVXAdOCRy = ehT0Px3KOsy9('\060' + '\x6f' + chr(54) + chr(0b110000) + chr(2131 - 2083) + '\063', ord("\x08"))
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b"\xfb'\xfb7"), chr(9870 - 9770) + chr(0b1100101 + 0o0) + '\143' + chr(0b1001111 + 0o40) + chr(0b1100100) + chr(2352 - 2251))('\x75' + chr(8679 - 8563) + chr(0b1100110) + '\x2d' + chr(56))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'\xf1)\xfb'), chr(5084 - 4984) + chr(101) + chr(7288 - 7189) + chr(111) + '\144' + chr(0b1100101))(chr(0b100010 + 0o123) + '\164' + '\146' + '\x2d' + chr(56))
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(785 - 737) + '\x6f' + chr(0b110001) + chr(0b110000), 8)
n4ljua2gi1Pr.RW_xSzp18UeS = 0.3
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_base_10l_8h_big_uncond_dr03_dan_64
|
def imagetransformer_base_10l_8h_big_uncond_dr03_dan_64():
"""big 1d model for unconditional generation on imagenet."""
hparams = imagetransformer_base_10l_8h_big_cond_dr03_dan()
hparams.unconditional = True
hparams.max_length = 14000
hparams.batch_size = 1
hparams.img_len = 64
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
python
|
def imagetransformer_base_10l_8h_big_uncond_dr03_dan_64():
"""big 1d model for unconditional generation on imagenet."""
hparams = imagetransformer_base_10l_8h_big_cond_dr03_dan()
hparams.unconditional = True
hparams.max_length = 14000
hparams.batch_size = 1
hparams.img_len = 64
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
[
"def",
"imagetransformer_base_10l_8h_big_uncond_dr03_dan_64",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_base_10l_8h_big_cond_dr03_dan",
"(",
")",
"hparams",
".",
"unconditional",
"=",
"True",
"hparams",
".",
"max_length",
"=",
"14000",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"img_len",
"=",
"64",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.1",
"return",
"hparams"
] |
big 1d model for unconditional generation on imagenet.
|
[
"big",
"1d",
"model",
"for",
"unconditional",
"generation",
"on",
"imagenet",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L404-L412
|
train
|
big 1d model for unconditional generation on imagenet.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNBHlx,ZsDPvpP4xdo3,cW7yQuyEnJ6E,KOHQGQ8qLDWm,NE1Yam2HHroQ,ygAzbDzrvRMh,SBRjvOU1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,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + '\x6f' + chr(395 - 346) + '\063' + '\065', 0o10), ehT0Px3KOsy9(chr(0b101111 + 0o1) + chr(111) + '\x31' + chr(0b110010) + chr(0b101001 + 0o12), 0o10), ehT0Px3KOsy9('\x30' + chr(10913 - 10802) + '\x31' + chr(0b10010 + 0o40) + '\x31', 54745 - 54737), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(51) + chr(0b11001 + 0o30) + chr(51), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(4379 - 4268) + '\062' + chr(2647 - 2595) + chr(0b101100 + 0o7), 8216 - 8208), ehT0Px3KOsy9(chr(526 - 478) + chr(11911 - 11800) + '\063' + chr(54) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110011) + chr(0b110110) + chr(53), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110111) + chr(55), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110001) + '\x31' + chr(54), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b10000 + 0o43) + chr(0b10011 + 0o43), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x32' + chr(0b110111) + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(197 - 149) + '\157' + chr(995 - 946) + chr(48) + chr(335 - 282), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\x32' + '\063' + chr(54), 34889 - 34881), ehT0Px3KOsy9(chr(0b101001 + 0o7) + chr(0b1101111) + chr(0b110001) + chr(1469 - 1417) + chr(54), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110011) + chr(0b10101 + 0o33) + '\x34', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b110110 + 0o71) + chr(51) + '\060' + chr(50), 9888 - 9880), ehT0Px3KOsy9('\x30' + chr(2813 - 2702) + chr(0b10111 + 0o34) + chr(0b1101 + 0o47) + chr(0b1000 + 0o56), ord("\x08")), ehT0Px3KOsy9(chr(0b0 + 0o60) + chr(11516 - 11405) + chr(51) + '\061' + '\x30', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(1849 - 1800) + chr(0b110011) + chr(0b11010 + 0o26), 0b1000), ehT0Px3KOsy9('\x30' + chr(5583 - 5472) + chr(2480 - 2429) + chr(1233 - 1179) + chr(53), 8), ehT0Px3KOsy9('\060' + chr(0b1100110 + 0o11) + chr(50) + '\067' + chr(48), 0o10), ehT0Px3KOsy9('\060' + '\157' + '\063' + '\x32' + chr(55), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + '\061' + chr(2012 - 1957) + chr(536 - 481), 0o10), ehT0Px3KOsy9(chr(617 - 569) + '\157' + chr(294 - 244) + chr(0b110100) + chr(53), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + '\061' + '\x32' + chr(50), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b10000 + 0o47) + '\x31', 48107 - 48099), ehT0Px3KOsy9(chr(892 - 844) + chr(111) + chr(0b1 + 0o63) + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(1812 - 1764) + '\157' + '\x31' + chr(52) + chr(0b110000), 3683 - 3675), ehT0Px3KOsy9('\x30' + chr(0b1011 + 0o144) + chr(0b11 + 0o60) + '\x37' + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(493 - 445) + '\x6f' + chr(2211 - 2161) + chr(2267 - 2212) + '\x34', 0o10), ehT0Px3KOsy9(chr(255 - 207) + chr(0b1101111) + chr(0b10101 + 0o35) + chr(0b110010) + chr(53), 0b1000), ehT0Px3KOsy9(chr(627 - 579) + chr(0b1010101 + 0o32) + chr(0b100001 + 0o20) + chr(1554 - 1505) + '\060', 0o10), ehT0Px3KOsy9('\x30' + '\157' + '\061' + chr(1970 - 1915) + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(828 - 780) + chr(0b1101111) + '\063' + chr(1722 - 1672) + chr(1353 - 1299), 0b1000), ehT0Px3KOsy9(chr(1869 - 1821) + '\157' + chr(1121 - 1071) + chr(0b101001 + 0o10) + chr(0b110110 + 0o1), 6783 - 6775), ehT0Px3KOsy9('\060' + '\x6f' + chr(2073 - 2023) + '\066' + chr(52), 0b1000), ehT0Px3KOsy9(chr(1228 - 1180) + '\x6f' + '\x32' + chr(50) + chr(52), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(50) + chr(0b101001 + 0o14) + chr(0b110011 + 0o3), 2311 - 2303), ehT0Px3KOsy9(chr(48) + chr(0b1100100 + 0o13) + '\x33' + chr(1147 - 1092) + chr(0b110000 + 0o6), 0o10), ehT0Px3KOsy9('\060' + chr(0b101100 + 0o103) + chr(0b1 + 0o61) + '\x33' + chr(0b1111 + 0o44), ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(1711 - 1658) + chr(0b110000), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b's'), chr(0b100001 + 0o103) + chr(9041 - 8940) + '\143' + '\157' + '\144' + chr(0b1100101))(chr(0b101001 + 0o114) + '\x74' + '\146' + chr(45) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def fhwxkWvqdXR8():
n4ljua2gi1Pr = TS_4t0ewPrP2()
n4ljua2gi1Pr.IcYfltg0WkcT = ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b101101 + 0o4), 0o10)
n4ljua2gi1Pr._o7pVXAdOCRy = ehT0Px3KOsy9(chr(48) + chr(0b10011 + 0o134) + chr(739 - 688) + chr(0b10110 + 0o35) + '\x32' + chr(0b110110) + chr(130 - 82), 0b1000)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(0b100110 + 0o12) + chr(8010 - 7899) + '\x31', 8)
n4ljua2gi1Pr.laxD7jy5y7k1 = ehT0Px3KOsy9(chr(48) + '\157' + chr(49) + chr(1770 - 1722) + '\x30', 0b1000)
n4ljua2gi1Pr.RW_xSzp18UeS = 0.1
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformerpp_sep_channels_8l_8h
|
def imagetransformerpp_sep_channels_8l_8h():
"""separate rgb embeddings."""
hparams = imagetransformer_base()
hparams.likelihood = cia.DistributionType.DMOL
hparams.num_channels = 1
hparams.bottom["targets"] = modalities.image_channel_compress_targets_bottom
hparams.top["targets"] = modalities.identity_top
hparams.num_heads = 8
hparams.batch_size = 4
hparams.attention_key_channels = hparams.attention_value_channels = 0
hparams.hidden_size = 512
hparams.filter_size = 512
hparams.num_hidden_layers = 8
hparams.sampling_method = "random"
hparams.layer_preprocess_sequence = "n"
hparams.layer_postprocess_sequence = "da"
hparams.summarize_grads = True
hparams.learning_rate = 0.1
return hparams
|
python
|
def imagetransformerpp_sep_channels_8l_8h():
"""separate rgb embeddings."""
hparams = imagetransformer_base()
hparams.likelihood = cia.DistributionType.DMOL
hparams.num_channels = 1
hparams.bottom["targets"] = modalities.image_channel_compress_targets_bottom
hparams.top["targets"] = modalities.identity_top
hparams.num_heads = 8
hparams.batch_size = 4
hparams.attention_key_channels = hparams.attention_value_channels = 0
hparams.hidden_size = 512
hparams.filter_size = 512
hparams.num_hidden_layers = 8
hparams.sampling_method = "random"
hparams.layer_preprocess_sequence = "n"
hparams.layer_postprocess_sequence = "da"
hparams.summarize_grads = True
hparams.learning_rate = 0.1
return hparams
|
[
"def",
"imagetransformerpp_sep_channels_8l_8h",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_base",
"(",
")",
"hparams",
".",
"likelihood",
"=",
"cia",
".",
"DistributionType",
".",
"DMOL",
"hparams",
".",
"num_channels",
"=",
"1",
"hparams",
".",
"bottom",
"[",
"\"targets\"",
"]",
"=",
"modalities",
".",
"image_channel_compress_targets_bottom",
"hparams",
".",
"top",
"[",
"\"targets\"",
"]",
"=",
"modalities",
".",
"identity_top",
"hparams",
".",
"num_heads",
"=",
"8",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"attention_key_channels",
"=",
"hparams",
".",
"attention_value_channels",
"=",
"0",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"filter_size",
"=",
"512",
"hparams",
".",
"num_hidden_layers",
"=",
"8",
"hparams",
".",
"sampling_method",
"=",
"\"random\"",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"n\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"da\"",
"hparams",
".",
"summarize_grads",
"=",
"True",
"hparams",
".",
"learning_rate",
"=",
"0.1",
"return",
"hparams"
] |
separate rgb embeddings.
|
[
"separate",
"rgb",
"embeddings",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L416-L434
|
train
|
separate rgb embeddings.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_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HaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + chr(0b1101110 + 0o1) + '\062' + chr(0b110111) + chr(0b100000 + 0o20), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1011110 + 0o21) + chr(224 - 174) + chr(0b10101 + 0o40) + chr(0b110001), ord("\x08")), ehT0Px3KOsy9(chr(205 - 157) + chr(0b1101111) + chr(51) + chr(0b110101) + '\x30', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b111101 + 0o62) + '\x32' + '\064' + '\066', 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x32' + chr(0b110001) + chr(0b100 + 0o55), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(294 - 244) + chr(0b110 + 0o56) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(1351 - 1303) + chr(6571 - 6460) + chr(0b110111) + chr(0b110101), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(1404 - 1355) + chr(0b10100 + 0o35) + '\064', 9557 - 9549), ehT0Px3KOsy9('\060' + chr(111) + '\x31' + '\061', 0o10), ehT0Px3KOsy9(chr(883 - 835) + chr(0b1011110 + 0o21) + '\x33' + '\x32' + chr(306 - 256), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b11110 + 0o25) + chr(156 - 105) + '\061', 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(0b100 + 0o55) + chr(50) + '\061', 0o10), ehT0Px3KOsy9(chr(0b100101 + 0o13) + chr(0b1011111 + 0o20) + '\063' + chr(0b10001 + 0o45) + '\060', 12199 - 12191), ehT0Px3KOsy9(chr(48) + chr(0b1101010 + 0o5) + '\063' + '\066', 4140 - 4132), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(2388 - 2337) + chr(2072 - 2023) + chr(2267 - 2219), 43990 - 43982), ehT0Px3KOsy9('\060' + chr(0b101000 + 0o107) + '\x31' + '\x31' + '\x30', 63812 - 63804), ehT0Px3KOsy9('\x30' + '\157' + chr(1560 - 1509) + '\x35', ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(50) + chr(0b100100 + 0o20) + '\x30', 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b1000111 + 0o50) + '\061' + chr(0b110100) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110011 + 0o4) + chr(1662 - 1611), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110010) + chr(384 - 335) + '\067', 15058 - 15050), ehT0Px3KOsy9(chr(645 - 597) + '\157' + '\x33' + chr(0b110000 + 0o1) + '\x36', 0b1000), ehT0Px3KOsy9(chr(48) + chr(9075 - 8964) + '\x32' + chr(0b10110 + 0o34) + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110011) + chr(52) + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(0b100011 + 0o15) + chr(0b1010000 + 0o37) + chr(0b11010 + 0o27) + '\061' + chr(0b110011), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101100 + 0o3) + chr(0b100010 + 0o20) + chr(0b101011 + 0o7) + chr(0b1101 + 0o50), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(0b11011 + 0o33) + '\x35', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b110111 + 0o70) + '\067' + chr(581 - 527), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1100101 + 0o12) + chr(50) + chr(2322 - 2269) + chr(0b101001 + 0o11), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x35' + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(3265 - 3154) + '\061' + '\061', 8), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b101010 + 0o7) + chr(2040 - 1989) + chr(51), 0o10), ehT0Px3KOsy9(chr(1672 - 1624) + chr(0b1101111) + chr(49) + chr(52) + chr(988 - 938), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1010 + 0o145) + chr(1532 - 1482) + chr(0b100100 + 0o15) + '\x37', 8), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(49) + chr(2669 - 2614) + chr(2078 - 2027), 42267 - 42259), ehT0Px3KOsy9(chr(0b101111 + 0o1) + chr(0b111111 + 0o60) + chr(0b100 + 0o55) + '\061' + chr(0b10011 + 0o41), 8), ehT0Px3KOsy9(chr(48) + chr(0b11110 + 0o121) + chr(0b110011) + '\066' + chr(451 - 402), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(1626 - 1515) + chr(50) + chr(54) + chr(0b110010), 60968 - 60960), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110101) + chr(0b1111 + 0o41), 0b1000), ehT0Px3KOsy9(chr(595 - 547) + '\x6f' + chr(265 - 214) + chr(2528 - 2477) + chr(0b110001), 8)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(111) + chr(0b100101 + 0o20) + chr(0b1 + 0o57), 8)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x96'), '\144' + chr(0b1100101) + chr(0b110110 + 0o55) + chr(111) + chr(100) + '\145')(chr(0b111 + 0o156) + chr(116) + chr(102) + '\055' + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def jNScdXltATXC():
n4ljua2gi1Pr = qcOiVha39Kfr()
n4ljua2gi1Pr.LcCIWJ2WYLVy = oIL3U1EOcJgs.DistributionType.DMOL
n4ljua2gi1Pr.X1ZpHSxyKbHn = ehT0Px3KOsy9('\060' + chr(111) + chr(103 - 54), 0o10)
n4ljua2gi1Pr.kXxsZxlIQUSQ[xafqLlk3kkUe(SXOLrMavuUCe(b'\xcc\xc8\x9a\xc1\xec\xd4N'), chr(0b1101 + 0o127) + chr(4420 - 4319) + '\143' + chr(7390 - 7279) + chr(1885 - 1785) + chr(0b100110 + 0o77))(chr(1260 - 1143) + chr(116) + chr(102) + chr(0b10000 + 0o35) + chr(0b1000 + 0o60))] = PuPeNl0CuqOQ.image_channel_compress_targets_bottom
n4ljua2gi1Pr.qxrVBjeryNEZ[xafqLlk3kkUe(SXOLrMavuUCe(b'\xcc\xc8\x9a\xc1\xec\xd4N'), chr(0b1100100) + chr(101) + '\143' + chr(0b1000101 + 0o52) + chr(0b1100100) + '\x65')(chr(0b10010 + 0o143) + chr(0b1011110 + 0o26) + '\x66' + '\x2d' + chr(0b111000))] = PuPeNl0CuqOQ.identity_top
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(48) + chr(111) + '\x31' + chr(0b11100 + 0o24), 0o10)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(0b1111 + 0o41) + chr(0b1100101 + 0o12) + '\064', ord("\x08"))
n4ljua2gi1Pr.Hj_JCZasfmqG = n4ljua2gi1Pr.PZHUuenu09ti = ehT0Px3KOsy9(chr(0b100000 + 0o20) + chr(0b100000 + 0o117) + chr(48), 0b1000)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9('\060' + '\x6f' + '\061' + chr(48) + chr(879 - 831) + '\060', 43537 - 43529)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9('\060' + '\157' + chr(49) + '\060' + chr(0b10111 + 0o31) + chr(48), 8)
n4ljua2gi1Pr.jZh5_pLUoOoZ = ehT0Px3KOsy9('\x30' + '\157' + chr(0b10101 + 0o34) + '\060', 8)
n4ljua2gi1Pr.Ud1InQ7hapop = xafqLlk3kkUe(SXOLrMavuUCe(b'\xca\xc8\x86\xc2\xe6\xcd'), chr(0b1100100) + chr(0b1100101) + chr(2863 - 2764) + chr(1345 - 1234) + chr(0b110011 + 0o61) + '\145')(chr(7791 - 7674) + chr(116) + '\x66' + '\x2d' + chr(1905 - 1849))
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'\xd6'), chr(0b1100100) + chr(0b101111 + 0o66) + chr(0b110011 + 0o60) + '\157' + chr(0b1100100) + '\x65')(chr(8093 - 7976) + chr(116) + chr(0b1100110) + chr(0b1101 + 0o40) + chr(0b0 + 0o70))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'\xdc\xc8'), chr(0b1010001 + 0o23) + chr(0b1100101) + '\143' + chr(210 - 99) + '\x64' + '\x65')('\165' + chr(0b1110100) + chr(102) + chr(0b101101) + chr(56))
n4ljua2gi1Pr.g1CKJR0X4YHm = ehT0Px3KOsy9('\060' + chr(0b10010 + 0o135) + '\061', 8)
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.1
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformerpp_base_8l_8h_big_cond_dr03_dan
|
def imagetransformerpp_base_8l_8h_big_cond_dr03_dan():
"""big 1d model for conditional image generation.2.99 on cifar10."""
hparams = imagetransformerpp_sep_channels_8l_8h()
hparams.hidden_size = 512
hparams.num_heads = 8
hparams.filter_size = 2048
hparams.batch_size = 4
hparams.max_length = 3075
hparams.layer_prepostprocess_dropout = 0.3
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.summarize_grads = True
hparams.learning_rate = 0.01
return hparams
|
python
|
def imagetransformerpp_base_8l_8h_big_cond_dr03_dan():
"""big 1d model for conditional image generation.2.99 on cifar10."""
hparams = imagetransformerpp_sep_channels_8l_8h()
hparams.hidden_size = 512
hparams.num_heads = 8
hparams.filter_size = 2048
hparams.batch_size = 4
hparams.max_length = 3075
hparams.layer_prepostprocess_dropout = 0.3
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.summarize_grads = True
hparams.learning_rate = 0.01
return hparams
|
[
"def",
"imagetransformerpp_base_8l_8h_big_cond_dr03_dan",
"(",
")",
":",
"hparams",
"=",
"imagetransformerpp_sep_channels_8l_8h",
"(",
")",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"num_heads",
"=",
"8",
"hparams",
".",
"filter_size",
"=",
"2048",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"max_length",
"=",
"3075",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.3",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"hparams",
".",
"summarize_grads",
"=",
"True",
"hparams",
".",
"learning_rate",
"=",
"0.01",
"return",
"hparams"
] |
big 1d model for conditional image generation.2.99 on cifar10.
|
[
"big",
"1d",
"model",
"for",
"conditional",
"image",
"generation",
".",
"2",
".",
"99",
"on",
"cifar10",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L438-L451
|
train
|
big 1d model for conditional image generation. 2. 99 on cifar10.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNBHlx,ZsDPvpP4xdo3,cW7yQuyEnJ6E,KOHQGQ8qLDWm,NE1Yam2HHroQ,ygAzbDzrvRMh,SBRjvOU1ufVC,hOkXjmluKZfJ,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LkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(111) + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b111001 + 0o66) + chr(0b1111 + 0o44) + '\061', 0b1000), ehT0Px3KOsy9(chr(339 - 291) + chr(8234 - 8123) + chr(50) + chr(0b110101) + '\x31', 7340 - 7332), ehT0Px3KOsy9(chr(0b110000) + chr(0b110001 + 0o76) + chr(1298 - 1248) + chr(54) + chr(0b110101), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(1575 - 1526) + '\x35' + chr(0b110100), ord("\x08")), ehT0Px3KOsy9(chr(1010 - 962) + chr(0b1101111) + chr(0b10101 + 0o34) + '\x32' + '\x35', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(53) + '\064', 0b1000), ehT0Px3KOsy9(chr(1396 - 1348) + chr(111) + chr(0b110011) + '\065' + chr(1090 - 1041), 0o10), ehT0Px3KOsy9('\x30' + chr(1788 - 1677) + '\x37' + chr(50), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + '\064' + chr(0b101 + 0o55), 61355 - 61347), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b100001 + 0o20) + '\x35' + chr(1901 - 1852), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(10053 - 9942) + '\064' + chr(900 - 850), 8), ehT0Px3KOsy9(chr(48) + chr(0b100110 + 0o111) + chr(50) + chr(0b101110 + 0o6), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1000011 + 0o54) + '\066' + chr(2341 - 2288), 0o10), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(2581 - 2470) + '\061' + chr(0b1000 + 0o54) + chr(523 - 473), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\063' + '\067' + chr(48), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(2497 - 2447) + '\x36' + chr(0b110010), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x31' + chr(0b110000) + chr(52), 0b1000), ehT0Px3KOsy9(chr(0b1001 + 0o47) + '\x6f' + chr(541 - 491) + chr(2514 - 2462) + chr(0b10 + 0o60), 0o10), ehT0Px3KOsy9('\060' + chr(722 - 611) + chr(0b10000 + 0o42) + chr(0b1111 + 0o45) + '\x37', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(6450 - 6339) + chr(0b110011) + chr(2469 - 2415) + chr(0b100100 + 0o15), 38435 - 38427), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\061' + chr(53) + chr(48), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(4100 - 3989) + '\x31' + chr(0b100000 + 0o24) + chr(2401 - 2346), 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(0b0 + 0o61) + chr(0b1000 + 0o53) + '\066', 0b1000), ehT0Px3KOsy9(chr(0b1011 + 0o45) + '\x6f' + chr(0b101 + 0o56) + '\063' + chr(845 - 793), 37365 - 37357), ehT0Px3KOsy9(chr(2071 - 2023) + chr(0b1011110 + 0o21) + '\063', 11935 - 11927), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(53), 12763 - 12755), ehT0Px3KOsy9('\060' + chr(111) + '\062' + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(103 - 52) + chr(362 - 311) + chr(54), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\066' + chr(0b110011), 40298 - 40290), ehT0Px3KOsy9('\060' + '\157' + chr(55) + chr(0b110001), 23696 - 23688), ehT0Px3KOsy9('\x30' + chr(111) + chr(50) + '\x31' + chr(0b100011 + 0o16), 50117 - 50109), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x32' + '\x32' + '\066', ord("\x08")), ehT0Px3KOsy9(chr(0b100011 + 0o15) + chr(6756 - 6645) + chr(49) + '\x35' + chr(0b101111 + 0o1), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110001) + chr(0b110011) + chr(50), 644 - 636), ehT0Px3KOsy9('\x30' + chr(0b110110 + 0o71) + chr(51) + chr(896 - 841) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(284 - 173) + chr(0b1100 + 0o47) + chr(0b110100) + chr(52), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + '\x33' + chr(0b101001 + 0o10) + '\066', 0b1000), ehT0Px3KOsy9(chr(0b10000 + 0o40) + '\157' + chr(0b110100) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b100011 + 0o114) + chr(158 - 109) + chr(0b110011) + '\x33', 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b101100 + 0o11) + '\x30', 12902 - 12894)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'.'), chr(1785 - 1685) + chr(0b1100101) + chr(733 - 634) + '\157' + chr(0b111111 + 0o45) + '\145')('\165' + chr(0b1000101 + 0o57) + chr(102) + '\055' + chr(2139 - 2083)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def q0nvlxyVt1Q_():
n4ljua2gi1Pr = jNScdXltATXC()
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110001) + '\060' + '\x30' + chr(0b110000), 64023 - 64015)
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(0b101000 + 0o10) + '\157' + chr(49) + chr(0b110000), ord("\x08"))
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(48) + '\x6f' + '\064' + '\060' + '\x30' + chr(0b100 + 0o54), 0o10)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(48) + chr(0b11010 + 0o125) + '\064', 32277 - 32269)
n4ljua2gi1Pr._o7pVXAdOCRy = ehT0Px3KOsy9('\x30' + chr(111) + chr(730 - 676) + '\060' + chr(0b100111 + 0o11) + '\063', 0o10)
n4ljua2gi1Pr.RW_xSzp18UeS = 0.3
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'nv\xc7\xd0'), chr(100) + chr(936 - 835) + chr(99) + '\x6f' + chr(0b1010001 + 0o23) + chr(0b11101 + 0o110))(chr(117) + '\x74' + '\x66' + chr(0b101101) + '\x38')
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'dx\xc7'), '\144' + chr(0b1001101 + 0o30) + chr(0b1100011) + '\x6f' + '\144' + chr(0b1001000 + 0o35))(chr(117) + '\x74' + chr(102) + chr(1633 - 1588) + chr(1244 - 1188))
n4ljua2gi1Pr.g1CKJR0X4YHm = ehT0Px3KOsy9('\x30' + chr(0b1101000 + 0o7) + chr(0b1110 + 0o43), 41804 - 41796)
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.01
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformerpp_base_14l_8h_big_uncond_dr03_dan_p
|
def imagetransformerpp_base_14l_8h_big_uncond_dr03_dan_p():
"""Gets to 2.92 in just under 4 days on 8 p100s."""
hparams = imagetransformerpp_base_12l_8h_big_uncond_dr03_dan_l()
hparams.num_decoder_layers = 14
hparams.batch_size = 8
hparams.layer_prepostprocess_dropout = 0.2
return hparams
|
python
|
def imagetransformerpp_base_14l_8h_big_uncond_dr03_dan_p():
"""Gets to 2.92 in just under 4 days on 8 p100s."""
hparams = imagetransformerpp_base_12l_8h_big_uncond_dr03_dan_l()
hparams.num_decoder_layers = 14
hparams.batch_size = 8
hparams.layer_prepostprocess_dropout = 0.2
return hparams
|
[
"def",
"imagetransformerpp_base_14l_8h_big_uncond_dr03_dan_p",
"(",
")",
":",
"hparams",
"=",
"imagetransformerpp_base_12l_8h_big_uncond_dr03_dan_l",
"(",
")",
"hparams",
".",
"num_decoder_layers",
"=",
"14",
"hparams",
".",
"batch_size",
"=",
"8",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.2",
"return",
"hparams"
] |
Gets to 2.92 in just under 4 days on 8 p100s.
|
[
"Gets",
"to",
"2",
".",
"92",
"in",
"just",
"under",
"4",
"days",
"on",
"8",
"p100s",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L537-L543
|
train
|
Gets to 2. 92 in just under 4 days on 8 p100s.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,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ZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(929 - 881) + chr(0b11 + 0o154) + chr(1805 - 1753) + '\x36', 0o10), ehT0Px3KOsy9('\060' + '\157' + chr(50) + chr(55) + '\062', 39654 - 39646), ehT0Px3KOsy9('\x30' + '\157' + chr(0b1101 + 0o44) + chr(0b101 + 0o56) + chr(0b101001 + 0o11), 0b1000), ehT0Px3KOsy9(chr(48) + chr(9823 - 9712) + chr(0b110001) + chr(0b110110) + chr(0b10111 + 0o40), 38359 - 38351), ehT0Px3KOsy9(chr(48) + chr(0b111001 + 0o66) + chr(0b11101 + 0o24) + chr(54) + chr(0b101110 + 0o2), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110011) + chr(0b110011) + '\066', 28422 - 28414), ehT0Px3KOsy9('\060' + '\157' + chr(51) + chr(2696 - 2644) + chr(53), 23811 - 23803), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(50) + chr(0b10000 + 0o47) + chr(1174 - 1123), 0o10), ehT0Px3KOsy9(chr(0b1011 + 0o45) + chr(0b1101111) + '\063' + '\061' + '\062', ord("\x08")), ehT0Px3KOsy9(chr(1017 - 969) + '\x6f' + chr(50) + chr(52) + chr(0b101000 + 0o14), 14087 - 14079), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(111) + '\x31' + chr(48) + chr(0b110100), 63283 - 63275), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b101100 + 0o5) + '\x35' + chr(1960 - 1909), 0o10), ehT0Px3KOsy9('\060' + chr(111) + '\061' + chr(0b110001) + chr(0b110111), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b101 + 0o55) + chr(0b110100) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9('\060' + chr(7198 - 7087) + '\x31' + '\061' + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(48) + chr(11313 - 11202) + '\x31' + '\061' + '\065', 47438 - 47430), ehT0Px3KOsy9('\060' + chr(0b1111 + 0o140) + '\x31' + chr(940 - 890) + '\x35', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1001 + 0o146) + chr(0b110010) + '\061' + chr(0b110000), 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110000 + 0o2) + chr(0b11000 + 0o34) + chr(0b110000), 0b1000), ehT0Px3KOsy9(chr(263 - 215) + chr(7548 - 7437) + chr(0b110011) + chr(52) + chr(0b110011), 54888 - 54880), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b11011 + 0o30) + '\x35' + chr(51), 0o10), ehT0Px3KOsy9('\060' + chr(0b11000 + 0o127) + '\x33' + '\x30' + '\x30', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1010 + 0o145) + chr(2175 - 2125) + '\x34' + '\062', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1010101 + 0o32) + chr(0b110011) + chr(52) + '\x34', 15242 - 15234), ehT0Px3KOsy9(chr(0b101001 + 0o7) + chr(111) + '\x32' + chr(0b11101 + 0o30) + '\062', 0b1000), ehT0Px3KOsy9(chr(1166 - 1118) + chr(0b1101111 + 0o0) + chr(0b11001 + 0o30) + chr(50), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\063' + chr(0b1001 + 0o54) + chr(53), 29329 - 29321), ehT0Px3KOsy9(chr(48) + chr(111) + '\061' + chr(52) + '\x31', 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\067' + '\066', 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + '\x33' + '\066' + '\x32', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(2708 - 2597) + chr(72 - 22) + '\063' + '\060', ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(49) + '\064' + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(1349 - 1301) + chr(11766 - 11655) + '\065' + chr(1869 - 1818), ord("\x08")), ehT0Px3KOsy9(chr(0b11 + 0o55) + chr(2108 - 1997) + '\x36', 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + '\x31' + chr(0b110101), 41397 - 41389), ehT0Px3KOsy9('\060' + chr(0b111111 + 0o60) + '\x31' + '\067', 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110011) + chr(0b110001) + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110010) + chr(2020 - 1966) + chr(0b11111 + 0o30), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110001) + chr(990 - 940) + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(952 - 904) + chr(0b1000010 + 0o55) + chr(0b1 + 0o61) + chr(1786 - 1738) + '\065', 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(0b100101 + 0o112) + chr(0b110101) + '\x30', ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x08'), chr(100) + '\x65' + chr(0b1100011) + chr(0b100111 + 0o110) + chr(0b101111 + 0o65) + '\145')(chr(117) + chr(0b1110100) + chr(102) + '\055' + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def _8cSablqc7Q4():
n4ljua2gi1Pr = ADH2IrX5vzQh()
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110001) + chr(54), 26220 - 26212)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(2160 - 2112) + '\157' + chr(0b1 + 0o60) + chr(149 - 101), 51756 - 51748)
n4ljua2gi1Pr.RW_xSzp18UeS = 0.2
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformerpp_base_5l_8h_big_uncond_dr00_dan_g_bs1
|
def imagetransformerpp_base_5l_8h_big_uncond_dr00_dan_g_bs1():
"""For 256x256."""
hparams = imagetransformerpp_base_10l_8h_big_uncond_dr03_dan_g()
# TODO(trandustin): I forgot to set this in the runs! Maybe it's not used in
# image transformer training implementation?
# hparams.img_len = 256
hparams.max_length = 66000 # allow for 256x256
hparams.batch_size = 1
hparams.num_decoder_layers = 5
hparams.hidden_size = 128
hparams.filter_size = 128
hparams.attention_key_channels = 64
hparams.attention_value_channels = 64
hparams.layer_prepostprocess_dropout = 0.0
return hparams
|
python
|
def imagetransformerpp_base_5l_8h_big_uncond_dr00_dan_g_bs1():
"""For 256x256."""
hparams = imagetransformerpp_base_10l_8h_big_uncond_dr03_dan_g()
# TODO(trandustin): I forgot to set this in the runs! Maybe it's not used in
# image transformer training implementation?
# hparams.img_len = 256
hparams.max_length = 66000 # allow for 256x256
hparams.batch_size = 1
hparams.num_decoder_layers = 5
hparams.hidden_size = 128
hparams.filter_size = 128
hparams.attention_key_channels = 64
hparams.attention_value_channels = 64
hparams.layer_prepostprocess_dropout = 0.0
return hparams
|
[
"def",
"imagetransformerpp_base_5l_8h_big_uncond_dr00_dan_g_bs1",
"(",
")",
":",
"hparams",
"=",
"imagetransformerpp_base_10l_8h_big_uncond_dr03_dan_g",
"(",
")",
"# TODO(trandustin): I forgot to set this in the runs! Maybe it's not used in",
"# image transformer training implementation?",
"# hparams.img_len = 256",
"hparams",
".",
"max_length",
"=",
"66000",
"# allow for 256x256",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"num_decoder_layers",
"=",
"5",
"hparams",
".",
"hidden_size",
"=",
"128",
"hparams",
".",
"filter_size",
"=",
"128",
"hparams",
".",
"attention_key_channels",
"=",
"64",
"hparams",
".",
"attention_value_channels",
"=",
"64",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.0",
"return",
"hparams"
] |
For 256x256.
|
[
"For",
"256x256",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L565-L579
|
train
|
For 256x256.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeX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M4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b10110 + 0o34) + chr(49) + chr(0b110111 + 0o0), 0o10), ehT0Px3KOsy9(chr(48) + chr(11667 - 11556) + '\061' + chr(0b1000 + 0o56) + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + '\061' + chr(2181 - 2133) + '\061', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b110110 + 0o71) + '\x33' + chr(1541 - 1491) + chr(2042 - 1988), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(140 - 90) + chr(0b101100 + 0o11) + chr(0b11001 + 0o36), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110001) + '\066' + '\062', ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(0b10011 + 0o44) + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b1110 + 0o45) + chr(49) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(1511 - 1463) + '\157' + chr(0b110001) + chr(50) + chr(0b1000 + 0o52), 65487 - 65479), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(0b100110 + 0o12) + chr(0b1101111) + chr(50) + chr(51) + '\x36', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b10101 + 0o132) + chr(902 - 852) + '\067' + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(0b10001 + 0o37) + chr(0b1101111) + chr(51) + chr(0b110111) + '\x35', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110001) + chr(49) + chr(0b110111), 0b1000), ehT0Px3KOsy9(chr(2145 - 2097) + '\157' + chr(91 - 41) + '\064', 38316 - 38308), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x31' + '\x32' + '\063', 0o10), ehT0Px3KOsy9('\x30' + chr(9980 - 9869) + '\x31' + chr(0b110001) + chr(0b111 + 0o60), 8), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110001) + chr(2464 - 2410) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(0b11110 + 0o22) + '\x6f' + chr(49) + chr(0b10111 + 0o31) + chr(125 - 73), 2240 - 2232), ehT0Px3KOsy9(chr(0b101011 + 0o5) + chr(4207 - 4096) + chr(49) + '\x34' + '\065', ord("\x08")), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(0b100011 + 0o114) + chr(51) + chr(53) + chr(0b110110), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b11101 + 0o24) + chr(0b11100 + 0o32) + chr(537 - 485), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110001) + chr(0b1001 + 0o56), 0b1000), ehT0Px3KOsy9(chr(96 - 48) + '\x6f' + chr(2212 - 2162) + '\x32' + chr(2529 - 2478), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(51) + '\x36' + '\067', 0o10), ehT0Px3KOsy9(chr(1260 - 1212) + chr(9712 - 9601) + chr(0b10111 + 0o34) + chr(50) + chr(0b110110), 8), ehT0Px3KOsy9('\x30' + chr(0b110101 + 0o72) + chr(0b110011) + chr(0b11110 + 0o25) + chr(0b101011 + 0o12), 11591 - 11583), ehT0Px3KOsy9(chr(48) + '\157' + chr(50) + chr(239 - 188) + '\065', 0o10), ehT0Px3KOsy9(chr(1998 - 1950) + chr(0b1001010 + 0o45) + chr(0b110010) + chr(54) + chr(0b11000 + 0o36), 0o10), ehT0Px3KOsy9(chr(1383 - 1335) + chr(111) + chr(0b110011) + chr(53) + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(1561 - 1513) + '\x6f' + chr(0b110001 + 0o0) + chr(1185 - 1131), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + '\x32' + chr(1400 - 1351) + '\067', 8), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\066' + chr(53), 0o10), ehT0Px3KOsy9(chr(0b100101 + 0o13) + '\x6f' + chr(51) + chr(0b1001 + 0o50) + '\065', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1000110 + 0o51) + chr(0b110010) + chr(53) + chr(0b110100), 0b1000), ehT0Px3KOsy9('\060' + chr(7000 - 6889) + '\x33' + chr(50) + chr(50), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(9053 - 8942) + '\x37' + '\x36', 0o10), ehT0Px3KOsy9('\x30' + chr(111) + '\x32' + chr(0b101 + 0o54) + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(175 - 127) + chr(111) + chr(0b110010) + '\x35' + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(0b110000 + 0o0) + '\157' + '\x31' + chr(0b110111) + '\x36', ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b11111 + 0o26) + chr(0b101011 + 0o5), 15026 - 15018)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xa1'), chr(100) + '\x65' + chr(3641 - 3542) + chr(977 - 866) + chr(0b1001111 + 0o25) + '\145')(chr(0b1101110 + 0o7) + chr(116) + '\x66' + chr(45) + chr(0b0 + 0o70)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def rZC7wBlIbOzV():
n4ljua2gi1Pr = to7ppheN1_dR()
n4ljua2gi1Pr._o7pVXAdOCRy = ehT0Px3KOsy9(chr(1146 - 1098) + chr(111) + chr(50) + '\x30' + chr(1698 - 1650) + chr(0b110111) + '\062' + chr(48), 34036 - 34028)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(49), 0o10)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(2013 - 1965) + chr(0b1101111) + chr(0b110101), 4681 - 4673)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9('\x30' + chr(10074 - 9963) + chr(354 - 304) + chr(0b101101 + 0o3) + chr(48), 0o10)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(4974 - 4863) + '\062' + chr(0b110000) + chr(0b110000), 8)
n4ljua2gi1Pr.Hj_JCZasfmqG = ehT0Px3KOsy9(chr(256 - 208) + chr(0b1101111) + chr(0b1000 + 0o51) + chr(0b110000) + chr(2160 - 2112), 0b1000)
n4ljua2gi1Pr.PZHUuenu09ti = ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(0b1101101 + 0o2) + '\x31' + '\x30' + chr(2049 - 2001), 8)
n4ljua2gi1Pr.RW_xSzp18UeS = 0.0
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_base_8l_8h_big_cond_dr03_dan_dilated
|
def imagetransformer_base_8l_8h_big_cond_dr03_dan_dilated():
"""Dilated hparams."""
hparams = imagetransformer_base_8l_8h_big_cond_dr03_dan()
hparams.gap_sizes = [0, 16, 64, 0, 16, 64, 128, 0]
hparams.dec_attention_type = cia.AttentionType.DILATED
hparams.block_length = 128
hparams.block_width = 128
hparams.add_hparam("num_memory_blocks", 1)
return hparams
|
python
|
def imagetransformer_base_8l_8h_big_cond_dr03_dan_dilated():
"""Dilated hparams."""
hparams = imagetransformer_base_8l_8h_big_cond_dr03_dan()
hparams.gap_sizes = [0, 16, 64, 0, 16, 64, 128, 0]
hparams.dec_attention_type = cia.AttentionType.DILATED
hparams.block_length = 128
hparams.block_width = 128
hparams.add_hparam("num_memory_blocks", 1)
return hparams
|
[
"def",
"imagetransformer_base_8l_8h_big_cond_dr03_dan_dilated",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_base_8l_8h_big_cond_dr03_dan",
"(",
")",
"hparams",
".",
"gap_sizes",
"=",
"[",
"0",
",",
"16",
",",
"64",
",",
"0",
",",
"16",
",",
"64",
",",
"128",
",",
"0",
"]",
"hparams",
".",
"dec_attention_type",
"=",
"cia",
".",
"AttentionType",
".",
"DILATED",
"hparams",
".",
"block_length",
"=",
"128",
"hparams",
".",
"block_width",
"=",
"128",
"hparams",
".",
"add_hparam",
"(",
"\"num_memory_blocks\"",
",",
"1",
")",
"return",
"hparams"
] |
Dilated hparams.
|
[
"Dilated",
"hparams",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L635-L643
|
train
|
Dilated hparams.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HP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3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(50) + chr(0b100000 + 0o20) + chr(0b110001), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(1348 - 1298) + '\x31' + '\061', 0o10), ehT0Px3KOsy9('\x30' + chr(10218 - 10107) + chr(0b110010) + chr(55) + chr(54), 27013 - 27005), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b1100 + 0o45) + chr(0b110101 + 0o0) + chr(334 - 285), 32044 - 32036), ehT0Px3KOsy9(chr(0b11111 + 0o21) + chr(6424 - 6313) + chr(0b110011) + '\067' + chr(185 - 137), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + '\061' + '\063', ord("\x08")), ehT0Px3KOsy9(chr(0b100011 + 0o15) + chr(5436 - 5325) + chr(49) + chr(407 - 352) + '\066', 0o10), ehT0Px3KOsy9(chr(523 - 475) + '\157' + '\063' + chr(53) + chr(48), 29695 - 29687), ehT0Px3KOsy9('\060' + '\x6f' + chr(50) + chr(48) + chr(873 - 824), 8), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110010) + chr(0b110010) + chr(0b1100 + 0o46), 0o10), ehT0Px3KOsy9(chr(1192 - 1144) + chr(0b1101111) + chr(0b11 + 0o56) + chr(54) + chr(0b101001 + 0o16), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x31' + chr(0b110101) + chr(53), 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + '\062' + chr(54) + chr(914 - 863), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110011) + chr(0b101 + 0o60) + '\x37', ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + '\x32' + chr(0b110011) + chr(0b110100), 55102 - 55094), ehT0Px3KOsy9('\x30' + chr(0b1001101 + 0o42) + chr(0b101110 + 0o3) + '\x35' + chr(50), ord("\x08")), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(0b111011 + 0o64) + '\060', 0b1000), ehT0Px3KOsy9('\060' + chr(4873 - 4762) + '\x31' + '\x32' + '\065', 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(2795 - 2742) + '\x35', 48505 - 48497), ehT0Px3KOsy9('\060' + chr(111) + '\x32' + '\x34' + chr(2119 - 2067), 945 - 937), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110010) + chr(0b110101) + chr(2495 - 2442), 0o10), ehT0Px3KOsy9('\060' + chr(111) + '\x33' + chr(50) + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1000011 + 0o54) + chr(1960 - 1911) + chr(51) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(320 - 272) + chr(111) + '\x35' + chr(50), 33193 - 33185), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\061' + chr(1095 - 1046) + chr(53), 52147 - 52139), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(2474 - 2424) + chr(0b0 + 0o67) + chr(0b11100 + 0o25), 0o10), ehT0Px3KOsy9(chr(0b1100 + 0o44) + chr(0b1101111) + chr(0b110011) + chr(53) + chr(0b110001), 45412 - 45404), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x31' + chr(0b110000) + chr(55), 54713 - 54705), ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(0b1001000 + 0o47) + '\064' + chr(1122 - 1073), 4017 - 4009), ehT0Px3KOsy9('\x30' + '\x6f' + chr(50) + '\x35', 0o10), ehT0Px3KOsy9('\x30' + chr(0b111011 + 0o64) + chr(49) + chr(52) + chr(0b11110 + 0o23), 0b1000), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(111) + chr(0b110111 + 0o0), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(2089 - 2040) + chr(0b110100) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(48) + chr(7078 - 6967) + '\x33' + chr(0b110111) + '\066', 0b1000), ehT0Px3KOsy9(chr(0b101010 + 0o6) + chr(9530 - 9419) + chr(0b110 + 0o60) + chr(0b11 + 0o62), 63118 - 63110), ehT0Px3KOsy9(chr(0b0 + 0o60) + '\x6f' + chr(1302 - 1252) + chr(0b110011) + chr(295 - 242), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(50) + chr(54) + chr(54), 57583 - 57575), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\067', 8), ehT0Px3KOsy9(chr(1966 - 1918) + chr(0b1101111) + chr(0b10001 + 0o40) + '\063' + chr(1672 - 1617), 8), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(52) + chr(884 - 834), ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(950 - 902) + chr(0b1011000 + 0o27) + '\x35' + '\x30', 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xaf'), '\x64' + '\145' + chr(0b1100011) + '\157' + chr(0b1010101 + 0o17) + '\x65')('\x75' + chr(0b10110 + 0o136) + chr(1769 - 1667) + chr(45) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def SX21id68pAvF():
n4ljua2gi1Pr = x0CHyP_lfSrD()
n4ljua2gi1Pr.KoBu_7YSNAF7 = [ehT0Px3KOsy9(chr(48) + chr(10225 - 10114) + '\x30', 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b1000 + 0o52) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b10110 + 0o33) + '\x30' + chr(0b10101 + 0o33), 0o10), ehT0Px3KOsy9(chr(1657 - 1609) + chr(0b1101111) + '\x30', 8), ehT0Px3KOsy9(chr(1312 - 1264) + chr(111) + chr(50) + chr(0b110000), 8), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110001) + '\060' + '\x30', 8), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(5007 - 4896) + chr(0b101010 + 0o10) + chr(0b0 + 0o60) + chr(2004 - 1956), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(572 - 524), 8)]
n4ljua2gi1Pr.h3BUtwwQ_ZW5 = oIL3U1EOcJgs.AttentionType.DILATED
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9(chr(0b110000) + chr(3239 - 3128) + '\x32' + '\x30' + chr(0b101001 + 0o7), 8)
n4ljua2gi1Pr.H_cF2TKAb4ed = ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b1111 + 0o43) + chr(0b11010 + 0o26) + chr(0b10001 + 0o37), 8)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe0\xed\xda6\x90{\x1f\x9a\xe0\xff'), chr(100) + chr(0b1010100 + 0o21) + '\x63' + chr(0b1101111) + '\144' + chr(101))('\x75' + chr(0b1101101 + 0o7) + chr(0b11000 + 0o116) + '\055' + chr(964 - 908)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xef\xfc\xd36\x95n\x13\x87\xf3\xeb(\x0f\xdf\x80\xff\x01s'), '\x64' + '\145' + chr(7975 - 7876) + '\157' + chr(0b10 + 0o142) + '\x65')(chr(8031 - 7914) + chr(0b1101110 + 0o6) + chr(4254 - 4152) + '\x2d' + chr(0b100000 + 0o30)), ehT0Px3KOsy9('\060' + chr(0b110000 + 0o77) + '\061', 62996 - 62988))
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_base_12l_8h_big
|
def imagetransformer_base_12l_8h_big():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_sep_channels_8l_8h()
hparams.filter_size = 1024
hparams.num_decoder_layers = 12
hparams.batch_size = 1
hparams.hidden_size = 512
hparams.learning_rate_warmup_steps = 4000
hparams.sampling_method = "random"
hparams.beam_size = 1
hparams.block_width = 256
return hparams
|
python
|
def imagetransformer_base_12l_8h_big():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_sep_channels_8l_8h()
hparams.filter_size = 1024
hparams.num_decoder_layers = 12
hparams.batch_size = 1
hparams.hidden_size = 512
hparams.learning_rate_warmup_steps = 4000
hparams.sampling_method = "random"
hparams.beam_size = 1
hparams.block_width = 256
return hparams
|
[
"def",
"imagetransformer_base_12l_8h_big",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_sep_channels_8l_8h",
"(",
")",
"hparams",
".",
"filter_size",
"=",
"1024",
"hparams",
".",
"num_decoder_layers",
"=",
"12",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"4000",
"hparams",
".",
"sampling_method",
"=",
"\"random\"",
"hparams",
".",
"beam_size",
"=",
"1",
"hparams",
".",
"block_width",
"=",
"256",
"return",
"hparams"
] |
big 1d model for conditional image generation.
|
[
"big",
"1d",
"model",
"for",
"conditional",
"image",
"generation",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L673-L684
|
train
|
big 1d model for conditional image generation.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNBHlx,ZsDPvpP4xdo3,cW7yQuyEnJ6E,KOHQGQ8qLDWm,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MsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + chr(0b1101011 + 0o4) + chr(0b110001), 57616 - 57608), ehT0Px3KOsy9(chr(1330 - 1282) + chr(111) + '\063' + '\x32', 18932 - 18924), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110010) + chr(0b110111) + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(6793 - 6682) + '\061' + '\x35' + chr(0b110110), 0o10), ehT0Px3KOsy9(chr(0b100100 + 0o14) + chr(0b1000001 + 0o56) + chr(0b110111) + chr(2036 - 1981), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b11100 + 0o31) + chr(0b101 + 0o53), ord("\x08")), ehT0Px3KOsy9(chr(0b110000 + 0o0) + '\157' + chr(0b1010 + 0o50) + chr(908 - 854) + chr(0b111 + 0o57), 0b1000), ehT0Px3KOsy9(chr(0b10011 + 0o35) + '\x6f' + '\x33' + chr(54) + chr(53), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110110) + '\x31', 0o10), ehT0Px3KOsy9('\060' + '\157' + '\x33' + chr(53) + chr(0b110101), 21556 - 21548), ehT0Px3KOsy9(chr(0b110000) + chr(0b11 + 0o154) + '\x31' + '\x32' + chr(1746 - 1691), 0b1000), ehT0Px3KOsy9(chr(48) + chr(10826 - 10715) + chr(51) + chr(48) + chr(1653 - 1604), 24275 - 24267), ehT0Px3KOsy9(chr(0b1 + 0o57) + chr(10497 - 10386) + '\x31' + chr(0b1101 + 0o43) + chr(0b1111 + 0o41), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110011) + chr(55) + chr(0b110111), 56494 - 56486), ehT0Px3KOsy9(chr(0b110000) + chr(1459 - 1348) + chr(49) + chr(1499 - 1447) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(715 - 604) + chr(0b11110 + 0o25) + chr(0b110010) + chr(1344 - 1293), ord("\x08")), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(8098 - 7987) + chr(0b10110 + 0o33) + chr(0b110000) + '\063', 0o10), ehT0Px3KOsy9(chr(0b10100 + 0o34) + chr(0b1100011 + 0o14) + chr(0b110111) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(1300 - 1252) + '\x6f' + '\062' + chr(0b101100 + 0o6) + chr(331 - 282), 0b1000), ehT0Px3KOsy9(chr(0b101000 + 0o10) + chr(0b110 + 0o151) + chr(2204 - 2154) + chr(0b110001) + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(8176 - 8065) + chr(1454 - 1405) + '\x33' + chr(55), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(351 - 302) + chr(0b110001) + '\x32', 53131 - 53123), ehT0Px3KOsy9(chr(0b101011 + 0o5) + '\x6f' + chr(912 - 863) + chr(0b11001 + 0o27) + chr(0b10000 + 0o45), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110001) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(0b10001 + 0o37) + chr(11879 - 11768) + chr(0b110001) + chr(0b100110 + 0o12) + chr(0b101101 + 0o3), 8), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110001) + chr(50) + chr(2368 - 2318), 0o10), ehT0Px3KOsy9(chr(759 - 711) + chr(0b101001 + 0o106) + chr(0b110100) + '\064', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b101111 + 0o4) + '\x31' + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(2048 - 2000) + '\157' + chr(0b100001 + 0o22) + chr(0b110011) + '\060', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(50) + '\066' + chr(0b100110 + 0o21), 11199 - 11191), ehT0Px3KOsy9(chr(0b110000) + chr(3079 - 2968) + '\x31' + chr(0b110100) + chr(0b110100), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\067' + chr(874 - 824), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + '\063' + '\067' + '\064', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(5646 - 5535) + chr(0b11001 + 0o32) + '\066' + '\x37', 3246 - 3238), ehT0Px3KOsy9('\060' + chr(0b1000010 + 0o55) + chr(0b10010 + 0o37) + '\x32' + chr(1590 - 1542), ord("\x08")), ehT0Px3KOsy9(chr(505 - 457) + chr(0b1101111) + chr(2183 - 2133) + chr(0b1110 + 0o45) + '\x31', 0o10), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(0b1010110 + 0o31) + '\066' + chr(0b10011 + 0o35), 0b1000), ehT0Px3KOsy9(chr(1123 - 1075) + '\157' + chr(52), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\x33' + chr(0b100 + 0o61) + chr(52), 51393 - 51385), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110111) + chr(1031 - 977), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + '\157' + chr(0b110100 + 0o1) + chr(48), 8)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'/'), chr(100) + chr(101) + '\143' + chr(129 - 18) + '\x64' + '\x65')(chr(117) + chr(116) + chr(0b1100110) + chr(0b101101) + chr(932 - 876)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def MN7JUL3espT9():
n4ljua2gi1Pr = t0dZC3h9xNt6()
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(111) + chr(0b11111 + 0o23) + chr(0b101100 + 0o4) + chr(1682 - 1634) + chr(48), ord("\x08"))
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(49) + '\064', 64664 - 64656)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(48) + '\x6f' + chr(100 - 51), 8)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9('\060' + chr(111) + chr(49) + chr(48) + chr(48) + '\060', 36411 - 36403)
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9(chr(0b1 + 0o57) + chr(0b1101111) + chr(0b110111) + chr(54) + chr(1389 - 1337) + chr(0b10011 + 0o35), 0o10)
n4ljua2gi1Pr.Ud1InQ7hapop = xafqLlk3kkUe(SXOLrMavuUCe(b's{\xd7\nPE'), chr(100) + '\145' + '\143' + '\157' + '\x64' + chr(0b1100101))(chr(117) + '\x74' + chr(0b11010 + 0o114) + '\x2d' + '\070')
n4ljua2gi1Pr.PQZjDxhiHJGf = ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(49), 8)
n4ljua2gi1Pr.H_cF2TKAb4ed = ehT0Px3KOsy9(chr(0b100110 + 0o12) + '\157' + chr(2389 - 2337) + chr(1912 - 1864) + chr(48), 0b1000)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer1d_base_8l_64by64
|
def imagetransformer1d_base_8l_64by64():
"""hparams fo 12 layer big 1d model for imagenet 64x64."""
hparams = image_transformer_base()
hparams.num_heads = 8
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.num_decoder_layers = 8
hparams.batch_size = 1
hparams.block_length = 512
hparams.block_width = 768
hparams.layer_prepostprocess_dropout = 0.1
hparams.max_length = 14000
hparams.unconditional = int(False)
return hparams
|
python
|
def imagetransformer1d_base_8l_64by64():
"""hparams fo 12 layer big 1d model for imagenet 64x64."""
hparams = image_transformer_base()
hparams.num_heads = 8
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.num_decoder_layers = 8
hparams.batch_size = 1
hparams.block_length = 512
hparams.block_width = 768
hparams.layer_prepostprocess_dropout = 0.1
hparams.max_length = 14000
hparams.unconditional = int(False)
return hparams
|
[
"def",
"imagetransformer1d_base_8l_64by64",
"(",
")",
":",
"hparams",
"=",
"image_transformer_base",
"(",
")",
"hparams",
".",
"num_heads",
"=",
"8",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"filter_size",
"=",
"2048",
"hparams",
".",
"num_decoder_layers",
"=",
"8",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"block_length",
"=",
"512",
"hparams",
".",
"block_width",
"=",
"768",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.1",
"hparams",
".",
"max_length",
"=",
"14000",
"hparams",
".",
"unconditional",
"=",
"int",
"(",
"False",
")",
"return",
"hparams"
] |
hparams fo 12 layer big 1d model for imagenet 64x64.
|
[
"hparams",
"fo",
"12",
"layer",
"big",
"1d",
"model",
"for",
"imagenet",
"64x64",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L688-L701
|
train
|
Hparams fo 12 layer big 1d model for imagenet 64x64.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_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HaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + chr(0b110111 + 0o70) + '\061' + '\064' + chr(50), 0o10), ehT0Px3KOsy9(chr(1293 - 1245) + chr(0b1001000 + 0o47) + chr(0b110111) + chr(0b110000 + 0o4), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b11011 + 0o124) + chr(0b101010 + 0o11) + chr(53) + chr(0b110111), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + '\x33' + chr(53) + chr(50), 30007 - 29999), ehT0Px3KOsy9(chr(358 - 310) + chr(4472 - 4361) + chr(0b110011) + '\x35', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\062' + chr(197 - 148) + '\064', 0o10), ehT0Px3KOsy9('\060' + chr(0b100010 + 0o115) + chr(0b110010) + chr(54), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1010101 + 0o32) + '\x31' + '\062', ord("\x08")), ehT0Px3KOsy9('\060' + chr(4956 - 4845) + chr(0b11101 + 0o24) + chr(0b11110 + 0o25) + chr(0b10 + 0o56), 0b1000), ehT0Px3KOsy9(chr(0b101000 + 0o10) + chr(0b1101111) + '\061' + chr(55) + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b101100 + 0o6) + chr(456 - 405) + '\x33', 11066 - 11058), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\061' + chr(1143 - 1088) + '\x34', 0o10), ehT0Px3KOsy9(chr(813 - 765) + chr(111) + chr(0b1000 + 0o52) + chr(0b1101 + 0o46) + chr(0b110111), 487 - 479), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b111 + 0o54) + chr(0b10010 + 0o43) + '\x34', 0o10), ehT0Px3KOsy9('\060' + chr(111) + '\062' + '\063' + chr(882 - 834), 0o10), ehT0Px3KOsy9('\060' + '\157' + '\062' + chr(946 - 892) + '\066', 0b1000), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(0b1010010 + 0o35) + chr(946 - 892) + chr(50), 1265 - 1257), ehT0Px3KOsy9(chr(2137 - 2089) + '\157' + '\062' + '\061' + chr(51), 0o10), ehT0Px3KOsy9('\060' + '\157' + '\x31' + chr(0b110010) + chr(0b101110 + 0o11), 34217 - 34209), ehT0Px3KOsy9(chr(321 - 273) + chr(111) + chr(51) + chr(0b110101) + '\x30', 48783 - 48775), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110011) + chr(705 - 654) + chr(54), 56849 - 56841), ehT0Px3KOsy9(chr(48) + chr(0b1011100 + 0o23) + chr(50) + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b1101111) + chr(0b101100 + 0o7) + chr(54), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(2447 - 2336) + chr(0b10000 + 0o41) + '\065' + chr(2842 - 2787), 48516 - 48508), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101100 + 0o3) + chr(1524 - 1470) + '\x35', 0o10), ehT0Px3KOsy9(chr(1767 - 1719) + chr(111) + '\062' + '\061' + chr(0b110001), 19573 - 19565), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b111 + 0o53) + chr(54) + '\x37', 8915 - 8907), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b1100 + 0o46) + chr(2466 - 2415) + chr(1338 - 1287), 8), ehT0Px3KOsy9(chr(1682 - 1634) + '\x6f' + '\x33' + chr(0b101110 + 0o6) + chr(51), 0o10), ehT0Px3KOsy9(chr(0b100001 + 0o17) + chr(0b1100000 + 0o17) + chr(0b1001 + 0o51) + '\062' + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(12082 - 11971) + '\x31' + chr(0b101010 + 0o7) + chr(761 - 713), 30040 - 30032), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b101100 + 0o5) + '\066' + '\060', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\062', 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(1652 - 1601) + chr(0b110011) + chr(0b110000 + 0o4), 8039 - 8031), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110001 + 0o1) + '\x36' + '\x34', 17167 - 17159), ehT0Px3KOsy9('\060' + '\157' + chr(2217 - 2168) + '\x34', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(1042 - 993) + '\066' + '\x34', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110011) + '\x36' + '\x30', 22216 - 22208), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x35' + '\065', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\064' + chr(0b110101), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(1985 - 1932) + chr(1999 - 1951), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'L'), chr(100) + chr(0b1100101) + chr(4359 - 4260) + chr(111) + chr(0b111101 + 0o47) + chr(101))(chr(117) + chr(13286 - 13170) + '\x66' + '\x2d' + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def KOX3KGhOSvx6():
n4ljua2gi1Pr = TD_pfRN9LWG0()
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(309 - 260) + '\x30', 0o10)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(1841 - 1793) + '\x6f' + chr(0b11 + 0o56) + chr(0b110000) + chr(154 - 106) + chr(48), 0o10)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9('\x30' + chr(0b1000 + 0o147) + chr(0b110100) + chr(0b110000) + '\x30' + '\060', 27058 - 27050)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(1184 - 1136) + chr(111) + chr(0b110001) + chr(48), 8)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(1481 - 1433) + '\x6f' + '\061', 0o10)
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9(chr(389 - 341) + chr(111) + '\x31' + chr(48) + '\060' + chr(48), 8)
n4ljua2gi1Pr.H_cF2TKAb4ed = ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2100 - 2051) + '\x34' + '\060' + chr(0b110000), 0o10)
n4ljua2gi1Pr.RW_xSzp18UeS = 0.1
n4ljua2gi1Pr._o7pVXAdOCRy = ehT0Px3KOsy9(chr(0b110000) + chr(0b110100 + 0o73) + chr(2000 - 1949) + '\x33' + chr(589 - 539) + '\066' + chr(48), ord("\x08"))
n4ljua2gi1Pr.IcYfltg0WkcT = ehT0Px3KOsy9(ehT0Px3KOsy9('\x30' + chr(0b1010 + 0o145) + chr(48), 0o10))
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_sep_channels_12l_16h_imagenet_large
|
def imagetransformer_sep_channels_12l_16h_imagenet_large():
"""separate rgb embeddings."""
hparams = imagetransformer_sep_channels_8l_8h()
hparams.num_hidden_layers = 12
hparams.batch_size = 1
hparams.filter_size = 2048
hparams.num_heads = 16
hparams.learning_rate_warmup_steps = 16000
hparams.sampling_method = "random"
hparams.learning_rate = 0.1
return hparams
|
python
|
def imagetransformer_sep_channels_12l_16h_imagenet_large():
"""separate rgb embeddings."""
hparams = imagetransformer_sep_channels_8l_8h()
hparams.num_hidden_layers = 12
hparams.batch_size = 1
hparams.filter_size = 2048
hparams.num_heads = 16
hparams.learning_rate_warmup_steps = 16000
hparams.sampling_method = "random"
hparams.learning_rate = 0.1
return hparams
|
[
"def",
"imagetransformer_sep_channels_12l_16h_imagenet_large",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_sep_channels_8l_8h",
"(",
")",
"hparams",
".",
"num_hidden_layers",
"=",
"12",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"filter_size",
"=",
"2048",
"hparams",
".",
"num_heads",
"=",
"16",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"16000",
"hparams",
".",
"sampling_method",
"=",
"\"random\"",
"hparams",
".",
"learning_rate",
"=",
"0.1",
"return",
"hparams"
] |
separate rgb embeddings.
|
[
"separate",
"rgb",
"embeddings",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L754-L764
|
train
|
separate rgb embeddings.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEH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eError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + '\157' + chr(1807 - 1757) + chr(0b1000 + 0o50) + chr(49), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(1966 - 1916) + chr(54) + chr(54), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\063' + '\x30', 36484 - 36476), ehT0Px3KOsy9(chr(2283 - 2235) + chr(7823 - 7712) + chr(0b110011) + chr(0b110111) + chr(49), 0b1000), ehT0Px3KOsy9(chr(0b1111 + 0o41) + '\x6f' + chr(0b100111 + 0o17) + chr(314 - 259), 0b1000), ehT0Px3KOsy9(chr(0b11010 + 0o26) + chr(0b111001 + 0o66) + '\062' + '\065' + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b100111 + 0o12) + chr(2070 - 2018) + '\065', 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b10110 + 0o34) + chr(0b101010 + 0o11) + chr(0b100111 + 0o17), 0o10), ehT0Px3KOsy9(chr(0b11110 + 0o22) + '\157' + chr(50) + '\061' + '\x36', 0o10), ehT0Px3KOsy9(chr(0b1011 + 0o45) + chr(6025 - 5914) + chr(51) + chr(0b100111 + 0o13) + chr(51), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110000 + 0o7) + chr(0b1000 + 0o51), 54821 - 54813), ehT0Px3KOsy9(chr(0b101110 + 0o2) + chr(0b1101111) + chr(54) + '\x37', 8), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b10101 + 0o37) + chr(53), 51040 - 51032), ehT0Px3KOsy9(chr(48) + chr(0b101100 + 0o103) + '\x33' + chr(0b110000) + chr(0b100011 + 0o23), ord("\x08")), ehT0Px3KOsy9(chr(0b101010 + 0o6) + '\157' + chr(775 - 726) + chr(50) + '\064', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(2152 - 2041) + '\062' + chr(2767 - 2714) + chr(0b10110 + 0o40), 43882 - 43874), ehT0Px3KOsy9(chr(2284 - 2236) + chr(1890 - 1779) + chr(0b11011 + 0o27) + '\061' + chr(0b110001 + 0o3), 58559 - 58551), ehT0Px3KOsy9('\x30' + '\x6f' + chr(534 - 485) + chr(0b1001 + 0o55) + '\x33', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(884 - 834) + chr(0b110010), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1011000 + 0o27) + '\x31' + chr(188 - 135) + '\060', 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2308 - 2257) + chr(0b10010 + 0o36) + '\060', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(4907 - 4796) + chr(0b110101) + '\067', 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(0b100110 + 0o15) + chr(0b110110) + chr(2075 - 2022), 0b1000), ehT0Px3KOsy9('\060' + chr(6464 - 6353) + chr(51) + chr(0b1011 + 0o45) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(0b1100000 + 0o17) + chr(0b110010) + '\060' + '\060', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(2931 - 2820) + chr(0b110101) + chr(0b11000 + 0o37), 8), ehT0Px3KOsy9('\060' + '\157' + chr(49) + chr(53) + chr(0b10111 + 0o34), ord("\x08")), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(0b1101111) + chr(0b110010) + '\x36' + chr(0b110100), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(54) + chr(53), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110011) + '\065' + chr(0b101000 + 0o12), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110001) + chr(2349 - 2295) + '\067', 0b1000), ehT0Px3KOsy9(chr(2103 - 2055) + chr(2435 - 2324) + '\x32' + '\x31' + chr(0b110100), 8), ehT0Px3KOsy9('\060' + '\x6f' + chr(49) + chr(0b1111 + 0o42) + chr(0b110001), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b11111 + 0o23) + chr(50) + chr(591 - 542), ord("\x08")), ehT0Px3KOsy9(chr(2193 - 2145) + '\157' + '\x33' + chr(0b110100) + '\063', 63810 - 63802), ehT0Px3KOsy9('\x30' + chr(0b1000 + 0o147) + chr(0b100100 + 0o16) + '\066', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110001) + '\062' + chr(0b10100 + 0o40), 8), ehT0Px3KOsy9('\x30' + chr(111) + '\x33' + chr(0b110001) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\065' + chr(0b110101), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\063' + chr(0b100001 + 0o22) + chr(0b110111), ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(1195 - 1147) + chr(111) + chr(128 - 75) + '\x30', 33231 - 33223)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xaf'), '\x64' + '\x65' + chr(5864 - 5765) + chr(0b1101111) + '\x64' + chr(0b1100101))(chr(0b1110101) + chr(0b1110100) + '\x66' + chr(0b101101) + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def ALe87UC4WiyG():
n4ljua2gi1Pr = t0dZC3h9xNt6()
n4ljua2gi1Pr.jZh5_pLUoOoZ = ehT0Px3KOsy9(chr(48) + '\157' + '\061' + chr(0b110100), 22488 - 22480)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\060' + chr(111) + '\x31', 0o10)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(131 - 83) + chr(0b1101111) + '\064' + '\x30' + '\060' + '\x30', ord("\x08"))
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\062' + '\x30', 0b1000)
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x33' + '\067' + '\062' + chr(0b110000) + '\060', 41904 - 41896)
n4ljua2gi1Pr.Ud1InQ7hapop = xafqLlk3kkUe(SXOLrMavuUCe(b'\xf3\xd7v\x9dX\xc4'), chr(0b1001 + 0o133) + '\x65' + chr(0b1000101 + 0o36) + chr(111) + chr(0b1010000 + 0o24) + chr(0b1010110 + 0o17))('\x75' + chr(116) + chr(0b1100110) + '\x2d' + chr(2918 - 2862))
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.1
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_sep_channels_16l_16h_imgnet_lrg_loc
|
def imagetransformer_sep_channels_16l_16h_imgnet_lrg_loc():
"""separate rgb embeddings."""
hparams = imagetransformer_sep_channels_12l_16h_imagenet_large()
hparams.num_hidden_layers = 16
hparams.local_attention = True
hparams.batch_size = 1
hparams.block_length = 256
return hparams
|
python
|
def imagetransformer_sep_channels_16l_16h_imgnet_lrg_loc():
"""separate rgb embeddings."""
hparams = imagetransformer_sep_channels_12l_16h_imagenet_large()
hparams.num_hidden_layers = 16
hparams.local_attention = True
hparams.batch_size = 1
hparams.block_length = 256
return hparams
|
[
"def",
"imagetransformer_sep_channels_16l_16h_imgnet_lrg_loc",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_sep_channels_12l_16h_imagenet_large",
"(",
")",
"hparams",
".",
"num_hidden_layers",
"=",
"16",
"hparams",
".",
"local_attention",
"=",
"True",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"block_length",
"=",
"256",
"return",
"hparams"
] |
separate rgb embeddings.
|
[
"separate",
"rgb",
"embeddings",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L768-L775
|
train
|
separate rgb embeddings.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o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edError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(111) + '\x31' + chr(53) + chr(0b110101), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1000100 + 0o53) + '\x31' + chr(0b1000 + 0o50) + '\064', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\061' + chr(1316 - 1264) + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(7997 - 7886) + chr(0b110101) + chr(0b100110 + 0o16), 0o10), ehT0Px3KOsy9(chr(48) + chr(9388 - 9277) + '\x33' + chr(50) + '\x35', 36475 - 36467), ehT0Px3KOsy9('\060' + chr(0b101110 + 0o101) + '\x31' + chr(219 - 167) + chr(48), 43845 - 43837), ehT0Px3KOsy9('\x30' + '\157' + '\062' + '\x32' + chr(111 - 58), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\062' + '\063' + chr(2707 - 2653), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110011) + chr(1139 - 1090) + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b1001 + 0o52) + chr(0b110001 + 0o0) + chr(339 - 287), 23181 - 23173), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2392 - 2341) + chr(48) + chr(52), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\061' + '\x32' + chr(49), 0o10), ehT0Px3KOsy9(chr(0b1010 + 0o46) + chr(6864 - 6753) + chr(0b1101 + 0o50), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1010011 + 0o34) + chr(1036 - 987) + '\x33' + '\x34', ord("\x08")), ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(111) + chr(51) + chr(50) + chr(1939 - 1891), 0b1000), ehT0Px3KOsy9(chr(48) + chr(4021 - 3910) + '\x31' + '\x34' + '\x34', 37852 - 37844), ehT0Px3KOsy9('\x30' + chr(0b1011001 + 0o26) + '\061' + chr(1626 - 1575) + chr(0b110100), 8), ehT0Px3KOsy9(chr(48) + chr(5060 - 4949) + chr(51) + chr(2257 - 2207) + chr(0b10011 + 0o43), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1001111 + 0o40) + '\061' + chr(0b10011 + 0o35) + '\x34', 8), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110001) + chr(0b110100) + '\062', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\063' + '\066' + chr(2087 - 2039), 0o10), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b1011100 + 0o23) + chr(0b110001) + '\064' + chr(53), 45858 - 45850), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110011) + chr(545 - 494) + chr(0b100 + 0o60), 45094 - 45086), ehT0Px3KOsy9('\060' + chr(111) + chr(50) + chr(733 - 680) + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(0b1101111) + chr(0b110011 + 0o3), 0o10), ehT0Px3KOsy9(chr(350 - 302) + '\x6f' + chr(0b110010) + '\062' + chr(0b110001), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x32' + '\x30' + '\x35', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\x37' + chr(0b110001), 19424 - 19416), ehT0Px3KOsy9(chr(48) + chr(1851 - 1740) + '\063' + '\x34' + '\067', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(49) + chr(0b10100 + 0o36) + chr(0b100000 + 0o26), 0o10), ehT0Px3KOsy9(chr(1552 - 1504) + chr(0b11011 + 0o124) + chr(1924 - 1874) + chr(0b110110) + '\063', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1010010 + 0o35) + chr(0b110011) + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(1939 - 1891) + chr(111) + '\067', 0b1000), ehT0Px3KOsy9(chr(0b10100 + 0o34) + chr(0b1010011 + 0o34) + chr(0b110001) + chr(54) + chr(2738 - 2684), 0b1000), ehT0Px3KOsy9(chr(266 - 218) + chr(0b10001 + 0o136) + '\063' + '\x32', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b100101 + 0o112) + chr(50) + chr(0b110001) + '\x30', 57459 - 57451), ehT0Px3KOsy9(chr(2242 - 2194) + chr(111) + '\061' + '\x37' + '\x35', 40468 - 40460), ehT0Px3KOsy9('\060' + chr(0b11 + 0o154) + chr(0b10010 + 0o37) + chr(49) + chr(49), 0o10), ehT0Px3KOsy9(chr(0b101010 + 0o6) + chr(8043 - 7932) + chr(0b110001) + chr(55) + chr(0b1010 + 0o55), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b11000 + 0o127) + chr(0b101101 + 0o4) + chr(0b101111 + 0o10) + '\x35', 8)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(0b100111 + 0o110) + chr(0b110101) + '\x30', 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'C'), chr(0b1100100) + chr(4784 - 4683) + '\x63' + chr(0b1101111) + chr(0b1011110 + 0o6) + chr(0b1100101))(chr(117) + chr(0b1000110 + 0o56) + chr(0b1011101 + 0o11) + chr(45) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def hbl_RDc_gIre():
n4ljua2gi1Pr = ALe87UC4WiyG()
n4ljua2gi1Pr.jZh5_pLUoOoZ = ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(111) + '\x32' + '\060', ord("\x08"))
n4ljua2gi1Pr.MhPA5aCBbXBt = ehT0Px3KOsy9('\x30' + chr(11581 - 11470) + chr(0b11101 + 0o24), 1261 - 1253)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(111) + chr(49), 8)
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9(chr(1444 - 1396) + chr(111) + '\x34' + chr(0b1001 + 0o47) + chr(490 - 442), 0o10)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_sep_channels_16l_16h_imgnet_lrg_loc_128
|
def imagetransformer_sep_channels_16l_16h_imgnet_lrg_loc_128():
"""separate rgb embeddings."""
hparams = imagetransformer_sep_channels_12l_16h_imagenet_large()
hparams.num_hidden_layers = 16
hparams.local_attention = True
hparams.batch_size = 1
hparams.block_length = 128
return hparams
|
python
|
def imagetransformer_sep_channels_16l_16h_imgnet_lrg_loc_128():
"""separate rgb embeddings."""
hparams = imagetransformer_sep_channels_12l_16h_imagenet_large()
hparams.num_hidden_layers = 16
hparams.local_attention = True
hparams.batch_size = 1
hparams.block_length = 128
return hparams
|
[
"def",
"imagetransformer_sep_channels_16l_16h_imgnet_lrg_loc_128",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_sep_channels_12l_16h_imagenet_large",
"(",
")",
"hparams",
".",
"num_hidden_layers",
"=",
"16",
"hparams",
".",
"local_attention",
"=",
"True",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"block_length",
"=",
"128",
"return",
"hparams"
] |
separate rgb embeddings.
|
[
"separate",
"rgb",
"embeddings",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L779-L786
|
train
|
separate rgb embeddings.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCR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,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(1513 - 1465) + chr(0b1100010 + 0o15) + '\062' + '\x34', ord("\x08")), ehT0Px3KOsy9(chr(931 - 883) + chr(0b1011110 + 0o21) + chr(0b110010) + chr(0b110110 + 0o0) + chr(54), 0b1000), ehT0Px3KOsy9(chr(969 - 921) + '\157' + chr(49) + chr(0b10100 + 0o37) + chr(299 - 245), 23885 - 23877), ehT0Px3KOsy9('\060' + chr(111) + chr(51) + chr(1337 - 1282) + '\x35', 0o10), ehT0Px3KOsy9(chr(0b100110 + 0o12) + chr(9408 - 9297) + chr(0b101010 + 0o11) + chr(0b11011 + 0o31) + chr(0b100101 + 0o15), 0b1000), ehT0Px3KOsy9(chr(0b11010 + 0o26) + chr(111) + chr(49) + chr(0b110100) + chr(0b110001 + 0o5), 28609 - 28601), ehT0Px3KOsy9('\x30' + chr(0b101001 + 0o106) + '\x37' + chr(0b11000 + 0o37), 0b1000), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(0b1101111) + chr(53) + chr(0b110110), 20043 - 20035), ehT0Px3KOsy9(chr(48) + chr(111) + chr(160 - 110) + '\062' + '\x34', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x37' + chr(919 - 871), 42949 - 42941), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110001) + chr(0b110000) + chr(0b110101), 0o10), ehT0Px3KOsy9('\060' + chr(8062 - 7951) + chr(51) + chr(54), 22101 - 22093), ehT0Px3KOsy9('\x30' + chr(9418 - 9307) + '\061' + chr(0b11100 + 0o27) + chr(48), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\061' + chr(0b110011) + '\x37', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\x31' + chr(0b110110) + chr(0b10100 + 0o36), 0b1000), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(0b1101111) + chr(0b110 + 0o55) + chr(54) + '\x32', 0o10), ehT0Px3KOsy9(chr(602 - 554) + chr(0b1100 + 0o143) + '\061' + chr(51) + chr(0b101011 + 0o10), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(7714 - 7603) + chr(0b110001) + chr(2223 - 2169) + chr(54), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1685 - 1630) + chr(51), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110010) + chr(0b110100) + '\x34', 0o10), ehT0Px3KOsy9(chr(862 - 814) + '\157' + chr(0b110010) + chr(0b110110) + chr(0b101010 + 0o11), 65023 - 65015), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110011 + 0o2) + '\064', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(51) + '\x31' + '\067', 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\x31' + chr(1140 - 1090) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(1670 - 1621) + '\x36' + '\x35', 0o10), ehT0Px3KOsy9(chr(48) + chr(11498 - 11387) + '\061' + '\x37' + chr(0b110100), ord("\x08")), ehT0Px3KOsy9(chr(0b1011 + 0o45) + '\x6f' + chr(0b110001) + chr(48) + '\x34', 0b1000), ehT0Px3KOsy9('\x30' + chr(3541 - 3430) + chr(0b11101 + 0o24) + chr(0b110011) + chr(0b11000 + 0o30), 8), ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(0b100000 + 0o117) + '\x32' + chr(48) + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(0b11001 + 0o27) + '\x6f' + chr(0b11000 + 0o32) + chr(0b110001) + chr(0b10 + 0o56), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\067' + chr(0b10001 + 0o41), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110111) + chr(1018 - 968), 8), ehT0Px3KOsy9(chr(0b101001 + 0o7) + '\157' + chr(0b100 + 0o56) + chr(0b100100 + 0o16) + chr(288 - 240), 59098 - 59090), ehT0Px3KOsy9('\x30' + chr(111) + '\x31' + chr(1553 - 1504) + '\x34', 35937 - 35929), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b101010 + 0o11) + chr(0b100 + 0o57) + '\x32', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b0 + 0o63) + chr(2046 - 1998) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b110001 + 0o76) + chr(49) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b11101 + 0o122) + chr(50) + chr(2328 - 2273), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110010) + chr(0b110101) + chr(0b110001), 9487 - 9479), ehT0Px3KOsy9(chr(1781 - 1733) + chr(111) + chr(0b11 + 0o56) + chr(1694 - 1645) + '\060', 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b11110 + 0o27) + chr(0b101101 + 0o3), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b':'), chr(0b1100100) + '\x65' + chr(0b1001100 + 0o27) + chr(0b1101111) + chr(0b1011100 + 0o10) + chr(9809 - 9708))(chr(0b111010 + 0o73) + chr(0b1100100 + 0o20) + '\146' + '\055' + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def pZBvF5r0FdFj():
n4ljua2gi1Pr = ALe87UC4WiyG()
n4ljua2gi1Pr.jZh5_pLUoOoZ = ehT0Px3KOsy9('\x30' + chr(111) + '\062' + chr(0b110000), 65391 - 65383)
n4ljua2gi1Pr.MhPA5aCBbXBt = ehT0Px3KOsy9('\060' + '\x6f' + chr(49), ord("\x08"))
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\060' + chr(0b1011000 + 0o27) + chr(0b110001), 8)
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9(chr(48) + chr(228 - 117) + '\062' + chr(0b110000) + '\x30', 0o10)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_base_10l_16h_big_uncond_dr01_imgnet
|
def imagetransformer_base_10l_16h_big_uncond_dr01_imgnet():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_base_14l_8h_big_dr01()
# num_hidden_layers
hparams.num_decoder_layers = 10
hparams.num_heads = 16
hparams.hidden_size = 1024
hparams.filter_size = 4096
hparams.batch_size = 1
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
python
|
def imagetransformer_base_10l_16h_big_uncond_dr01_imgnet():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_base_14l_8h_big_dr01()
# num_hidden_layers
hparams.num_decoder_layers = 10
hparams.num_heads = 16
hparams.hidden_size = 1024
hparams.filter_size = 4096
hparams.batch_size = 1
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
[
"def",
"imagetransformer_base_10l_16h_big_uncond_dr01_imgnet",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_base_14l_8h_big_dr01",
"(",
")",
"# num_hidden_layers",
"hparams",
".",
"num_decoder_layers",
"=",
"10",
"hparams",
".",
"num_heads",
"=",
"16",
"hparams",
".",
"hidden_size",
"=",
"1024",
"hparams",
".",
"filter_size",
"=",
"4096",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.1",
"return",
"hparams"
] |
big 1d model for conditional image generation.
|
[
"big",
"1d",
"model",
"for",
"conditional",
"image",
"generation",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L799-L809
|
train
|
big 1d model for conditional image generation.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5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yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + chr(0b1010010 + 0o35) + '\063' + chr(2445 - 2390) + chr(1735 - 1682), 0o10), ehT0Px3KOsy9(chr(1182 - 1134) + chr(0b111100 + 0o63) + chr(0b101000 + 0o13) + chr(938 - 885), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\x32' + chr(61 - 7) + chr(2030 - 1979), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(876 - 825) + '\067' + '\062', 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110011) + '\060', 0o10), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(111) + chr(900 - 849) + chr(0b1100 + 0o53) + '\061', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(2548 - 2497) + chr(54) + '\063', ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(271 - 220) + chr(50) + chr(646 - 595), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\062' + chr(1679 - 1629) + chr(0b11001 + 0o27), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b11110 + 0o121) + '\061' + '\061' + chr(2195 - 2141), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b10010 + 0o37) + '\065' + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1000100 + 0o53) + chr(0b110100) + '\067', 50663 - 50655), ehT0Px3KOsy9(chr(0b10111 + 0o31) + chr(0b1101111) + chr(1012 - 962) + '\063', 55377 - 55369), ehT0Px3KOsy9(chr(321 - 273) + '\x6f' + '\x32' + '\060' + '\x37', 19970 - 19962), ehT0Px3KOsy9(chr(1054 - 1006) + chr(111) + '\061' + '\066' + chr(1151 - 1100), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(586 - 536) + '\062' + chr(2108 - 2057), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1010011 + 0o34) + chr(0b100111 + 0o12) + '\x30', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110001) + chr(0b110110) + chr(516 - 462), ord("\x08")), ehT0Px3KOsy9('\060' + chr(8907 - 8796) + '\x31' + chr(51) + '\x30', 22566 - 22558), ehT0Px3KOsy9(chr(1206 - 1158) + '\x6f' + chr(762 - 711) + '\067' + chr(1547 - 1493), 47544 - 47536), ehT0Px3KOsy9('\060' + '\157' + '\062' + chr(51) + chr(82 - 27), 0b1000), ehT0Px3KOsy9(chr(48) + chr(3936 - 3825) + chr(0b110001) + chr(0b110001), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + '\064' + chr(49), 0b1000), ehT0Px3KOsy9(chr(0b0 + 0o60) + '\157' + chr(0b110001) + chr(0b110110) + '\x36', 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(744 - 693) + chr(52) + '\x33', 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110011) + chr(757 - 709) + chr(0b110101), 8103 - 8095), ehT0Px3KOsy9(chr(1220 - 1172) + '\157' + chr(0b1111 + 0o42) + chr(0b101101 + 0o3) + chr(0b110001 + 0o0), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + '\065' + '\065', ord("\x08")), ehT0Px3KOsy9(chr(1891 - 1843) + chr(0b1010001 + 0o36) + chr(0b100010 + 0o21) + '\060' + '\x33', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(49) + chr(53) + chr(51), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + '\x33' + chr(2705 - 2651), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110011) + chr(1723 - 1669) + '\063', 8), ehT0Px3KOsy9(chr(439 - 391) + chr(111) + chr(1098 - 1048) + chr(49) + '\067', 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(0b110000 + 0o2) + chr(51) + chr(0b10011 + 0o37), ord("\x08")), ehT0Px3KOsy9(chr(409 - 361) + chr(0b1100101 + 0o12) + '\x31' + chr(580 - 525) + chr(2162 - 2110), 25487 - 25479), ehT0Px3KOsy9(chr(0b110000) + chr(0b1000001 + 0o56) + chr(0b110000), 63990 - 63982), ehT0Px3KOsy9(chr(0b100 + 0o54) + '\x6f' + chr(0b110011) + chr(0b110011) + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110101) + '\067', ord("\x08")), ehT0Px3KOsy9(chr(659 - 611) + chr(111) + '\063' + chr(49) + chr(51), 6235 - 6227), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(111) + chr(0b111 + 0o54) + chr(0b101011 + 0o10) + chr(601 - 550), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + '\157' + chr(0b110101) + chr(48), 6917 - 6909)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xd3'), chr(0b1100100) + chr(101) + '\x63' + chr(0b1100111 + 0o10) + chr(3827 - 3727) + chr(0b1000010 + 0o43))(chr(0b1101101 + 0o10) + chr(0b1011110 + 0o26) + chr(0b1100110) + chr(45) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def PVqS4dxQP37U():
n4ljua2gi1Pr = uHhVPaKApQVz()
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(48) + '\157' + '\061' + '\062', ord("\x08"))
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(48) + chr(2624 - 2513) + chr(0b100001 + 0o21) + '\060', ord("\x08"))
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9('\060' + '\x6f' + '\062' + '\060' + '\x30' + chr(1794 - 1746), 0b1000)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(528 - 480) + chr(0b10100 + 0o133) + chr(0b100 + 0o55) + chr(254 - 206) + chr(0b1001 + 0o47) + chr(1668 - 1620) + '\x30', 55607 - 55599)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\060' + '\x6f' + '\061', 0o10)
n4ljua2gi1Pr.RW_xSzp18UeS = 0.1
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_base_10l_16h_big_dr01_imgnet
|
def imagetransformer_base_10l_16h_big_dr01_imgnet():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_base_14l_8h_big_dr01()
# num_hidden_layers
hparams.num_decoder_layers = 10
hparams.num_heads = 16
hparams.hidden_size = 1024
hparams.filter_size = 4096
hparams.batch_size = 1
hparams.unconditional = False
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
python
|
def imagetransformer_base_10l_16h_big_dr01_imgnet():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_base_14l_8h_big_dr01()
# num_hidden_layers
hparams.num_decoder_layers = 10
hparams.num_heads = 16
hparams.hidden_size = 1024
hparams.filter_size = 4096
hparams.batch_size = 1
hparams.unconditional = False
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
[
"def",
"imagetransformer_base_10l_16h_big_dr01_imgnet",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_base_14l_8h_big_dr01",
"(",
")",
"# num_hidden_layers",
"hparams",
".",
"num_decoder_layers",
"=",
"10",
"hparams",
".",
"num_heads",
"=",
"16",
"hparams",
".",
"hidden_size",
"=",
"1024",
"hparams",
".",
"filter_size",
"=",
"4096",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"unconditional",
"=",
"False",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.1",
"return",
"hparams"
] |
big 1d model for conditional image generation.
|
[
"big",
"1d",
"model",
"for",
"conditional",
"image",
"generation",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L813-L824
|
train
|
big 1d model for conditional image generation.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ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aZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(513 - 465) + chr(0b1101111) + '\063' + chr(0b110011) + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(0b0 + 0o60) + chr(0b1101111 + 0o0) + '\x31' + '\x35' + chr(51), 47975 - 47967), ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(10443 - 10332) + '\061' + '\066' + chr(54), 4385 - 4377), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110011) + chr(54) + chr(72 - 24), 36990 - 36982), ehT0Px3KOsy9('\x30' + chr(8978 - 8867) + chr(2581 - 2527) + chr(0b11000 + 0o35), 0o10), ehT0Px3KOsy9(chr(399 - 351) + chr(0b1101111) + '\x32' + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(622 - 571) + chr(2012 - 1961) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(1046 - 998) + chr(0b110 + 0o151) + '\065' + chr(0b110010), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1010100 + 0o33) + chr(1613 - 1563) + chr(0b110010) + chr(0b110100), 0b1000), ehT0Px3KOsy9('\x30' + chr(10574 - 10463) + chr(2041 - 1992) + '\067' + chr(1519 - 1467), 0o10), ehT0Px3KOsy9('\x30' + chr(0b101000 + 0o107) + chr(0b110011) + chr(0b101010 + 0o14) + chr(0b11100 + 0o31), 0o10), ehT0Px3KOsy9(chr(0b100010 + 0o16) + chr(0b10100 + 0o133) + chr(0b110010) + chr(0b10010 + 0o41) + chr(52), 0o10), ehT0Px3KOsy9(chr(0b101110 + 0o2) + '\157' + chr(51) + chr(296 - 242) + chr(0b110001), ord("\x08")), ehT0Px3KOsy9(chr(0b110000 + 0o0) + '\x6f' + chr(0b100101 + 0o15) + chr(101 - 48), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b10000 + 0o44) + chr(0b11010 + 0o30), 38891 - 38883), ehT0Px3KOsy9(chr(1819 - 1771) + chr(0b1010010 + 0o35) + chr(53) + chr(0b110001), 26942 - 26934), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b1110 + 0o43) + chr(0b110101) + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(0b101001 + 0o7) + chr(0b1101111) + chr(50) + chr(2011 - 1961), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b10111 + 0o33) + '\064' + chr(0b100000 + 0o24), 5356 - 5348), ehT0Px3KOsy9(chr(0b110000) + chr(0b110101 + 0o72) + '\061' + '\062', ord("\x08")), ehT0Px3KOsy9(chr(1935 - 1887) + chr(7095 - 6984) + chr(1905 - 1855) + chr(48) + chr(0b10101 + 0o40), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(54) + chr(0b101111 + 0o3), 52964 - 52956), ehT0Px3KOsy9(chr(48) + chr(6735 - 6624) + chr(54) + '\x30', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\066', 2757 - 2749), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110001) + chr(54) + '\065', 60546 - 60538), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\063' + chr(1873 - 1823) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(48) + chr(2612 - 2501) + chr(0b110001) + '\066' + chr(0b110000), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\x33' + chr(0b110000) + chr(49), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b101011 + 0o7) + '\062' + '\067', 9264 - 9256), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\063' + chr(0b100010 + 0o17) + chr(0b110100), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x31' + '\x37' + '\061', ord("\x08")), ehT0Px3KOsy9(chr(1025 - 977) + chr(111) + chr(0b110010) + '\061' + '\067', 37582 - 37574), ehT0Px3KOsy9(chr(48) + chr(0b1101111 + 0o0) + chr(2218 - 2169) + chr(2197 - 2145) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(1868 - 1820) + chr(0b1011001 + 0o26) + chr(0b10001 + 0o43) + chr(50), 8), ehT0Px3KOsy9(chr(254 - 206) + chr(111) + chr(0b110111) + chr(0b110100 + 0o1), 0o10), ehT0Px3KOsy9('\x30' + '\157' + '\061' + '\x35' + '\x34', 8), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110010), 57957 - 57949), ehT0Px3KOsy9(chr(0b11111 + 0o21) + '\x6f' + chr(0b110001) + '\x35' + chr(55), 37697 - 37689), ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(8376 - 8265) + '\x33' + chr(0b110010 + 0o3) + chr(80 - 26), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(51) + chr(53) + '\065', ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(111) + chr(1734 - 1681) + '\x30', ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xf3'), chr(100) + '\145' + '\143' + '\157' + chr(8938 - 8838) + chr(101))(chr(117) + chr(13272 - 13156) + '\146' + chr(0b101001 + 0o4) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def BoTeOwcsjML4():
n4ljua2gi1Pr = uHhVPaKApQVz()
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9('\x30' + chr(111) + '\061' + chr(0b11101 + 0o25), 8)
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9('\060' + chr(111) + '\062' + '\060', 0b1000)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(0b111 + 0o51) + chr(111) + chr(1179 - 1129) + '\x30' + '\060' + chr(0b1011 + 0o45), 0o10)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(1689 - 1641) + '\157' + chr(49) + chr(48) + '\060' + chr(0b110000) + '\060', ord("\x08"))
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(49), ord("\x08"))
n4ljua2gi1Pr.IcYfltg0WkcT = ehT0Px3KOsy9(chr(0b101000 + 0o10) + '\157' + '\060', ord("\x08"))
n4ljua2gi1Pr.RW_xSzp18UeS = 0.1
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_sep_channels_8l_8h
|
def imagetransformer_sep_channels_8l_8h():
"""separate rgb embeddings."""
hparams = imagetransformer_base()
hparams.num_heads = 8
hparams.batch_size = 1
hparams.attention_key_channels = hparams.attention_value_channels = 0
hparams.hidden_size = 512
hparams.filter_size = 512
hparams.num_hidden_layers = 8
hparams.sampling_method = "random"
return hparams
|
python
|
def imagetransformer_sep_channels_8l_8h():
"""separate rgb embeddings."""
hparams = imagetransformer_base()
hparams.num_heads = 8
hparams.batch_size = 1
hparams.attention_key_channels = hparams.attention_value_channels = 0
hparams.hidden_size = 512
hparams.filter_size = 512
hparams.num_hidden_layers = 8
hparams.sampling_method = "random"
return hparams
|
[
"def",
"imagetransformer_sep_channels_8l_8h",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_base",
"(",
")",
"hparams",
".",
"num_heads",
"=",
"8",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"attention_key_channels",
"=",
"hparams",
".",
"attention_value_channels",
"=",
"0",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"filter_size",
"=",
"512",
"hparams",
".",
"num_hidden_layers",
"=",
"8",
"hparams",
".",
"sampling_method",
"=",
"\"random\"",
"return",
"hparams"
] |
separate rgb embeddings.
|
[
"separate",
"rgb",
"embeddings",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L828-L838
|
train
|
separate rgb embeddings.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMC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s,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(2143 - 2091) + chr(1305 - 1257), ord("\x08")), ehT0Px3KOsy9(chr(888 - 840) + chr(0b11011 + 0o124) + chr(2737 - 2684) + chr(0b110111), 47886 - 47878), ehT0Px3KOsy9(chr(48) + chr(111) + '\063' + chr(0b110000) + '\066', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\061' + chr(0b110101) + chr(2417 - 2366), ord("\x08")), ehT0Px3KOsy9(chr(0b1101 + 0o43) + chr(3645 - 3534) + '\x32' + '\x36' + '\x31', 0b1000), ehT0Px3KOsy9('\x30' + chr(947 - 836) + chr(215 - 166) + chr(49) + chr(48), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(9553 - 9442) + '\064' + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101000 + 0o7) + chr(0b110011) + chr(391 - 342) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x31' + chr(0b110111) + chr(0b110100), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(5510 - 5399) + '\063' + '\060', 0b1000), ehT0Px3KOsy9(chr(2049 - 2001) + '\x6f' + chr(2219 - 2170) + chr(2165 - 2115) + '\x35', 0o10), ehT0Px3KOsy9(chr(1440 - 1392) + '\x6f' + '\x32' + chr(0b110111) + '\x31', 0b1000), ehT0Px3KOsy9(chr(721 - 673) + chr(5717 - 5606) + chr(0b110111) + chr(0b1010 + 0o51), 32599 - 32591), ehT0Px3KOsy9(chr(0b110000) + chr(2975 - 2864) + chr(0b101000 + 0o13) + '\x36', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(961 - 850) + chr(49) + chr(48) + chr(0b110110), 0o10), ehT0Px3KOsy9(chr(805 - 757) + chr(111) + '\x33' + '\x35' + '\060', 57655 - 57647), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(526 - 477) + chr(54) + chr(0b110110), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\x33' + chr(0b11110 + 0o26) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(0b0 + 0o60) + chr(0b1101111) + chr(0b110011) + '\x30' + chr(1605 - 1553), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(2840 - 2729) + '\x32' + '\x32' + chr(1041 - 993), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + chr(49) + '\060' + '\x34', 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + '\061' + chr(0b100 + 0o57) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(1356 - 1308) + chr(0b1101111) + chr(0b110011) + chr(1579 - 1526) + chr(0b11 + 0o60), 11053 - 11045), ehT0Px3KOsy9(chr(48) + '\157' + '\x36', 1024 - 1016), ehT0Px3KOsy9('\060' + '\157' + chr(0b111 + 0o53) + chr(0b110000) + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(0b101000 + 0o10) + chr(6645 - 6534) + chr(0b100010 + 0o21) + chr(0b110001) + '\x34', 0b1000), ehT0Px3KOsy9(chr(0b1 + 0o57) + '\x6f' + chr(50) + '\060' + chr(0b100 + 0o54), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1100111 + 0o10) + chr(0b110101) + '\x33', 0o10), ehT0Px3KOsy9(chr(1807 - 1759) + '\x6f' + '\x32' + '\062' + '\061', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1011011 + 0o24) + chr(0b1000 + 0o51), 43568 - 43560), ehT0Px3KOsy9(chr(0b100000 + 0o20) + '\x6f' + '\061' + '\x31' + chr(0b110110), 7500 - 7492), ehT0Px3KOsy9(chr(48) + chr(0b100000 + 0o117) + '\062' + chr(0b110011) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(1766 - 1716) + '\x33' + '\x36', 28840 - 28832), ehT0Px3KOsy9(chr(0b11011 + 0o25) + chr(111) + chr(2778 - 2725) + chr(0b110100), 13635 - 13627), ehT0Px3KOsy9('\x30' + '\x6f' + '\x31' + '\x30' + '\065', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(1434 - 1323) + chr(49) + chr(0b110100) + '\066', ord("\x08")), ehT0Px3KOsy9(chr(1010 - 962) + '\x6f' + chr(0b110010) + chr(2585 - 2532) + chr(185 - 134), 43485 - 43477), ehT0Px3KOsy9(chr(48) + chr(111) + chr(1759 - 1704) + '\063', 8), ehT0Px3KOsy9('\060' + chr(3153 - 3042) + chr(50) + chr(0b110010) + chr(0b110010), 664 - 656), ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(0b1101111) + chr(0b110010 + 0o4) + chr(1044 - 994), ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(0b1101111) + '\065' + chr(0b101011 + 0o5), 9009 - 9001)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x0e'), chr(7589 - 7489) + chr(101) + '\143' + chr(0b1101111) + chr(0b1010011 + 0o21) + chr(0b1100101))(chr(0b1110101) + '\164' + chr(0b1100110) + chr(844 - 799) + chr(0b100100 + 0o24)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def t0dZC3h9xNt6():
n4ljua2gi1Pr = qcOiVha39Kfr()
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(2012 - 1964) + chr(1092 - 981) + '\x31' + chr(0b110000), 64957 - 64949)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x31', 8)
n4ljua2gi1Pr.Hj_JCZasfmqG = n4ljua2gi1Pr.PZHUuenu09ti = ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b1010 + 0o46), 0o10)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9('\x30' + '\x6f' + '\x31' + chr(48) + '\060' + chr(48), 18 - 10)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110001) + chr(0b110000) + '\x30' + '\060', 8)
n4ljua2gi1Pr.jZh5_pLUoOoZ = ehT0Px3KOsy9('\060' + chr(111) + chr(0b110001) + chr(0b110000), 8)
n4ljua2gi1Pr.Ud1InQ7hapop = xafqLlk3kkUe(SXOLrMavuUCe(b'RN\xa8\x0f\xde%'), chr(100) + chr(7168 - 7067) + chr(5246 - 5147) + '\157' + chr(100) + chr(101))(chr(0b1110101) + chr(0b1110100) + '\x66' + chr(531 - 486) + chr(2491 - 2435))
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_sep_channels_8l_8h_local_and_global_att
|
def imagetransformer_sep_channels_8l_8h_local_and_global_att():
"""separate rgb embeddings."""
hparams = imagetransformer_sep_channels_8l_8h()
hparams.num_heads = 8
hparams.batch_size = 1
hparams.attention_key_channels = hparams.attention_value_channels = 0
hparams.hidden_size = 256
hparams.filter_size = 256
hparams.num_hidden_layers = 4
hparams.sampling_method = "random"
hparams.local_and_global_att = True
return hparams
|
python
|
def imagetransformer_sep_channels_8l_8h_local_and_global_att():
"""separate rgb embeddings."""
hparams = imagetransformer_sep_channels_8l_8h()
hparams.num_heads = 8
hparams.batch_size = 1
hparams.attention_key_channels = hparams.attention_value_channels = 0
hparams.hidden_size = 256
hparams.filter_size = 256
hparams.num_hidden_layers = 4
hparams.sampling_method = "random"
hparams.local_and_global_att = True
return hparams
|
[
"def",
"imagetransformer_sep_channels_8l_8h_local_and_global_att",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_sep_channels_8l_8h",
"(",
")",
"hparams",
".",
"num_heads",
"=",
"8",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"attention_key_channels",
"=",
"hparams",
".",
"attention_value_channels",
"=",
"0",
"hparams",
".",
"hidden_size",
"=",
"256",
"hparams",
".",
"filter_size",
"=",
"256",
"hparams",
".",
"num_hidden_layers",
"=",
"4",
"hparams",
".",
"sampling_method",
"=",
"\"random\"",
"hparams",
".",
"local_and_global_att",
"=",
"True",
"return",
"hparams"
] |
separate rgb embeddings.
|
[
"separate",
"rgb",
"embeddings",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L842-L853
|
train
|
separate rgb embeddings.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5H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ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + '\x6f' + chr(2547 - 2493) + chr(0b11100 + 0o26), 41095 - 41087), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\063' + chr(0b110001) + chr(1614 - 1565), 0o10), ehT0Px3KOsy9('\060' + chr(7662 - 7551) + chr(785 - 734) + chr(0b110100) + chr(0b110101 + 0o1), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110011) + chr(0b10101 + 0o37) + '\x34', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b100101 + 0o112) + chr(0b10000 + 0o42) + chr(0b101010 + 0o10) + '\x32', 18289 - 18281), ehT0Px3KOsy9('\060' + chr(111) + chr(0b101110 + 0o3) + chr(0b0 + 0o61) + chr(1175 - 1126), 0b1000), ehT0Px3KOsy9(chr(0b1011 + 0o45) + chr(0b1101111) + chr(0b110001) + '\x35', 0o10), ehT0Px3KOsy9(chr(624 - 576) + '\157' + chr(0b110011) + '\x31' + '\x32', 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\x33' + chr(51) + chr(0b10110 + 0o37), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1111 + 0o140) + '\x31' + '\065' + '\x35', 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(545 - 495) + chr(0b1100 + 0o52) + chr(0b110110), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b1000 + 0o52) + chr(1262 - 1214) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(1748 - 1700) + chr(0b1010011 + 0o34) + '\063' + '\x32' + chr(48), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(6912 - 6801) + chr(101 - 47) + chr(0b110111), 48333 - 48325), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b101000 + 0o13) + '\x31', 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b100100 + 0o15) + chr(55) + chr(55), 0o10), ehT0Px3KOsy9(chr(0b1101 + 0o43) + '\x6f' + chr(0b110011) + '\066' + chr(55), 44549 - 44541), ehT0Px3KOsy9(chr(0b10111 + 0o31) + '\157' + chr(881 - 831) + '\x33' + '\x33', 3503 - 3495), ehT0Px3KOsy9('\060' + '\x6f' + chr(50) + chr(53) + chr(2598 - 2543), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(50) + '\x32' + chr(1469 - 1418), 0o10), ehT0Px3KOsy9('\060' + chr(111) + '\062' + chr(48), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110011) + chr(49) + chr(53), 27369 - 27361), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(111) + chr(0b110001) + '\062' + '\x31', 0b1000), ehT0Px3KOsy9(chr(0b11010 + 0o26) + '\x6f' + '\x33' + '\x30' + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(86 - 38) + chr(0b101010 + 0o105) + chr(2395 - 2346) + '\x35' + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101 + 0o142) + '\061' + chr(0b110011) + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(0b101110 + 0o2) + chr(111) + chr(51) + chr(0b100101 + 0o22) + chr(1753 - 1700), 0b1000), ehT0Px3KOsy9(chr(1980 - 1932) + '\157' + '\061' + chr(1729 - 1678) + chr(0b11010 + 0o33), 64046 - 64038), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(50) + '\062' + chr(49), ord("\x08")), ehT0Px3KOsy9(chr(0b11010 + 0o26) + '\157' + chr(1635 - 1586) + chr(0b110110), 41769 - 41761), ehT0Px3KOsy9(chr(0b100101 + 0o13) + chr(0b1101111) + chr(0b110001) + chr(49) + chr(53), 0o10), ehT0Px3KOsy9(chr(0b11001 + 0o27) + chr(3175 - 3064) + chr(1712 - 1663) + chr(0b110011) + chr(54), 2154 - 2146), ehT0Px3KOsy9(chr(0b110000) + chr(10519 - 10408) + '\x37' + '\x35', 0b1000), ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(0b1101111) + chr(50) + chr(50) + chr(53), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(50) + chr(735 - 686) + '\066', 0b1000), ehT0Px3KOsy9(chr(0b1 + 0o57) + chr(885 - 774) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(1200 - 1152) + chr(7041 - 6930) + chr(0b11111 + 0o22) + chr(1028 - 974) + chr(2446 - 2392), 0b1000), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(0b1010111 + 0o30) + chr(0b110010) + chr(53) + '\x32', 61343 - 61335), ehT0Px3KOsy9('\060' + '\157' + '\x32' + '\061' + chr(931 - 878), 62100 - 62092), ehT0Px3KOsy9(chr(0b111 + 0o51) + chr(111) + chr(51) + chr(0b110111) + chr(0b100110 + 0o12), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000 + 0o0) + '\157' + chr(0b101 + 0o60) + '\060', 60399 - 60391)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x1c'), chr(0b1100100) + chr(101) + '\x63' + '\157' + chr(0b1001110 + 0o26) + chr(0b111 + 0o136))('\165' + chr(0b111010 + 0o72) + '\x66' + '\x2d' + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def f9huMLn7jFfm():
n4ljua2gi1Pr = t0dZC3h9xNt6()
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9('\x30' + chr(111) + '\x31' + '\x30', 60592 - 60584)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(48) + chr(111) + chr(2205 - 2156), ord("\x08"))
n4ljua2gi1Pr.Hj_JCZasfmqG = n4ljua2gi1Pr.PZHUuenu09ti = ehT0Px3KOsy9('\x30' + chr(4355 - 4244) + chr(1789 - 1741), 23865 - 23857)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110100) + '\x30' + chr(691 - 643), ord("\x08"))
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(876 - 828) + '\157' + chr(0b10001 + 0o43) + '\x30' + '\x30', 8)
n4ljua2gi1Pr.jZh5_pLUoOoZ = ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\064', 0b1000)
n4ljua2gi1Pr.Ud1InQ7hapop = xafqLlk3kkUe(SXOLrMavuUCe(b'@\xa8\x88\x80\xfd$'), chr(3898 - 3798) + chr(101) + chr(99) + chr(6434 - 6323) + '\x64' + '\x65')(chr(117) + chr(1329 - 1213) + chr(6642 - 6540) + chr(0b101101) + chr(56))
n4ljua2gi1Pr.RTkRSabf2dIc = ehT0Px3KOsy9(chr(1367 - 1319) + '\x6f' + chr(0b100101 + 0o14), 8)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_bas8l_8h_big_uncond_dr03_imgnet
|
def imagetransformer_bas8l_8h_big_uncond_dr03_imgnet():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_base_14l_8h_big_dr01()
# num_hidden_layers
hparams.num_decoder_layers = 8
hparams.num_heads = 8
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.layer_prepostprocess_dropout = 0.3
return hparams
|
python
|
def imagetransformer_bas8l_8h_big_uncond_dr03_imgnet():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_base_14l_8h_big_dr01()
# num_hidden_layers
hparams.num_decoder_layers = 8
hparams.num_heads = 8
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.layer_prepostprocess_dropout = 0.3
return hparams
|
[
"def",
"imagetransformer_bas8l_8h_big_uncond_dr03_imgnet",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_base_14l_8h_big_dr01",
"(",
")",
"# num_hidden_layers",
"hparams",
".",
"num_decoder_layers",
"=",
"8",
"hparams",
".",
"num_heads",
"=",
"8",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"filter_size",
"=",
"2048",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.3",
"return",
"hparams"
] |
big 1d model for conditional image generation.
|
[
"big",
"1d",
"model",
"for",
"conditional",
"image",
"generation",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L857-L866
|
train
|
big 1d model for conditional image generation.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9D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,tzcpInYwBvYW,iDQ_gSK8V7h0,Rurm1zTRfSmY,reqGiMiVQ77y,bsS9P6_LpdIe,sbGAZlkZOtyh,Cf_Qef15s3_F,eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + '\157' + '\062' + '\x32' + chr(0b110110), 0b1000), ehT0Px3KOsy9('\060' + '\157' + '\x32' + chr(0b110000 + 0o4) + '\062', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b101 + 0o152) + chr(49) + '\x35' + '\061', ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(0b1001 + 0o50) + chr(50) + chr(0b100100 + 0o21), 0o10), ehT0Px3KOsy9(chr(0b11101 + 0o23) + '\157' + chr(0b110010) + chr(0b101100 + 0o4) + chr(0b110110), 25699 - 25691), ehT0Px3KOsy9(chr(656 - 608) + chr(12187 - 12076) + '\x32' + chr(0b101111 + 0o2) + '\062', 22113 - 22105), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b11000 + 0o33) + chr(0b101011 + 0o13), 0b1000), ehT0Px3KOsy9(chr(48) + chr(3246 - 3135) + chr(76 - 22) + '\067', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + '\063' + '\065' + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b0 + 0o62) + chr(51) + chr(48), 46020 - 46012), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x32' + '\060' + chr(0b101110 + 0o2), ord("\x08")), ehT0Px3KOsy9(chr(1356 - 1308) + chr(0b1101111) + '\061' + chr(0b111 + 0o53) + chr(0b11111 + 0o27), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b101010 + 0o7) + chr(0b100111 + 0o14) + '\x33', 0o10), ehT0Px3KOsy9(chr(0b100111 + 0o11) + chr(10033 - 9922) + chr(1893 - 1843) + chr(48) + chr(0b101000 + 0o10), 8), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110011) + chr(0b110110), 8), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(802 - 753) + chr(0b10011 + 0o36) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(152 - 104) + chr(111) + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(1137 - 1089) + chr(8813 - 8702) + chr(0b110010) + '\x37', 54864 - 54856), ehT0Px3KOsy9(chr(53 - 5) + chr(2124 - 2013) + chr(51) + '\060' + chr(2020 - 1968), 57108 - 57100), ehT0Px3KOsy9(chr(48) + chr(4056 - 3945) + chr(496 - 447) + '\063' + chr(0b110010), 39306 - 39298), ehT0Px3KOsy9(chr(893 - 845) + '\157' + '\062' + chr(50), 0o10), ehT0Px3KOsy9('\x30' + '\157' + '\061' + '\x31' + chr(0b100011 + 0o20), 15814 - 15806), ehT0Px3KOsy9(chr(815 - 767) + chr(111) + chr(0b110010) + chr(0b10101 + 0o33) + chr(1590 - 1538), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110011) + chr(0b110111) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(2057 - 2009) + chr(111) + chr(0b110100), 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b1111 + 0o140) + '\061' + chr(0b110110), 2734 - 2726), ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(0b1011100 + 0o23) + chr(50) + chr(0b100101 + 0o15) + '\062', 3640 - 3632), ehT0Px3KOsy9('\060' + '\157' + '\062' + '\x35', ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110010) + '\066' + chr(0b110000), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110001) + chr(0b110110) + '\065', 48453 - 48445), ehT0Px3KOsy9(chr(48) + '\157' + '\062' + chr(52) + chr(0b100011 + 0o22), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + '\062' + '\x32' + chr(50), 8), ehT0Px3KOsy9(chr(48) + chr(0b111 + 0o150) + chr(2352 - 2302) + chr(48) + chr(55), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + '\x32' + '\x36' + chr(55), 0b1000), ehT0Px3KOsy9(chr(236 - 188) + chr(0b1101111) + chr(51) + '\x33' + '\x36', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x31' + chr(0b1111 + 0o43) + chr(415 - 367), 4756 - 4748), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(0b1101111) + chr(51) + chr(736 - 681) + chr(48), 8), ehT0Px3KOsy9('\x30' + '\157' + '\063' + chr(721 - 673) + '\x35', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1110 + 0o141) + chr(0b110001) + '\x30' + chr(0b101101 + 0o3), 51802 - 51794), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(0b1101111) + chr(51) + chr(0b110000), 22823 - 22815)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(1826 - 1778) + '\157' + chr(654 - 601) + '\060', 26416 - 26408)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xb8'), '\144' + chr(0b1100101) + chr(673 - 574) + chr(0b1010001 + 0o36) + chr(0b1100100) + '\x65')(chr(117) + chr(0b1101100 + 0o10) + chr(0b1100000 + 0o6) + chr(0b101101) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def pgkv8qf4pDLc():
n4ljua2gi1Pr = uHhVPaKApQVz()
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(0b100110 + 0o12) + '\157' + chr(0b110001) + chr(0b110000), 0b1000)
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9('\060' + chr(111) + chr(557 - 508) + chr(0b110000), 8)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9('\060' + chr(0b100100 + 0o113) + chr(1761 - 1712) + '\060' + '\060' + chr(1782 - 1734), ord("\x08"))
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9('\060' + chr(0b1011101 + 0o22) + chr(52) + '\x30' + chr(1119 - 1071) + '\060', 0o10)
n4ljua2gi1Pr.RW_xSzp18UeS = 0.3
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_base_10l_16h_big_dr01_moe_imgnet
|
def imagetransformer_base_10l_16h_big_dr01_moe_imgnet():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_base_10l_16h_big_dr01_imgnet()
hparams.initializer = "orthogonal"
hparams.learning_rate_warmup_steps = 16000
hparams.add_hparam("moe_layers_decoder", "2,7") # Which layer is MoE.
hparams.moe_hidden_sizes = "4096" # Hidden layer sizes (comma-separated).
hparams.moe_num_experts = 64 # Number of experts in each MoE layer.
hparams.moe_k = 4 # How many experts to use per batch element (try 2 or 4).
hparams.moe_loss_coef = 3e-2 # MoE loss coefficient (1e-2 is usually ok).
hparams.scheduled_sampling_prob = 0.1
hparams.scheduled_sampling_warmup_steps = 200000
return hparams
|
python
|
def imagetransformer_base_10l_16h_big_dr01_moe_imgnet():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_base_10l_16h_big_dr01_imgnet()
hparams.initializer = "orthogonal"
hparams.learning_rate_warmup_steps = 16000
hparams.add_hparam("moe_layers_decoder", "2,7") # Which layer is MoE.
hparams.moe_hidden_sizes = "4096" # Hidden layer sizes (comma-separated).
hparams.moe_num_experts = 64 # Number of experts in each MoE layer.
hparams.moe_k = 4 # How many experts to use per batch element (try 2 or 4).
hparams.moe_loss_coef = 3e-2 # MoE loss coefficient (1e-2 is usually ok).
hparams.scheduled_sampling_prob = 0.1
hparams.scheduled_sampling_warmup_steps = 200000
return hparams
|
[
"def",
"imagetransformer_base_10l_16h_big_dr01_moe_imgnet",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_base_10l_16h_big_dr01_imgnet",
"(",
")",
"hparams",
".",
"initializer",
"=",
"\"orthogonal\"",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"16000",
"hparams",
".",
"add_hparam",
"(",
"\"moe_layers_decoder\"",
",",
"\"2,7\"",
")",
"# Which layer is MoE.",
"hparams",
".",
"moe_hidden_sizes",
"=",
"\"4096\"",
"# Hidden layer sizes (comma-separated).",
"hparams",
".",
"moe_num_experts",
"=",
"64",
"# Number of experts in each MoE layer.",
"hparams",
".",
"moe_k",
"=",
"4",
"# How many experts to use per batch element (try 2 or 4).",
"hparams",
".",
"moe_loss_coef",
"=",
"3e-2",
"# MoE loss coefficient (1e-2 is usually ok).",
"hparams",
".",
"scheduled_sampling_prob",
"=",
"0.1",
"hparams",
".",
"scheduled_sampling_warmup_steps",
"=",
"200000",
"return",
"hparams"
] |
big 1d model for conditional image generation.
|
[
"big",
"1d",
"model",
"for",
"conditional",
"image",
"generation",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L902-L914
|
train
|
big 1d model for conditional image generation.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcj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r8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + chr(0b10 + 0o155) + chr(1317 - 1268) + '\x36' + '\064', 0b1000), ehT0Px3KOsy9(chr(0b1 + 0o57) + '\x6f' + chr(50) + chr(0b110011) + chr(53), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(49) + chr(49) + chr(50), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\061' + '\066' + '\x33', ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(2080 - 2030) + chr(52) + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110010) + chr(100 - 51) + chr(1895 - 1841), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\x32' + '\063' + chr(2317 - 2264), 8), ehT0Px3KOsy9(chr(1876 - 1828) + '\157' + chr(0b110001) + '\065' + chr(0b110101), 17 - 9), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b101010 + 0o11) + '\x35' + chr(526 - 471), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110101) + chr(0b110111), 47858 - 47850), ehT0Px3KOsy9(chr(1659 - 1611) + '\x6f' + chr(344 - 292) + chr(55), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110011) + chr(51) + chr(1664 - 1613), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b101001 + 0o11) + chr(50) + chr(0b1010 + 0o50), 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(49) + chr(51) + chr(53), 0o10), ehT0Px3KOsy9(chr(679 - 631) + '\x6f' + '\067' + chr(0b11111 + 0o24), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b110110 + 0o71) + '\063' + chr(0b11011 + 0o32) + chr(0b1010 + 0o53), 40736 - 40728), ehT0Px3KOsy9('\060' + chr(9582 - 9471) + chr(50) + chr(2722 - 2668) + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110010) + chr(0b110110) + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b10100 + 0o35) + chr(270 - 221) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(7065 - 6954) + chr(51) + chr(0b101 + 0o57) + chr(0b110110), 0o10), ehT0Px3KOsy9('\060' + chr(0b1010101 + 0o32) + '\063' + '\x36' + chr(0b100111 + 0o17), 22656 - 22648), ehT0Px3KOsy9(chr(1210 - 1162) + chr(0b1001100 + 0o43) + '\x33' + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b1101111) + chr(1138 - 1088) + chr(0b11100 + 0o24) + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(0b11001 + 0o27) + '\x6f' + chr(55) + '\065', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1717 - 1668) + chr(0b110111) + chr(0b101110 + 0o6), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + '\063' + chr(0b110011) + '\x36', 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110111) + chr(0b100010 + 0o22), 51652 - 51644), ehT0Px3KOsy9(chr(2008 - 1960) + '\x6f' + chr(50) + chr(639 - 584) + chr(0b110001), 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(51) + chr(0b110100) + chr(0b101000 + 0o10), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b11101 + 0o26) + chr(0b110011) + chr(48), 0o10), ehT0Px3KOsy9(chr(983 - 935) + '\x6f' + '\x31' + chr(972 - 921) + '\x36', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(11800 - 11689) + chr(2226 - 2177) + chr(0b101111 + 0o3) + chr(52), 0o10), ehT0Px3KOsy9('\x30' + chr(0b111010 + 0o65) + '\061' + chr(55) + chr(0b110000), 34166 - 34158), ehT0Px3KOsy9(chr(48) + '\157' + chr(869 - 820) + '\065' + chr(0b101100 + 0o5), 40709 - 40701), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110011) + '\061' + chr(0b110000), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\062' + chr(0b111 + 0o56) + chr(1840 - 1787), 0b1000), ehT0Px3KOsy9(chr(0b100111 + 0o11) + chr(0b1101111) + '\x31' + '\063' + chr(1285 - 1232), 8), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(1157 - 1106) + '\065' + chr(0b100001 + 0o22), 57009 - 57001), ehT0Px3KOsy9(chr(0b110000) + chr(0b10001 + 0o136) + chr(192 - 142) + chr(52) + chr(0b110101), 42016 - 42008), ehT0Px3KOsy9(chr(600 - 552) + chr(111) + chr(50) + chr(88 - 34), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(1072 - 1024) + '\x6f' + '\x35' + '\060', 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'Z'), chr(100) + chr(0b1100101) + chr(0b1100011) + chr(111) + chr(6298 - 6198) + chr(0b1100101))(chr(0b1110101) + chr(0b1110100) + '\146' + chr(0b101011 + 0o2) + chr(0b11111 + 0o31)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def TKVjeksu76_J():
n4ljua2gi1Pr = BoTeOwcsjML4()
n4ljua2gi1Pr.kwfuYzkY5C57 = xafqLlk3kkUe(SXOLrMavuUCe(b'\x1b\xef>\x1b\xcf\xe9\xf2\x03\x8eC'), '\144' + '\145' + '\x63' + chr(0b111111 + 0o60) + '\x64' + chr(0b1100101))(chr(0b11100 + 0o131) + chr(0b1001101 + 0o47) + '\146' + '\055' + chr(56))
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9(chr(0b1100 + 0o44) + '\x6f' + chr(122 - 71) + chr(55) + chr(0b110010) + chr(260 - 212) + chr(1229 - 1181), ord("\x08"))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\x15\xf9.,\xc8\xfe\xfc\x1f\x8eB'), '\144' + chr(0b1000100 + 0o41) + chr(7331 - 7232) + chr(0b11100 + 0o123) + chr(100) + chr(0b1000010 + 0o43))('\165' + chr(0b1110100) + chr(10163 - 10061) + chr(0b101101) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\x19\xf2/,\xcc\xef\xe4\x08\x9d\\x\xbf\xf7>T\x89\xd1\xc2'), chr(5609 - 5509) + chr(0b1100101) + chr(99) + chr(0b1101111) + chr(0b101 + 0o137) + '\145')('\165' + '\164' + '\146' + '\055' + chr(0b110110 + 0o2)), xafqLlk3kkUe(SXOLrMavuUCe(b'F\xb1}'), '\144' + '\145' + chr(0b1100011) + chr(8865 - 8754) + '\144' + chr(0b1100101))('\165' + '\164' + chr(0b101110 + 0o70) + chr(0b101101) + chr(0b10110 + 0o42)))
n4ljua2gi1Pr.GlalSbqmunyH = xafqLlk3kkUe(SXOLrMavuUCe(b'@\xadsE'), chr(0b1100100) + '\145' + chr(2828 - 2729) + chr(5673 - 5562) + chr(0b1100100) + '\145')(chr(117) + '\164' + chr(5532 - 5430) + chr(854 - 809) + chr(0b111000))
n4ljua2gi1Pr.r99iQzD4Y8i3 = ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x31' + '\060' + '\060', 34378 - 34370)
n4ljua2gi1Pr.xwl05__wedRi = ehT0Px3KOsy9(chr(885 - 837) + chr(0b1100111 + 0o10) + chr(52), 0b1000)
n4ljua2gi1Pr.VMsZZrjA_RNt = 0.03
n4ljua2gi1Pr.R153SBG2CDLp = 0.1
n4ljua2gi1Pr.fS20WIxYM77_ = ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110110) + '\x30' + '\066' + chr(53) + chr(346 - 298) + chr(0b10011 + 0o35), 0o10)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_moe_tiny
|
def imagetransformer_moe_tiny():
"""Set of hyperparameters for a very small imagetransformer with MoE."""
hparams = imagetransformer_tiny()
hparams.hidden_size = 64
hparams.batch_size = 1
hparams.num_hidden_layers = 3
hparams.dec_attention_type = cia.AttentionType.MOE_LOCAL_1D
hparams.add_hparam("moe_layers_decoder", "1") # Which layer is MoE.
hparams.moe_hidden_sizes = "1024" # Hidden layer sizes (comma-separated).
hparams.moe_num_experts = 16 # Number of experts in each MoE layer.
hparams.moe_k = 2 # How many experts to use per batch element (try 2 or 4).
hparams.moe_loss_coef = 1e-2 # MoE loss coefficient (1e-2 is usually ok).
return hparams
|
python
|
def imagetransformer_moe_tiny():
"""Set of hyperparameters for a very small imagetransformer with MoE."""
hparams = imagetransformer_tiny()
hparams.hidden_size = 64
hparams.batch_size = 1
hparams.num_hidden_layers = 3
hparams.dec_attention_type = cia.AttentionType.MOE_LOCAL_1D
hparams.add_hparam("moe_layers_decoder", "1") # Which layer is MoE.
hparams.moe_hidden_sizes = "1024" # Hidden layer sizes (comma-separated).
hparams.moe_num_experts = 16 # Number of experts in each MoE layer.
hparams.moe_k = 2 # How many experts to use per batch element (try 2 or 4).
hparams.moe_loss_coef = 1e-2 # MoE loss coefficient (1e-2 is usually ok).
return hparams
|
[
"def",
"imagetransformer_moe_tiny",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_tiny",
"(",
")",
"hparams",
".",
"hidden_size",
"=",
"64",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"num_hidden_layers",
"=",
"3",
"hparams",
".",
"dec_attention_type",
"=",
"cia",
".",
"AttentionType",
".",
"MOE_LOCAL_1D",
"hparams",
".",
"add_hparam",
"(",
"\"moe_layers_decoder\"",
",",
"\"1\"",
")",
"# Which layer is MoE.",
"hparams",
".",
"moe_hidden_sizes",
"=",
"\"1024\"",
"# Hidden layer sizes (comma-separated).",
"hparams",
".",
"moe_num_experts",
"=",
"16",
"# Number of experts in each MoE layer.",
"hparams",
".",
"moe_k",
"=",
"2",
"# How many experts to use per batch element (try 2 or 4).",
"hparams",
".",
"moe_loss_coef",
"=",
"1e-2",
"# MoE loss coefficient (1e-2 is usually ok).",
"return",
"hparams"
] |
Set of hyperparameters for a very small imagetransformer with MoE.
|
[
"Set",
"of",
"hyperparameters",
"for",
"a",
"very",
"small",
"imagetransformer",
"with",
"MoE",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L918-L930
|
train
|
Set of hyperparameters for a very small imagetransformer with MoE.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIF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Osy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b10100 + 0o34) + chr(0b1101111) + '\062' + chr(1641 - 1592) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(0b101110 + 0o2) + '\x6f' + chr(50) + '\x33' + chr(2331 - 2279), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(2341 - 2291) + chr(0b110010 + 0o5) + chr(2310 - 2260), 0o10), ehT0Px3KOsy9(chr(0b101010 + 0o6) + chr(111) + chr(49) + '\064' + chr(53), 17406 - 17398), ehT0Px3KOsy9(chr(0b110000) + chr(5813 - 5702) + '\x30', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101101 + 0o2) + '\062' + '\066' + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(1293 - 1245) + '\x6f' + chr(0b110011) + chr(722 - 667) + chr(0b110100 + 0o2), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(0b10001 + 0o42) + '\061' + '\061', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b101000 + 0o107) + chr(49) + chr(0b1000 + 0o55) + chr(54), 0o10), ehT0Px3KOsy9(chr(0b10001 + 0o37) + '\x6f' + '\x33' + chr(53) + '\062', 0o10), ehT0Px3KOsy9('\060' + '\157' + '\061' + '\065' + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(0b100101 + 0o13) + chr(3461 - 3350) + '\061' + '\x32', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(51) + chr(759 - 705) + chr(587 - 533), 17148 - 17140), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(1176 - 1127) + chr(52) + '\062', 33475 - 33467), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110010 + 0o2) + chr(54), 0o10), ehT0Px3KOsy9('\x30' + chr(6553 - 6442) + '\062' + '\x34' + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b1011 + 0o45) + '\x6f' + '\062' + chr(0b110101) + chr(0b10001 + 0o45), ord("\x08")), ehT0Px3KOsy9(chr(0b101110 + 0o2) + chr(11858 - 11747) + chr(1205 - 1155) + chr(0b101001 + 0o12) + chr(0b110110 + 0o1), ord("\x08")), ehT0Px3KOsy9(chr(417 - 369) + chr(0b1101000 + 0o7) + chr(53) + chr(2317 - 2267), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110011) + chr(53) + chr(55), 38084 - 38076), ehT0Px3KOsy9(chr(541 - 493) + chr(0b1101111) + chr(51) + chr(2903 - 2848) + chr(0b110001), 34188 - 34180), ehT0Px3KOsy9(chr(0b100110 + 0o12) + chr(0b1101111) + '\x37' + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(1770 - 1722) + chr(0b100010 + 0o115) + '\x33' + '\066' + chr(0b10100 + 0o40), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1001110 + 0o41) + chr(1998 - 1947) + chr(0b110111) + chr(50), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(51) + '\x34' + chr(0b100 + 0o54), 27921 - 27913), ehT0Px3KOsy9(chr(0b101110 + 0o2) + chr(2141 - 2030) + '\062' + '\x32' + chr(0b11100 + 0o30), 0b1000), ehT0Px3KOsy9(chr(0b1101 + 0o43) + chr(0b1101111) + '\063' + chr(53) + chr(50), 8), ehT0Px3KOsy9(chr(48) + '\x6f' + '\x35' + chr(0b1111 + 0o42), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1001 + 0o146) + '\x34', 5912 - 5904), ehT0Px3KOsy9(chr(48) + chr(9373 - 9262) + '\x32', 0o10), ehT0Px3KOsy9(chr(1155 - 1107) + chr(111) + chr(808 - 759) + '\x34' + '\066', 0o10), ehT0Px3KOsy9('\060' + chr(0b1101000 + 0o7) + '\061' + chr(52) + '\066', 8), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2785 - 2732) + chr(0b100010 + 0o21), 0b1000), ehT0Px3KOsy9(chr(289 - 241) + '\x6f' + chr(0b1 + 0o62) + chr(0b10001 + 0o44) + chr(53), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x33' + chr(0b110 + 0o55) + '\060', 0o10), ehT0Px3KOsy9('\x30' + chr(5765 - 5654) + '\062' + chr(479 - 427) + chr(0b11 + 0o60), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110010) + chr(2239 - 2186), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\061' + chr(50) + '\065', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\062' + chr(52) + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(50) + chr(0b110100) + chr(0b110011), 8)][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + chr(0b110001 + 0o76) + chr(53) + chr(0b110000), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xa3'), '\144' + '\145' + chr(1875 - 1776) + chr(3509 - 3398) + chr(8350 - 8250) + chr(101))('\165' + chr(116) + chr(8806 - 8704) + '\x2d' + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def QTM9jzmJPYwB():
n4ljua2gi1Pr = P5hoC4D8b8FG()
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(49) + chr(1627 - 1579) + '\060', 0b1000)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\x30' + chr(4666 - 4555) + chr(0b100001 + 0o20), 0o10)
n4ljua2gi1Pr.jZh5_pLUoOoZ = ehT0Px3KOsy9('\x30' + chr(111) + '\x33', 0o10)
n4ljua2gi1Pr.h3BUtwwQ_ZW5 = oIL3U1EOcJgs.AttentionType.MOE_LOCAL_1D
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'\xec\xf8\xde:h\xc6\x9f\xbb\x0f\x87'), chr(0b10011 + 0o121) + chr(101) + '\143' + chr(111) + chr(100) + chr(0b1100101))('\165' + chr(9450 - 9334) + chr(102) + chr(45) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xe0\xf3\xdf:l\xd7\x87\xac\x1c\x997n\x93\x01I\xc5\xcb\xed'), chr(0b1100100) + '\x65' + chr(0b1100011) + '\x6f' + chr(1538 - 1438) + '\x65')(chr(117) + chr(12360 - 12244) + chr(9662 - 9560) + '\055' + '\070'), xafqLlk3kkUe(SXOLrMavuUCe(b'\xbc'), chr(100) + chr(101) + '\x63' + '\157' + chr(0b100110 + 0o76) + chr(0b1100101))(chr(0b1110101) + chr(10340 - 10224) + '\x66' + chr(263 - 218) + chr(948 - 892)))
n4ljua2gi1Pr.GlalSbqmunyH = xafqLlk3kkUe(SXOLrMavuUCe(b'\xbc\xac\x88Q'), chr(0b1 + 0o143) + chr(101) + chr(0b11000 + 0o113) + '\x6f' + chr(0b1100100) + chr(0b1100101))(chr(117) + chr(116) + chr(3434 - 3332) + chr(0b11111 + 0o16) + chr(56))
n4ljua2gi1Pr.r99iQzD4Y8i3 = ehT0Px3KOsy9(chr(1847 - 1799) + chr(0b1011011 + 0o24) + chr(0b110010) + chr(0b101011 + 0o5), 0b1000)
n4ljua2gi1Pr.xwl05__wedRi = ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(0b100111 + 0o110) + chr(50), 8)
n4ljua2gi1Pr.VMsZZrjA_RNt = 0.01
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_sep_channels_8l_tpu
|
def imagetransformer_sep_channels_8l_tpu():
"""Hparams for training imagetransformer on tpu."""
hparams = imagetransformer_sep_channels_8l()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.shared_embedding_and_softmax_weights = False
return hparams
|
python
|
def imagetransformer_sep_channels_8l_tpu():
"""Hparams for training imagetransformer on tpu."""
hparams = imagetransformer_sep_channels_8l()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.shared_embedding_and_softmax_weights = False
return hparams
|
[
"def",
"imagetransformer_sep_channels_8l_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_sep_channels_8l",
"(",
")",
"update_hparams_for_tpu",
"(",
"hparams",
")",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"num_heads",
"=",
"4",
"# heads are expensive on tpu",
"hparams",
".",
"shared_embedding_and_softmax_weights",
"=",
"False",
"return",
"hparams"
] |
Hparams for training imagetransformer on tpu.
|
[
"Hparams",
"for",
"training",
"imagetransformer",
"on",
"tpu",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L941-L948
|
train
|
Hparams for training imagetransformer on tpu.
|
Pu7Z6IJCgH3a,vcEHXBQ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bUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b1 + 0o60) + chr(0b101111 + 0o3) + chr(0b1011 + 0o51), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110010) + chr(0b101001 + 0o7) + chr(1956 - 1904), 0b1000), ehT0Px3KOsy9('\x30' + chr(6325 - 6214) + '\x37' + '\066', 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(1061 - 1010) + chr(2244 - 2195) + chr(1342 - 1291), 43837 - 43829), ehT0Px3KOsy9(chr(0b110000) + chr(5991 - 5880) + '\x31' + chr(1380 - 1328) + chr(0b10110 + 0o40), 52314 - 52306), ehT0Px3KOsy9(chr(0b110000) + chr(4475 - 4364) + '\x32' + chr(48) + '\x35', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b100110 + 0o111) + chr(0b110001) + '\060' + chr(198 - 150), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(559 - 509) + '\x36' + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(1850 - 1802) + chr(111) + '\062' + chr(0b0 + 0o67) + '\062', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1010010 + 0o35) + '\062' + '\061' + chr(602 - 547), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(2395 - 2345), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + '\061' + chr(0b1101 + 0o51) + chr(1756 - 1706), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1000111 + 0o50) + '\061' + chr(0b11101 + 0o27) + chr(0b11 + 0o57), 0b1000), ehT0Px3KOsy9(chr(1970 - 1922) + '\x6f' + '\x34' + chr(140 - 87), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1125 - 1074) + '\066' + '\x31', 0o10), ehT0Px3KOsy9(chr(0b10001 + 0o37) + '\157' + '\x33' + '\067' + chr(2198 - 2145), 62181 - 62173), ehT0Px3KOsy9(chr(0b110000) + chr(9675 - 9564) + '\x31' + '\061' + chr(0b1001 + 0o50), 22724 - 22716), ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(111) + '\062' + '\x33', 45092 - 45084), ehT0Px3KOsy9(chr(0b110 + 0o52) + '\157' + '\061' + chr(1001 - 950) + '\x35', 4993 - 4985), ehT0Px3KOsy9('\060' + chr(0b101001 + 0o106) + chr(50) + chr(0b110010) + chr(1501 - 1446), ord("\x08")), ehT0Px3KOsy9(chr(1811 - 1763) + '\x6f' + chr(0b1101 + 0o46) + chr(0b10 + 0o56) + '\064', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b111010 + 0o65) + chr(0b100010 + 0o20) + chr(0b110111) + chr(1832 - 1783), 33423 - 33415), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b101 + 0o57) + chr(1761 - 1710), ord("\x08")), ehT0Px3KOsy9(chr(1260 - 1212) + chr(0b1001110 + 0o41) + chr(0b110010) + chr(0b11 + 0o60) + chr(0b10010 + 0o36), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(50) + chr(0b110100 + 0o2) + chr(0b1101 + 0o51), 8), ehT0Px3KOsy9('\060' + '\x6f' + chr(569 - 518) + chr(52) + '\x31', 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + '\062' + chr(0b110000) + '\066', ord("\x08")), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(2877 - 2766) + chr(1816 - 1766) + chr(0b10000 + 0o46) + chr(49), 60495 - 60487), ehT0Px3KOsy9(chr(0b1 + 0o57) + '\157' + chr(0b110111), 0o10), ehT0Px3KOsy9('\060' + chr(11440 - 11329) + chr(651 - 602) + '\064' + '\066', 8), ehT0Px3KOsy9(chr(0b1101 + 0o43) + chr(111) + chr(0b1111 + 0o44) + chr(846 - 798) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(1907 - 1859) + chr(0b1101111) + chr(877 - 827) + chr(50) + '\x32', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\061' + chr(55) + chr(1193 - 1142), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(1712 - 1662) + '\x31' + chr(2508 - 2454), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(51) + chr(0b1100 + 0o50) + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(0b10101 + 0o33) + '\157' + chr(49) + chr(1262 - 1207) + chr(0b110111 + 0o0), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + '\061' + chr(0b110010) + '\060', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b101001 + 0o106) + chr(2451 - 2401) + chr(49) + '\x35', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101010 + 0o5) + chr(640 - 586) + '\x32', 14044 - 14036), ehT0Px3KOsy9(chr(48) + chr(0b1000100 + 0o53) + '\x32' + chr(0b110000) + chr(0b10111 + 0o36), 8)][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + '\x6f' + '\x35' + chr(0b101010 + 0o6), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'z'), chr(100) + chr(0b1100101) + chr(99) + chr(0b100110 + 0o111) + chr(100) + chr(0b1010100 + 0o21))(chr(0b1110101) + '\x74' + chr(0b1010101 + 0o21) + '\x2d' + chr(0b1010 + 0o56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def yi0Dm9_q0W2h():
n4ljua2gi1Pr = g3k4ND1EpGdS()
gWr33mh0VbqT(n4ljua2gi1Pr)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\x30' + chr(4217 - 4106) + chr(52), ord("\x08"))
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9('\060' + chr(0b101011 + 0o104) + chr(52), 8)
n4ljua2gi1Pr.qVamxim0L2I1 = ehT0Px3KOsy9(chr(0b110000) + chr(0b10001 + 0o136) + '\060', 33983 - 33975)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_b10l_4h_big_uncond_dr03_tpu
|
def imagetransformer_b10l_4h_big_uncond_dr03_tpu():
"""Small model for tpu cifar 10."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 10
hparams.block_length = 128
hparams.hidden_size = 512
hparams.filter_size = 1024
hparams.learning_rate = 0.2
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
return hparams
|
python
|
def imagetransformer_b10l_4h_big_uncond_dr03_tpu():
"""Small model for tpu cifar 10."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 10
hparams.block_length = 128
hparams.hidden_size = 512
hparams.filter_size = 1024
hparams.learning_rate = 0.2
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
return hparams
|
[
"def",
"imagetransformer_b10l_4h_big_uncond_dr03_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_bas8l_8h_big_uncond_dr03_imgnet",
"(",
")",
"update_hparams_for_tpu",
"(",
"hparams",
")",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"num_heads",
"=",
"4",
"# heads are expensive on tpu",
"hparams",
".",
"num_decoder_layers",
"=",
"10",
"hparams",
".",
"block_length",
"=",
"128",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"filter_size",
"=",
"1024",
"hparams",
".",
"learning_rate",
"=",
"0.2",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"return",
"hparams"
] |
Small model for tpu cifar 10.
|
[
"Small",
"model",
"for",
"tpu",
"cifar",
"10",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L952-L965
|
train
|
Small model for tpu cifar 10.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNBHlx,ZsDPvpP4xdo3,cW7yQuyEnJ6E,KOHQGQ8qLDWm,NE1Yam2HHroQ,ygAzbDzrvRMh,SBRjvOU1ufVC,hOkXjmluKZfJ,q1QCh3W88sgk,TLbJ60djyws0,rIcPej9ZqMqV,W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y8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110001) + '\060' + '\x30', 0b1000), ehT0Px3KOsy9('\060' + chr(7185 - 7074) + '\x33' + chr(0b110101) + '\x37', 23301 - 23293), ehT0Px3KOsy9(chr(0b11011 + 0o25) + '\x6f' + chr(50) + chr(2216 - 2161) + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(0b100011 + 0o15) + '\157' + chr(1658 - 1607) + '\x37' + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b100 + 0o153) + '\062', 5319 - 5311), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(111) + '\x31' + '\061' + chr(0b1010 + 0o47), 0o10), ehT0Px3KOsy9(chr(1285 - 1237) + '\157' + '\x33' + chr(0b110101 + 0o1) + '\x37', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110001) + '\061' + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(678 - 630) + '\x6f' + '\067' + chr(1343 - 1291), 0o10), ehT0Px3KOsy9(chr(1142 - 1094) + '\157' + '\x33' + chr(0b10101 + 0o33), 0o10), ehT0Px3KOsy9('\060' + chr(0b111100 + 0o63) + chr(0b101010 + 0o11) + '\x30' + chr(55), 60391 - 60383), ehT0Px3KOsy9('\x30' + '\x6f' + chr(50) + '\063' + chr(0b100111 + 0o12), 64362 - 64354), ehT0Px3KOsy9(chr(0b110000) + chr(0b111000 + 0o67) + chr(2079 - 2028) + chr(54) + chr(53), 23851 - 23843), ehT0Px3KOsy9('\060' + '\157' + '\x36' + chr(2448 - 2394), ord("\x08")), ehT0Px3KOsy9(chr(0b100101 + 0o13) + '\157' + '\066' + chr(824 - 776), 0o10), ehT0Px3KOsy9(chr(413 - 365) + chr(111) + '\062' + '\063' + chr(557 - 509), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(50) + '\062' + '\x32', 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b1 + 0o62) + chr(0b1010 + 0o52) + chr(0b100011 + 0o22), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(51) + chr(1463 - 1414) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b101001 + 0o11) + '\x36' + chr(49), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1 + 0o156) + chr(0b110001) + chr(50) + chr(424 - 370), 29567 - 29559), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110010) + '\066' + '\x35', 0o10), ehT0Px3KOsy9(chr(0b100111 + 0o11) + '\x6f' + '\x32' + chr(0b100001 + 0o20) + chr(0b10111 + 0o36), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(1905 - 1854) + chr(0b11000 + 0o33) + chr(0b110010), 59774 - 59766), ehT0Px3KOsy9(chr(1743 - 1695) + '\x6f' + '\x33' + chr(195 - 141) + chr(54), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b101 + 0o54) + '\066' + '\x34', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(2339 - 2288) + chr(0b110110), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + '\063' + chr(0b110010) + chr(0b11 + 0o55), 10187 - 10179), ehT0Px3KOsy9(chr(1872 - 1824) + '\x6f' + chr(49) + chr(0b110100) + chr(1321 - 1267), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b100000 + 0o117) + chr(864 - 814) + chr(0b110 + 0o60), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b100000 + 0o23) + chr(0b11 + 0o62) + '\061', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(1000 - 889) + '\061' + chr(53) + '\x35', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(11845 - 11734) + '\x36' + chr(2578 - 2525), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + '\x35' + '\066', 0o10), ehT0Px3KOsy9('\060' + chr(0b1000011 + 0o54) + '\x31' + chr(1132 - 1081) + chr(0b111 + 0o51), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + '\x32' + chr(0b100110 + 0o14), 0b1000), ehT0Px3KOsy9(chr(1456 - 1408) + '\x6f' + chr(749 - 699) + chr(0b11100 + 0o25) + '\065', 8), ehT0Px3KOsy9('\x30' + chr(0b100000 + 0o117) + chr(0b110011) + chr(0b110001) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\063' + chr(55), 693 - 685), ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(0b1101111) + '\061' + chr(0b110110) + '\x32', 36366 - 36358)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(2316 - 2263) + '\x30', 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'n'), chr(4632 - 4532) + chr(2341 - 2240) + '\x63' + '\x6f' + chr(0b1010110 + 0o16) + chr(0b111111 + 0o46))(chr(0b1101 + 0o150) + chr(11461 - 11345) + '\x66' + '\055' + chr(0b11110 + 0o32)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def zbk52mjSK9wc():
n4ljua2gi1Pr = pgkv8qf4pDLc()
gWr33mh0VbqT(n4ljua2gi1Pr)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x34', 0o10)
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(2264 - 2216) + chr(9701 - 9590) + '\x34', 8)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x31' + chr(639 - 589), ord("\x08"))
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9(chr(0b110000) + chr(10947 - 10836) + chr(0b11111 + 0o23) + chr(0b110000) + chr(1444 - 1396), 0b1000)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(111) + '\061' + '\060' + chr(726 - 678) + '\060', 0b1000)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110010) + chr(0b100 + 0o54) + '\x30' + chr(48), 0b1000)
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.2
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'.\x80\xd6\x9c'), chr(2686 - 2586) + chr(101) + chr(99) + chr(0b1010100 + 0o33) + '\x64' + chr(101))(chr(10976 - 10859) + chr(0b1000100 + 0o60) + chr(973 - 871) + chr(45) + chr(0b101 + 0o63))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'$\x8e\xd6'), chr(0b111100 + 0o50) + chr(0b1100101) + '\x63' + chr(111) + '\x64' + chr(101))(chr(117) + chr(0b1110100) + '\146' + chr(45) + chr(0b101110 + 0o12))
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_b10l_dr03_moe_tpu
|
def imagetransformer_b10l_dr03_moe_tpu():
"""Moe tpu params."""
hparams = imagetransformer_b10l_4h_big_uncond_dr03_tpu()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 10
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.ffn_layer = "local_moe_tpu"
return hparams
|
python
|
def imagetransformer_b10l_dr03_moe_tpu():
"""Moe tpu params."""
hparams = imagetransformer_b10l_4h_big_uncond_dr03_tpu()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 10
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.ffn_layer = "local_moe_tpu"
return hparams
|
[
"def",
"imagetransformer_b10l_dr03_moe_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_b10l_4h_big_uncond_dr03_tpu",
"(",
")",
"update_hparams_for_tpu",
"(",
"hparams",
")",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"num_heads",
"=",
"4",
"# heads are expensive on tpu",
"hparams",
".",
"num_decoder_layers",
"=",
"10",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"hparams",
".",
"ffn_layer",
"=",
"\"local_moe_tpu\"",
"return",
"hparams"
] |
Moe tpu params.
|
[
"Moe",
"tpu",
"params",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L969-L979
|
train
|
Moe tpu params.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,F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XYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + '\x6f' + '\061' + chr(51) + chr(2335 - 2281), 24650 - 24642), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(1977 - 1927) + '\064' + '\x35', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(53) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(0b1110 + 0o42) + '\157' + '\x33' + '\x37' + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110011) + chr(0b100111 + 0o17) + chr(2022 - 1970), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b111111 + 0o60) + '\x32' + '\x37' + chr(0b10111 + 0o34), 45435 - 45427), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110001) + chr(49) + chr(0b1000 + 0o51), ord("\x08")), ehT0Px3KOsy9(chr(2040 - 1992) + '\157' + '\061' + chr(0b110100) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(5871 - 5760) + chr(0b110011) + chr(0b101110 + 0o6) + chr(0b110111), 33161 - 33153), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110010) + '\x34' + chr(48), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(50) + chr(0b110101 + 0o2) + chr(49), 0o10), ehT0Px3KOsy9(chr(861 - 813) + chr(0b1101111) + chr(0b110011) + chr(2193 - 2145) + '\060', 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\x31' + chr(0b110111) + chr(0b11011 + 0o31), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x32' + chr(0b0 + 0o67) + '\066', ord("\x08")), ehT0Px3KOsy9(chr(1012 - 964) + '\157' + '\x32' + chr(0b110011) + chr(53), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x32' + '\x35' + chr(2113 - 2064), ord("\x08")), ehT0Px3KOsy9(chr(582 - 534) + chr(111) + '\x34' + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(52) + '\x31', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110011) + '\061', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101011 + 0o4) + chr(50) + '\065' + chr(0b100000 + 0o21), 8), ehT0Px3KOsy9(chr(170 - 122) + chr(0b10100 + 0o133) + chr(0b100100 + 0o16) + chr(0b110010) + '\x32', 0b1000), ehT0Px3KOsy9('\060' + chr(6789 - 6678) + '\062' + chr(0b1100 + 0o45), 0o10), ehT0Px3KOsy9(chr(0b1100 + 0o44) + '\x6f' + chr(0b101111 + 0o2) + '\065', 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(49) + '\066' + chr(0b100100 + 0o23), 0b1000), ehT0Px3KOsy9('\x30' + chr(7976 - 7865) + '\061' + chr(54) + chr(51), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(2334 - 2283) + chr(1511 - 1461) + chr(0b11100 + 0o26), ord("\x08")), ehT0Px3KOsy9(chr(0b1100 + 0o44) + '\157' + chr(50) + chr(0b110110) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b11001 + 0o31) + '\x34' + chr(0b110100), 0o10), ehT0Px3KOsy9('\x30' + chr(4645 - 4534) + chr(51) + '\x36' + '\x31', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(11585 - 11474) + chr(0b110011) + chr(0b11111 + 0o27) + chr(0b11111 + 0o25), 8), ehT0Px3KOsy9(chr(0b11111 + 0o21) + chr(111) + '\061' + chr(54) + chr(51), 8), ehT0Px3KOsy9(chr(2145 - 2097) + chr(0b10000 + 0o137) + chr(586 - 535) + chr(0b10111 + 0o33) + chr(2400 - 2348), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110011) + '\065' + chr(50), 0b1000), ehT0Px3KOsy9(chr(149 - 101) + '\x6f' + '\x33' + chr(1462 - 1411) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(3924 - 3813) + chr(75 - 26) + chr(0b110000) + '\062', 10238 - 10230), ehT0Px3KOsy9('\060' + chr(0b1100 + 0o143) + chr(0b110011) + chr(0b110111) + '\062', 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x31' + chr(0b110011) + '\x32', 0o10), ehT0Px3KOsy9(chr(1917 - 1869) + chr(111) + chr(49) + '\064' + '\065', 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(51) + chr(0b110101), 56786 - 56778), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\066' + '\064', 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + '\x6f' + chr(1720 - 1667) + chr(48), 14128 - 14120)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'p'), '\x64' + chr(0b1000110 + 0o37) + '\x63' + chr(0b1001100 + 0o43) + chr(100) + '\145')('\165' + '\164' + chr(102) + '\055' + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def epYOUeCdENL0():
n4ljua2gi1Pr = zbk52mjSK9wc()
gWr33mh0VbqT(n4ljua2gi1Pr)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(110 - 58), 0b1000)
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9('\060' + chr(111) + chr(0b110100), 8)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9('\x30' + '\157' + chr(0b110001) + '\x32', ord("\x08"))
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'0\xcaA\x99'), '\144' + chr(0b0 + 0o145) + chr(0b111011 + 0o50) + chr(111) + chr(0b1100011 + 0o1) + '\145')('\x75' + '\x74' + chr(0b1000101 + 0o41) + chr(112 - 67) + chr(0b100000 + 0o30))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b':\xc4A'), chr(100) + chr(101) + chr(99) + '\157' + chr(100) + chr(2077 - 1976))(chr(0b100000 + 0o125) + '\x74' + chr(0b1100110) + chr(1326 - 1281) + chr(56))
n4ljua2gi1Pr.SH5PH2T7PEUB = xafqLlk3kkUe(SXOLrMavuUCe(b'2\xcaL\x9d\x98\xe4$\x0f\x82\xff\xcd\xb0\t'), '\x64' + chr(0b1100101) + chr(0b111011 + 0o50) + '\x6f' + chr(0b110001 + 0o63) + '\145')(chr(117) + chr(3745 - 3629) + chr(102) + chr(0b101101) + chr(0b100100 + 0o24))
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_b10l_4h_big_uncond_dr03_lr025_tpu
|
def imagetransformer_b10l_4h_big_uncond_dr03_lr025_tpu():
"""TPU related small model."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 10
hparams.learning_rate = 0.25
hparams.learning_rate_warmup_steps = 8000
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
# hparams.unconditional = True
return hparams
|
python
|
def imagetransformer_b10l_4h_big_uncond_dr03_lr025_tpu():
"""TPU related small model."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 10
hparams.learning_rate = 0.25
hparams.learning_rate_warmup_steps = 8000
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
# hparams.unconditional = True
return hparams
|
[
"def",
"imagetransformer_b10l_4h_big_uncond_dr03_lr025_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_bas8l_8h_big_uncond_dr03_imgnet",
"(",
")",
"update_hparams_for_tpu",
"(",
"hparams",
")",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"num_heads",
"=",
"4",
"# heads are expensive on tpu",
"hparams",
".",
"num_decoder_layers",
"=",
"10",
"hparams",
".",
"learning_rate",
"=",
"0.25",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"8000",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"# hparams.unconditional = True",
"return",
"hparams"
] |
TPU related small model.
|
[
"TPU",
"related",
"small",
"model",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L983-L995
|
train
|
TPU related small model.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWA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ithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x31' + '\x31' + chr(50), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(1476 - 1427) + chr(50) + '\067', 0o10), ehT0Px3KOsy9(chr(2210 - 2162) + '\157' + chr(0b100110 + 0o13) + chr(0b110101) + chr(0b11111 + 0o26), ord("\x08")), ehT0Px3KOsy9(chr(955 - 907) + chr(8046 - 7935) + chr(0b110111) + '\063', 1497 - 1489), ehT0Px3KOsy9(chr(48) + chr(111) + '\x34', 41596 - 41588), ehT0Px3KOsy9(chr(1113 - 1065) + '\157' + chr(0b11011 + 0o27) + '\x37' + chr(0b110001), 56858 - 56850), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(922 - 871) + chr(0b11 + 0o55) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b111000 + 0o67) + '\063' + chr(0b110010), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x33' + chr(2117 - 2069), 6449 - 6441), ehT0Px3KOsy9(chr(0b1111 + 0o41) + '\x6f' + '\061' + chr(0b110001) + chr(0b110001), 42328 - 42320), ehT0Px3KOsy9(chr(0b101001 + 0o7) + '\x6f' + chr(50) + chr(0b100111 + 0o14) + '\065', 8058 - 8050), ehT0Px3KOsy9(chr(0b101111 + 0o1) + chr(0b101 + 0o152) + chr(923 - 874) + '\x33' + chr(53), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\x33' + '\x34' + chr(52), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(1869 - 1820) + chr(0b110101) + chr(124 - 75), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(49) + chr(0b110011) + '\063', 8588 - 8580), ehT0Px3KOsy9(chr(0b1000 + 0o50) + '\x6f' + chr(0b100111 + 0o17) + chr(760 - 711), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110011 + 0o0) + chr(0b10010 + 0o40) + chr(0b110100), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110011) + chr(1239 - 1187) + chr(0b110011), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + '\x36' + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(111) + chr(117 - 66) + chr(1885 - 1837) + chr(0b110101), 17786 - 17778), ehT0Px3KOsy9(chr(48) + chr(0b1010101 + 0o32) + chr(2299 - 2249) + chr(0b11110 + 0o23) + chr(54), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\x31' + '\066' + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(1423 - 1375) + '\x6f' + '\065' + chr(0b101 + 0o54), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\061' + chr(1795 - 1745), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b101 + 0o54) + chr(0b100 + 0o54) + chr(0b110111), 8231 - 8223), ehT0Px3KOsy9('\x30' + chr(1768 - 1657) + chr(0b0 + 0o63) + chr(0b110010) + chr(0b110100), 8), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x33' + chr(0b11110 + 0o26) + chr(0b110100), 8), ehT0Px3KOsy9(chr(48) + chr(111) + chr(50) + chr(0b100110 + 0o15) + chr(0b101010 + 0o13), 8), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110001) + chr(0b110 + 0o52) + chr(0b110011), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\x32' + chr(53) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(1134 - 1083) + chr(0b10000 + 0o41) + chr(0b10011 + 0o36), 38365 - 38357), ehT0Px3KOsy9('\x30' + '\157' + chr(51) + chr(0b110001) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(1705 - 1594) + chr(0b101110 + 0o4) + '\065' + chr(989 - 941), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(49) + '\x30' + chr(2540 - 2489), 8), ehT0Px3KOsy9(chr(48) + '\157' + '\x32' + '\x37' + chr(0b100101 + 0o14), 8), ehT0Px3KOsy9(chr(0b10111 + 0o31) + '\157' + chr(1980 - 1929) + chr(0b110100) + chr(50), 0b1000), ehT0Px3KOsy9('\x30' + chr(11418 - 11307) + chr(50) + '\065' + chr(0b110011), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b100110 + 0o13) + '\062', 8), ehT0Px3KOsy9(chr(259 - 211) + chr(0b11110 + 0o121) + '\x32' + '\x33' + chr(50), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b101101 + 0o6) + '\x33' + '\062', 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b1010 + 0o46) + '\x6f' + chr(1035 - 982) + chr(0b110000), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'd'), '\x64' + chr(101) + chr(99) + chr(0b1101111) + chr(5044 - 4944) + '\145')(chr(0b1100001 + 0o24) + chr(7342 - 7226) + '\x66' + '\x2d' + chr(0b110101 + 0o3)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def L0UcxFOTwh3m():
n4ljua2gi1Pr = pgkv8qf4pDLc()
gWr33mh0VbqT(n4ljua2gi1Pr)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(48) + '\157' + '\064', 8)
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(0b110000) + '\157' + '\064', 8)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(667 - 619) + chr(111) + chr(0b1000 + 0o51) + chr(774 - 724), 8)
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.25
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9(chr(0b110000) + chr(0b111110 + 0o61) + chr(0b100011 + 0o16) + chr(55) + chr(2210 - 2157) + chr(0b11100 + 0o24) + '\060', 0o10)
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'$8\x03^'), '\144' + '\145' + '\x63' + chr(0b1001 + 0o146) + chr(100) + '\x65')(chr(0b1110101) + chr(0b1110100) + '\x66' + chr(1473 - 1428) + chr(0b111000))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'.6\x03'), '\x64' + chr(7782 - 7681) + chr(99) + '\x6f' + chr(3493 - 3393) + '\x65')('\x75' + '\x74' + chr(102) + '\x2d' + chr(911 - 855))
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_b12l_4h_b256_uncond_dr03_tpu
|
def imagetransformer_b12l_4h_b256_uncond_dr03_tpu():
"""works very well on 4x4."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 12
hparams.block_length = 256
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.learning_rate = 0.5
hparams.learning_rate_warmup_steps = 4000
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.3
hparams.unconditional = True
return hparams
|
python
|
def imagetransformer_b12l_4h_b256_uncond_dr03_tpu():
"""works very well on 4x4."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 12
hparams.block_length = 256
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.learning_rate = 0.5
hparams.learning_rate_warmup_steps = 4000
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.3
hparams.unconditional = True
return hparams
|
[
"def",
"imagetransformer_b12l_4h_b256_uncond_dr03_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_bas8l_8h_big_uncond_dr03_imgnet",
"(",
")",
"update_hparams_for_tpu",
"(",
"hparams",
")",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"num_heads",
"=",
"4",
"# heads are expensive on tpu",
"hparams",
".",
"num_decoder_layers",
"=",
"12",
"hparams",
".",
"block_length",
"=",
"256",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"filter_size",
"=",
"2048",
"hparams",
".",
"learning_rate",
"=",
"0.5",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"4000",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.3",
"hparams",
".",
"unconditional",
"=",
"True",
"return",
"hparams"
] |
works very well on 4x4.
|
[
"works",
"very",
"well",
"on",
"4x4",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L1025-L1041
|
train
|
Hparams for tpu - undirected dr03.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEX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,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110001 + 0o0) + chr(51) + '\x35', 0o10), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(3525 - 3414) + chr(0b110011 + 0o0) + '\064' + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(0b101101 + 0o3) + '\157' + chr(54) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(4588 - 4477) + chr(0b110001) + chr(0b110110) + '\065', 22352 - 22344), ehT0Px3KOsy9('\x30' + chr(0b101 + 0o152) + '\x36' + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(0b10 + 0o56) + '\157' + chr(0b10100 + 0o36) + '\x37' + chr(0b101001 + 0o10), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x32' + chr(0b1110 + 0o50) + chr(0b101001 + 0o13), 0o10), ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(0b1101111) + chr(50) + chr(51) + chr(2391 - 2339), 0o10), ehT0Px3KOsy9('\060' + chr(4827 - 4716) + chr(621 - 570) + '\x33' + chr(0b110110), 49819 - 49811), ehT0Px3KOsy9('\x30' + chr(111) + '\x33' + chr(774 - 722), 0o10), ehT0Px3KOsy9(chr(244 - 196) + chr(322 - 211) + chr(2761 - 2707) + chr(439 - 387), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(49) + '\x36' + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(1402 - 1354) + '\157' + '\061' + '\x33', 17694 - 17686), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(2249 - 2201) + '\157' + '\063', ord("\x08")), ehT0Px3KOsy9('\060' + chr(6952 - 6841) + chr(1884 - 1833) + chr(0b100101 + 0o16) + chr(51), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(5621 - 5510) + chr(0b110010) + chr(0b110001) + chr(1667 - 1618), 39144 - 39136), ehT0Px3KOsy9(chr(48) + '\157' + chr(55) + chr(0b11100 + 0o24), 22594 - 22586), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(0b1100101 + 0o12) + '\x31' + '\x34' + chr(0b110001), 34215 - 34207), ehT0Px3KOsy9('\x30' + chr(111) + chr(49) + chr(0b110111) + '\066', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1100101 + 0o12) + chr(0b100111 + 0o15) + chr(1914 - 1863), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + '\x31' + chr(645 - 597) + chr(0b111 + 0o52), 54903 - 54895), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110010) + chr(2604 - 2551), 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(49) + chr(0b101000 + 0o17) + '\060', 0o10), ehT0Px3KOsy9(chr(579 - 531) + chr(0b1101111) + '\062' + chr(0b110101 + 0o0), 8), ehT0Px3KOsy9('\060' + '\x6f' + chr(1228 - 1179) + chr(1364 - 1316) + '\x37', 29175 - 29167), ehT0Px3KOsy9(chr(600 - 552) + '\x6f' + chr(49) + chr(0b110111 + 0o0) + chr(1101 - 1048), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + '\063' + chr(0b110000) + chr(2234 - 2184), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(11216 - 11105) + '\061' + chr(0b110101) + chr(1857 - 1803), 61743 - 61735), ehT0Px3KOsy9('\x30' + chr(5837 - 5726) + chr(0b110011) + chr(0b110001) + chr(0b10011 + 0o40), 0b1000), ehT0Px3KOsy9(chr(0b101010 + 0o6) + chr(111) + chr(1313 - 1264) + '\060', 0o10), ehT0Px3KOsy9('\x30' + chr(111) + '\x37' + '\067', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\061' + chr(2879 - 2824) + chr(1349 - 1299), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110001) + chr(55) + chr(0b110100), 0o10), ehT0Px3KOsy9('\060' + chr(0b1011011 + 0o24) + chr(1205 - 1155) + chr(2109 - 2058) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(3763 - 3652) + chr(0b110011) + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1011100 + 0o23) + chr(1041 - 991) + chr(0b101110 + 0o10) + chr(0b110100), 8), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\062' + '\065' + chr(1758 - 1710), 21535 - 21527), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b100010 + 0o17) + '\x31' + '\x30', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x33' + '\x33' + chr(0b11111 + 0o23), 1557 - 1549)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(111) + chr(53) + chr(48), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b's'), '\144' + chr(5829 - 5728) + chr(99) + chr(111) + '\144' + '\x65')(chr(117) + '\164' + chr(0b1100110) + '\055' + chr(0b10000 + 0o50)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def DhhdvXHepfHn():
n4ljua2gi1Pr = pgkv8qf4pDLc()
gWr33mh0VbqT(n4ljua2gi1Pr)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(52), ord("\x08"))
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(52), 8)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(48) + chr(111) + '\061' + chr(52), 0b1000)
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9('\x30' + '\157' + chr(0b110100) + chr(0b110000) + '\060', 45097 - 45089)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9('\060' + chr(111) + chr(2329 - 2280) + chr(48) + chr(103 - 55) + chr(0b110000), 0o10)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(0b110000) + chr(0b1011110 + 0o21) + chr(52) + '\x30' + chr(0b110000) + '\x30', 26800 - 26792)
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.5
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9(chr(0b101011 + 0o5) + chr(111) + '\x37' + chr(54) + chr(0b101100 + 0o10) + chr(0b110000), 0o10)
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'3\x8c\\\x10'), '\x64' + '\x65' + chr(99) + chr(12081 - 11970) + chr(0b11101 + 0o107) + chr(101))(chr(0b11000 + 0o135) + chr(0b1110100) + chr(0b1100110) + chr(0b100111 + 0o6) + chr(951 - 895))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'9\x82\\'), chr(100) + '\145' + '\143' + chr(0b111 + 0o150) + chr(641 - 541) + '\145')(chr(117) + '\x74' + chr(102) + '\x2d' + chr(0b111000))
n4ljua2gi1Pr.RW_xSzp18UeS = 0.3
n4ljua2gi1Pr.IcYfltg0WkcT = ehT0Px3KOsy9(chr(569 - 521) + '\x6f' + '\061', ord("\x08"))
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_b12l_4h_b256_uncond_dr03_rel_tpu
|
def imagetransformer_b12l_4h_b256_uncond_dr03_rel_tpu():
"""works very well on 4x4."""
hparams = imagetransformer_b12l_4h_b256_uncond_dr03_tpu()
hparams.shared_rel = True
hparams.dec_attention_type = cia.AttentionType.RELATIVE_LOCAL_1D
return hparams
|
python
|
def imagetransformer_b12l_4h_b256_uncond_dr03_rel_tpu():
"""works very well on 4x4."""
hparams = imagetransformer_b12l_4h_b256_uncond_dr03_tpu()
hparams.shared_rel = True
hparams.dec_attention_type = cia.AttentionType.RELATIVE_LOCAL_1D
return hparams
|
[
"def",
"imagetransformer_b12l_4h_b256_uncond_dr03_rel_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_b12l_4h_b256_uncond_dr03_tpu",
"(",
")",
"hparams",
".",
"shared_rel",
"=",
"True",
"hparams",
".",
"dec_attention_type",
"=",
"cia",
".",
"AttentionType",
".",
"RELATIVE_LOCAL_1D",
"return",
"hparams"
] |
works very well on 4x4.
|
[
"works",
"very",
"well",
"on",
"4x4",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L1045-L1050
|
train
|
works very well on 4x4.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy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Error,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + '\157' + chr(0b110111) + chr(49), 0b1000), ehT0Px3KOsy9(chr(48) + chr(6872 - 6761) + chr(614 - 563) + chr(0b110011) + chr(49), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b10 + 0o57) + chr(0b110111) + chr(0b110000), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(2108 - 2057) + '\x34' + '\x35', 0b1000), ehT0Px3KOsy9('\060' + chr(0b11110 + 0o121) + '\x32' + chr(0b110000) + chr(0b10000 + 0o46), 11614 - 11606), ehT0Px3KOsy9(chr(0b10101 + 0o33) + chr(8083 - 7972) + chr(0b110010) + '\065' + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(0b10 + 0o56) + '\157' + chr(0b101 + 0o55) + chr(0b100101 + 0o22) + chr(51), 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(1235 - 1185) + '\x35' + chr(0b110011), 14565 - 14557), ehT0Px3KOsy9(chr(1061 - 1013) + '\x6f' + '\x35' + '\067', 0b1000), ehT0Px3KOsy9(chr(965 - 917) + chr(2515 - 2404) + chr(0b101001 + 0o10) + '\x31' + chr(550 - 500), 0o10), ehT0Px3KOsy9('\060' + '\157' + chr(49) + '\067' + chr(55), 31285 - 31277), ehT0Px3KOsy9(chr(0b110000) + chr(0b1010101 + 0o32) + chr(2255 - 2206) + chr(0b111 + 0o55) + '\067', 0o10), ehT0Px3KOsy9(chr(0b1111 + 0o41) + '\157' + chr(49) + chr(2310 - 2260) + '\062', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b11000 + 0o31) + chr(0b10011 + 0o41) + chr(0b100 + 0o57), 0o10), ehT0Px3KOsy9('\060' + chr(111) + '\061' + '\x35', 0b1000), ehT0Px3KOsy9('\060' + chr(0b110101 + 0o72) + '\061' + '\065' + chr(0b110110 + 0o0), 0o10), ehT0Px3KOsy9('\060' + chr(0b1010000 + 0o37) + chr(49) + chr(1603 - 1555) + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(1707 - 1659) + chr(111) + '\062' + '\065' + chr(0b11110 + 0o24), ord("\x08")), ehT0Px3KOsy9(chr(779 - 731) + chr(0b1101111) + chr(0b1100 + 0o47) + chr(62 - 9) + chr(0b100001 + 0o24), 16787 - 16779), ehT0Px3KOsy9('\x30' + '\157' + '\061' + '\066' + chr(0b11110 + 0o26), 51829 - 51821), ehT0Px3KOsy9(chr(48) + '\x6f' + '\061' + '\063' + chr(48), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + '\x33' + '\066' + chr(50), 0o10), ehT0Px3KOsy9(chr(0b10010 + 0o36) + '\x6f' + chr(0b110011) + '\067' + '\x33', 0o10), ehT0Px3KOsy9(chr(48) + '\157' + '\x33' + chr(55) + '\064', 0o10), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(5960 - 5849) + '\x32' + '\064' + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(0b11011 + 0o25) + chr(0b1101111) + '\061' + chr(0b1101 + 0o46) + chr(48), 8), ehT0Px3KOsy9(chr(0b100000 + 0o20) + chr(8431 - 8320) + chr(49) + chr(50) + chr(373 - 324), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\061' + '\x35' + chr(0b110001), 22799 - 22791), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2577 - 2526) + '\062' + chr(0b101100 + 0o6), 45548 - 45540), ehT0Px3KOsy9('\x30' + chr(0b111101 + 0o62) + '\x33' + '\064' + chr(1132 - 1080), 0o10), ehT0Px3KOsy9('\x30' + chr(2126 - 2015) + '\061' + chr(52) + '\x30', 0o10), ehT0Px3KOsy9(chr(0b11101 + 0o23) + chr(0b11001 + 0o126) + '\x33' + '\063', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\062' + chr(1693 - 1644), 0o10), ehT0Px3KOsy9(chr(0b10 + 0o56) + chr(0b1101111) + chr(0b110011) + chr(55) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(0b1000 + 0o50) + chr(5495 - 5384) + chr(51) + '\061' + '\x37', 21823 - 21815), ehT0Px3KOsy9(chr(0b100010 + 0o16) + chr(8060 - 7949) + '\062' + chr(0b110101) + chr(52), 0o10), ehT0Px3KOsy9('\060' + chr(0b100000 + 0o117) + chr(1822 - 1772) + chr(0b110000), 56904 - 56896), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(49) + chr(53), 8), ehT0Px3KOsy9(chr(707 - 659) + chr(0b101101 + 0o102) + chr(0b110011) + '\062' + chr(2303 - 2255), 49337 - 49329), ehT0Px3KOsy9(chr(48) + '\x6f' + '\061' + '\x35' + chr(0b110101), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(9084 - 8973) + '\065' + '\060', 33340 - 33332)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x17'), '\x64' + '\145' + chr(99) + chr(9792 - 9681) + chr(0b101000 + 0o74) + chr(0b1100101))(chr(0b1001101 + 0o50) + '\164' + '\x66' + chr(0b110 + 0o47) + chr(1821 - 1765)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def umxlK4u6YXZ6():
n4ljua2gi1Pr = DhhdvXHepfHn()
n4ljua2gi1Pr.PCprZFqm0QIL = ehT0Px3KOsy9(chr(0b100010 + 0o16) + chr(10943 - 10832) + chr(49), 0o10)
n4ljua2gi1Pr.h3BUtwwQ_ZW5 = oIL3U1EOcJgs.AttentionType.RELATIVE_LOCAL_1D
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_cifar_tpu_range
|
def imagetransformer_cifar_tpu_range(rhp):
"""Range of hyperparameters for vizier."""
# After starting from base, set intervals for some parameters.
rhp.set_float("learning_rate", 0.01, 1.0, scale=rhp.LOG_SCALE)
rhp.set_discrete("num_decoder_layers", [8, 10, 12, 14, 16])
rhp.set_discrete("hidden_size", [256, 512, 1024])
rhp.set_discrete("block_length", [128, 256, 512])
rhp.set_categorical("dec_attention_type", [
cia.AttentionType.RELATIVE_LOCAL_1D, cia.AttentionType.LOCAL_1D])
|
python
|
def imagetransformer_cifar_tpu_range(rhp):
"""Range of hyperparameters for vizier."""
# After starting from base, set intervals for some parameters.
rhp.set_float("learning_rate", 0.01, 1.0, scale=rhp.LOG_SCALE)
rhp.set_discrete("num_decoder_layers", [8, 10, 12, 14, 16])
rhp.set_discrete("hidden_size", [256, 512, 1024])
rhp.set_discrete("block_length", [128, 256, 512])
rhp.set_categorical("dec_attention_type", [
cia.AttentionType.RELATIVE_LOCAL_1D, cia.AttentionType.LOCAL_1D])
|
[
"def",
"imagetransformer_cifar_tpu_range",
"(",
"rhp",
")",
":",
"# After starting from base, set intervals for some parameters.",
"rhp",
".",
"set_float",
"(",
"\"learning_rate\"",
",",
"0.01",
",",
"1.0",
",",
"scale",
"=",
"rhp",
".",
"LOG_SCALE",
")",
"rhp",
".",
"set_discrete",
"(",
"\"num_decoder_layers\"",
",",
"[",
"8",
",",
"10",
",",
"12",
",",
"14",
",",
"16",
"]",
")",
"rhp",
".",
"set_discrete",
"(",
"\"hidden_size\"",
",",
"[",
"256",
",",
"512",
",",
"1024",
"]",
")",
"rhp",
".",
"set_discrete",
"(",
"\"block_length\"",
",",
"[",
"128",
",",
"256",
",",
"512",
"]",
")",
"rhp",
".",
"set_categorical",
"(",
"\"dec_attention_type\"",
",",
"[",
"cia",
".",
"AttentionType",
".",
"RELATIVE_LOCAL_1D",
",",
"cia",
".",
"AttentionType",
".",
"LOCAL_1D",
"]",
")"
] |
Range of hyperparameters for vizier.
|
[
"Range",
"of",
"hyperparameters",
"for",
"vizier",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L1054-L1062
|
train
|
Range of hyperparameters for vizier.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvb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nectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b1010 + 0o46) + chr(0b1101111) + chr(50) + chr(52) + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(1794 - 1744) + chr(0b110 + 0o53) + chr(0b10100 + 0o37), 3032 - 3024), ehT0Px3KOsy9(chr(345 - 297) + chr(0b1101111) + chr(270 - 219) + chr(0b110110) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(0b10100 + 0o34) + chr(0b1101100 + 0o3) + '\065' + '\066', 0o10), ehT0Px3KOsy9(chr(48) + chr(6254 - 6143) + chr(50) + chr(52) + chr(0b101010 + 0o13), 8), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110011) + chr(0b110110) + '\062', 50102 - 50094), ehT0Px3KOsy9(chr(0b101110 + 0o2) + '\157' + chr(2476 - 2426) + chr(0b110001) + chr(0b1 + 0o63), 18164 - 18156), ehT0Px3KOsy9(chr(913 - 865) + '\157' + '\x32' + chr(0b0 + 0o62) + chr(0b110000), 0b1000), ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(8586 - 8475) + chr(267 - 217) + '\065' + chr(50), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + '\x33' + chr(0b110011), 8761 - 8753), ehT0Px3KOsy9(chr(48) + '\157' + '\x31' + chr(0b100000 + 0o22) + chr(1499 - 1451), ord("\x08")), ehT0Px3KOsy9(chr(1201 - 1153) + chr(0b1101111) + '\061' + '\063' + '\064', 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2044 - 1993) + '\064', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + '\063' + chr(1637 - 1588) + chr(260 - 212), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x33' + chr(48) + '\065', 6416 - 6408), ehT0Px3KOsy9('\x30' + chr(0b11001 + 0o126) + chr(0b110010) + chr(52) + '\x33', 51343 - 51335), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x31' + chr(0b110001) + chr(1367 - 1318), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\x32' + chr(0b110001) + '\060', 38345 - 38337), ehT0Px3KOsy9(chr(2270 - 2222) + chr(0b1101111) + chr(1365 - 1315), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110001) + chr(0b110011) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(1749 - 1701) + chr(3931 - 3820) + '\061' + chr(0b110000) + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x31' + '\061' + '\x36', 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(51) + chr(0b110111) + chr(0b10000 + 0o44), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x35' + '\062', 61367 - 61359), ehT0Px3KOsy9(chr(48) + chr(111) + chr(2310 - 2261) + chr(53) + chr(55), 0o10), ehT0Px3KOsy9(chr(0b100000 + 0o20) + '\x6f' + '\x31' + chr(0b110000) + chr(0b1010 + 0o46), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b11110 + 0o23) + chr(0b10111 + 0o33) + chr(0b101011 + 0o13), 11826 - 11818), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b101111 + 0o4) + '\x33', 8), ehT0Px3KOsy9(chr(0b1101 + 0o43) + chr(0b1101111) + chr(0b110001) + '\061' + '\064', 24973 - 24965), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(625 - 573) + chr(53), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b100001 + 0o116) + chr(50) + '\066' + chr(926 - 877), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b11011 + 0o124) + chr(556 - 507) + chr(0b1 + 0o65), 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + '\067' + '\x36', 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(2110 - 2060) + '\x30' + chr(49), 0b1000), ehT0Px3KOsy9(chr(0b10 + 0o56) + chr(0b10001 + 0o136) + chr(49) + chr(0b101 + 0o60) + chr(1756 - 1705), 0b1000), ehT0Px3KOsy9(chr(0b11 + 0o55) + chr(4176 - 4065) + chr(2493 - 2442) + chr(0b110111) + chr(0b100 + 0o60), 8), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(51) + chr(48) + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b100011 + 0o114) + '\x32' + chr(0b1110 + 0o45) + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(0b1001 + 0o47) + '\x6f' + chr(49) + chr(54) + chr(54), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(51) + chr(0b101000 + 0o17) + chr(52), 8)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b101000 + 0o10) + chr(111) + chr(53) + chr(48), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x8b'), chr(100) + chr(0b100100 + 0o101) + '\x63' + '\157' + chr(662 - 562) + chr(101))(chr(7479 - 7362) + '\x74' + '\x66' + chr(0b101101) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def DaRYP4f81rPB(IwsgmEzQknPc):
xafqLlk3kkUe(IwsgmEzQknPc, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd6\xee\x83q\xc3\x9e\xe3\xf1\xde'), '\144' + chr(1933 - 1832) + '\143' + '\x6f' + '\x64' + '\x65')(chr(0b1010011 + 0o42) + '\164' + chr(0b10111 + 0o117) + chr(1470 - 1425) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc9\xee\x96\\\xcb\x9b\xe2\xf7\xf5i1(y'), chr(100) + chr(0b1100101) + '\143' + chr(0b1101111) + chr(2585 - 2485) + chr(0b1100101))(chr(0b100111 + 0o116) + '\x74' + '\146' + chr(0b101101) + chr(56)), 0.01, 1.0, scale=xafqLlk3kkUe(IwsgmEzQknPc, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe9\xc4\xb0q\xf6\xb1\xcd\xdc\xef'), '\144' + chr(0b1100101) + chr(99) + chr(0b110011 + 0o74) + chr(264 - 164) + chr(0b1010 + 0o133))(chr(117) + chr(0b1110100) + chr(0b1100110) + '\x2d' + chr(1446 - 1390))))
xafqLlk3kkUe(IwsgmEzQknPc, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd6\xee\x83q\xc1\x9b\xff\xf3\xd8~$9'), chr(100) + chr(101) + chr(99) + '\157' + chr(0b110111 + 0o55) + chr(101))(chr(117) + '\164' + chr(102) + chr(0b101101) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xcb\xfe\x9aq\xc1\x97\xef\xff\xce~"\x03p\xa9\xbc\xc6;\xfb'), chr(979 - 879) + chr(101) + chr(0b1100011) + chr(0b1101111) + chr(7262 - 7162) + '\x65')(chr(117) + chr(0b1101111 + 0o5) + '\146' + '\055' + chr(0b0 + 0o70)), [ehT0Px3KOsy9(chr(1573 - 1525) + chr(5775 - 5664) + chr(0b100 + 0o55) + '\060', 0o10), ehT0Px3KOsy9(chr(0b1110 + 0o42) + '\x6f' + chr(49) + chr(0b110010), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(49) + chr(1083 - 1031), 0o10), ehT0Px3KOsy9(chr(0b100001 + 0o17) + '\157' + '\061' + '\066', 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b10101 + 0o132) + chr(50) + chr(48), 0b1000)])
xafqLlk3kkUe(IwsgmEzQknPc, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd6\xee\x83q\xc1\x9b\xff\xf3\xd8~$9'), '\144' + chr(309 - 208) + chr(0b10111 + 0o114) + '\157' + '\144' + chr(6196 - 6095))(chr(0b100 + 0o161) + '\164' + chr(979 - 877) + chr(0b1111 + 0o36) + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xcd\xe2\x93J\xc0\x9c\xd3\xe3\xc3a5'), chr(100) + '\x65' + '\x63' + chr(111) + '\144' + chr(0b1100101))(chr(4774 - 4657) + chr(1614 - 1498) + chr(102) + '\055' + chr(2774 - 2718)), [ehT0Px3KOsy9('\x30' + '\x6f' + '\064' + '\060' + chr(0b1001 + 0o47), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\061' + '\060' + chr(0b10000 + 0o40) + chr(0b101110 + 0o2), 0b1000), ehT0Px3KOsy9('\060' + chr(1897 - 1786) + '\x32' + chr(0b110000) + '\x30' + chr(0b1101 + 0o43), ord("\x08"))])
xafqLlk3kkUe(IwsgmEzQknPc, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd6\xee\x83q\xc1\x9b\xff\xf3\xd8~$9'), '\x64' + chr(101) + '\x63' + chr(0b1101000 + 0o7) + '\x64' + chr(101))(chr(0b11101 + 0o130) + chr(0b1110100) + '\x66' + '\x2d' + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc7\xe7\x98M\xce\xad\xe0\xf5\xc4|$4'), '\144' + chr(3354 - 3253) + chr(0b10010 + 0o121) + chr(0b101100 + 0o103) + '\144' + '\145')('\x75' + chr(7851 - 7735) + chr(0b1100110) + '\055' + '\x38'), [ehT0Px3KOsy9('\x30' + chr(0b100001 + 0o116) + '\x32' + chr(0b110000) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(0b10100 + 0o34) + chr(111) + chr(1888 - 1836) + chr(48) + chr(2250 - 2202), 8), ehT0Px3KOsy9('\x30' + '\x6f' + chr(49) + chr(0b110000) + chr(0b0 + 0o60) + chr(0b1011 + 0o45), 8)])
xafqLlk3kkUe(IwsgmEzQknPc, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd6\xee\x83q\xc6\x93\xf8\xf5\xcdt"5\x7f\xa9\xa9'), '\x64' + chr(101) + chr(0b1100011) + chr(0b101111 + 0o100) + '\x64' + '\145')(chr(5535 - 5418) + chr(116) + chr(0b1100110) + '\x2d' + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xc1\xee\x94q\xc4\x86\xf8\xf5\xc4o93r\x97\xb1\xda9\xed'), '\x64' + chr(101) + chr(0b1100011) + chr(111) + '\144' + '\x65')(chr(0b1110101) + chr(0b1101001 + 0o13) + chr(0b1100110) + '\x2d' + chr(0b11000 + 0o40)), [xafqLlk3kkUe(oIL3U1EOcJgs.AttentionType, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf7\xce\xbbo\xf1\xbb\xda\xd5\xf5W\x1f\x1f]\x84\x9a\x92\r'), chr(100) + chr(101) + chr(99) + chr(0b1101111) + chr(0b1011100 + 0o10) + '\145')(chr(0b101010 + 0o113) + chr(0b1110100) + chr(0b1100110) + '\x2d' + '\070')), xafqLlk3kkUe(oIL3U1EOcJgs.AttentionType, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe9\xc4\xb4o\xe9\xad\xbd\xd4'), chr(4164 - 4064) + '\145' + chr(0b1100011) + chr(0b1101111) + chr(0b0 + 0o144) + chr(0b1100101))('\165' + '\x74' + '\x66' + '\x2d' + chr(2110 - 2054)))])
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_b12l_4h_b128_h512_uncond_dr01_im
|
def imagetransformer_b12l_4h_b128_h512_uncond_dr01_im():
"""TPU related imagenet model."""
hparams = imagetransformer_b12l_4h_b256_uncond_dr03_tpu()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.optimizer = "Adafactor"
hparams.learning_rate_schedule = "rsqrt_decay"
hparams.learning_rate_warmup_steps = 6000
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
python
|
def imagetransformer_b12l_4h_b128_h512_uncond_dr01_im():
"""TPU related imagenet model."""
hparams = imagetransformer_b12l_4h_b256_uncond_dr03_tpu()
update_hparams_for_tpu(hparams)
hparams.batch_size = 4
hparams.optimizer = "Adafactor"
hparams.learning_rate_schedule = "rsqrt_decay"
hparams.learning_rate_warmup_steps = 6000
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
[
"def",
"imagetransformer_b12l_4h_b128_h512_uncond_dr01_im",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_b12l_4h_b256_uncond_dr03_tpu",
"(",
")",
"update_hparams_for_tpu",
"(",
"hparams",
")",
"hparams",
".",
"batch_size",
"=",
"4",
"hparams",
".",
"optimizer",
"=",
"\"Adafactor\"",
"hparams",
".",
"learning_rate_schedule",
"=",
"\"rsqrt_decay\"",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"6000",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.1",
"return",
"hparams"
] |
TPU related imagenet model.
|
[
"TPU",
"related",
"imagenet",
"model",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L1085-L1094
|
train
|
TPU related imagenet model.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH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,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(396 - 348) + chr(0b111001 + 0o66) + '\x31' + chr(0b11011 + 0o32) + chr(0b110000), 0o10), ehT0Px3KOsy9('\060' + chr(10591 - 10480) + chr(0b100011 + 0o16) + '\062' + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(2251 - 2203) + '\157' + '\062' + chr(0b1001 + 0o51) + '\x33', 0b1000), ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(0b1000101 + 0o52) + chr(0b101101 + 0o5) + '\061' + '\060', 0b1000), ehT0Px3KOsy9('\060' + chr(0b101100 + 0o103) + chr(50) + chr(0b1010 + 0o53) + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(1089 - 1041) + '\x6f' + chr(0b110010) + '\x32' + chr(55), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b10001 + 0o45) + chr(1829 - 1777), 0o10), ehT0Px3KOsy9(chr(0b100011 + 0o15) + chr(11714 - 11603) + '\061' + chr(1718 - 1670) + chr(0b101010 + 0o11), 20557 - 20549), ehT0Px3KOsy9(chr(48) + chr(111) + '\x37' + '\x34', 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(50) + '\x34' + chr(55), 0b1000), ehT0Px3KOsy9(chr(0b11111 + 0o21) + chr(111) + chr(0b110010) + '\061' + chr(0b110111), 4185 - 4177), ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(0b1101111) + '\x32' + chr(52) + chr(513 - 461), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b100011 + 0o17) + chr(48) + '\062', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1001 + 0o146) + chr(0b110001) + chr(0b110100) + chr(0b110111), 0b1000), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(11156 - 11045) + chr(0b1 + 0o60) + chr(1545 - 1492) + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(1001 - 953) + '\x6f' + chr(0b110010) + chr(2422 - 2370) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(552 - 504) + '\x6f' + chr(49) + chr(0b110110) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(9371 - 9260) + chr(0b100010 + 0o20) + '\061' + '\067', 8), ehT0Px3KOsy9(chr(761 - 713) + chr(0b1101111) + chr(0b1011 + 0o50) + chr(0b110001) + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(1383 - 1335) + chr(0b1101111) + '\062' + chr(0b101001 + 0o16) + chr(0b101000 + 0o10), 36622 - 36614), ehT0Px3KOsy9('\x30' + chr(425 - 314) + chr(0b110110) + chr(0b11010 + 0o30), 0b1000), ehT0Px3KOsy9(chr(1047 - 999) + chr(0b11001 + 0o126) + chr(0b110001) + '\066' + '\x35', 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110010) + '\067' + chr(50), 24602 - 24594), ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(0b1101111) + chr(0b110101), 12668 - 12660), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(262 - 213) + '\061' + chr(0b110010), 17631 - 17623), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(1191 - 1140) + chr(0b110001) + chr(48), 0b1000), ehT0Px3KOsy9(chr(0b101000 + 0o10) + chr(0b1101111) + '\063' + chr(49) + chr(0b11 + 0o61), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(2020 - 1966) + '\060', 0b1000), ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(10747 - 10636) + '\061' + '\066' + chr(52), 0b1000), ehT0Px3KOsy9('\060' + chr(10689 - 10578) + '\x31' + chr(0b110111) + chr(879 - 824), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b10001 + 0o136) + chr(0b100 + 0o56) + '\067' + '\065', 0b1000), ehT0Px3KOsy9(chr(130 - 82) + chr(5277 - 5166) + chr(0b1101 + 0o46) + chr(53) + '\060', 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(129 - 79) + chr(55 - 2) + '\x33', 62469 - 62461), ehT0Px3KOsy9(chr(0b110000) + chr(6968 - 6857) + '\061' + chr(2644 - 2592) + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(0b10001 + 0o37) + chr(0b1001001 + 0o46) + chr(0b1 + 0o62) + '\x33' + '\066', 0o10), ehT0Px3KOsy9('\060' + '\x6f' + '\061' + chr(0b110001) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(1665 - 1617) + '\157' + chr(0b10011 + 0o37) + chr(1240 - 1191) + chr(0b11011 + 0o31), 21230 - 21222), ehT0Px3KOsy9(chr(710 - 662) + chr(5772 - 5661) + '\061' + chr(0b110111) + chr(0b110011), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1011111 + 0o20) + '\066' + chr(0b0 + 0o64), 8), ehT0Px3KOsy9('\x30' + chr(111) + chr(2385 - 2331), 16550 - 16542)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\065' + chr(0b110000 + 0o0), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'F'), chr(4127 - 4027) + chr(101) + '\x63' + chr(5122 - 5011) + '\144' + '\x65')('\165' + chr(0b1111 + 0o145) + '\146' + chr(1339 - 1294) + chr(2125 - 2069)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def isog7q9YYQEp():
n4ljua2gi1Pr = DhhdvXHepfHn()
gWr33mh0VbqT(n4ljua2gi1Pr)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\x30' + chr(0b1010011 + 0o34) + '\x34', 0b1000)
n4ljua2gi1Pr.XdKNcYRObPK3 = xafqLlk3kkUe(SXOLrMavuUCe(b')2\xf2\xee\xcf\xf4@,N'), chr(5590 - 5490) + chr(101) + '\x63' + '\157' + chr(100) + chr(2800 - 2699))('\x75' + chr(0b1111 + 0o145) + chr(0b1100110) + '\x2d' + chr(56))
n4ljua2gi1Pr.Lz_s7neUzM5V = xafqLlk3kkUe(SXOLrMavuUCe(b'\x1a%\xe2\xfa\xda\xc8P&_\xc6\xf6'), chr(296 - 196) + chr(0b1100101) + chr(0b1100011) + chr(4134 - 4023) + chr(2735 - 2635) + chr(101))(chr(0b1100001 + 0o24) + chr(0b1110100) + chr(102) + '\055' + chr(0b111000 + 0o0))
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110001) + '\063' + '\065' + chr(54) + chr(0b110000), 0o10)
n4ljua2gi1Pr.RW_xSzp18UeS = 0.1
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_b12l_4h_uncond_dr03_tpu
|
def imagetransformer_b12l_4h_uncond_dr03_tpu():
"""TPU related small model."""
hparams = imagetransformer_b12l_4h_b256_uncond_dr03_tpu()
hparams.learning_rate = 0.2
hparams.learning_rate_warmup_steps = 4000
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.3
return hparams
|
python
|
def imagetransformer_b12l_4h_uncond_dr03_tpu():
"""TPU related small model."""
hparams = imagetransformer_b12l_4h_b256_uncond_dr03_tpu()
hparams.learning_rate = 0.2
hparams.learning_rate_warmup_steps = 4000
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.3
return hparams
|
[
"def",
"imagetransformer_b12l_4h_uncond_dr03_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_b12l_4h_b256_uncond_dr03_tpu",
"(",
")",
"hparams",
".",
"learning_rate",
"=",
"0.2",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"4000",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.3",
"return",
"hparams"
] |
TPU related small model.
|
[
"TPU",
"related",
"small",
"model",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L1098-L1106
|
train
|
TPU related small model.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N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A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(473 - 425) + '\157' + '\062' + '\066' + '\066', 32231 - 32223), ehT0Px3KOsy9(chr(0b101000 + 0o10) + chr(10518 - 10407) + '\065' + '\x37', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b1010 + 0o50) + chr(0b110010) + '\060', 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110001) + chr(0b1 + 0o57) + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(2162 - 2114) + chr(111) + '\x37' + chr(229 - 179), ord("\x08")), ehT0Px3KOsy9(chr(0b10111 + 0o31) + '\157' + chr(0b110001) + chr(2495 - 2441) + chr(0b110101), 17188 - 17180), ehT0Px3KOsy9(chr(1488 - 1440) + chr(0b1010010 + 0o35) + chr(51) + chr(0b11010 + 0o27) + '\066', 0b1000), ehT0Px3KOsy9(chr(0b110000 + 0o0) + '\157' + chr(55) + '\066', ord("\x08")), ehT0Px3KOsy9(chr(0b11011 + 0o25) + chr(6488 - 6377) + chr(50) + chr(1858 - 1805) + chr(0b100101 + 0o21), 40144 - 40136), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b100101 + 0o15) + chr(1289 - 1239) + chr(0b110000), 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b10110 + 0o131) + chr(51) + chr(0b101100 + 0o13) + chr(0b110110), 0o10), ehT0Px3KOsy9('\060' + '\157' + chr(51) + '\x30' + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(0b1101111) + '\061' + chr(118 - 70) + chr(0b110000), 0b1000), ehT0Px3KOsy9(chr(582 - 534) + chr(111) + '\061' + '\x37', 30787 - 30779), ehT0Px3KOsy9('\060' + chr(3753 - 3642) + chr(0b10011 + 0o36) + '\066' + chr(0b110100), 21945 - 21937), ehT0Px3KOsy9(chr(48) + '\x6f' + '\065' + '\060', 32664 - 32656), ehT0Px3KOsy9(chr(0b110000) + chr(5895 - 5784) + '\062' + chr(0b110111) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(50) + '\060' + '\x33', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\061' + chr(49) + '\x30', 0b1000), ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(111) + chr(0b110001), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(0b10 + 0o57) + chr(49), 0o10), ehT0Px3KOsy9(chr(1009 - 961) + chr(111) + '\063' + chr(0b110001) + chr(0b110101), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b10 + 0o60) + chr(0b110001) + chr(1973 - 1925), ord("\x08")), ehT0Px3KOsy9(chr(0b11010 + 0o26) + chr(3983 - 3872) + '\x32' + chr(2125 - 2073) + chr(290 - 236), ord("\x08")), ehT0Px3KOsy9('\060' + chr(789 - 678) + chr(0b110010 + 0o0) + '\x35' + '\063', 0o10), ehT0Px3KOsy9('\060' + chr(0b11100 + 0o123) + chr(1463 - 1414) + chr(51) + '\063', 34754 - 34746), ehT0Px3KOsy9(chr(0b110000) + chr(0b1011010 + 0o25) + chr(334 - 283) + '\x30' + chr(48), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b1110 + 0o44), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(1133 - 1083) + chr(0b110010) + chr(1572 - 1517), 24736 - 24728), ehT0Px3KOsy9(chr(1395 - 1347) + chr(0b1101111) + '\x33' + '\x30' + chr(55), 56070 - 56062), ehT0Px3KOsy9(chr(400 - 352) + chr(4943 - 4832) + '\061' + chr(0b110011) + chr(0b100 + 0o57), 8), ehT0Px3KOsy9('\060' + '\157' + '\061' + chr(48) + chr(53), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + '\x32' + chr(52) + chr(1106 - 1055), 29329 - 29321), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x31' + '\x33' + chr(0b110011), 8), ehT0Px3KOsy9(chr(767 - 719) + chr(0b1101111) + chr(618 - 564), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110100 + 0o2) + '\067', 48834 - 48826), ehT0Px3KOsy9('\060' + chr(111) + '\x33' + '\x36', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1000110 + 0o51) + chr(1927 - 1878) + chr(51) + chr(0b1011 + 0o52), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\061' + '\064', 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110010) + '\x35' + chr(0b110001), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(1647 - 1599) + chr(0b10000 + 0o137) + chr(0b110101) + chr(48), 8)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x98'), chr(0b1100100) + chr(0b10101 + 0o120) + '\x63' + chr(0b110000 + 0o77) + chr(5098 - 4998) + chr(0b1100101))('\165' + chr(116) + chr(0b1100110) + chr(1854 - 1809) + chr(0b10100 + 0o44)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def flsEMcMcLqqd():
n4ljua2gi1Pr = DhhdvXHepfHn()
n4ljua2gi1Pr.QGSIpd_yUNzU = 0.2
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(2388 - 2333) + chr(0b110110) + chr(52) + '\060', ord("\x08"))
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b"\xd8@\xfe'"), '\x64' + '\x65' + chr(0b111001 + 0o52) + chr(111) + '\x64' + chr(0b1100101))(chr(0b1110101) + chr(2395 - 2279) + chr(0b1010000 + 0o26) + '\055' + '\070')
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'\xd2N\xfe'), chr(3637 - 3537) + '\x65' + chr(0b11111 + 0o104) + chr(8400 - 8289) + '\x64' + chr(0b1100101))(chr(11999 - 11882) + chr(0b1100111 + 0o15) + chr(102) + chr(1145 - 1100) + chr(56))
n4ljua2gi1Pr.RW_xSzp18UeS = 0.3
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_b12l_4h_b128_uncond_dr03_tpu
|
def imagetransformer_b12l_4h_b128_uncond_dr03_tpu():
"""TPU config for cifar 10."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 2
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 12
hparams.block_length = 128
hparams.hidden_size = 256
hparams.filter_size = 2048
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.1
hparams.optimizer = "Adafactor"
hparams.learning_rate_schedule = "rsqrt_decay"
hparams.learning_rate_warmup_steps = 10000
return hparams
|
python
|
def imagetransformer_b12l_4h_b128_uncond_dr03_tpu():
"""TPU config for cifar 10."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 2
hparams.num_heads = 4 # heads are expensive on tpu
hparams.num_decoder_layers = 12
hparams.block_length = 128
hparams.hidden_size = 256
hparams.filter_size = 2048
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.1
hparams.optimizer = "Adafactor"
hparams.learning_rate_schedule = "rsqrt_decay"
hparams.learning_rate_warmup_steps = 10000
return hparams
|
[
"def",
"imagetransformer_b12l_4h_b128_uncond_dr03_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_bas8l_8h_big_uncond_dr03_imgnet",
"(",
")",
"update_hparams_for_tpu",
"(",
"hparams",
")",
"hparams",
".",
"batch_size",
"=",
"2",
"hparams",
".",
"num_heads",
"=",
"4",
"# heads are expensive on tpu",
"hparams",
".",
"num_decoder_layers",
"=",
"12",
"hparams",
".",
"block_length",
"=",
"128",
"hparams",
".",
"hidden_size",
"=",
"256",
"hparams",
".",
"filter_size",
"=",
"2048",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.1",
"hparams",
".",
"optimizer",
"=",
"\"Adafactor\"",
"hparams",
".",
"learning_rate_schedule",
"=",
"\"rsqrt_decay\"",
"hparams",
".",
"learning_rate_warmup_steps",
"=",
"10000",
"return",
"hparams"
] |
TPU config for cifar 10.
|
[
"TPU",
"config",
"for",
"cifar",
"10",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L1110-L1126
|
train
|
TPU config for cifar 10.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvb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nectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(83 - 35) + '\x6f' + chr(0b110010) + chr(499 - 447) + '\065', 52081 - 52073), ehT0Px3KOsy9(chr(0b1000 + 0o50) + chr(0b101001 + 0o106) + chr(0b110001) + chr(49) + chr(53), 62095 - 62087), ehT0Px3KOsy9('\060' + chr(0b1011101 + 0o22) + '\x32' + chr(0b10010 + 0o44) + chr(0b10010 + 0o43), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(51) + chr(1963 - 1909), 0o10), ehT0Px3KOsy9(chr(1121 - 1073) + '\x6f' + '\061' + '\x32' + chr(0b110111), 44451 - 44443), ehT0Px3KOsy9(chr(48) + chr(2236 - 2125) + chr(0b110010) + '\x34' + '\x33', 4358 - 4350), ehT0Px3KOsy9(chr(0b110000) + chr(9837 - 9726) + chr(50) + chr(0b101100 + 0o5) + chr(51), 5349 - 5341), ehT0Px3KOsy9('\060' + chr(552 - 441) + chr(49) + chr(54) + '\x30', 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110010) + chr(0b110100) + chr(52), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b1111 + 0o44) + chr(2383 - 2333) + '\067', 21365 - 21357), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(2050 - 1999) + chr(0b110101) + chr(48), 42055 - 42047), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110001) + chr(1619 - 1571) + chr(0b110110), 46888 - 46880), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x32' + chr(0b110010) + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(1867 - 1756) + chr(50) + chr(0b101 + 0o57) + chr(0b110010), 35304 - 35296), ehT0Px3KOsy9(chr(48) + chr(1827 - 1716) + '\062' + chr(0b1111 + 0o50) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(934 - 823) + '\061' + '\x37' + '\064', 64348 - 64340), ehT0Px3KOsy9('\x30' + chr(111) + '\061' + chr(55) + chr(0b100010 + 0o22), 8), ehT0Px3KOsy9(chr(0b100100 + 0o14) + chr(0b1101111) + chr(0b110100) + '\066', 0o10), ehT0Px3KOsy9(chr(491 - 443) + chr(0b1000 + 0o147) + chr(0b11001 + 0o32) + '\065' + chr(2228 - 2178), ord("\x08")), ehT0Px3KOsy9(chr(0b110 + 0o52) + '\x6f' + '\063' + chr(285 - 236) + chr(0b110110), 32762 - 32754), ehT0Px3KOsy9(chr(0b111 + 0o51) + chr(111) + chr(53) + chr(55), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + '\x32' + '\063' + chr(0b110100), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\x31' + chr(0b110011) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(3122 - 3011) + chr(0b110111) + '\064', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x33' + chr(51) + '\064', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110 + 0o54) + chr(0b110010) + chr(0b110001), 18173 - 18165), ehT0Px3KOsy9(chr(48) + chr(8309 - 8198) + chr(2441 - 2391) + chr(1082 - 1034) + '\x33', 0b1000), ehT0Px3KOsy9(chr(0b101010 + 0o6) + chr(111) + chr(50) + chr(1350 - 1299) + '\x31', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\064' + '\x34', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + '\x33' + '\067' + '\061', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x32' + chr(0b110111) + chr(897 - 848), 30544 - 30536), ehT0Px3KOsy9(chr(450 - 402) + '\x6f' + chr(49) + chr(0b101001 + 0o15) + chr(48), 8), ehT0Px3KOsy9(chr(0b10011 + 0o35) + '\157' + chr(2115 - 2066) + chr(0b1110 + 0o46) + chr(0b11010 + 0o27), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(7111 - 7000) + '\x37' + chr(52), 8), ehT0Px3KOsy9('\060' + chr(111) + chr(0b101001 + 0o10) + chr(1129 - 1081) + chr(1383 - 1335), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b10111 + 0o34) + chr(54) + '\x36', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b11101 + 0o122) + '\061' + chr(0b110011) + chr(0b110110), 52949 - 52941), ehT0Px3KOsy9('\060' + '\x6f' + '\x32' + chr(1306 - 1257) + chr(1965 - 1912), 0b1000), ehT0Px3KOsy9(chr(1486 - 1438) + chr(119 - 8) + '\x36' + chr(0b101000 + 0o11), 54332 - 54324), ehT0Px3KOsy9('\060' + chr(111) + chr(51) + chr(0b110111) + '\x31', 8)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(1188 - 1135) + chr(48), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x8b'), '\144' + chr(0b1100101) + chr(3778 - 3679) + chr(0b1101111) + '\x64' + chr(0b11010 + 0o113))('\x75' + '\164' + '\146' + chr(0b101101) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def g3rW9IxXBeQG():
n4ljua2gi1Pr = pgkv8qf4pDLc()
gWr33mh0VbqT(n4ljua2gi1Pr)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\x30' + chr(111) + chr(1797 - 1747), ord("\x08"))
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(48) + chr(4006 - 3895) + chr(0b100110 + 0o16), 0b1000)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(0b111 + 0o51) + '\x6f' + '\x31' + '\x34', 54974 - 54966)
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9('\060' + '\157' + chr(0b10011 + 0o37) + chr(0b1111 + 0o41) + chr(0b101010 + 0o6), 11319 - 11311)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(4787 - 4676) + chr(2453 - 2401) + chr(723 - 675) + chr(48), 40369 - 40361)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(0b1101111) + '\x34' + chr(2265 - 2217) + '\060' + chr(48), 0b1000)
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'\xcb"\xdb{'), chr(100) + chr(0b1100101) + '\143' + chr(0b100010 + 0o115) + '\x64' + '\145')('\x75' + '\x74' + '\146' + chr(0b101101) + chr(0b111000))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'\xc1,\xdb'), chr(100) + chr(6541 - 6440) + chr(0b1100011) + chr(0b1101111) + chr(4562 - 4462) + chr(0b1000100 + 0o41))(chr(9199 - 9082) + '\x74' + chr(102) + chr(662 - 617) + chr(0b111000))
n4ljua2gi1Pr.RW_xSzp18UeS = 0.1
n4ljua2gi1Pr.XdKNcYRObPK3 = xafqLlk3kkUe(SXOLrMavuUCe(b'\xe4)\xd4x6\xc0\xff\x1f\xd6'), chr(0b1100100) + chr(0b1100101) + chr(99) + chr(0b1100001 + 0o16) + '\x64' + '\x65')(chr(117) + chr(0b1110100) + chr(102) + '\x2d' + chr(0b111000))
n4ljua2gi1Pr.Lz_s7neUzM5V = xafqLlk3kkUe(SXOLrMavuUCe(b'\xd7>\xc4l#\xfc\xef\x15\xc7\xb6\x91'), '\144' + chr(0b111101 + 0o50) + chr(0b110000 + 0o63) + chr(2749 - 2638) + '\144' + '\x65')(chr(0b11001 + 0o134) + chr(0b1111 + 0o145) + chr(102) + '\x2d' + chr(56))
n4ljua2gi1Pr.fHyhoyGmdvM9 = ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110010) + chr(1736 - 1685) + chr(0b110100) + '\062' + '\060', 0b1000)
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_b12l_8h_b256_uncond_dr03_tpu
|
def imagetransformer_b12l_8h_b256_uncond_dr03_tpu():
"""TPU related 12 layer 8 heads model."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 2
hparams.num_heads = 8 # heads are expensive on tpu
hparams.num_decoder_layers = 12
hparams.block_length = 256
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.3
return hparams
|
python
|
def imagetransformer_b12l_8h_b256_uncond_dr03_tpu():
"""TPU related 12 layer 8 heads model."""
hparams = imagetransformer_bas8l_8h_big_uncond_dr03_imgnet()
update_hparams_for_tpu(hparams)
hparams.batch_size = 2
hparams.num_heads = 8 # heads are expensive on tpu
hparams.num_decoder_layers = 12
hparams.block_length = 256
hparams.hidden_size = 512
hparams.filter_size = 2048
hparams.layer_preprocess_sequence = "none"
hparams.layer_postprocess_sequence = "dan"
hparams.layer_prepostprocess_dropout = 0.3
return hparams
|
[
"def",
"imagetransformer_b12l_8h_b256_uncond_dr03_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_bas8l_8h_big_uncond_dr03_imgnet",
"(",
")",
"update_hparams_for_tpu",
"(",
"hparams",
")",
"hparams",
".",
"batch_size",
"=",
"2",
"hparams",
".",
"num_heads",
"=",
"8",
"# heads are expensive on tpu",
"hparams",
".",
"num_decoder_layers",
"=",
"12",
"hparams",
".",
"block_length",
"=",
"256",
"hparams",
".",
"hidden_size",
"=",
"512",
"hparams",
".",
"filter_size",
"=",
"2048",
"hparams",
".",
"layer_preprocess_sequence",
"=",
"\"none\"",
"hparams",
".",
"layer_postprocess_sequence",
"=",
"\"dan\"",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.3",
"return",
"hparams"
] |
TPU related 12 layer 8 heads model.
|
[
"TPU",
"related",
"12",
"layer",
"8",
"heads",
"model",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/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RS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b10 + 0o61) + chr(49) + chr(54), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b101011 + 0o6) + chr(0b110011) + chr(52), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x32' + chr(0b110111) + chr(54), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + '\064' + chr(49), 0b1000), ehT0Px3KOsy9(chr(48) + chr(11757 - 11646) + chr(56 - 4) + '\x36', 0o10), ehT0Px3KOsy9(chr(48) + chr(4589 - 4478) + chr(540 - 489) + chr(53) + chr(1053 - 1000), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + '\062' + '\x34' + chr(0b110010), 35964 - 35956), ehT0Px3KOsy9(chr(1557 - 1509) + '\x6f' + chr(0b110110) + chr(52), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(1759 - 1710) + chr(55), 50547 - 50539), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(2184 - 2133) + chr(49) + chr(52), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\062' + '\067' + '\061', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b101110 + 0o5) + chr(1813 - 1765) + chr(0b110011), 471 - 463), ehT0Px3KOsy9('\x30' + chr(0b1010111 + 0o30) + chr(49) + chr(447 - 399) + chr(52), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b10 + 0o56), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(1734 - 1623) + chr(1678 - 1628) + chr(0b110000) + chr(1660 - 1606), ord("\x08")), ehT0Px3KOsy9(chr(0b10101 + 0o33) + '\157' + chr(931 - 876) + chr(2488 - 2433), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\x31' + chr(53) + chr(2075 - 2026), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(9433 - 9322) + '\x33' + '\064' + chr(0b100110 + 0o13), 9868 - 9860), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110110) + '\x37', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(853 - 802) + chr(1876 - 1825) + chr(0b110011), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1010111 + 0o30) + chr(2358 - 2307) + chr(49) + chr(52), 8), ehT0Px3KOsy9(chr(654 - 606) + chr(0b1100101 + 0o12) + chr(51) + '\061' + chr(1889 - 1837), 8), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110001) + '\067' + chr(0b100 + 0o63), 0b1000), ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(111) + '\x33' + '\066', ord("\x08")), ehT0Px3KOsy9(chr(990 - 942) + chr(0b1101111) + '\x34', 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110001) + '\061' + '\x32', 0o10), ehT0Px3KOsy9(chr(571 - 523) + chr(2283 - 2172) + chr(1929 - 1880) + chr(860 - 809) + chr(2086 - 2037), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110010) + chr(51) + chr(50), 0o10), ehT0Px3KOsy9(chr(48) + chr(2573 - 2462) + chr(1836 - 1785) + '\x30' + chr(51), 8), ehT0Px3KOsy9(chr(48) + '\x6f' + '\x32' + chr(51) + '\060', 34054 - 34046), ehT0Px3KOsy9(chr(0b11111 + 0o21) + chr(0b110001 + 0o76) + '\x37' + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(0b0 + 0o60) + '\157' + chr(375 - 325) + chr(1470 - 1419) + chr(0b110111), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b101100 + 0o6) + '\x31' + '\067', 0o10), ehT0Px3KOsy9(chr(0b101000 + 0o10) + '\x6f' + '\064' + '\063', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\x31' + chr(1067 - 1014) + '\x31', 8), ehT0Px3KOsy9(chr(0b110000) + chr(1064 - 953) + '\063' + chr(0b100000 + 0o25) + '\065', 8), ehT0Px3KOsy9(chr(0b110000) + chr(1742 - 1631) + '\061' + chr(0b101001 + 0o13) + chr(0b100001 + 0o20), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x32' + '\065' + chr(1679 - 1628), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b101100 + 0o7) + chr(0b100111 + 0o14) + '\x35', 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(51) + chr(0b110110) + chr(54), 40189 - 40181)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b11000 + 0o30) + chr(3070 - 2959) + '\x35' + chr(0b110000), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xe0'), chr(3276 - 3176) + chr(1416 - 1315) + '\143' + chr(111) + chr(1412 - 1312) + '\145')(chr(0b111001 + 0o74) + '\x74' + chr(0b100011 + 0o103) + chr(0b1100 + 0o41) + chr(1073 - 1017)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def w3Pg8Lz4ZfHl():
n4ljua2gi1Pr = pgkv8qf4pDLc()
gWr33mh0VbqT(n4ljua2gi1Pr)
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b1110 + 0o44), 0b1000)
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9('\060' + '\157' + '\061' + chr(0b11 + 0o55), 0b1000)
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9('\x30' + '\157' + chr(379 - 330) + chr(0b100110 + 0o16), ord("\x08"))
n4ljua2gi1Pr.MMwtQ0bPonxt = ehT0Px3KOsy9('\x30' + chr(3829 - 3718) + '\x34' + chr(1654 - 1606) + chr(48), 0o10)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(306 - 258) + chr(0b11110 + 0o121) + chr(49) + chr(0b110000) + chr(1050 - 1002) + chr(0b110000), 0b1000)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(0b110000) + chr(11044 - 10933) + '\x34' + chr(48) + chr(0b101101 + 0o3) + '\x30', ord("\x08"))
n4ljua2gi1Pr.WjY1aZ7lwLOu = xafqLlk3kkUe(SXOLrMavuUCe(b'\xa03\xd0D'), chr(1871 - 1771) + chr(7010 - 6909) + chr(0b1100011) + '\x6f' + chr(4105 - 4005) + '\x65')('\x75' + chr(11794 - 11678) + chr(4675 - 4573) + '\055' + chr(881 - 825))
n4ljua2gi1Pr.s6T_PoakASTI = xafqLlk3kkUe(SXOLrMavuUCe(b'\xaa=\xd0'), '\144' + chr(1564 - 1463) + chr(0b1000 + 0o133) + chr(9531 - 9420) + '\x64' + chr(101))(chr(117) + chr(9136 - 9020) + chr(0b1100110) + chr(0b101101) + chr(56))
n4ljua2gi1Pr.RW_xSzp18UeS = 0.3
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/models/image_transformer.py
|
imagetransformer_b10l_4h_big_uncond_dr01_tpu
|
def imagetransformer_b10l_4h_big_uncond_dr01_tpu():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_b12l_4h_big_uncond_dr03_tpu()
# num_hidden_layers
hparams.num_decoder_layers = 10
hparams.num_heads = 4
hparams.hidden_size = 1024
hparams.filter_size = 4096
hparams.batch_size = 1
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
python
|
def imagetransformer_b10l_4h_big_uncond_dr01_tpu():
"""big 1d model for conditional image generation."""
hparams = imagetransformer_b12l_4h_big_uncond_dr03_tpu()
# num_hidden_layers
hparams.num_decoder_layers = 10
hparams.num_heads = 4
hparams.hidden_size = 1024
hparams.filter_size = 4096
hparams.batch_size = 1
hparams.layer_prepostprocess_dropout = 0.1
return hparams
|
[
"def",
"imagetransformer_b10l_4h_big_uncond_dr01_tpu",
"(",
")",
":",
"hparams",
"=",
"imagetransformer_b12l_4h_big_uncond_dr03_tpu",
"(",
")",
"# num_hidden_layers",
"hparams",
".",
"num_decoder_layers",
"=",
"10",
"hparams",
".",
"num_heads",
"=",
"4",
"hparams",
".",
"hidden_size",
"=",
"1024",
"hparams",
".",
"filter_size",
"=",
"4096",
"hparams",
".",
"batch_size",
"=",
"1",
"hparams",
".",
"layer_prepostprocess_dropout",
"=",
"0.1",
"return",
"hparams"
] |
big 1d model for conditional image generation.
|
[
"big",
"1d",
"model",
"for",
"conditional",
"image",
"generation",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/image_transformer.py#L1147-L1157
|
train
|
big 1d model for conditional image generation.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0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kKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(51) + chr(0b100011 + 0o20) + chr(0b100011 + 0o16), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b11001 + 0o126) + chr(612 - 563) + '\060' + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b10111 + 0o130) + chr(0b1 + 0o61) + chr(0b100111 + 0o15) + chr(53), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(50) + '\061' + chr(0b10000 + 0o43), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(49) + '\x31', 32757 - 32749), ehT0Px3KOsy9('\060' + chr(0b1001011 + 0o44) + chr(0b1101 + 0o46) + '\064' + '\066', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x32' + '\x31' + chr(0b110100), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110000 + 0o1) + '\066' + '\063', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b111010 + 0o65) + '\066' + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(2029 - 1981) + chr(0b1101111) + chr(51) + chr(0b110011) + chr(0b110001), 8), ehT0Px3KOsy9(chr(48) + chr(0b100111 + 0o110) + '\061' + '\x36' + chr(0b110100), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110011) + '\x36' + chr(0b110000), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + '\x31' + chr(0b100011 + 0o15) + chr(0b110101), 50737 - 50729), ehT0Px3KOsy9(chr(0b110000) + chr(2418 - 2307) + '\063' + '\x36' + '\061', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\061' + '\065' + chr(0b110000), 5154 - 5146), ehT0Px3KOsy9(chr(0b110000) + chr(0b1000011 + 0o54) + '\062' + chr(0b110111) + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(1825 - 1777) + '\x6f' + '\061' + chr(50) + chr(0b110011), 935 - 927), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110010) + chr(49) + chr(0b110000 + 0o6), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(5563 - 5452) + chr(51) + chr(1735 - 1680) + '\x32', 20886 - 20878), ehT0Px3KOsy9(chr(0b110000) + chr(0b1100110 + 0o11) + chr(0b10 + 0o62) + '\060', 0o10), ehT0Px3KOsy9(chr(1998 - 1950) + chr(111) + chr(193 - 142) + '\064' + chr(0b110011), 714 - 706), ehT0Px3KOsy9('\060' + '\157' + chr(0b1000 + 0o57) + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(51) + '\x37' + chr(497 - 445), 7776 - 7768), ehT0Px3KOsy9('\060' + '\157' + '\x31' + chr(0b100011 + 0o24) + '\061', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(49) + chr(55) + chr(0b110010), 0o10), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(111) + '\x33' + '\067', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1100011 + 0o14) + '\x34' + chr(54), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b101001 + 0o15) + chr(0b10 + 0o57), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(49) + chr(0b101010 + 0o6) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x35' + chr(50), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(49) + chr(0b110001) + '\061', 0b1000), ehT0Px3KOsy9(chr(561 - 513) + chr(111) + chr(51) + '\x31' + '\067', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(151 - 101) + chr(0b110110) + chr(54), 0b1000), ehT0Px3KOsy9('\060' + '\157' + '\063' + '\x37' + chr(0b110101), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b110011) + chr(2299 - 2248), 53067 - 53059), ehT0Px3KOsy9('\x30' + '\x6f' + chr(391 - 341) + '\x31' + chr(0b110111), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1100011 + 0o14) + chr(883 - 834) + '\x36' + chr(0b110000), 38427 - 38419), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(1335 - 1284) + chr(48), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x31' + chr(55) + chr(48), 11341 - 11333), ehT0Px3KOsy9(chr(48) + chr(111) + chr(53) + '\065', 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b0 + 0o60) + chr(0b1101111) + chr(0b11001 + 0o34) + chr(2211 - 2163), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xf7'), '\144' + chr(0b1100011 + 0o2) + '\x63' + chr(0b111000 + 0o67) + chr(0b1011110 + 0o6) + chr(0b111011 + 0o52))('\165' + chr(116) + chr(7766 - 7664) + chr(1963 - 1918) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def V3vQIhvJQYkB():
n4ljua2gi1Pr = cvyTh_M3A6eu()
n4ljua2gi1Pr.pRi6YFAYEnH4 = ehT0Px3KOsy9(chr(0b10011 + 0o35) + '\157' + chr(0b110001) + chr(0b110010), 0o10)
n4ljua2gi1Pr.vRVqPOZ1hUG7 = ehT0Px3KOsy9(chr(48) + chr(2833 - 2722) + chr(52), ord("\x08"))
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(355 - 305) + '\x30' + chr(2072 - 2024) + chr(0b110000), 0o10)
n4ljua2gi1Pr.deybX8NJ0oEI = ehT0Px3KOsy9(chr(360 - 312) + chr(0b1101111) + chr(0b101011 + 0o6) + chr(0b110000) + chr(48) + '\x30' + chr(1479 - 1431), ord("\x08"))
n4ljua2gi1Pr.ix9dZyeAmUxY = ehT0Px3KOsy9(chr(0b110000) + '\157' + '\061', 0o10)
n4ljua2gi1Pr.RW_xSzp18UeS = 0.1
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/rl/restarter.py
|
Restarter.training_loop
|
def training_loop(self):
"""Context manager wrapping the training loop, updates step counters."""
if not self.restarting:
self._write_counters(self._local_step_at_start, self._global_step)
tf.logging.info(
"Training %s up to %d, %d to go", self.model_mode,
self.target_local_step, self.steps_to_go
)
yield
self._write_counters(self.target_local_step, -1)
|
python
|
def training_loop(self):
"""Context manager wrapping the training loop, updates step counters."""
if not self.restarting:
self._write_counters(self._local_step_at_start, self._global_step)
tf.logging.info(
"Training %s up to %d, %d to go", self.model_mode,
self.target_local_step, self.steps_to_go
)
yield
self._write_counters(self.target_local_step, -1)
|
[
"def",
"training_loop",
"(",
"self",
")",
":",
"if",
"not",
"self",
".",
"restarting",
":",
"self",
".",
"_write_counters",
"(",
"self",
".",
"_local_step_at_start",
",",
"self",
".",
"_global_step",
")",
"tf",
".",
"logging",
".",
"info",
"(",
"\"Training %s up to %d, %d to go\"",
",",
"self",
".",
"model_mode",
",",
"self",
".",
"target_local_step",
",",
"self",
".",
"steps_to_go",
")",
"yield",
"self",
".",
"_write_counters",
"(",
"self",
".",
"target_local_step",
",",
"-",
"1",
")"
] |
Context manager wrapping the training loop, updates step counters.
|
[
"Context",
"manager",
"wrapping",
"the",
"training",
"loop",
"updates",
"step",
"counters",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/rl/restarter.py#L90-L102
|
train
|
Context manager wrapping the training loop.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNBHlx,ZsDPvpP4xdo3,cW7yQuyEnJ6E,KOHQGQ8qLDWm,NE1Yam2HHroQ,ygAzbDzrvRMh,SBRjvOU1ufVC,hO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OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110110) + chr(0b110100), 0o10), ehT0Px3KOsy9('\060' + chr(0b1100101 + 0o12) + chr(0b110110) + chr(1116 - 1061), 0b1000), ehT0Px3KOsy9('\060' + chr(11323 - 11212) + chr(0b100111 + 0o13) + chr(51) + chr(93 - 44), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b100010 + 0o115) + chr(51) + chr(0b110010) + '\x32', 0o10), ehT0Px3KOsy9(chr(1170 - 1122) + chr(0b1101111) + chr(0b1000 + 0o52) + chr(0b110110) + '\062', 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(49) + chr(0b110101) + chr(0b1111 + 0o46), 34361 - 34353), ehT0Px3KOsy9(chr(0b1011 + 0o45) + chr(0b1101111) + chr(0b110001) + chr(0b11100 + 0o26) + chr(0b110010), 32940 - 32932), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b1010 + 0o50) + chr(0b101100 + 0o12) + chr(50), 8), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110010) + chr(0b110100) + '\x31', 24168 - 24160), ehT0Px3KOsy9(chr(0b1100 + 0o44) + '\x6f' + chr(1282 - 1232) + chr(0b110111) + chr(0b110000), 12616 - 12608), ehT0Px3KOsy9(chr(0b110000) + chr(0b101010 + 0o105) + chr(0b11010 + 0o31) + chr(52) + chr(1551 - 1502), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(50) + '\062' + chr(0b1010 + 0o47), 39143 - 39135), ehT0Px3KOsy9(chr(48) + chr(111) + '\061' + '\x33' + '\x32', ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + '\062' + chr(922 - 871) + '\063', 13055 - 13047), ehT0Px3KOsy9(chr(736 - 688) + chr(0b1101111) + chr(0b110011) + chr(0b10011 + 0o42) + chr(0b110011), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110001) + chr(0b1 + 0o65) + '\066', 0o10), ehT0Px3KOsy9('\060' + chr(10508 - 10397) + '\061' + chr(2009 - 1959) + chr(0b100001 + 0o20), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b10000 + 0o137) + chr(51) + chr(0b11110 + 0o26) + '\061', 8), ehT0Px3KOsy9('\060' + chr(5303 - 5192) + chr(0b101011 + 0o10) + chr(52) + '\x34', 0o10), ehT0Px3KOsy9('\x30' + chr(9441 - 9330) + chr(0b110001) + '\x33' + chr(0b1110 + 0o45), 0o10), ehT0Px3KOsy9('\x30' + chr(11600 - 11489) + chr(2310 - 2260) + chr(0b1 + 0o57), 0o10), ehT0Px3KOsy9(chr(2005 - 1957) + chr(0b1101111) + '\063' + '\x33', ord("\x08")), ehT0Px3KOsy9(chr(375 - 327) + chr(111) + chr(1422 - 1371) + '\064' + '\065', 0o10), ehT0Px3KOsy9('\x30' + chr(111) + '\063' + '\x30' + '\x33', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110001) + '\063' + chr(0b10011 + 0o42), 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2266 - 2214) + chr(0b1010 + 0o46), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + '\063' + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(657 - 609) + chr(8903 - 8792) + '\064' + chr(530 - 480), 29971 - 29963), ehT0Px3KOsy9(chr(0b100001 + 0o17) + chr(3529 - 3418) + chr(50) + chr(0b11100 + 0o30) + chr(2283 - 2232), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + '\x32' + chr(0b101101 + 0o5) + chr(2283 - 2232), ord("\x08")), ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(0b1101000 + 0o7) + chr(50) + chr(52) + '\x35', 0b1000), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(0b11 + 0o154) + '\061' + chr(0b110000) + chr(52), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(1290 - 1241) + chr(50) + chr(2751 - 2697), 0b1000), ehT0Px3KOsy9(chr(1146 - 1098) + '\x6f' + chr(51) + chr(2495 - 2443), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b11011 + 0o33) + '\064', 8), ehT0Px3KOsy9(chr(951 - 903) + chr(11156 - 11045) + chr(963 - 913) + chr(0b110111) + chr(0b10001 + 0o41), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x33' + chr(51) + '\x34', 0b1000), ehT0Px3KOsy9(chr(285 - 237) + chr(0b1001000 + 0o47) + '\062' + chr(1613 - 1564) + chr(407 - 355), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + '\061' + chr(55) + chr(0b11110 + 0o24), 0b1000), ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(111) + chr(0b10011 + 0o37) + chr(53) + chr(1706 - 1655), ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + '\x6f' + chr(519 - 466) + chr(1551 - 1503), ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x1a'), chr(0b100001 + 0o103) + chr(101) + chr(0b1100011) + '\157' + '\x64' + chr(0b1100101))('\x75' + chr(0b1110100) + chr(0b1001010 + 0o34) + chr(1884 - 1839) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def MTa14RvCBWlS(oVre8I6UXc3b):
if not xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'FR\xea\xa6\xd3\x1f&\xdb\xcf\xdf'), chr(2773 - 2673) + '\145' + chr(0b1100001 + 0o2) + chr(4461 - 4350) + chr(5880 - 5780) + chr(0b1100101))(chr(117) + chr(11528 - 11412) + chr(0b11110 + 0o110) + '\x2d' + chr(600 - 544))):
xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'k@\xeb\xbb\xc6\x08\r\xd1\xce\xcd\x8f\xe5?\xe9\x98'), '\x64' + chr(101) + chr(0b111110 + 0o45) + '\x6f' + chr(0b11000 + 0o114) + '\x65')(chr(117) + chr(0b1110100 + 0o0) + chr(0b1100110) + chr(402 - 357) + chr(2282 - 2226)))(xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'k[\xf6\xb1\xd3\x01\r\xc1\xd5\xdd\x91\xce;\xef\xb4\x05%\x80\x96/'), '\144' + '\x65' + chr(1021 - 922) + chr(0b1101111) + '\x64' + '\145')('\165' + chr(0b1110100) + chr(0b1011101 + 0o11) + '\x2d' + chr(56))), xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'kP\xf5\xbd\xd0\x0c>\xed\xd2\xcc\x84\xe1'), chr(100) + '\x65' + chr(0b1100011) + chr(2718 - 2607) + chr(100) + '\145')('\165' + chr(116) + chr(8572 - 8470) + '\055' + '\x38')))
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b'g\x00\xd1\xaa\xc7\x0e5\x85\xcb\xd4\xbb\xfa'), chr(0b110100 + 0o60) + chr(0b1100101) + '\x63' + chr(11302 - 11191) + chr(0b1100100) + '\145')(chr(117) + '\x74' + '\x66' + chr(45) + chr(56)))(xafqLlk3kkUe(SXOLrMavuUCe(b'`E\xf8\xbb\xdc\x04<\xd5\x81\x9d\x92\xb1/\xeb\xcb\x02>\xc1\xc1?<;\xc0\xa7}Tw\x02\xc4\xfc'), chr(0b1100100) + chr(0b1100101) + chr(0b1100011) + '\x6f' + chr(2578 - 2478) + chr(3820 - 3719))(chr(117) + '\x74' + chr(0b1100110) + chr(45) + chr(0b111000)), xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'YX\xfd\xb7\xde2?\xdd\xc5\xdd'), chr(6413 - 6313) + '\145' + chr(0b1100011) + chr(5307 - 5196) + '\144' + chr(1877 - 1776))(chr(0b1110101) + '\x74' + chr(8648 - 8546) + chr(45) + chr(896 - 840))), xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'@V\xeb\xb5\xd7\x19\r\xde\xce\xdb\x80\xfd\x05\xe8\x9f\x13!'), '\144' + '\x65' + chr(0b1000 + 0o133) + chr(0b1000100 + 0o53) + chr(0b1100100) + chr(0b110101 + 0o60))(chr(0b1010101 + 0o40) + chr(0b1110100) + '\146' + chr(0b10110 + 0o27) + chr(56))), xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'GC\xfc\xa2\xc12&\xdd\xfe\xdf\x8e'), chr(0b1100100) + chr(0b1100101) + chr(7159 - 7060) + chr(0b1011111 + 0o20) + '\144' + chr(101))('\165' + chr(5400 - 5284) + chr(8449 - 8347) + chr(0b100111 + 0o6) + chr(0b111000))))
yield
xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'k@\xeb\xbb\xc6\x08\r\xd1\xce\xcd\x8f\xe5?\xe9\x98'), chr(0b1100100) + chr(3992 - 3891) + chr(0b1100011) + '\157' + chr(0b1100100) + chr(0b1100101))(chr(117) + chr(11715 - 11599) + chr(0b1100110) + '\055' + chr(1858 - 1802)))(xafqLlk3kkUe(oVre8I6UXc3b, xafqLlk3kkUe(SXOLrMavuUCe(b'@V\xeb\xb5\xd7\x19\r\xde\xce\xdb\x80\xfd\x05\xe8\x9f\x13!'), chr(4412 - 4312) + chr(101) + '\x63' + '\x6f' + chr(100) + '\145')(chr(0b1110101) + '\x74' + chr(8776 - 8674) + chr(0b100 + 0o51) + chr(56))), -ehT0Px3KOsy9('\x30' + '\x6f' + chr(181 - 132), 0b1000))
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/ptb.py
|
_read_words
|
def _read_words(filename):
"""Reads words from a file."""
with tf.gfile.GFile(filename, "r") as f:
if sys.version_info[0] >= 3:
return f.read().replace("\n", " %s " % EOS).split()
else:
return f.read().decode("utf-8").replace("\n", " %s " % EOS).split()
|
python
|
def _read_words(filename):
"""Reads words from a file."""
with tf.gfile.GFile(filename, "r") as f:
if sys.version_info[0] >= 3:
return f.read().replace("\n", " %s " % EOS).split()
else:
return f.read().decode("utf-8").replace("\n", " %s " % EOS).split()
|
[
"def",
"_read_words",
"(",
"filename",
")",
":",
"with",
"tf",
".",
"gfile",
".",
"GFile",
"(",
"filename",
",",
"\"r\"",
")",
"as",
"f",
":",
"if",
"sys",
".",
"version_info",
"[",
"0",
"]",
">=",
"3",
":",
"return",
"f",
".",
"read",
"(",
")",
".",
"replace",
"(",
"\"\\n\"",
",",
"\" %s \"",
"%",
"EOS",
")",
".",
"split",
"(",
")",
"else",
":",
"return",
"f",
".",
"read",
"(",
")",
".",
"decode",
"(",
"\"utf-8\"",
")",
".",
"replace",
"(",
"\"\\n\"",
",",
"\" %s \"",
"%",
"EOS",
")",
".",
"split",
"(",
")"
] |
Reads words from a file.
|
[
"Reads",
"words",
"from",
"a",
"file",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/ptb.py#L39-L45
|
train
|
Reads words from a file.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0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Im,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b1100 + 0o44) + chr(0b1101111) + '\065' + '\x32', 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(0b11 + 0o57) + chr(1362 - 1307) + '\065', 0o10), ehT0Px3KOsy9(chr(0b101110 + 0o2) + chr(111) + '\063' + chr(55) + chr(0b110101), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(2650 - 2597) + chr(0b110001 + 0o2), 36045 - 36037), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(2419 - 2368) + chr(0b110110) + '\x31', 0b1000), ehT0Px3KOsy9(chr(1637 - 1589) + '\x6f' + chr(0b100110 + 0o14) + chr(701 - 649) + chr(0b110100), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(2149 - 2099) + chr(53) + '\x32', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\063' + '\x30' + chr(0b0 + 0o63), 0b1000), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(0b1001010 + 0o45) + chr(49) + chr(53) + '\064', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\x31' + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(0b100001 + 0o116) + '\x33' + chr(0b110100) + chr(0b110111), 36831 - 36823), ehT0Px3KOsy9(chr(0b101100 + 0o4) + chr(111) + chr(0b110001) + '\063' + chr(0b100110 + 0o15), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + '\x31' + chr(478 - 430) + '\062', ord("\x08")), ehT0Px3KOsy9(chr(1180 - 1132) + chr(0b1001100 + 0o43) + '\x32' + chr(51) + chr(1755 - 1701), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110100) + '\064', 0o10), ehT0Px3KOsy9(chr(1574 - 1526) + '\157' + '\x36' + chr(0b101011 + 0o12), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(10040 - 9929) + chr(49) + '\x36' + chr(0b101 + 0o60), 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110010) + chr(0b110110) + chr(0b110111), 0o10), ehT0Px3KOsy9(chr(0b1011 + 0o45) + chr(5470 - 5359) + chr(0b11000 + 0o31) + chr(0b10101 + 0o35) + chr(51), 0o10), ehT0Px3KOsy9(chr(0b10100 + 0o34) + '\157' + chr(49) + chr(0b110010) + chr(0b110010), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110011) + '\x34' + chr(809 - 758), 0o10), ehT0Px3KOsy9(chr(48) + chr(8274 - 8163) + chr(0b10010 + 0o41) + chr(50) + chr(1848 - 1794), 0o10), ehT0Px3KOsy9(chr(1864 - 1816) + chr(8955 - 8844) + '\x31' + '\x33' + chr(0b1010 + 0o53), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x31' + chr(0b110111), 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(2552 - 2501) + chr(243 - 195) + chr(0b110101), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110010) + chr(0b101011 + 0o6) + chr(2290 - 2239), 65529 - 65521), ehT0Px3KOsy9('\x30' + chr(7832 - 7721) + chr(51) + '\067' + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b110011 + 0o74) + chr(1226 - 1176) + chr(515 - 463) + '\067', 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110011) + chr(0b1 + 0o63) + chr(0b110001 + 0o0), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1100111 + 0o10) + '\061' + chr(0b10 + 0o63) + chr(0b110100), 8), ehT0Px3KOsy9(chr(48) + chr(7910 - 7799) + chr(50) + '\062' + '\x37', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(1372 - 1261) + chr(2260 - 2211) + chr(0b110010) + chr(0b101111 + 0o4), 8), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110001) + '\x33' + chr(53), 8), ehT0Px3KOsy9('\060' + chr(111) + '\062' + chr(51) + chr(2533 - 2478), 0o10), ehT0Px3KOsy9(chr(0b100110 + 0o12) + '\157' + '\x33' + chr(0b11000 + 0o33) + chr(1928 - 1875), 0o10), ehT0Px3KOsy9('\x30' + chr(9906 - 9795) + chr(0b1101 + 0o45) + chr(0b11 + 0o56) + '\x30', 0o10), ehT0Px3KOsy9('\x30' + chr(7851 - 7740) + '\063' + chr(551 - 501), 16215 - 16207), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(111) + chr(54), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(1129 - 1080) + chr(0b110110) + chr(123 - 74), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(0b11001 + 0o32) + chr(49) + '\x37', ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(1744 - 1696) + chr(0b101100 + 0o103) + chr(0b110101) + '\060', ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x04'), chr(0b1100100) + chr(7284 - 7183) + '\x63' + chr(0b1101111) + '\x64' + '\145')(chr(7007 - 6890) + chr(116) + '\146' + '\055' + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def ZpcD3MVcZa3j(xw4DsBfIJ22E):
with xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'm\xfb\x94G\x94'), chr(3205 - 3105) + chr(6549 - 6448) + chr(0b111011 + 0o50) + '\157' + chr(803 - 703) + chr(0b1100101))('\165' + '\164' + chr(0b1100110) + chr(0b100101 + 0o10) + chr(56)))(xw4DsBfIJ22E, xafqLlk3kkUe(SXOLrMavuUCe(b'X'), '\144' + chr(0b1100101) + chr(0b1100011) + '\x6f' + chr(5502 - 5402) + '\145')(chr(6486 - 6369) + chr(0b1101010 + 0o12) + '\x66' + chr(0b101101) + chr(0b111000))) as EGyt1xfPT1P6:
if xafqLlk3kkUe(a2SYDDomXDZ2, xafqLlk3kkUe(SXOLrMavuUCe(b'\\\xd8\x8fX\x98\xcb\xc4\x9c\x05e\x814'), chr(0b10100 + 0o120) + '\x65' + chr(0b1011100 + 0o7) + chr(0b100010 + 0o115) + chr(2641 - 2541) + chr(0b1100101))(chr(117) + chr(116) + chr(9048 - 8946) + chr(0b100 + 0o51) + chr(56)))[ehT0Px3KOsy9('\x30' + chr(3824 - 3713) + chr(676 - 628), 25354 - 25346)] >= ehT0Px3KOsy9('\060' + chr(111) + chr(2275 - 2224), 0b1000):
return xafqLlk3kkUe(EGyt1xfPT1P6.read().replace(xafqLlk3kkUe(SXOLrMavuUCe(b' '), chr(0b1000101 + 0o37) + chr(0b1100011 + 0o2) + chr(0b100 + 0o137) + chr(0b1101111) + '\144' + '\x65')(chr(0b1100000 + 0o25) + '\164' + '\x66' + chr(0b101101) + '\x38'), xafqLlk3kkUe(SXOLrMavuUCe(b'\n\x98\x8e\x0b'), '\144' + chr(0b1001111 + 0o26) + chr(0b111101 + 0o46) + chr(0b111 + 0o150) + '\144' + chr(527 - 426))(chr(117) + chr(0b11100 + 0o130) + '\146' + chr(1144 - 1099) + chr(0b100100 + 0o24)) % JZLlZR4Uyjym), xafqLlk3kkUe(SXOLrMavuUCe(b'Y\xcd\x91B\x85'), chr(6381 - 6281) + chr(0b1100101) + chr(6906 - 6807) + '\157' + chr(4797 - 4697) + '\145')('\165' + '\164' + chr(7186 - 7084) + chr(0b101101) + chr(2656 - 2600)))()
else:
return xafqLlk3kkUe(EGyt1xfPT1P6.read().decode(xafqLlk3kkUe(SXOLrMavuUCe(b'_\xc9\x9b\x06\xc9'), '\x64' + chr(101) + '\x63' + '\157' + '\x64' + chr(4344 - 4243))('\165' + chr(116) + chr(0b1100110) + chr(0b101101) + chr(56))).replace(xafqLlk3kkUe(SXOLrMavuUCe(b' '), chr(100) + '\145' + chr(0b1100011) + '\157' + chr(343 - 243) + chr(0b1100101))('\165' + chr(116) + chr(0b101110 + 0o70) + chr(0b10111 + 0o26) + chr(0b101001 + 0o17)), xafqLlk3kkUe(SXOLrMavuUCe(b'\n\x98\x8e\x0b'), '\144' + chr(101) + '\x63' + '\157' + '\x64' + '\x65')('\x75' + '\164' + chr(102) + '\055' + '\070') % JZLlZR4Uyjym), xafqLlk3kkUe(SXOLrMavuUCe(b'Y\xcd\x91B\x85'), chr(1186 - 1086) + '\145' + chr(0b1100011) + '\x6f' + chr(4209 - 4109) + '\x65')('\165' + chr(0b110111 + 0o75) + chr(0b1100110) + chr(45) + '\x38'))()
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/ptb.py
|
_build_vocab
|
def _build_vocab(filename, vocab_path, vocab_size):
"""Reads a file to build a vocabulary of `vocab_size` most common words.
The vocabulary is sorted by occurrence count and has one word per line.
Originally from:
https://github.com/tensorflow/models/blob/master/tutorials/rnn/ptb/reader.py
Args:
filename: file to read list of words from.
vocab_path: path where to save the vocabulary.
vocab_size: size of the vocabulary to generate.
"""
data = _read_words(filename)
counter = collections.Counter(data)
count_pairs = sorted(counter.items(), key=lambda x: (-x[1], x[0]))
words, _ = list(zip(*count_pairs))
words = words[:vocab_size]
with open(vocab_path, "w") as f:
f.write("\n".join(words))
|
python
|
def _build_vocab(filename, vocab_path, vocab_size):
"""Reads a file to build a vocabulary of `vocab_size` most common words.
The vocabulary is sorted by occurrence count and has one word per line.
Originally from:
https://github.com/tensorflow/models/blob/master/tutorials/rnn/ptb/reader.py
Args:
filename: file to read list of words from.
vocab_path: path where to save the vocabulary.
vocab_size: size of the vocabulary to generate.
"""
data = _read_words(filename)
counter = collections.Counter(data)
count_pairs = sorted(counter.items(), key=lambda x: (-x[1], x[0]))
words, _ = list(zip(*count_pairs))
words = words[:vocab_size]
with open(vocab_path, "w") as f:
f.write("\n".join(words))
|
[
"def",
"_build_vocab",
"(",
"filename",
",",
"vocab_path",
",",
"vocab_size",
")",
":",
"data",
"=",
"_read_words",
"(",
"filename",
")",
"counter",
"=",
"collections",
".",
"Counter",
"(",
"data",
")",
"count_pairs",
"=",
"sorted",
"(",
"counter",
".",
"items",
"(",
")",
",",
"key",
"=",
"lambda",
"x",
":",
"(",
"-",
"x",
"[",
"1",
"]",
",",
"x",
"[",
"0",
"]",
")",
")",
"words",
",",
"_",
"=",
"list",
"(",
"zip",
"(",
"*",
"count_pairs",
")",
")",
"words",
"=",
"words",
"[",
":",
"vocab_size",
"]",
"with",
"open",
"(",
"vocab_path",
",",
"\"w\"",
")",
"as",
"f",
":",
"f",
".",
"write",
"(",
"\"\\n\"",
".",
"join",
"(",
"words",
")",
")"
] |
Reads a file to build a vocabulary of `vocab_size` most common words.
The vocabulary is sorted by occurrence count and has one word per line.
Originally from:
https://github.com/tensorflow/models/blob/master/tutorials/rnn/ptb/reader.py
Args:
filename: file to read list of words from.
vocab_path: path where to save the vocabulary.
vocab_size: size of the vocabulary to generate.
|
[
"Reads",
"a",
"file",
"to",
"build",
"a",
"vocabulary",
"of",
"vocab_size",
"most",
"common",
"words",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/ptb.py#L48-L66
|
train
|
Reads a file to build a vocabulary of vocab_size most common words.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4Be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eM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + '\x6f' + '\062' + chr(0b110000) + '\061', 44214 - 44206), ehT0Px3KOsy9('\x30' + chr(6858 - 6747) + '\062' + chr(0b110110) + '\064', 371 - 363), ehT0Px3KOsy9('\x30' + chr(0b1010100 + 0o33) + chr(1729 - 1678) + chr(1088 - 1039), ord("\x08")), ehT0Px3KOsy9(chr(1676 - 1628) + chr(0b101100 + 0o103) + chr(0b110011) + chr(0b101111 + 0o1) + chr(99 - 50), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(49) + chr(50) + '\x33', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b111011 + 0o64) + chr(0b10100 + 0o35) + chr(50), 19122 - 19114), ehT0Px3KOsy9(chr(1412 - 1364) + chr(111) + chr(0b110010) + chr(1190 - 1135) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1010000 + 0o37) + chr(0b110 + 0o55) + '\x30' + '\x31', 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110110) + chr(54), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(9091 - 8980) + chr(228 - 179) + '\061' + chr(73 - 19), 0o10), ehT0Px3KOsy9('\060' + chr(0b1011 + 0o144) + '\062' + chr(0b110100) + '\060', ord("\x08")), ehT0Px3KOsy9(chr(0b1100 + 0o44) + '\x6f' + chr(0b110010 + 0o1) + '\065' + '\063', 60747 - 60739), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(49) + chr(0b10100 + 0o40) + chr(54), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(0b110010) + '\061' + chr(736 - 683), 0o10), ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(0b101011 + 0o104) + '\063' + chr(52) + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(1793 - 1745) + '\x6f' + chr(894 - 843) + chr(0b10101 + 0o41) + chr(50), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b110010 + 0o75) + '\063' + chr(0b110100) + chr(2474 - 2420), 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(53) + chr(55), 0o10), ehT0Px3KOsy9('\x30' + '\157' + '\x33' + '\x31' + chr(49), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(2270 - 2216) + '\063', 24563 - 24555), ehT0Px3KOsy9(chr(0b101110 + 0o2) + chr(0b111001 + 0o66) + chr(1671 - 1620) + chr(0b110000) + '\064', 0o10), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(0b100000 + 0o117) + '\061' + chr(0b11010 + 0o32) + '\x33', 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110011) + chr(0b110111) + '\066', 0o10), ehT0Px3KOsy9('\x30' + chr(0b1010100 + 0o33) + chr(0b110001), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(1829 - 1776) + chr(1579 - 1524), 8), ehT0Px3KOsy9('\060' + '\157' + '\x32' + '\x32' + chr(1579 - 1525), 0o10), ehT0Px3KOsy9(chr(1685 - 1637) + chr(111) + chr(0b110010) + chr(0b11 + 0o62) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\x32' + '\x32' + '\x33', 0b1000), ehT0Px3KOsy9(chr(1151 - 1103) + chr(0b1010101 + 0o32) + chr(49) + '\x37' + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(5159 - 5048) + chr(2284 - 2233) + '\x36' + chr(54), 4179 - 4171), ehT0Px3KOsy9(chr(1204 - 1156) + chr(111) + chr(1130 - 1079), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1001110 + 0o41) + '\063' + chr(53) + '\x34', 0b1000), ehT0Px3KOsy9('\060' + chr(111) + '\x31' + '\x31' + chr(0b11100 + 0o33), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\062' + chr(0b110110) + chr(0b110010), 0o10), ehT0Px3KOsy9(chr(0b11000 + 0o30) + chr(111) + '\x31' + chr(0b101011 + 0o10) + '\x31', 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\x32' + '\062' + chr(0b101001 + 0o13), 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(235 - 186) + chr(322 - 270) + chr(662 - 612), ord("\x08")), ehT0Px3KOsy9(chr(0b10001 + 0o37) + chr(0b1101111) + '\062' + chr(0b110110) + chr(386 - 334), 8), ehT0Px3KOsy9(chr(397 - 349) + '\157' + '\x32' + chr(51) + '\064', 0o10), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(0b1101111) + chr(1459 - 1408) + chr(0b110101) + '\x35', ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(2004 - 1956) + chr(0b101011 + 0o104) + chr(848 - 795) + chr(0b110000), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xaf'), chr(0b1100100) + '\145' + '\x63' + chr(7196 - 7085) + chr(100) + chr(0b11001 + 0o114))('\165' + chr(0b1110100) + '\146' + chr(0b101101) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def ITNmwpAgrirJ(xw4DsBfIJ22E, rbbFI9rmibl3, CeyMIoSyrpkQ):
ULnjp6D6efFH = ZpcD3MVcZa3j(xw4DsBfIJ22E)
pD5Ye7vZLivj = FGhnnwoh1Dd8.Counter(ULnjp6D6efFH)
Uzbfosj30Ffz = vUlqIvNSaRMa(pD5Ye7vZLivj.NzveIZ3IlSH9(), key=lambda OeWW0F1dBPRQ: (-OeWW0F1dBPRQ[ehT0Px3KOsy9(chr(48) + '\157' + chr(0b1000 + 0o51), 8)], OeWW0F1dBPRQ[ehT0Px3KOsy9(chr(0b100111 + 0o11) + chr(9274 - 9163) + '\060', 37538 - 37530)]))
(o34DiSJcu6N2, VNGQdHSFPrso) = YyaZ4tpXu4lf(pZ0NK2y6HRbn(*Uzbfosj30Ffz))
o34DiSJcu6N2 = o34DiSJcu6N2[:CeyMIoSyrpkQ]
with _fwkIVCGgtAN(rbbFI9rmibl3, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6'), chr(0b1100100) + chr(101) + chr(1228 - 1129) + chr(0b1101111) + chr(0b1000010 + 0o42) + chr(0b1011111 + 0o6))(chr(0b1100011 + 0o22) + chr(0b1101011 + 0o11) + '\x66' + chr(0b101101) + chr(0b101110 + 0o12))) as EGyt1xfPT1P6:
xafqLlk3kkUe(EGyt1xfPT1P6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xf6\xc6p\xb56'), chr(100) + chr(101) + '\x63' + chr(111) + chr(0b100110 + 0o76) + '\145')(chr(0b101111 + 0o106) + chr(116) + chr(9232 - 9130) + chr(0b10101 + 0o30) + '\070'))(xafqLlk3kkUe(xafqLlk3kkUe(SXOLrMavuUCe(b'\x8b'), chr(6447 - 6347) + chr(0b1100101) + chr(0b1100011) + chr(111) + chr(0b1100100) + chr(0b10101 + 0o120))(chr(0b1110101) + '\x74' + chr(102) + chr(0b101101) + chr(753 - 697)), xafqLlk3kkUe(SXOLrMavuUCe(b'\xeb\xdbp\xaf'), chr(100) + chr(0b1100101) + chr(7208 - 7109) + chr(0b1101111) + chr(8970 - 8870) + chr(101))(chr(0b1100001 + 0o24) + '\x74' + chr(4029 - 3927) + '\x2d' + '\x38'))(o34DiSJcu6N2))
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/ptb.py
|
_get_token_encoder
|
def _get_token_encoder(vocab_dir, vocab_name, filename):
"""Reads from file and returns a `TokenTextEncoder` for the vocabulary."""
vocab_path = os.path.join(vocab_dir, vocab_name)
if not tf.gfile.Exists(vocab_path):
_build_vocab(filename, vocab_path, 10000)
return text_encoder.TokenTextEncoder(vocab_path)
|
python
|
def _get_token_encoder(vocab_dir, vocab_name, filename):
"""Reads from file and returns a `TokenTextEncoder` for the vocabulary."""
vocab_path = os.path.join(vocab_dir, vocab_name)
if not tf.gfile.Exists(vocab_path):
_build_vocab(filename, vocab_path, 10000)
return text_encoder.TokenTextEncoder(vocab_path)
|
[
"def",
"_get_token_encoder",
"(",
"vocab_dir",
",",
"vocab_name",
",",
"filename",
")",
":",
"vocab_path",
"=",
"os",
".",
"path",
".",
"join",
"(",
"vocab_dir",
",",
"vocab_name",
")",
"if",
"not",
"tf",
".",
"gfile",
".",
"Exists",
"(",
"vocab_path",
")",
":",
"_build_vocab",
"(",
"filename",
",",
"vocab_path",
",",
"10000",
")",
"return",
"text_encoder",
".",
"TokenTextEncoder",
"(",
"vocab_path",
")"
] |
Reads from file and returns a `TokenTextEncoder` for the vocabulary.
|
[
"Reads",
"from",
"file",
"and",
"returns",
"a",
"TokenTextEncoder",
"for",
"the",
"vocabulary",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/ptb.py#L69-L74
|
train
|
Reads from file and returns a TokenTextEncoder for the vocabulary.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAf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_gSK8V7h0,Rurm1zTRfSmY,reqGiMiVQ77y,bsS9P6_LpdIe,sbGAZlkZOtyh,Cf_Qef15s3_F,eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + chr(0b1101000 + 0o7) + '\063' + chr(0b110011) + '\x36', 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + '\061' + chr(54) + '\x31', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110011) + chr(55) + chr(2338 - 2284), 54882 - 54874), ehT0Px3KOsy9(chr(0b101 + 0o53) + '\x6f' + '\x31' + chr(179 - 127) + chr(1522 - 1473), 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b100011 + 0o16) + '\x34' + chr(1069 - 1020), 8), ehT0Px3KOsy9('\x30' + chr(6694 - 6583) + '\065' + chr(1595 - 1547), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\063' + chr(0b101000 + 0o14) + chr(0b100111 + 0o12), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b101000 + 0o12) + '\062' + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(1326 - 1278) + chr(0b1101111) + chr(1349 - 1298) + '\x35' + chr(0b1110 + 0o42), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(50) + '\067' + '\064', 0b1000), ehT0Px3KOsy9(chr(0b111 + 0o51) + '\x6f' + '\x31' + chr(0b100001 + 0o17), 9595 - 9587), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b11100 + 0o25) + chr(0b11101 + 0o24) + chr(2465 - 2410), 18570 - 18562), ehT0Px3KOsy9(chr(1662 - 1614) + '\x6f' + '\061' + '\067' + chr(48), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b11101 + 0o122) + '\x31' + chr(0b110010) + chr(0b11 + 0o57), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(1753 - 1704) + chr(0b101100 + 0o10) + chr(0b110000), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(1033 - 984) + chr(0b110100) + chr(1635 - 1580), 0o10), ehT0Px3KOsy9(chr(0b11101 + 0o23) + '\157' + '\063' + chr(48) + chr(0b100010 + 0o17), 6195 - 6187), ehT0Px3KOsy9(chr(0b110000) + chr(11891 - 11780) + '\061' + chr(0b110000) + chr(968 - 919), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1001101 + 0o42) + chr(0b110011) + chr(0b100111 + 0o15), 13384 - 13376), ehT0Px3KOsy9(chr(1113 - 1065) + chr(111) + chr(1061 - 1012) + chr(53) + '\x33', 60225 - 60217), ehT0Px3KOsy9('\x30' + chr(111) + chr(1269 - 1218) + chr(0b100111 + 0o16) + '\x32', 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(50) + chr(0b100110 + 0o14) + chr(1136 - 1083), 8), ehT0Px3KOsy9(chr(852 - 804) + chr(0b1101111) + chr(135 - 86) + chr(0b1001 + 0o53) + chr(1347 - 1293), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(832 - 781) + '\064' + '\x37', ord("\x08")), ehT0Px3KOsy9(chr(2210 - 2162) + '\157' + chr(49) + chr(51) + chr(50), 49587 - 49579), ehT0Px3KOsy9('\x30' + '\x6f' + '\062' + '\061', 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + chr(49) + chr(665 - 612) + chr(0b110011), 8), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\061' + '\061' + chr(54), 39849 - 39841), ehT0Px3KOsy9(chr(48) + '\157' + chr(51) + chr(0b110111) + chr(52), 59733 - 59725), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110001) + '\x37' + chr(0b110001), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110001) + chr(0b110011) + '\x35', ord("\x08")), ehT0Px3KOsy9(chr(1600 - 1552) + '\157' + '\062' + '\060' + chr(0b101101 + 0o10), ord("\x08")), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(111) + chr(0b1011 + 0o46) + chr(49) + '\x30', 12924 - 12916), ehT0Px3KOsy9('\x30' + chr(1180 - 1069) + chr(0b110011) + '\065' + chr(0b101000 + 0o10), 8), ehT0Px3KOsy9(chr(48) + chr(0b110 + 0o151) + chr(0b110001) + chr(0b110000) + chr(0b100010 + 0o23), 54571 - 54563), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(147 - 97) + chr(50) + '\060', ord("\x08")), ehT0Px3KOsy9('\060' + chr(494 - 383) + chr(254 - 204) + chr(1490 - 1436) + '\x37', 0b1000), ehT0Px3KOsy9('\060' + chr(0b110101 + 0o72) + chr(55) + chr(1957 - 1909), 22886 - 22878), ehT0Px3KOsy9('\060' + '\157' + chr(0b110010) + chr(104 - 51) + '\x30', 0o10), ehT0Px3KOsy9(chr(0b10 + 0o56) + chr(5526 - 5415) + chr(0b110001) + chr(0b10101 + 0o33) + chr(50), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\065' + '\060', 8)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xf0'), '\144' + chr(0b1100101) + chr(0b110 + 0o135) + chr(0b11100 + 0o123) + chr(0b1100100) + chr(0b1100101))('\x75' + chr(0b1110100) + '\x66' + chr(0b101101) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def uIlP5O4OTndC(jQPzVuGI0sJA, CAY9HHsWlyPg, xw4DsBfIJ22E):
rbbFI9rmibl3 = oqhJDdMJfuwx.path.join(jQPzVuGI0sJA, CAY9HHsWlyPg)
if not xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\x9b\t\x97\x12\x15['), chr(0b1100100) + '\145' + chr(0b1100011) + '\157' + chr(0b1010 + 0o132) + chr(0b1100101))(chr(0b1101010 + 0o13) + '\164' + chr(0b10011 + 0o123) + chr(0b101101) + chr(3073 - 3017)))(rbbFI9rmibl3):
ITNmwpAgrirJ(xw4DsBfIJ22E, rbbFI9rmibl3, ehT0Px3KOsy9('\060' + '\157' + chr(0b110010) + chr(996 - 945) + chr(0b110100) + chr(50) + chr(1291 - 1243), 6084 - 6076))
return xafqLlk3kkUe(nCRDzZ_Is9fz, xafqLlk3kkUe(SXOLrMavuUCe(b'\x8a\x1e\x95\x04\x0f|\x84\xed\x9c\xf9f,\x176\x05\x15'), chr(0b10010 + 0o122) + chr(1757 - 1656) + chr(0b1100011) + chr(5821 - 5710) + '\x64' + chr(5538 - 5437))(chr(117) + chr(0b1110100) + chr(7645 - 7543) + chr(0b101101) + chr(0b0 + 0o70)))(rbbFI9rmibl3)
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/ptb.py
|
_maybe_download_corpus
|
def _maybe_download_corpus(tmp_dir, vocab_type):
"""Download and unpack the corpus.
Args:
tmp_dir: directory containing dataset.
vocab_type: which vocabulary are we using.
Returns:
The list of names of files.
"""
filename = os.path.basename(PTB_URL)
compressed_filepath = generator_utils.maybe_download(
tmp_dir, filename, PTB_URL)
ptb_files = []
ptb_char_files = []
with tarfile.open(compressed_filepath, "r:gz") as tgz:
files = []
# Selecting only relevant files.
for m in tgz.getmembers():
if "ptb" in m.name and ".txt" in m.name:
if "char" in m.name:
ptb_char_files += [m.name]
else:
ptb_files += [m.name]
files += [m]
tgz.extractall(tmp_dir, members=files)
if vocab_type == text_problems.VocabType.CHARACTER:
return ptb_char_files
else:
return ptb_files
|
python
|
def _maybe_download_corpus(tmp_dir, vocab_type):
"""Download and unpack the corpus.
Args:
tmp_dir: directory containing dataset.
vocab_type: which vocabulary are we using.
Returns:
The list of names of files.
"""
filename = os.path.basename(PTB_URL)
compressed_filepath = generator_utils.maybe_download(
tmp_dir, filename, PTB_URL)
ptb_files = []
ptb_char_files = []
with tarfile.open(compressed_filepath, "r:gz") as tgz:
files = []
# Selecting only relevant files.
for m in tgz.getmembers():
if "ptb" in m.name and ".txt" in m.name:
if "char" in m.name:
ptb_char_files += [m.name]
else:
ptb_files += [m.name]
files += [m]
tgz.extractall(tmp_dir, members=files)
if vocab_type == text_problems.VocabType.CHARACTER:
return ptb_char_files
else:
return ptb_files
|
[
"def",
"_maybe_download_corpus",
"(",
"tmp_dir",
",",
"vocab_type",
")",
":",
"filename",
"=",
"os",
".",
"path",
".",
"basename",
"(",
"PTB_URL",
")",
"compressed_filepath",
"=",
"generator_utils",
".",
"maybe_download",
"(",
"tmp_dir",
",",
"filename",
",",
"PTB_URL",
")",
"ptb_files",
"=",
"[",
"]",
"ptb_char_files",
"=",
"[",
"]",
"with",
"tarfile",
".",
"open",
"(",
"compressed_filepath",
",",
"\"r:gz\"",
")",
"as",
"tgz",
":",
"files",
"=",
"[",
"]",
"# Selecting only relevant files.",
"for",
"m",
"in",
"tgz",
".",
"getmembers",
"(",
")",
":",
"if",
"\"ptb\"",
"in",
"m",
".",
"name",
"and",
"\".txt\"",
"in",
"m",
".",
"name",
":",
"if",
"\"char\"",
"in",
"m",
".",
"name",
":",
"ptb_char_files",
"+=",
"[",
"m",
".",
"name",
"]",
"else",
":",
"ptb_files",
"+=",
"[",
"m",
".",
"name",
"]",
"files",
"+=",
"[",
"m",
"]",
"tgz",
".",
"extractall",
"(",
"tmp_dir",
",",
"members",
"=",
"files",
")",
"if",
"vocab_type",
"==",
"text_problems",
".",
"VocabType",
".",
"CHARACTER",
":",
"return",
"ptb_char_files",
"else",
":",
"return",
"ptb_files"
] |
Download and unpack the corpus.
Args:
tmp_dir: directory containing dataset.
vocab_type: which vocabulary are we using.
Returns:
The list of names of files.
|
[
"Download",
"and",
"unpack",
"the",
"corpus",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/ptb.py#L77-L109
|
train
|
Download and unpack the corpus.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,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,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b100101 + 0o13) + '\x6f' + chr(49) + '\067' + '\060', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(50) + chr(0b101111 + 0o2) + chr(0b11101 + 0o26), ord("\x08")), ehT0Px3KOsy9(chr(0b11 + 0o55) + chr(111) + chr(0b110011) + '\063' + '\x30', 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(54) + chr(55), 30933 - 30925), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110010 + 0o1) + '\061' + chr(0b110011), 0o10), ehT0Px3KOsy9(chr(48) + chr(10560 - 10449) + chr(1995 - 1944) + chr(0b100000 + 0o24) + '\x36', 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b101100 + 0o5) + '\x32' + chr(49), 0o10), ehT0Px3KOsy9('\x30' + chr(8301 - 8190) + chr(2011 - 1957) + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(920 - 872) + '\x6f' + '\061' + chr(0b110101) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x33' + chr(0b110011) + chr(873 - 825), 8), ehT0Px3KOsy9(chr(1138 - 1090) + chr(111) + chr(1781 - 1732) + chr(0b110011), 57754 - 57746), ehT0Px3KOsy9(chr(477 - 429) + chr(11225 - 11114) + chr(856 - 806) + chr(2488 - 2435) + chr(54), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + '\061' + chr(1263 - 1213) + chr(0b101 + 0o60), 5641 - 5633), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110011) + '\x37' + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x31' + '\x30' + chr(0b110010 + 0o5), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b100011 + 0o114) + chr(99 - 49) + chr(0b110100) + '\065', 56075 - 56067), ehT0Px3KOsy9(chr(0b1101 + 0o43) + '\157' + chr(49) + '\067' + chr(0b110000), 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(51) + chr(51) + chr(2179 - 2129), 0o10), ehT0Px3KOsy9('\060' + chr(0b11011 + 0o124) + chr(1137 - 1084) + '\x33', 18413 - 18405), ehT0Px3KOsy9(chr(48) + '\157' + '\x32' + '\x30' + chr(0b110100), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\061' + '\x33' + '\x30', 0o10), ehT0Px3KOsy9(chr(0b1011 + 0o45) + chr(1392 - 1281) + '\x33' + '\x30' + '\067', 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(1411 - 1362) + '\063' + chr(0b110101 + 0o0), 11939 - 11931), ehT0Px3KOsy9(chr(48) + chr(111) + chr(51) + '\063' + '\x32', 8), ehT0Px3KOsy9(chr(0b101110 + 0o2) + chr(111) + chr(51) + chr(53) + chr(55), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x35' + chr(0b11101 + 0o31), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + '\x34' + chr(55), 0o10), ehT0Px3KOsy9(chr(48) + chr(5181 - 5070) + '\067' + '\x35', 17813 - 17805), ehT0Px3KOsy9(chr(0b1100 + 0o44) + chr(0b10011 + 0o134) + chr(237 - 186) + chr(1790 - 1741) + chr(53), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b11111 + 0o22) + '\x36' + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(2154 - 2106) + chr(111) + '\x31' + '\065', 28213 - 28205), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(50) + '\064' + '\061', 25110 - 25102), ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(6451 - 6340) + chr(2292 - 2242), 0b1000), ehT0Px3KOsy9('\x30' + chr(10414 - 10303) + chr(0b110010) + chr(0b10101 + 0o37) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(10660 - 10549) + chr(0b110010) + chr(53) + chr(0b100110 + 0o16), 4033 - 4025), ehT0Px3KOsy9('\060' + '\157' + '\061' + '\064' + chr(2553 - 2501), 0o10), ehT0Px3KOsy9('\060' + chr(10072 - 9961) + chr(2386 - 2336) + '\062' + chr(0b101111 + 0o3), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(52) + '\x37', 8), ehT0Px3KOsy9('\x30' + chr(111) + '\063' + chr(50), ord("\x08")), ehT0Px3KOsy9(chr(651 - 603) + chr(11647 - 11536) + chr(0b100110 + 0o14) + chr(55) + '\063', ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(629 - 581) + '\x6f' + '\x35' + chr(1549 - 1501), 64724 - 64716)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'V'), chr(2592 - 2492) + chr(1380 - 1279) + '\143' + chr(7753 - 7642) + chr(0b100000 + 0o104) + '\x65')(chr(0b100 + 0o161) + chr(12653 - 12537) + chr(3634 - 3532) + chr(0b101101) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def nOhugYfEsDse(JsZ36NJUqtml, u9HmDYfas07P):
xw4DsBfIJ22E = oqhJDdMJfuwx.path.basename(m5eZXTIyoliN)
kLDY7zEPTscL = g1Z_RG9zP4cD.maybe_download(JsZ36NJUqtml, xw4DsBfIJ22E, m5eZXTIyoliN)
Vwgs4wGiBeya = []
DUaOb4Qb_aRt = []
with xafqLlk3kkUe(RxqDt8LqC5Ns, xafqLlk3kkUe(SXOLrMavuUCe(b'\x17\xfb\xbdY'), chr(0b1100100) + '\145' + chr(0b1100011) + '\157' + '\x64' + chr(2294 - 2193))('\x75' + chr(116) + chr(0b11011 + 0o113) + chr(1785 - 1740) + '\x38'))(kLDY7zEPTscL, xafqLlk3kkUe(SXOLrMavuUCe(b'\n\xb1\xbfM'), chr(0b100011 + 0o101) + chr(7187 - 7086) + chr(99) + chr(8548 - 8437) + '\x64' + '\x65')(chr(0b1110101) + chr(116) + '\146' + '\x2d' + chr(0b1000 + 0o60))) as awcLPeILMqQx:
uyc48vokp5OE = []
for r8ufID9JCHnI in xafqLlk3kkUe(awcLPeILMqQx, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1f\xee\xacZ\xae\x8b3U\x1d\xab'), '\144' + chr(101) + '\x63' + '\x6f' + '\x64' + '\x65')(chr(117) + '\x74' + chr(102) + chr(655 - 610) + chr(0b111000)))():
if xafqLlk3kkUe(SXOLrMavuUCe(b'\x08\xff\xba'), chr(0b1100000 + 0o4) + '\145' + chr(99) + '\157' + chr(5792 - 5692) + chr(101))(chr(9024 - 8907) + chr(0b1110100) + chr(971 - 869) + chr(45) + '\070') in xafqLlk3kkUe(r8ufID9JCHnI, xafqLlk3kkUe(SXOLrMavuUCe(b'9\xc2\xae}\x99\x9c\x1dT+\xbel\xe8'), chr(7468 - 7368) + chr(8967 - 8866) + chr(0b11100 + 0o107) + chr(8121 - 8010) + '\144' + chr(101))('\165' + '\x74' + '\x66' + chr(45) + chr(0b100110 + 0o22))) and xafqLlk3kkUe(SXOLrMavuUCe(b'V\xff\xa0C'), chr(0b1100100) + chr(6447 - 6346) + chr(2438 - 2339) + chr(111) + chr(0b1100100) + chr(0b1010000 + 0o25))('\165' + chr(0b1110100) + chr(1097 - 995) + chr(45) + chr(56)) in xafqLlk3kkUe(r8ufID9JCHnI, xafqLlk3kkUe(SXOLrMavuUCe(b'9\xc2\xae}\x99\x9c\x1dT+\xbel\xe8'), chr(0b1100100) + chr(4073 - 3972) + '\143' + chr(111) + chr(0b1010001 + 0o23) + chr(8477 - 8376))(chr(0b1110101) + chr(0b1000111 + 0o55) + chr(102) + chr(0b1011 + 0o42) + '\x38')):
if xafqLlk3kkUe(SXOLrMavuUCe(b'\x1b\xe3\xb9E'), chr(100) + chr(135 - 34) + chr(7925 - 7826) + chr(0b1101111) + chr(100) + chr(101))(chr(0b1110101) + '\x74' + chr(0b1100110) + chr(45) + chr(56)) in xafqLlk3kkUe(r8ufID9JCHnI, xafqLlk3kkUe(SXOLrMavuUCe(b'9\xc2\xae}\x99\x9c\x1dT+\xbel\xe8'), chr(0b1100100) + '\x65' + '\143' + chr(3101 - 2990) + chr(0b1100100) + chr(0b1000000 + 0o45))(chr(0b110111 + 0o76) + '\164' + chr(2347 - 2245) + '\x2d' + chr(0b11111 + 0o31))):
DUaOb4Qb_aRt += [r8ufID9JCHnI.AIvJRzLdDfgF]
else:
Vwgs4wGiBeya += [r8ufID9JCHnI.AIvJRzLdDfgF]
uyc48vokp5OE += [r8ufID9JCHnI]
xafqLlk3kkUe(awcLPeILMqQx, xafqLlk3kkUe(SXOLrMavuUCe(b'\x1d\xf3\xacE\xaa\x85%Q\x03\xb4'), chr(7312 - 7212) + chr(101) + chr(99) + chr(11390 - 11279) + chr(0b1100100) + chr(0b1100101))('\165' + '\x74' + chr(0b1100110) + chr(0b111 + 0o46) + chr(0b101110 + 0o12)))(JsZ36NJUqtml, members=uyc48vokp5OE)
if u9HmDYfas07P == xafqLlk3kkUe(GkH56QMxhclz.VocabType, xafqLlk3kkUe(SXOLrMavuUCe(b';\xc3\x99e\x8a\xa5\x05u='), chr(100) + '\x65' + chr(0b1100011) + '\x6f' + '\x64' + chr(7654 - 7553))(chr(0b1 + 0o164) + '\x74' + '\146' + chr(45) + '\070')):
return DUaOb4Qb_aRt
else:
return Vwgs4wGiBeya
|
tensorflow/tensor2tensor
|
tensor2tensor/visualization/attention.py
|
resize
|
def resize(att_mat, max_length=None):
"""Normalize attention matrices and reshape as necessary."""
for i, att in enumerate(att_mat):
# Add extra batch dim for viz code to work.
if att.ndim == 3:
att = np.expand_dims(att, axis=0)
if max_length is not None:
# Sum across different attention values for each token.
att = att[:, :, :max_length, :max_length]
row_sums = np.sum(att, axis=2)
# Normalize
att /= row_sums[:, :, np.newaxis]
att_mat[i] = att
return att_mat
|
python
|
def resize(att_mat, max_length=None):
"""Normalize attention matrices and reshape as necessary."""
for i, att in enumerate(att_mat):
# Add extra batch dim for viz code to work.
if att.ndim == 3:
att = np.expand_dims(att, axis=0)
if max_length is not None:
# Sum across different attention values for each token.
att = att[:, :, :max_length, :max_length]
row_sums = np.sum(att, axis=2)
# Normalize
att /= row_sums[:, :, np.newaxis]
att_mat[i] = att
return att_mat
|
[
"def",
"resize",
"(",
"att_mat",
",",
"max_length",
"=",
"None",
")",
":",
"for",
"i",
",",
"att",
"in",
"enumerate",
"(",
"att_mat",
")",
":",
"# Add extra batch dim for viz code to work.",
"if",
"att",
".",
"ndim",
"==",
"3",
":",
"att",
"=",
"np",
".",
"expand_dims",
"(",
"att",
",",
"axis",
"=",
"0",
")",
"if",
"max_length",
"is",
"not",
"None",
":",
"# Sum across different attention values for each token.",
"att",
"=",
"att",
"[",
":",
",",
":",
",",
":",
"max_length",
",",
":",
"max_length",
"]",
"row_sums",
"=",
"np",
".",
"sum",
"(",
"att",
",",
"axis",
"=",
"2",
")",
"# Normalize",
"att",
"/=",
"row_sums",
"[",
":",
",",
":",
",",
"np",
".",
"newaxis",
"]",
"att_mat",
"[",
"i",
"]",
"=",
"att",
"return",
"att_mat"
] |
Normalize attention matrices and reshape as necessary.
|
[
"Normalize",
"attention",
"matrices",
"and",
"reshape",
"as",
"necessary",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/visualization/attention.py#L62-L75
|
train
|
Normalize attention matrices and reshape as necessary.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDR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Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\063', 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + '\065', 0b1000), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(0b1011001 + 0o26) + chr(0b10101 + 0o36) + chr(0b11 + 0o55) + '\060', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101001 + 0o6) + '\x31' + chr(0b10011 + 0o40) + '\065', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b1011 + 0o47) + chr(0b100111 + 0o16) + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b11000 + 0o33) + chr(0b110011) + chr(1823 - 1771), 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110010) + chr(0b110011) + '\x35', 0o10), ehT0Px3KOsy9('\x30' + chr(111) + '\x32' + chr(0b110111) + chr(0b110111), 0o10), ehT0Px3KOsy9('\060' + chr(4233 - 4122) + '\061' + chr(0b10111 + 0o36) + chr(51), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + '\062' + chr(0b100110 + 0o15) + '\061', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + '\x32' + chr(49) + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b1010 + 0o50) + chr(0b110011) + chr(0b110100), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1817 - 1768) + '\x37', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\066' + '\x30', 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1908 - 1859) + '\066' + chr(0b110000 + 0o0), 16717 - 16709), ehT0Px3KOsy9(chr(1080 - 1032) + chr(11199 - 11088) + '\065' + chr(0b100010 + 0o20), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(50) + '\066' + chr(48), 0o10), ehT0Px3KOsy9(chr(1213 - 1165) + '\157' + '\061' + chr(52) + chr(0b110000 + 0o0), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(10707 - 10596) + chr(55) + '\065', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(52) + chr(48), 0o10), ehT0Px3KOsy9(chr(0b1101 + 0o43) + chr(0b1101111) + chr(2067 - 2018) + chr(0b110011) + chr(0b110001), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(50) + chr(50) + chr(0b110011), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(51) + '\060' + chr(49), 0o10), ehT0Px3KOsy9(chr(48) + chr(381 - 270) + '\061' + '\x36' + '\x30', 8), ehT0Px3KOsy9(chr(1527 - 1479) + chr(111) + chr(2067 - 2016) + chr(0b10 + 0o57) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(53) + chr(2385 - 2333), 17152 - 17144), ehT0Px3KOsy9('\x30' + chr(1778 - 1667) + '\063' + '\x30' + '\064', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x33' + chr(0b100001 + 0o23) + '\x33', 21347 - 21339), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b110001) + chr(0b110001) + '\x33', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b110001 + 0o76) + '\x33' + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110101) + chr(0b1111 + 0o45), 8), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\062' + chr(0b110011) + chr(0b110011), 0o10), ehT0Px3KOsy9(chr(0b10001 + 0o37) + chr(111) + '\x33' + chr(1206 - 1157) + '\064', ord("\x08")), ehT0Px3KOsy9(chr(0b10000 + 0o40) + chr(111) + chr(0b1000 + 0o54) + chr(53), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\061' + chr(0b101000 + 0o13) + chr(0b110001 + 0o5), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(0b101011 + 0o7) + chr(49) + chr(49), 8), ehT0Px3KOsy9(chr(0b10 + 0o56) + chr(0b1101111) + '\x32', 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\x31' + '\064', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1001010 + 0o45) + chr(0b101111 + 0o4) + chr(2004 - 1951), 8), ehT0Px3KOsy9(chr(0b11000 + 0o30) + chr(0b1101111) + '\061' + '\x35' + '\x30', 35012 - 35004)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(346 - 293) + chr(48), 20241 - 20233)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'-'), chr(100) + '\x65' + chr(0b101 + 0o136) + chr(10656 - 10545) + chr(2057 - 1957) + '\145')('\165' + '\x74' + '\x66' + chr(351 - 306) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def x_dQG0ykrOi1(QYcdgLYZU57V, _o7pVXAdOCRy=None):
for (WVxHKyX45z_L, eqU8vkFje5tV) in YlkZvXL8qwsX(QYcdgLYZU57V):
if xafqLlk3kkUe(eqU8vkFje5tV, xafqLlk3kkUe(SXOLrMavuUCe(b'dj\xad-\xe1\x9e\xf4\xeb\x18\xff\xc3\xc8'), chr(100) + chr(0b1100101) + chr(99) + chr(0b101101 + 0o102) + '\144' + '\145')('\x75' + chr(0b1110000 + 0o4) + '\146' + chr(45) + chr(0b111000))) == ehT0Px3KOsy9(chr(0b110000) + chr(1041 - 930) + '\063', 8):
eqU8vkFje5tV = WqUC3KWvYVup.expand_dims(eqU8vkFje5tV, axis=ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(2184 - 2136), ord("\x08")))
if _o7pVXAdOCRy is not None:
eqU8vkFje5tV = eqU8vkFje5tV[:, :, :_o7pVXAdOCRy, :_o7pVXAdOCRy]
aabqPAUy4Jmn = WqUC3KWvYVup.xkxBmo49x2An(eqU8vkFje5tV, axis=ehT0Px3KOsy9('\060' + chr(0b100011 + 0o114) + chr(0b110010), 8))
eqU8vkFje5tV /= aabqPAUy4Jmn[:, :, WqUC3KWvYVup.newaxis]
QYcdgLYZU57V[WVxHKyX45z_L] = eqU8vkFje5tV
return QYcdgLYZU57V
|
tensorflow/tensor2tensor
|
tensor2tensor/visualization/attention.py
|
_get_attention
|
def _get_attention(inp_text, out_text, enc_atts, dec_atts, encdec_atts):
"""Compute representation of the attention ready for the d3 visualization.
Args:
inp_text: list of strings, words to be displayed on the left of the vis
out_text: list of strings, words to be displayed on the right of the vis
enc_atts: numpy array, encoder self-attentions
[num_layers, batch_size, num_heads, enc_length, enc_length]
dec_atts: numpy array, decoder self-attentions
[num_layers, batch_size, num_heads, dec_length, dec_length]
encdec_atts: numpy array, encoder-decoder attentions
[num_layers, batch_size, num_heads, dec_length, enc_length]
Returns:
Dictionary of attention representations with the structure:
{
'all': Representations for showing all attentions at the same time.
'inp_inp': Representations for showing encoder self-attentions
'inp_out': Representations for showing encoder-decoder attentions
'out_out': Representations for showing decoder self-attentions
}
and each sub-dictionary has structure:
{
'att': list of inter attentions matrices, one for each attention head
'top_text': list of strings, words to be displayed on the left of the vis
'bot_text': list of strings, words to be displayed on the right of the vis
}
"""
def get_full_attention(layer):
"""Get the full input+output - input+output attentions."""
enc_att = enc_atts[layer][0]
dec_att = dec_atts[layer][0]
encdec_att = encdec_atts[layer][0]
enc_att = np.transpose(enc_att, [0, 2, 1])
dec_att = np.transpose(dec_att, [0, 2, 1])
encdec_att = np.transpose(encdec_att, [0, 2, 1])
# [heads, query_length, memory_length]
enc_length = enc_att.shape[1]
dec_length = dec_att.shape[1]
num_heads = enc_att.shape[0]
first = np.concatenate([enc_att, encdec_att], axis=2)
second = np.concatenate(
[np.zeros((num_heads, dec_length, enc_length)), dec_att], axis=2)
full_att = np.concatenate([first, second], axis=1)
return [ha.T.tolist() for ha in full_att]
def get_inp_inp_attention(layer):
att = np.transpose(enc_atts[layer][0], (0, 2, 1))
return [ha.T.tolist() for ha in att]
def get_out_inp_attention(layer):
att = np.transpose(encdec_atts[layer][0], (0, 2, 1))
return [ha.T.tolist() for ha in att]
def get_out_out_attention(layer):
att = np.transpose(dec_atts[layer][0], (0, 2, 1))
return [ha.T.tolist() for ha in att]
def get_attentions(get_attention_fn):
num_layers = len(enc_atts)
return [get_attention_fn(i) for i in range(num_layers)]
attentions = {
'all': {
'att': get_attentions(get_full_attention),
'top_text': inp_text + out_text,
'bot_text': inp_text + out_text,
},
'inp_inp': {
'att': get_attentions(get_inp_inp_attention),
'top_text': inp_text,
'bot_text': inp_text,
},
'inp_out': {
'att': get_attentions(get_out_inp_attention),
'top_text': inp_text,
'bot_text': out_text,
},
'out_out': {
'att': get_attentions(get_out_out_attention),
'top_text': out_text,
'bot_text': out_text,
},
}
return attentions
|
python
|
def _get_attention(inp_text, out_text, enc_atts, dec_atts, encdec_atts):
"""Compute representation of the attention ready for the d3 visualization.
Args:
inp_text: list of strings, words to be displayed on the left of the vis
out_text: list of strings, words to be displayed on the right of the vis
enc_atts: numpy array, encoder self-attentions
[num_layers, batch_size, num_heads, enc_length, enc_length]
dec_atts: numpy array, decoder self-attentions
[num_layers, batch_size, num_heads, dec_length, dec_length]
encdec_atts: numpy array, encoder-decoder attentions
[num_layers, batch_size, num_heads, dec_length, enc_length]
Returns:
Dictionary of attention representations with the structure:
{
'all': Representations for showing all attentions at the same time.
'inp_inp': Representations for showing encoder self-attentions
'inp_out': Representations for showing encoder-decoder attentions
'out_out': Representations for showing decoder self-attentions
}
and each sub-dictionary has structure:
{
'att': list of inter attentions matrices, one for each attention head
'top_text': list of strings, words to be displayed on the left of the vis
'bot_text': list of strings, words to be displayed on the right of the vis
}
"""
def get_full_attention(layer):
"""Get the full input+output - input+output attentions."""
enc_att = enc_atts[layer][0]
dec_att = dec_atts[layer][0]
encdec_att = encdec_atts[layer][0]
enc_att = np.transpose(enc_att, [0, 2, 1])
dec_att = np.transpose(dec_att, [0, 2, 1])
encdec_att = np.transpose(encdec_att, [0, 2, 1])
# [heads, query_length, memory_length]
enc_length = enc_att.shape[1]
dec_length = dec_att.shape[1]
num_heads = enc_att.shape[0]
first = np.concatenate([enc_att, encdec_att], axis=2)
second = np.concatenate(
[np.zeros((num_heads, dec_length, enc_length)), dec_att], axis=2)
full_att = np.concatenate([first, second], axis=1)
return [ha.T.tolist() for ha in full_att]
def get_inp_inp_attention(layer):
att = np.transpose(enc_atts[layer][0], (0, 2, 1))
return [ha.T.tolist() for ha in att]
def get_out_inp_attention(layer):
att = np.transpose(encdec_atts[layer][0], (0, 2, 1))
return [ha.T.tolist() for ha in att]
def get_out_out_attention(layer):
att = np.transpose(dec_atts[layer][0], (0, 2, 1))
return [ha.T.tolist() for ha in att]
def get_attentions(get_attention_fn):
num_layers = len(enc_atts)
return [get_attention_fn(i) for i in range(num_layers)]
attentions = {
'all': {
'att': get_attentions(get_full_attention),
'top_text': inp_text + out_text,
'bot_text': inp_text + out_text,
},
'inp_inp': {
'att': get_attentions(get_inp_inp_attention),
'top_text': inp_text,
'bot_text': inp_text,
},
'inp_out': {
'att': get_attentions(get_out_inp_attention),
'top_text': inp_text,
'bot_text': out_text,
},
'out_out': {
'att': get_attentions(get_out_out_attention),
'top_text': out_text,
'bot_text': out_text,
},
}
return attentions
|
[
"def",
"_get_attention",
"(",
"inp_text",
",",
"out_text",
",",
"enc_atts",
",",
"dec_atts",
",",
"encdec_atts",
")",
":",
"def",
"get_full_attention",
"(",
"layer",
")",
":",
"\"\"\"Get the full input+output - input+output attentions.\"\"\"",
"enc_att",
"=",
"enc_atts",
"[",
"layer",
"]",
"[",
"0",
"]",
"dec_att",
"=",
"dec_atts",
"[",
"layer",
"]",
"[",
"0",
"]",
"encdec_att",
"=",
"encdec_atts",
"[",
"layer",
"]",
"[",
"0",
"]",
"enc_att",
"=",
"np",
".",
"transpose",
"(",
"enc_att",
",",
"[",
"0",
",",
"2",
",",
"1",
"]",
")",
"dec_att",
"=",
"np",
".",
"transpose",
"(",
"dec_att",
",",
"[",
"0",
",",
"2",
",",
"1",
"]",
")",
"encdec_att",
"=",
"np",
".",
"transpose",
"(",
"encdec_att",
",",
"[",
"0",
",",
"2",
",",
"1",
"]",
")",
"# [heads, query_length, memory_length]",
"enc_length",
"=",
"enc_att",
".",
"shape",
"[",
"1",
"]",
"dec_length",
"=",
"dec_att",
".",
"shape",
"[",
"1",
"]",
"num_heads",
"=",
"enc_att",
".",
"shape",
"[",
"0",
"]",
"first",
"=",
"np",
".",
"concatenate",
"(",
"[",
"enc_att",
",",
"encdec_att",
"]",
",",
"axis",
"=",
"2",
")",
"second",
"=",
"np",
".",
"concatenate",
"(",
"[",
"np",
".",
"zeros",
"(",
"(",
"num_heads",
",",
"dec_length",
",",
"enc_length",
")",
")",
",",
"dec_att",
"]",
",",
"axis",
"=",
"2",
")",
"full_att",
"=",
"np",
".",
"concatenate",
"(",
"[",
"first",
",",
"second",
"]",
",",
"axis",
"=",
"1",
")",
"return",
"[",
"ha",
".",
"T",
".",
"tolist",
"(",
")",
"for",
"ha",
"in",
"full_att",
"]",
"def",
"get_inp_inp_attention",
"(",
"layer",
")",
":",
"att",
"=",
"np",
".",
"transpose",
"(",
"enc_atts",
"[",
"layer",
"]",
"[",
"0",
"]",
",",
"(",
"0",
",",
"2",
",",
"1",
")",
")",
"return",
"[",
"ha",
".",
"T",
".",
"tolist",
"(",
")",
"for",
"ha",
"in",
"att",
"]",
"def",
"get_out_inp_attention",
"(",
"layer",
")",
":",
"att",
"=",
"np",
".",
"transpose",
"(",
"encdec_atts",
"[",
"layer",
"]",
"[",
"0",
"]",
",",
"(",
"0",
",",
"2",
",",
"1",
")",
")",
"return",
"[",
"ha",
".",
"T",
".",
"tolist",
"(",
")",
"for",
"ha",
"in",
"att",
"]",
"def",
"get_out_out_attention",
"(",
"layer",
")",
":",
"att",
"=",
"np",
".",
"transpose",
"(",
"dec_atts",
"[",
"layer",
"]",
"[",
"0",
"]",
",",
"(",
"0",
",",
"2",
",",
"1",
")",
")",
"return",
"[",
"ha",
".",
"T",
".",
"tolist",
"(",
")",
"for",
"ha",
"in",
"att",
"]",
"def",
"get_attentions",
"(",
"get_attention_fn",
")",
":",
"num_layers",
"=",
"len",
"(",
"enc_atts",
")",
"return",
"[",
"get_attention_fn",
"(",
"i",
")",
"for",
"i",
"in",
"range",
"(",
"num_layers",
")",
"]",
"attentions",
"=",
"{",
"'all'",
":",
"{",
"'att'",
":",
"get_attentions",
"(",
"get_full_attention",
")",
",",
"'top_text'",
":",
"inp_text",
"+",
"out_text",
",",
"'bot_text'",
":",
"inp_text",
"+",
"out_text",
",",
"}",
",",
"'inp_inp'",
":",
"{",
"'att'",
":",
"get_attentions",
"(",
"get_inp_inp_attention",
")",
",",
"'top_text'",
":",
"inp_text",
",",
"'bot_text'",
":",
"inp_text",
",",
"}",
",",
"'inp_out'",
":",
"{",
"'att'",
":",
"get_attentions",
"(",
"get_out_inp_attention",
")",
",",
"'top_text'",
":",
"inp_text",
",",
"'bot_text'",
":",
"out_text",
",",
"}",
",",
"'out_out'",
":",
"{",
"'att'",
":",
"get_attentions",
"(",
"get_out_out_attention",
")",
",",
"'top_text'",
":",
"out_text",
",",
"'bot_text'",
":",
"out_text",
",",
"}",
",",
"}",
"return",
"attentions"
] |
Compute representation of the attention ready for the d3 visualization.
Args:
inp_text: list of strings, words to be displayed on the left of the vis
out_text: list of strings, words to be displayed on the right of the vis
enc_atts: numpy array, encoder self-attentions
[num_layers, batch_size, num_heads, enc_length, enc_length]
dec_atts: numpy array, decoder self-attentions
[num_layers, batch_size, num_heads, dec_length, dec_length]
encdec_atts: numpy array, encoder-decoder attentions
[num_layers, batch_size, num_heads, dec_length, enc_length]
Returns:
Dictionary of attention representations with the structure:
{
'all': Representations for showing all attentions at the same time.
'inp_inp': Representations for showing encoder self-attentions
'inp_out': Representations for showing encoder-decoder attentions
'out_out': Representations for showing decoder self-attentions
}
and each sub-dictionary has structure:
{
'att': list of inter attentions matrices, one for each attention head
'top_text': list of strings, words to be displayed on the left of the vis
'bot_text': list of strings, words to be displayed on the right of the vis
}
|
[
"Compute",
"representation",
"of",
"the",
"attention",
"ready",
"for",
"the",
"d3",
"visualization",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/visualization/attention.py#L78-L163
|
train
|
Compute representation of the attention ready for the d3 visualization.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5H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ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b11101 + 0o23) + '\157' + '\063' + chr(0b110001) + '\060', 16272 - 16264), ehT0Px3KOsy9('\060' + chr(0b1011010 + 0o25) + '\067' + '\067', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1011011 + 0o24) + '\061' + chr(794 - 740) + chr(0b11001 + 0o32), 28182 - 28174), ehT0Px3KOsy9('\060' + chr(7468 - 7357) + '\062' + '\x35' + chr(55), 48113 - 48105), ehT0Px3KOsy9('\060' + chr(111) + '\062' + '\x34' + '\x37', 0b1000), ehT0Px3KOsy9(chr(0b100111 + 0o11) + chr(0b1101111) + '\061' + chr(0b1010 + 0o52) + chr(1855 - 1807), 0b1000), ehT0Px3KOsy9(chr(414 - 366) + chr(111) + '\x31' + chr(0b110101) + chr(290 - 239), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\063' + '\062' + chr(0b10110 + 0o41), 0b1000), ehT0Px3KOsy9(chr(1306 - 1258) + chr(792 - 681) + '\x31' + chr(0b1010 + 0o54) + '\x37', 44401 - 44393), ehT0Px3KOsy9(chr(0b100111 + 0o11) + chr(111) + '\066', 0b1000), ehT0Px3KOsy9('\060' + chr(8010 - 7899) + '\x31' + '\066' + chr(0b100010 + 0o20), 30939 - 30931), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x32' + chr(1725 - 1676) + chr(48), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x31' + '\x33' + chr(51), 7712 - 7704), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x31' + '\062' + '\060', 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + '\061' + chr(75 - 27) + chr(0b1010 + 0o54), 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b1011 + 0o51) + chr(1508 - 1458), 54091 - 54083), ehT0Px3KOsy9(chr(0b100101 + 0o13) + '\157' + chr(0b1101 + 0o45) + '\066', ord("\x08")), ehT0Px3KOsy9(chr(0b101001 + 0o7) + '\x6f' + chr(0b110 + 0o54) + chr(1846 - 1797) + chr(0b11 + 0o63), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b111110 + 0o61) + chr(0b110001) + '\x31' + '\x36', 672 - 664), ehT0Px3KOsy9(chr(1707 - 1659) + '\157' + chr(0b11000 + 0o32) + chr(0b110110), 8), ehT0Px3KOsy9('\x30' + chr(111) + chr(936 - 886) + '\062' + '\x31', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110110) + chr(880 - 830), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\061' + '\x37' + '\060', 0o10), ehT0Px3KOsy9('\x30' + chr(8909 - 8798) + chr(1814 - 1765) + '\x36' + chr(0b100011 + 0o20), 8), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(52) + '\x37', 25292 - 25284), ehT0Px3KOsy9(chr(48) + '\x6f' + '\066' + chr(0b10110 + 0o34), 8), ehT0Px3KOsy9(chr(0b101011 + 0o5) + '\157' + chr(0b10011 + 0o40) + '\064' + chr(54), 0b1000), ehT0Px3KOsy9(chr(0b1000 + 0o50) + chr(0b1011 + 0o144) + '\x33' + chr(0b101010 + 0o6), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + '\066', 8), ehT0Px3KOsy9('\060' + chr(11237 - 11126) + '\062' + chr(0b110001 + 0o1) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(257 - 209) + '\x6f' + chr(0b100001 + 0o21) + '\063' + '\x36', 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(595 - 544) + chr(0b11 + 0o61) + chr(911 - 859), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b11 + 0o154) + chr(50) + '\x30' + chr(0b1000 + 0o55), 19333 - 19325), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(51) + chr(1463 - 1411) + '\066', 8), ehT0Px3KOsy9(chr(0b101010 + 0o6) + '\x6f' + chr(0b101010 + 0o10) + chr(0b110000) + '\x32', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1000111 + 0o50) + chr(778 - 729) + chr(0b1110 + 0o43) + '\x31', 0o10), ehT0Px3KOsy9('\060' + chr(111) + chr(1418 - 1369) + chr(0b110100) + chr(1814 - 1759), 0b1000), ehT0Px3KOsy9(chr(0b0 + 0o60) + '\157' + chr(0b1011 + 0o47) + '\x33' + chr(0b101011 + 0o11), 3903 - 3895), ehT0Px3KOsy9('\x30' + chr(11462 - 11351) + chr(49) + '\060' + '\x35', 0o10), ehT0Px3KOsy9(chr(213 - 165) + '\157' + chr(54) + chr(0b110000), 5212 - 5204)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(1449 - 1401) + chr(0b1101111) + chr(0b10011 + 0o42) + chr(278 - 230), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xe6'), chr(0b1100100) + chr(0b1100101) + '\x63' + chr(111) + chr(0b1100100) + chr(101))('\x75' + '\x74' + '\x66' + '\x2d' + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def EYCIlr0vGufa(OkmQX1d55nvN, LrRzMH6fBfwu, YwTxVlXs3fGQ, xRXyHs5wBiFb, QGiQ5qJL9aHZ):
def WTNecHkyF0si(wgamNHppspXj):
xeGPQvD4b2OS = YwTxVlXs3fGQ[wgamNHppspXj][ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110000), 57418 - 57410)]
ETaRpCvQ5ehg = xRXyHs5wBiFb[wgamNHppspXj][ehT0Px3KOsy9(chr(0b110000) + chr(3651 - 3540) + chr(1780 - 1732), 8)]
T7PXcIi5InTJ = QGiQ5qJL9aHZ[wgamNHppspXj][ehT0Px3KOsy9(chr(48) + chr(111) + chr(1111 - 1063), 8)]
xeGPQvD4b2OS = WqUC3KWvYVup.transpose(xeGPQvD4b2OS, [ehT0Px3KOsy9(chr(528 - 480) + '\x6f' + chr(0b110000), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b110010), 39415 - 39407), ehT0Px3KOsy9('\060' + chr(0b1010 + 0o145) + chr(49), 0o10)])
ETaRpCvQ5ehg = WqUC3KWvYVup.transpose(ETaRpCvQ5ehg, [ehT0Px3KOsy9(chr(2027 - 1979) + chr(111) + chr(0b111 + 0o51), 8), ehT0Px3KOsy9(chr(0b100100 + 0o14) + chr(111) + chr(1415 - 1365), 8), ehT0Px3KOsy9(chr(0b111 + 0o51) + '\157' + chr(0b110001), 8)])
T7PXcIi5InTJ = WqUC3KWvYVup.transpose(T7PXcIi5InTJ, [ehT0Px3KOsy9(chr(0b110000) + '\157' + '\060', 8), ehT0Px3KOsy9(chr(0b1011 + 0o45) + '\157' + chr(50), 8), ehT0Px3KOsy9(chr(48) + chr(111) + chr(2104 - 2055), 8)])
kqFymqPpZHvw = xeGPQvD4b2OS.nauYfLglTpcb[ehT0Px3KOsy9('\x30' + chr(11806 - 11695) + chr(1819 - 1770), 8)]
_EarQ_mERXW_ = ETaRpCvQ5ehg.nauYfLglTpcb[ehT0Px3KOsy9(chr(48) + chr(0b11101 + 0o122) + chr(0b110001), 8)]
vRVqPOZ1hUG7 = xeGPQvD4b2OS.nauYfLglTpcb[ehT0Px3KOsy9(chr(0b110000) + chr(9473 - 9362) + chr(1817 - 1769), 8)]
It1LJs8swHZQ = WqUC3KWvYVup.concatenate([xeGPQvD4b2OS, T7PXcIi5InTJ], axis=ehT0Px3KOsy9(chr(719 - 671) + chr(8790 - 8679) + '\x32', 8))
KfcW3uWMQcng = WqUC3KWvYVup.concatenate([WqUC3KWvYVup.zeros((vRVqPOZ1hUG7, _EarQ_mERXW_, kqFymqPpZHvw)), ETaRpCvQ5ehg], axis=ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110010), 8))
A2GwdEQMU25I = WqUC3KWvYVup.concatenate([It1LJs8swHZQ, KfcW3uWMQcng], axis=ehT0Px3KOsy9(chr(558 - 510) + chr(0b110001 + 0o76) + chr(0b11111 + 0o22), 8))
return [xafqLlk3kkUe(ZYEH5tlRAg9i.T, xafqLlk3kkUe(SXOLrMavuUCe(b'\xbcP\x1f\xc6\xd4\x14'), '\144' + chr(101) + chr(99) + chr(0b101110 + 0o101) + '\x64' + chr(0b1100101))('\165' + chr(2532 - 2416) + chr(4402 - 4300) + chr(0b101101) + chr(0b100100 + 0o24)))() for ZYEH5tlRAg9i in A2GwdEQMU25I]
def R9QfkLdWrtdP(wgamNHppspXj):
eqU8vkFje5tV = WqUC3KWvYVup.transpose(YwTxVlXs3fGQ[wgamNHppspXj][ehT0Px3KOsy9('\x30' + chr(0b11011 + 0o124) + '\060', 8)], (ehT0Px3KOsy9('\060' + '\157' + chr(48), 8), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(2088 - 2038), 8), ehT0Px3KOsy9('\060' + chr(11651 - 11540) + chr(0b11010 + 0o27), 8)))
return [xafqLlk3kkUe(ZYEH5tlRAg9i.T, xafqLlk3kkUe(SXOLrMavuUCe(b'\xbcP\x1f\xc6\xd4\x14'), chr(100) + chr(1602 - 1501) + chr(0b1100011) + chr(11415 - 11304) + chr(100) + chr(0b1100101))(chr(464 - 347) + '\164' + '\x66' + chr(0b100 + 0o51) + '\x38'))() for ZYEH5tlRAg9i in eqU8vkFje5tV]
def V7r_Wd8DPCD1(wgamNHppspXj):
eqU8vkFje5tV = WqUC3KWvYVup.transpose(QGiQ5qJL9aHZ[wgamNHppspXj][ehT0Px3KOsy9('\060' + '\157' + chr(48), 8)], (ehT0Px3KOsy9(chr(479 - 431) + chr(0b100110 + 0o111) + chr(0b110000), 8), ehT0Px3KOsy9(chr(0b101010 + 0o6) + chr(0b1101111) + '\062', 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\061', 8)))
return [xafqLlk3kkUe(ZYEH5tlRAg9i.T, xafqLlk3kkUe(SXOLrMavuUCe(b'\xbcP\x1f\xc6\xd4\x14'), '\144' + '\x65' + '\143' + chr(111) + chr(0b11011 + 0o111) + chr(0b1010000 + 0o25))(chr(3413 - 3296) + chr(4918 - 4802) + chr(102) + chr(0b101000 + 0o5) + chr(2370 - 2314)))() for ZYEH5tlRAg9i in eqU8vkFje5tV]
def FJlI4oIHHLmr(wgamNHppspXj):
eqU8vkFje5tV = WqUC3KWvYVup.transpose(xRXyHs5wBiFb[wgamNHppspXj][ehT0Px3KOsy9(chr(1738 - 1690) + '\x6f' + chr(1595 - 1547), 8)], (ehT0Px3KOsy9(chr(803 - 755) + chr(111) + chr(0b110000), 8), ehT0Px3KOsy9(chr(48) + chr(9805 - 9694) + chr(50), 8), ehT0Px3KOsy9(chr(200 - 152) + chr(0b110000 + 0o77) + '\x31', 8)))
return [xafqLlk3kkUe(ZYEH5tlRAg9i.T, xafqLlk3kkUe(SXOLrMavuUCe(b'\xbcP\x1f\xc6\xd4\x14'), chr(0b1100100) + '\145' + chr(99) + '\157' + chr(0b1010110 + 0o16) + '\145')(chr(117) + chr(0b1110100) + chr(102) + chr(45) + chr(0b10010 + 0o46)))() for ZYEH5tlRAg9i in eqU8vkFje5tV]
def XmtDid7xFH5m(Dqbmn3nwz4eB):
uftkTXJyNORO = c2A0yzQpDQB3(YwTxVlXs3fGQ)
return [Dqbmn3nwz4eB(WVxHKyX45z_L) for WVxHKyX45z_L in vQr8gNKaIaWE(uftkTXJyNORO)]
sA5m7Mb7Zoum = {xafqLlk3kkUe(SXOLrMavuUCe(b'\xa9S\x1f'), '\144' + '\145' + chr(6190 - 6091) + chr(111) + chr(100) + chr(0b1011011 + 0o12))(chr(117) + chr(116) + chr(0b1100110) + chr(0b100001 + 0o14) + chr(0b111000)): {xafqLlk3kkUe(SXOLrMavuUCe(b'\xa9K\x07'), chr(9036 - 8936) + chr(0b1100101) + chr(99) + chr(0b111011 + 0o64) + chr(100) + chr(0b1011100 + 0o11))(chr(117) + '\x74' + chr(2064 - 1962) + '\055' + chr(0b11101 + 0o33)): XmtDid7xFH5m(WTNecHkyF0si), xafqLlk3kkUe(SXOLrMavuUCe(b'\xbcP\x03\xf0\xd3\x05\x13\xa3'), '\144' + '\145' + chr(99) + chr(7826 - 7715) + chr(0b1100100) + chr(4616 - 4515))(chr(8571 - 8454) + chr(0b1110100) + '\146' + '\055' + chr(0b111000)): OkmQX1d55nvN + LrRzMH6fBfwu, xafqLlk3kkUe(SXOLrMavuUCe(b'\xaaP\x07\xf0\xd3\x05\x13\xa3'), chr(0b1110 + 0o126) + chr(101) + '\x63' + chr(0b100111 + 0o110) + chr(2406 - 2306) + '\145')(chr(10904 - 10787) + '\x74' + chr(0b1100000 + 0o6) + chr(45) + '\x38'): OkmQX1d55nvN + LrRzMH6fBfwu}, xafqLlk3kkUe(SXOLrMavuUCe(b'\xa1Q\x03\xf0\xce\x0e\x1b'), chr(100) + chr(4618 - 4517) + '\143' + chr(111) + '\x64' + chr(0b1000001 + 0o44))('\x75' + chr(0b1110100) + '\x66' + chr(0b101101 + 0o0) + '\x38'): {xafqLlk3kkUe(SXOLrMavuUCe(b'\xa9K\x07'), chr(0b1100100) + chr(997 - 896) + chr(0b1100011) + '\157' + chr(0b1100100) + chr(0b1100101))(chr(117) + '\x74' + chr(102) + chr(0b101101) + chr(0b11101 + 0o33)): XmtDid7xFH5m(R9QfkLdWrtdP), xafqLlk3kkUe(SXOLrMavuUCe(b'\xbcP\x03\xf0\xd3\x05\x13\xa3'), '\x64' + chr(0b1100101) + chr(99) + chr(0b1101111) + '\x64' + '\145')(chr(0b1110101) + chr(0b1010011 + 0o41) + chr(0b1100110) + chr(1756 - 1711) + '\x38'): OkmQX1d55nvN, xafqLlk3kkUe(SXOLrMavuUCe(b'\xaaP\x07\xf0\xd3\x05\x13\xa3'), '\x64' + chr(101) + '\x63' + '\157' + '\x64' + chr(101))(chr(0b1110101) + chr(116) + chr(0b1100110) + chr(0b101101) + chr(3021 - 2965)): OkmQX1d55nvN}, xafqLlk3kkUe(SXOLrMavuUCe(b'\xa1Q\x03\xf0\xc8\x15\x1f'), chr(6067 - 5967) + '\145' + '\143' + '\x6f' + '\x64' + '\145')(chr(13168 - 13051) + '\x74' + chr(0b110 + 0o140) + '\055' + chr(0b11100 + 0o34)): {xafqLlk3kkUe(SXOLrMavuUCe(b'\xa9K\x07'), chr(2974 - 2874) + '\145' + chr(7194 - 7095) + chr(0b1101111) + chr(100) + '\x65')(chr(0b1100010 + 0o23) + chr(0b10100 + 0o140) + chr(0b1100110) + '\055' + '\070'): XmtDid7xFH5m(V7r_Wd8DPCD1), xafqLlk3kkUe(SXOLrMavuUCe(b'\xbcP\x03\xf0\xd3\x05\x13\xa3'), chr(100) + chr(3666 - 3565) + '\x63' + chr(111) + chr(0b1100100) + chr(1395 - 1294))(chr(13247 - 13130) + chr(0b1110100) + '\146' + chr(1149 - 1104) + chr(0b111000)): OkmQX1d55nvN, xafqLlk3kkUe(SXOLrMavuUCe(b'\xaaP\x07\xf0\xd3\x05\x13\xa3'), chr(0b111110 + 0o46) + '\x65' + chr(0b1011110 + 0o5) + chr(0b1101111) + '\x64' + chr(0b1100101))(chr(9095 - 8978) + '\164' + chr(102) + chr(490 - 445) + chr(2096 - 2040)): LrRzMH6fBfwu}, xafqLlk3kkUe(SXOLrMavuUCe(b'\xa7J\x07\xf0\xc8\x15\x1f'), chr(100) + '\x65' + chr(0b1000000 + 0o43) + chr(111) + chr(7983 - 7883) + chr(0b111010 + 0o53))('\x75' + chr(0b1110100) + chr(4282 - 4180) + chr(0b101000 + 0o5) + chr(56)): {xafqLlk3kkUe(SXOLrMavuUCe(b'\xa9K\x07'), chr(100) + chr(3844 - 3743) + '\x63' + chr(0b1001011 + 0o44) + chr(100) + chr(101))(chr(8086 - 7969) + chr(0b1110100) + chr(0b1011111 + 0o7) + chr(0b10011 + 0o32) + '\x38'): XmtDid7xFH5m(FJlI4oIHHLmr), xafqLlk3kkUe(SXOLrMavuUCe(b'\xbcP\x03\xf0\xd3\x05\x13\xa3'), chr(6122 - 6022) + '\x65' + '\143' + chr(0b1101111) + chr(9517 - 9417) + chr(0b1100101))(chr(0b1110101) + chr(116) + chr(0b1100110 + 0o0) + '\055' + '\070'): LrRzMH6fBfwu, xafqLlk3kkUe(SXOLrMavuUCe(b'\xaaP\x07\xf0\xd3\x05\x13\xa3'), chr(100) + chr(101) + chr(99) + chr(111) + chr(0b101 + 0o137) + '\145')(chr(117) + chr(0b1110100) + chr(0b1100110) + chr(0b1111 + 0o36) + chr(1427 - 1371)): LrRzMH6fBfwu}}
return sA5m7Mb7Zoum
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/tokenizer.py
|
decode
|
def decode(tokens):
"""Decode a list of tokens to a unicode string.
Args:
tokens: a list of Unicode strings
Returns:
a unicode string
"""
token_is_alnum = [t[0] in _ALPHANUMERIC_CHAR_SET for t in tokens]
ret = []
for i, token in enumerate(tokens):
if i > 0 and token_is_alnum[i - 1] and token_is_alnum[i]:
ret.append(u" ")
ret.append(token)
return "".join(ret)
|
python
|
def decode(tokens):
"""Decode a list of tokens to a unicode string.
Args:
tokens: a list of Unicode strings
Returns:
a unicode string
"""
token_is_alnum = [t[0] in _ALPHANUMERIC_CHAR_SET for t in tokens]
ret = []
for i, token in enumerate(tokens):
if i > 0 and token_is_alnum[i - 1] and token_is_alnum[i]:
ret.append(u" ")
ret.append(token)
return "".join(ret)
|
[
"def",
"decode",
"(",
"tokens",
")",
":",
"token_is_alnum",
"=",
"[",
"t",
"[",
"0",
"]",
"in",
"_ALPHANUMERIC_CHAR_SET",
"for",
"t",
"in",
"tokens",
"]",
"ret",
"=",
"[",
"]",
"for",
"i",
",",
"token",
"in",
"enumerate",
"(",
"tokens",
")",
":",
"if",
"i",
">",
"0",
"and",
"token_is_alnum",
"[",
"i",
"-",
"1",
"]",
"and",
"token_is_alnum",
"[",
"i",
"]",
":",
"ret",
".",
"append",
"(",
"u\" \"",
")",
"ret",
".",
"append",
"(",
"token",
")",
"return",
"\"\"",
".",
"join",
"(",
"ret",
")"
] |
Decode a list of tokens to a unicode string.
Args:
tokens: a list of Unicode strings
Returns:
a unicode string
|
[
"Decode",
"a",
"list",
"of",
"tokens",
"to",
"a",
"unicode",
"string",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/tokenizer.py#L91-L105
|
train
|
Decode a list of tokens to a unicode string.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X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kZOtyh,Cf_Qef15s3_F,eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(11175 - 11064) + chr(0b110011) + chr(0b1110 + 0o44) + chr(51), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(780 - 669) + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(1281 - 1232) + '\063' + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(3128 - 3017) + chr(50) + chr(2716 - 2662) + chr(0b110011), 25792 - 25784), ehT0Px3KOsy9('\x30' + '\x6f' + chr(2528 - 2477) + chr(759 - 711), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(0b110011) + '\x32' + chr(49), 1040 - 1032), ehT0Px3KOsy9(chr(48) + chr(4753 - 4642) + chr(49) + chr(325 - 275) + '\x30', 0b1000), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(111) + chr(0b110010) + chr(50) + '\060', 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110001) + '\x33' + chr(0b10011 + 0o44), 4603 - 4595), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(0b111011 + 0o64) + chr(0b101100 + 0o6) + chr(51) + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(0b101001 + 0o7) + '\157' + chr(999 - 945) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(2215 - 2165) + chr(0b110110) + chr(49), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1001101 + 0o42) + '\062' + chr(54) + chr(1632 - 1583), 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(49) + chr(345 - 296) + chr(0b110100), 1858 - 1850), ehT0Px3KOsy9(chr(1322 - 1274) + chr(0b110010 + 0o75) + '\061' + chr(0b110101) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b100001 + 0o21) + chr(0b110010) + '\061', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(2466 - 2415) + chr(0b100010 + 0o24) + chr(1995 - 1945), 33545 - 33537), ehT0Px3KOsy9(chr(1782 - 1734) + chr(1816 - 1705) + chr(50) + chr(0b100 + 0o56) + chr(48), 8), ehT0Px3KOsy9(chr(0b110000) + chr(0b1001 + 0o146) + chr(950 - 899) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(49) + chr(0b10 + 0o64), 0o10), ehT0Px3KOsy9(chr(1895 - 1847) + '\157' + chr(0b10101 + 0o35) + chr(0b110100) + chr(53), 0o10), ehT0Px3KOsy9('\060' + chr(0b11011 + 0o124) + chr(51) + chr(1825 - 1771) + chr(68 - 19), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b10011 + 0o41) + '\062', ord("\x08")), ehT0Px3KOsy9(chr(0b101011 + 0o5) + chr(10426 - 10315) + chr(940 - 890) + chr(49) + '\062', 0o10), ehT0Px3KOsy9('\x30' + chr(9668 - 9557) + chr(543 - 494) + chr(0b10010 + 0o44) + '\066', 9229 - 9221), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(670 - 619) + chr(0b110101) + chr(0b10010 + 0o41), 18360 - 18352), ehT0Px3KOsy9(chr(0b110000) + chr(1806 - 1695) + '\x32' + '\064' + '\066', 0b1000), ehT0Px3KOsy9(chr(967 - 919) + chr(0b101010 + 0o105) + '\061' + chr(51) + chr(51), 0b1000), ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(7620 - 7509) + '\061' + chr(55) + chr(0b10010 + 0o45), 0b1000), ehT0Px3KOsy9('\060' + chr(9927 - 9816) + chr(0b11101 + 0o25) + '\067' + '\060', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b100011 + 0o114) + '\x32' + '\066', 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(51) + chr(0b101101 + 0o4) + '\x37', ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(55) + chr(2337 - 2283), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x36' + '\x35', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1000001 + 0o56) + chr(0b110010) + '\065' + '\x36', 64548 - 64540), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b110000 + 0o1) + '\062' + chr(53), 0o10), ehT0Px3KOsy9(chr(1750 - 1702) + chr(111) + chr(0b100101 + 0o20) + '\061', 44956 - 44948), ehT0Px3KOsy9('\x30' + chr(111) + chr(52) + chr(0b101111 + 0o1), 1648 - 1640), ehT0Px3KOsy9(chr(1434 - 1386) + '\x6f' + '\x32' + chr(1268 - 1213) + chr(0b100000 + 0o21), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(0b110001) + '\061' + chr(49), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(258 - 210) + '\x6f' + '\065' + chr(48), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xfd'), '\x64' + chr(0b1000100 + 0o41) + '\143' + '\x6f' + chr(0b100111 + 0o75) + chr(2410 - 2309))(chr(117) + chr(10548 - 10432) + chr(102) + chr(45) + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def RSziqSuj39r9(Sz7tXxaCGqJ1):
wgCX6x15U86H = [YeT3l7JgTbWR[ehT0Px3KOsy9(chr(1533 - 1485) + chr(8293 - 8182) + '\060', ord("\x08"))] in NsQBqpdqHrT1 for YeT3l7JgTbWR in Sz7tXxaCGqJ1]
VHn4CV4Ymrei = []
for (WVxHKyX45z_L, mTy3fac_AqJ5) in YlkZvXL8qwsX(Sz7tXxaCGqJ1):
if WVxHKyX45z_L > ehT0Px3KOsy9(chr(110 - 62) + chr(111) + chr(48), 8) and wgCX6x15U86H[WVxHKyX45z_L - ehT0Px3KOsy9('\x30' + chr(111) + chr(291 - 242), 8)] and wgCX6x15U86H[WVxHKyX45z_L]:
xafqLlk3kkUe(VHn4CV4Ymrei, xafqLlk3kkUe(SXOLrMavuUCe(b'\xb2q.\xd6v\xb5'), chr(100) + chr(0b10101 + 0o120) + chr(0b1100011) + '\157' + '\144' + chr(101))(chr(0b1010100 + 0o41) + chr(0b1010001 + 0o43) + chr(6237 - 6135) + '\x2d' + '\x38'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xf3'), chr(0b110101 + 0o57) + chr(0b1100101) + chr(8811 - 8712) + chr(0b1101111) + '\144' + chr(0b1100101))(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + chr(874 - 829) + chr(56)))
xafqLlk3kkUe(VHn4CV4Ymrei, xafqLlk3kkUe(SXOLrMavuUCe(b'\xb2q.\xd6v\xb5'), chr(100) + chr(2332 - 2231) + chr(99) + chr(9295 - 9184) + '\x64' + chr(101))(chr(0b1100101 + 0o20) + chr(13303 - 13187) + chr(0b1000100 + 0o42) + chr(1652 - 1607) + chr(410 - 354)))(mTy3fac_AqJ5)
return xafqLlk3kkUe(xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(0b111101 + 0o47) + '\x65' + chr(0b1100011) + '\157' + '\144' + chr(5350 - 5249))(chr(3940 - 3823) + chr(0b100110 + 0o116) + '\146' + chr(0b0 + 0o55) + chr(0b111000)), xafqLlk3kkUe(SXOLrMavuUCe(b'\xb9n7\xdd'), chr(100) + '\145' + chr(696 - 597) + '\x6f' + '\x64' + chr(0b1100101))('\x75' + '\x74' + chr(102) + chr(0b101101) + '\x38'))(VHn4CV4Ymrei)
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/tokenizer.py
|
_read_filepattern
|
def _read_filepattern(filepattern, max_lines=None, split_on_newlines=True):
"""Reads files matching a wildcard pattern, yielding the contents.
Args:
filepattern: A wildcard pattern matching one or more files.
max_lines: If set, stop reading after reading this many lines.
split_on_newlines: A boolean. If true, then split files by lines and strip
leading and trailing whitespace from each line. Otherwise, treat each
file as a single string.
Yields:
The contents of the files as lines, if split_on_newlines is True, or
the entire contents of each file if False.
"""
filenames = sorted(tf.gfile.Glob(filepattern))
lines_read = 0
for filename in filenames:
with tf.gfile.Open(filename) as f:
if split_on_newlines:
for line in f:
yield line.strip()
lines_read += 1
if max_lines and lines_read >= max_lines:
return
else:
if max_lines:
doc = []
for line in f:
doc.append(line)
lines_read += 1
if max_lines and lines_read >= max_lines:
yield "".join(doc)
return
yield "".join(doc)
else:
yield f.read()
|
python
|
def _read_filepattern(filepattern, max_lines=None, split_on_newlines=True):
"""Reads files matching a wildcard pattern, yielding the contents.
Args:
filepattern: A wildcard pattern matching one or more files.
max_lines: If set, stop reading after reading this many lines.
split_on_newlines: A boolean. If true, then split files by lines and strip
leading and trailing whitespace from each line. Otherwise, treat each
file as a single string.
Yields:
The contents of the files as lines, if split_on_newlines is True, or
the entire contents of each file if False.
"""
filenames = sorted(tf.gfile.Glob(filepattern))
lines_read = 0
for filename in filenames:
with tf.gfile.Open(filename) as f:
if split_on_newlines:
for line in f:
yield line.strip()
lines_read += 1
if max_lines and lines_read >= max_lines:
return
else:
if max_lines:
doc = []
for line in f:
doc.append(line)
lines_read += 1
if max_lines and lines_read >= max_lines:
yield "".join(doc)
return
yield "".join(doc)
else:
yield f.read()
|
[
"def",
"_read_filepattern",
"(",
"filepattern",
",",
"max_lines",
"=",
"None",
",",
"split_on_newlines",
"=",
"True",
")",
":",
"filenames",
"=",
"sorted",
"(",
"tf",
".",
"gfile",
".",
"Glob",
"(",
"filepattern",
")",
")",
"lines_read",
"=",
"0",
"for",
"filename",
"in",
"filenames",
":",
"with",
"tf",
".",
"gfile",
".",
"Open",
"(",
"filename",
")",
"as",
"f",
":",
"if",
"split_on_newlines",
":",
"for",
"line",
"in",
"f",
":",
"yield",
"line",
".",
"strip",
"(",
")",
"lines_read",
"+=",
"1",
"if",
"max_lines",
"and",
"lines_read",
">=",
"max_lines",
":",
"return",
"else",
":",
"if",
"max_lines",
":",
"doc",
"=",
"[",
"]",
"for",
"line",
"in",
"f",
":",
"doc",
".",
"append",
"(",
"line",
")",
"lines_read",
"+=",
"1",
"if",
"max_lines",
"and",
"lines_read",
">=",
"max_lines",
":",
"yield",
"\"\"",
".",
"join",
"(",
"doc",
")",
"return",
"yield",
"\"\"",
".",
"join",
"(",
"doc",
")",
"else",
":",
"yield",
"f",
".",
"read",
"(",
")"
] |
Reads files matching a wildcard pattern, yielding the contents.
Args:
filepattern: A wildcard pattern matching one or more files.
max_lines: If set, stop reading after reading this many lines.
split_on_newlines: A boolean. If true, then split files by lines and strip
leading and trailing whitespace from each line. Otherwise, treat each
file as a single string.
Yields:
The contents of the files as lines, if split_on_newlines is True, or
the entire contents of each file if False.
|
[
"Reads",
"files",
"matching",
"a",
"wildcard",
"pattern",
"yielding",
"the",
"contents",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/tokenizer.py#L108-L145
|
train
|
Reads files matching a wildcard pattern yielding the contents.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_bikzMuRfbJG,sznFqDbNB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0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(308 - 197) + chr(0b110010) + '\x35' + chr(916 - 866), 12272 - 12264), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b100101 + 0o21) + '\064', 0o10), ehT0Px3KOsy9('\060' + chr(663 - 552) + chr(49) + '\067' + chr(546 - 496), 0o10), ehT0Px3KOsy9(chr(1777 - 1729) + '\157' + '\x31' + chr(1419 - 1371) + chr(0b1110 + 0o46), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(50) + chr(49) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(2884 - 2773) + chr(0b110011) + '\064' + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(1829 - 1781) + '\157' + chr(0b110011) + chr(549 - 497), 0b1000), ehT0Px3KOsy9(chr(0b10001 + 0o37) + chr(9688 - 9577) + chr(50) + chr(0b110110) + chr(0b110001 + 0o4), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b11 + 0o60) + '\067' + chr(2385 - 2331), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(1378 - 1329) + chr(0b110111) + '\x33', 0b1000), ehT0Px3KOsy9(chr(0b1000 + 0o50) + chr(0b1101111) + chr(0b0 + 0o62) + chr(0b110011 + 0o1) + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(1716 - 1605) + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(0b11000 + 0o30) + '\x6f' + '\063' + chr(0b0 + 0o65) + '\065', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x31' + '\064' + chr(49), ord("\x08")), ehT0Px3KOsy9('\060' + '\157' + chr(0b1000 + 0o51) + '\x30' + chr(1096 - 1042), 0b1000), ehT0Px3KOsy9(chr(0b101 + 0o53) + '\x6f' + '\x32' + chr(49) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(821 - 772) + chr(3011 - 2956) + chr(0b101000 + 0o11), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + '\061' + chr(2154 - 2104) + chr(50), 0b1000), ehT0Px3KOsy9('\060' + chr(111) + chr(0b110010) + chr(0b100101 + 0o17) + chr(2197 - 2143), 35690 - 35682), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b101000 + 0o12) + chr(0b101100 + 0o7) + '\x33', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\063' + '\x35' + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(253 - 205) + '\157' + chr(1621 - 1570) + chr(53) + chr(0b10 + 0o63), 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(1414 - 1360) + '\067', 56559 - 56551), ehT0Px3KOsy9('\060' + chr(9966 - 9855) + chr(51) + chr(51) + chr(48), 0b1000), ehT0Px3KOsy9(chr(48) + chr(5459 - 5348) + chr(0b110001) + chr(0b110100) + chr(0b110110), 44103 - 44095), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x32' + '\066' + chr(49), 18988 - 18980), ehT0Px3KOsy9('\060' + '\157' + chr(0b110010) + chr(0b100100 + 0o20) + chr(54), 8), ehT0Px3KOsy9(chr(508 - 460) + chr(0b1101100 + 0o3) + chr(1054 - 1001) + chr(49), 0b1000), ehT0Px3KOsy9(chr(673 - 625) + chr(0b1101111) + '\061' + chr(1870 - 1820) + '\x35', ord("\x08")), ehT0Px3KOsy9(chr(1089 - 1041) + '\157' + '\x31', 24020 - 24012), ehT0Px3KOsy9(chr(0b110000) + chr(0b111 + 0o150) + chr(0b10000 + 0o42) + chr(55) + chr(1116 - 1064), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101000 + 0o7) + chr(49) + chr(0b100000 + 0o26) + '\x30', 0o10), ehT0Px3KOsy9(chr(0b10010 + 0o36) + '\157' + chr(2436 - 2386) + chr(52) + chr(0b101000 + 0o11), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\061' + '\067' + chr(0b110111), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b0 + 0o63) + chr(1221 - 1167) + chr(55), 4222 - 4214), ehT0Px3KOsy9(chr(48) + '\x6f' + '\061' + chr(52), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(49) + chr(0b101100 + 0o5) + chr(991 - 941), ord("\x08")), ehT0Px3KOsy9(chr(0b10110 + 0o32) + '\x6f' + chr(0b11 + 0o60) + chr(0b101110 + 0o6) + '\066', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b1101 + 0o46) + chr(48), 28992 - 28984), ehT0Px3KOsy9(chr(0b1110 + 0o42) + chr(111) + chr(361 - 312) + chr(0b110000 + 0o6) + chr(0b11001 + 0o32), 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + chr(111) + '\065' + '\060', 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x84'), '\144' + chr(101) + '\x63' + chr(0b1011001 + 0o26) + chr(100) + chr(0b1100101))(chr(0b1101 + 0o150) + '\x74' + chr(2744 - 2642) + chr(0b101101) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def Q3geYgYGmfP7(mnAeTPQPQgT_, JasJv8KXVjRc=None, ZJfXltPmKAt1=ehT0Px3KOsy9(chr(48) + chr(0b10101 + 0o132) + chr(0b110001), 8)):
Xs6zu3BFE2Ws = vUlqIvNSaRMa(IDJ2eXGCBCDu.gfile.Glob(mnAeTPQPQgT_))
useeXVUbrTe1 = ehT0Px3KOsy9(chr(0b100100 + 0o14) + chr(2476 - 2365) + chr(0b110000), ord("\x08"))
for xw4DsBfIJ22E in Xs6zu3BFE2Ws:
with xafqLlk3kkUe(IDJ2eXGCBCDu.gfile, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe5D\x1f*'), chr(5779 - 5679) + '\145' + chr(99) + chr(0b1001111 + 0o40) + chr(0b1100100) + chr(0b101010 + 0o73))(chr(117) + chr(116) + chr(102) + chr(45) + '\070'))(xw4DsBfIJ22E) as EGyt1xfPT1P6:
if ZJfXltPmKAt1:
for LycYkDpyelF6 in EGyt1xfPT1P6:
yield xafqLlk3kkUe(LycYkDpyelF6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd9@\x08-\xfe'), chr(0b1100100) + chr(0b10001 + 0o124) + chr(0b1100011) + '\157' + chr(100) + '\x65')('\165' + '\x74' + chr(4898 - 4796) + chr(133 - 88) + chr(56)))()
useeXVUbrTe1 += ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(49), 8)
if JasJv8KXVjRc and useeXVUbrTe1 >= JasJv8KXVjRc:
return
elif JasJv8KXVjRc:
JCpEgna6NeKD = []
for LycYkDpyelF6 in EGyt1xfPT1P6:
xafqLlk3kkUe(JCpEgna6NeKD, xafqLlk3kkUe(SXOLrMavuUCe(b'\xcbD\n!\xe0\x81'), '\x64' + chr(101) + chr(0b1100011) + '\157' + chr(0b100011 + 0o101) + chr(0b1100101))(chr(0b11011 + 0o132) + chr(0b1110100) + chr(0b100 + 0o142) + '\055' + chr(610 - 554)))(LycYkDpyelF6)
useeXVUbrTe1 += ehT0Px3KOsy9('\060' + chr(111) + chr(0b110001), 8)
if JasJv8KXVjRc and useeXVUbrTe1 >= JasJv8KXVjRc:
yield xafqLlk3kkUe(xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(0b1100011 + 0o1) + chr(101) + chr(0b1001011 + 0o30) + '\x6f' + chr(0b101101 + 0o67) + '\145')('\165' + '\x74' + '\x66' + chr(45) + chr(0b110010 + 0o6)), xafqLlk3kkUe(SXOLrMavuUCe(b'\xc0[\x13*'), chr(0b1001100 + 0o30) + '\145' + chr(0b1100011) + chr(0b1101111) + chr(0b1100100) + chr(0b1100101))('\165' + '\x74' + chr(0b1100110) + '\x2d' + '\070'))(JCpEgna6NeKD)
return
yield xafqLlk3kkUe(xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(100) + '\x65' + chr(99) + '\x6f' + chr(0b110001 + 0o63) + chr(101))(chr(117) + '\x74' + '\x66' + chr(631 - 586) + chr(0b111000)), xafqLlk3kkUe(SXOLrMavuUCe(b'\xc0[\x13*'), chr(6749 - 6649) + '\x65' + chr(0b1100011) + chr(9162 - 9051) + '\144' + '\x65')(chr(0b10010 + 0o143) + chr(0b110011 + 0o101) + '\x66' + chr(646 - 601) + '\070'))(JCpEgna6NeKD)
else:
yield xafqLlk3kkUe(EGyt1xfPT1P6, xafqLlk3kkUe(SXOLrMavuUCe(b'\xff\x027-\xd9\x97t\xc0\xbd\x12\x90\\'), chr(0b1000110 + 0o36) + chr(0b1100101) + chr(99) + chr(7295 - 7184) + chr(3813 - 3713) + chr(7080 - 6979))(chr(0b1110101) + chr(0b1011110 + 0o26) + '\146' + chr(0b11001 + 0o24) + '\x38'))()
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/tokenizer.py
|
corpus_token_counts
|
def corpus_token_counts(
text_filepattern, corpus_max_lines, split_on_newlines=True):
"""Read the corpus and compute a dictionary of token counts.
Args:
text_filepattern: A pattern matching one or more files.
corpus_max_lines: An integer; maximum total lines to read.
split_on_newlines: A boolean. If true, then split files by lines and strip
leading and trailing whitespace from each line. Otherwise, treat each
file as a single string.
Returns:
a dictionary mapping token to count.
"""
counts = collections.Counter()
for doc in _read_filepattern(
text_filepattern,
max_lines=corpus_max_lines,
split_on_newlines=split_on_newlines):
counts.update(encode(_native_to_unicode(doc)))
mlperf_log.transformer_print(
key=mlperf_log.PREPROC_VOCAB_SIZE, value=len(counts))
return counts
|
python
|
def corpus_token_counts(
text_filepattern, corpus_max_lines, split_on_newlines=True):
"""Read the corpus and compute a dictionary of token counts.
Args:
text_filepattern: A pattern matching one or more files.
corpus_max_lines: An integer; maximum total lines to read.
split_on_newlines: A boolean. If true, then split files by lines and strip
leading and trailing whitespace from each line. Otherwise, treat each
file as a single string.
Returns:
a dictionary mapping token to count.
"""
counts = collections.Counter()
for doc in _read_filepattern(
text_filepattern,
max_lines=corpus_max_lines,
split_on_newlines=split_on_newlines):
counts.update(encode(_native_to_unicode(doc)))
mlperf_log.transformer_print(
key=mlperf_log.PREPROC_VOCAB_SIZE, value=len(counts))
return counts
|
[
"def",
"corpus_token_counts",
"(",
"text_filepattern",
",",
"corpus_max_lines",
",",
"split_on_newlines",
"=",
"True",
")",
":",
"counts",
"=",
"collections",
".",
"Counter",
"(",
")",
"for",
"doc",
"in",
"_read_filepattern",
"(",
"text_filepattern",
",",
"max_lines",
"=",
"corpus_max_lines",
",",
"split_on_newlines",
"=",
"split_on_newlines",
")",
":",
"counts",
".",
"update",
"(",
"encode",
"(",
"_native_to_unicode",
"(",
"doc",
")",
")",
")",
"mlperf_log",
".",
"transformer_print",
"(",
"key",
"=",
"mlperf_log",
".",
"PREPROC_VOCAB_SIZE",
",",
"value",
"=",
"len",
"(",
"counts",
")",
")",
"return",
"counts"
] |
Read the corpus and compute a dictionary of token counts.
Args:
text_filepattern: A pattern matching one or more files.
corpus_max_lines: An integer; maximum total lines to read.
split_on_newlines: A boolean. If true, then split files by lines and strip
leading and trailing whitespace from each line. Otherwise, treat each
file as a single string.
Returns:
a dictionary mapping token to count.
|
[
"Read",
"the",
"corpus",
"and",
"compute",
"a",
"dictionary",
"of",
"token",
"counts",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/tokenizer.py#L148-L171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AeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b11 + 0o56) + chr(1725 - 1673) + chr(448 - 397), 28087 - 28079), ehT0Px3KOsy9(chr(1236 - 1188) + chr(11016 - 10905) + '\063' + '\x35' + chr(49), 65051 - 65043), ehT0Px3KOsy9(chr(0b10010 + 0o36) + '\x6f' + '\066' + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(0b10111 + 0o31) + chr(3276 - 3165) + chr(725 - 676) + '\x34', 0b1000), ehT0Px3KOsy9(chr(328 - 280) + '\157' + chr(51) + '\x37' + chr(0b101110 + 0o7), 0b1000), ehT0Px3KOsy9(chr(1458 - 1410) + '\157' + '\x32' + '\x36' + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(0b1101111) + chr(54) + '\x33', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(49) + chr(1319 - 1270) + '\062', 10742 - 10734), ehT0Px3KOsy9(chr(1815 - 1767) + chr(0b1001001 + 0o46) + chr(0b110100) + chr(232 - 183), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + '\062' + chr(55) + '\x31', 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b101110 + 0o4) + chr(2352 - 2303) + '\x37', 52500 - 52492), ehT0Px3KOsy9(chr(48) + chr(2369 - 2258) + chr(55) + chr(2072 - 2018), 42882 - 42874), ehT0Px3KOsy9(chr(48) + '\157' + chr(50) + chr(1843 - 1788) + chr(0b10111 + 0o31), 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + '\062' + '\066' + '\x34', 20769 - 20761), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\061' + chr(0b11 + 0o61) + chr(53), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110011) + chr(299 - 251) + '\x35', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\063' + '\065' + chr(50), 13209 - 13201), ehT0Px3KOsy9(chr(364 - 316) + chr(11694 - 11583) + chr(169 - 119) + '\x33' + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(0b10010 + 0o36) + chr(0b1101111) + chr(49) + '\x34' + '\x35', 8), ehT0Px3KOsy9(chr(0b1001 + 0o47) + '\157' + '\063' + chr(0b110010), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1100011 + 0o14) + chr(0b110001) + '\066' + '\x37', 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110011) + chr(0b110011) + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110001) + chr(0b110111) + chr(0b110011), 0b1000), ehT0Px3KOsy9(chr(1731 - 1683) + chr(0b1101111) + chr(0b100111 + 0o13) + chr(0b1000 + 0o51) + '\x32', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b1011 + 0o46) + chr(0b1 + 0o64) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(0b10 + 0o56) + chr(0b1101111) + '\061' + chr(0b11111 + 0o30) + chr(509 - 457), 0o10), ehT0Px3KOsy9('\060' + chr(10898 - 10787) + chr(2278 - 2227) + '\063' + chr(0b1101 + 0o50), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x35' + '\062', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(1534 - 1484) + '\x33' + chr(0b110111), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(0b100111 + 0o13) + '\x31', 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(1910 - 1861) + '\064' + chr(0b110000), 2542 - 2534), ehT0Px3KOsy9(chr(48) + chr(0b1100101 + 0o12) + chr(0b110011) + chr(1453 - 1405) + chr(53), 8), ehT0Px3KOsy9(chr(1875 - 1827) + chr(0b1101111) + chr(0b110011) + chr(653 - 602) + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(1201 - 1153) + chr(111) + '\063' + chr(0b110000), 0o10), ehT0Px3KOsy9(chr(0b101010 + 0o6) + '\x6f' + chr(54) + '\061', ord("\x08")), ehT0Px3KOsy9('\060' + chr(12288 - 12177) + chr(0b110001) + chr(0b110100) + chr(0b110111), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110010) + chr(53) + chr(411 - 356), 0b1000), ehT0Px3KOsy9('\x30' + chr(10360 - 10249) + '\063' + '\060' + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(51) + '\060' + '\060', 8), ehT0Px3KOsy9(chr(738 - 690) + chr(10050 - 9939) + '\063' + chr(126 - 75) + '\062', 8)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + '\x6f' + chr(449 - 396) + chr(0b11100 + 0o24), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'M'), '\x64' + '\145' + '\x63' + chr(0b1011110 + 0o21) + '\x64' + chr(101))(chr(0b11 + 0o162) + '\164' + chr(0b1100110) + chr(45) + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def vvCbsevwTte0(VClZe2GK94na, j7uiafn_rmEj, ZJfXltPmKAt1=ehT0Px3KOsy9('\060' + chr(0b101000 + 0o107) + chr(49), 46973 - 46965)):
qaIx4JIwHiwL = FGhnnwoh1Dd8.Counter()
for JCpEgna6NeKD in Q3geYgYGmfP7(VClZe2GK94na, max_lines=j7uiafn_rmEj, split_on_newlines=ZJfXltPmKAt1):
xafqLlk3kkUe(qaIx4JIwHiwL, xafqLlk3kkUe(SXOLrMavuUCe(b'9\x9duI\x94\xfdy$X\x8d\xea\x0e'), '\144' + chr(0b1100101) + chr(0b1100011) + chr(0b10110 + 0o131) + chr(100) + chr(0b1100101))(chr(2851 - 2734) + chr(116) + chr(330 - 228) + '\x2d' + chr(0b10111 + 0o41)))(WZINe7poqZfF(EFhzw3SDsEgZ(JCpEgna6NeKD)))
xafqLlk3kkUe(mcP9wB7s3wV8, xafqLlk3kkUe(SXOLrMavuUCe(b'\x17\x9bUb\x8e\xd5\\8L\xdc\xfda\xc8\xc6\x0c\xab\x9e'), '\144' + '\145' + chr(0b1100011) + chr(0b1010101 + 0o32) + chr(0b1111 + 0o125) + chr(0b1100101))(chr(9337 - 9220) + chr(0b1110100) + '\x66' + '\055' + chr(0b1011 + 0o55)))(key=xafqLlk3kkUe(mcP9wB7s3wV8, xafqLlk3kkUe(SXOLrMavuUCe(b'3\xbbq\\\xaf\xfcp\x15w\xf6\xcc\x7f\xfa\xeb6\x8c\xb0\xde'), chr(100) + '\x65' + chr(0b1100011) + '\157' + chr(4542 - 4442) + '\145')(chr(117) + chr(11460 - 11344) + chr(102) + chr(45) + chr(56))), value=c2A0yzQpDQB3(qaIx4JIwHiwL))
return qaIx4JIwHiwL
|
tensorflow/tensor2tensor
|
tensor2tensor/data_generators/tokenizer.py
|
vocab_token_counts
|
def vocab_token_counts(text_filepattern, max_lines):
"""Read a vocab file and return a dictionary of token counts.
Reads a two-column CSV file of tokens and their frequency in a dataset. The
tokens are presumed to be generated by encode() or the equivalent.
Args:
text_filepattern: A pattern matching one or more files.
max_lines: An integer; maximum total lines to read.
Returns:
a dictionary mapping token to count.
"""
ret = {}
for i, line in enumerate(
_read_filepattern(text_filepattern, max_lines=max_lines)):
if "," not in line:
tf.logging.warning("Malformed vocab line #%d '%s'", i, line)
continue
token, count = line.rsplit(",", 1)
ret[_native_to_unicode(token)] = int(count)
return ret
|
python
|
def vocab_token_counts(text_filepattern, max_lines):
"""Read a vocab file and return a dictionary of token counts.
Reads a two-column CSV file of tokens and their frequency in a dataset. The
tokens are presumed to be generated by encode() or the equivalent.
Args:
text_filepattern: A pattern matching one or more files.
max_lines: An integer; maximum total lines to read.
Returns:
a dictionary mapping token to count.
"""
ret = {}
for i, line in enumerate(
_read_filepattern(text_filepattern, max_lines=max_lines)):
if "," not in line:
tf.logging.warning("Malformed vocab line #%d '%s'", i, line)
continue
token, count = line.rsplit(",", 1)
ret[_native_to_unicode(token)] = int(count)
return ret
|
[
"def",
"vocab_token_counts",
"(",
"text_filepattern",
",",
"max_lines",
")",
":",
"ret",
"=",
"{",
"}",
"for",
"i",
",",
"line",
"in",
"enumerate",
"(",
"_read_filepattern",
"(",
"text_filepattern",
",",
"max_lines",
"=",
"max_lines",
")",
")",
":",
"if",
"\",\"",
"not",
"in",
"line",
":",
"tf",
".",
"logging",
".",
"warning",
"(",
"\"Malformed vocab line #%d '%s'\"",
",",
"i",
",",
"line",
")",
"continue",
"token",
",",
"count",
"=",
"line",
".",
"rsplit",
"(",
"\",\"",
",",
"1",
")",
"ret",
"[",
"_native_to_unicode",
"(",
"token",
")",
"]",
"=",
"int",
"(",
"count",
")",
"return",
"ret"
] |
Read a vocab file and return a dictionary of token counts.
Reads a two-column CSV file of tokens and their frequency in a dataset. The
tokens are presumed to be generated by encode() or the equivalent.
Args:
text_filepattern: A pattern matching one or more files.
max_lines: An integer; maximum total lines to read.
Returns:
a dictionary mapping token to count.
|
[
"Read",
"a",
"vocab",
"file",
"and",
"return",
"a",
"dictionary",
"of",
"token",
"counts",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/data_generators/tokenizer.py#L174-L197
|
train
|
Reads a two - column CSV file and returns a dictionary of token counts.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,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,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\062' + chr(1455 - 1403) + chr(0b101 + 0o61), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b10111 + 0o130) + '\x33' + chr(435 - 382) + chr(624 - 576), 44304 - 44296), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1471 - 1420) + '\x33' + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(51) + chr(0b101000 + 0o15) + '\064', 0o10), ehT0Px3KOsy9('\060' + chr(0b101111 + 0o100) + '\x33' + chr(0b110010) + chr(51), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b100000 + 0o117) + chr(2332 - 2282) + chr(0b11110 + 0o25) + '\x32', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(2390 - 2279) + chr(0b101001 + 0o12) + chr(0b110101) + '\067', 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(0b1100 + 0o45) + chr(1729 - 1679) + chr(1772 - 1721), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b101001 + 0o106) + chr(398 - 347) + chr(0b110101), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\x32' + chr(0b110001) + chr(53), 44635 - 44627), ehT0Px3KOsy9(chr(0b101100 + 0o4) + '\157' + chr(263 - 212) + '\x30' + chr(0b110001), ord("\x08")), ehT0Px3KOsy9(chr(0b101101 + 0o3) + chr(0b1101111) + chr(0b1000 + 0o52) + '\063' + chr(0b110011), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b0 + 0o157) + '\061' + chr(0b101001 + 0o16) + '\x30', 0b1000), ehT0Px3KOsy9(chr(542 - 494) + '\157' + chr(1872 - 1822) + chr(55) + '\x34', 390 - 382), ehT0Px3KOsy9('\060' + '\x6f' + '\x32' + '\x33' + chr(0b1000 + 0o56), 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + '\063' + '\x30' + chr(0b100111 + 0o12), 8), ehT0Px3KOsy9('\x30' + '\x6f' + '\x33' + chr(0b11101 + 0o27) + '\066', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101000 + 0o7) + '\x32' + '\061' + chr(0b110001), 0o10), ehT0Px3KOsy9(chr(0b110000 + 0o0) + chr(0b1001 + 0o146) + chr(0b110001) + chr(0b110110) + chr(0b110110), 24772 - 24764), ehT0Px3KOsy9('\x30' + chr(0b111 + 0o150) + chr(50) + '\x34' + '\060', 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(402 - 352) + '\x34' + '\066', 8), ehT0Px3KOsy9(chr(0b100101 + 0o13) + chr(111) + '\063' + chr(0b110101), 8), ehT0Px3KOsy9(chr(48) + '\x6f' + '\x31' + '\x35' + chr(0b11 + 0o60), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(3061 - 2950) + '\x31' + chr(52), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + '\x33' + chr(2581 - 2526) + chr(53), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101010 + 0o5) + chr(54) + chr(50), 0o10), ehT0Px3KOsy9(chr(0b11 + 0o55) + chr(0b1011101 + 0o22) + '\x33' + chr(0b101111 + 0o6) + chr(54), 52743 - 52735), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x33' + chr(48), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\061' + chr(0b110011) + chr(53), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(8202 - 8091) + chr(0b110011) + chr(0b110101 + 0o0) + chr(54), 8), ehT0Px3KOsy9(chr(0b11 + 0o55) + '\x6f' + chr(0b110011) + '\067' + chr(0b110110), ord("\x08")), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b100000 + 0o22) + '\x31' + '\x34', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b100100 + 0o17) + '\065' + chr(0b11011 + 0o31), 8), ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(0b1101111) + chr(0b110011) + '\x31' + '\065', 6855 - 6847), ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(0b10101 + 0o36) + chr(0b1101 + 0o46) + chr(0b110110), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(51) + chr(0b110001) + '\067', 0b1000), ehT0Px3KOsy9(chr(2166 - 2118) + chr(6858 - 6747) + chr(0b110010 + 0o1) + chr(0b101101 + 0o11) + chr(1691 - 1643), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1011011 + 0o24) + chr(0b101011 + 0o13), 0b1000), ehT0Px3KOsy9(chr(0b10110 + 0o32) + chr(0b1010100 + 0o33) + '\063' + chr(51) + chr(1559 - 1511), ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110111) + chr(50), 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b101001 + 0o7) + chr(111) + chr(0b101100 + 0o11) + '\x30', ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x88'), chr(6217 - 6117) + chr(0b1100101) + chr(99) + '\x6f' + chr(0b100110 + 0o76) + '\145')(chr(0b1001010 + 0o53) + chr(0b1110100) + chr(102) + chr(0b101101) + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def GWoUB_MxSnSR(VClZe2GK94na, JasJv8KXVjRc):
VHn4CV4Ymrei = {}
for (WVxHKyX45z_L, LycYkDpyelF6) in YlkZvXL8qwsX(Q3geYgYGmfP7(VClZe2GK94na, max_lines=JasJv8KXVjRc)):
if xafqLlk3kkUe(SXOLrMavuUCe(b'\x8a'), chr(100) + chr(0b1100101) + chr(9221 - 9122) + '\157' + chr(100) + '\x65')('\x75' + '\164' + chr(0b1100110) + '\055' + '\x38') not in LycYkDpyelF6:
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b'\xd1\x89\xaf\x82\xba\xf4\x88'), chr(0b1100100) + chr(0b1100101) + chr(99) + chr(0b100100 + 0o113) + chr(0b1100100) + '\145')(chr(10115 - 9998) + '\x74' + chr(102) + chr(45) + '\070'))(xafqLlk3kkUe(SXOLrMavuUCe(b'\xeb\x89\xb1\x8a\xbc\xe8\x826y\xad\xb7\xf4\x1b\xdd\xfc\xe1\x8a\xe0\x18\xc5\x86>Nh\xdd\x15\xcbkz'), '\x64' + '\145' + chr(0b1100011) + chr(11829 - 11718) + '\144' + chr(0b110010 + 0o63))('\x75' + '\164' + chr(2591 - 2489) + chr(45) + chr(0b11011 + 0o35)), WVxHKyX45z_L, LycYkDpyelF6)
continue
(mTy3fac_AqJ5, ualWdDeXJEGO) = LycYkDpyelF6.rsplit(xafqLlk3kkUe(SXOLrMavuUCe(b'\x8a'), chr(100) + chr(101) + chr(3490 - 3391) + chr(111) + '\144' + '\x65')(chr(0b1110101) + chr(116) + '\x66' + '\055' + chr(56)), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110001), 5857 - 5849))
VHn4CV4Ymrei[EFhzw3SDsEgZ(mTy3fac_AqJ5)] = ehT0Px3KOsy9(ualWdDeXJEGO)
return VHn4CV4Ymrei
|
tensorflow/tensor2tensor
|
tensor2tensor/serving/serving_utils.py
|
_make_example
|
def _make_example(input_ids, problem, input_feature_name="inputs"):
"""Make a tf.train.Example for the problem.
features[input_feature_name] = input_ids
Also fills in any other required features with dummy values.
Args:
input_ids: list<int>.
problem: Problem.
input_feature_name: name of feature for input_ids.
Returns:
tf.train.Example
"""
features = {
input_feature_name:
tf.train.Feature(int64_list=tf.train.Int64List(value=input_ids))
}
# Fill in dummy values for any other required features that presumably
# will not actually be used for prediction.
data_fields, _ = problem.example_reading_spec()
for fname, ftype in data_fields.items():
if fname == input_feature_name:
continue
if not isinstance(ftype, tf.FixedLenFeature):
# Only FixedLenFeatures are required
continue
if ftype.default_value is not None:
# If there's a default value, no need to fill it in
continue
num_elements = functools.reduce(lambda acc, el: acc * el, ftype.shape, 1)
if ftype.dtype in [tf.int32, tf.int64]:
value = tf.train.Feature(
int64_list=tf.train.Int64List(value=[0] * num_elements))
if ftype.dtype in [tf.float32, tf.float64]:
value = tf.train.Feature(
float_list=tf.train.FloatList(value=[0.] * num_elements))
if ftype.dtype == tf.bytes:
value = tf.train.Feature(
bytes_list=tf.train.BytesList(value=[""] * num_elements))
tf.logging.info("Adding dummy value for feature %s as it is required by "
"the Problem.", fname)
features[fname] = value
return tf.train.Example(features=tf.train.Features(feature=features))
|
python
|
def _make_example(input_ids, problem, input_feature_name="inputs"):
"""Make a tf.train.Example for the problem.
features[input_feature_name] = input_ids
Also fills in any other required features with dummy values.
Args:
input_ids: list<int>.
problem: Problem.
input_feature_name: name of feature for input_ids.
Returns:
tf.train.Example
"""
features = {
input_feature_name:
tf.train.Feature(int64_list=tf.train.Int64List(value=input_ids))
}
# Fill in dummy values for any other required features that presumably
# will not actually be used for prediction.
data_fields, _ = problem.example_reading_spec()
for fname, ftype in data_fields.items():
if fname == input_feature_name:
continue
if not isinstance(ftype, tf.FixedLenFeature):
# Only FixedLenFeatures are required
continue
if ftype.default_value is not None:
# If there's a default value, no need to fill it in
continue
num_elements = functools.reduce(lambda acc, el: acc * el, ftype.shape, 1)
if ftype.dtype in [tf.int32, tf.int64]:
value = tf.train.Feature(
int64_list=tf.train.Int64List(value=[0] * num_elements))
if ftype.dtype in [tf.float32, tf.float64]:
value = tf.train.Feature(
float_list=tf.train.FloatList(value=[0.] * num_elements))
if ftype.dtype == tf.bytes:
value = tf.train.Feature(
bytes_list=tf.train.BytesList(value=[""] * num_elements))
tf.logging.info("Adding dummy value for feature %s as it is required by "
"the Problem.", fname)
features[fname] = value
return tf.train.Example(features=tf.train.Features(feature=features))
|
[
"def",
"_make_example",
"(",
"input_ids",
",",
"problem",
",",
"input_feature_name",
"=",
"\"inputs\"",
")",
":",
"features",
"=",
"{",
"input_feature_name",
":",
"tf",
".",
"train",
".",
"Feature",
"(",
"int64_list",
"=",
"tf",
".",
"train",
".",
"Int64List",
"(",
"value",
"=",
"input_ids",
")",
")",
"}",
"# Fill in dummy values for any other required features that presumably",
"# will not actually be used for prediction.",
"data_fields",
",",
"_",
"=",
"problem",
".",
"example_reading_spec",
"(",
")",
"for",
"fname",
",",
"ftype",
"in",
"data_fields",
".",
"items",
"(",
")",
":",
"if",
"fname",
"==",
"input_feature_name",
":",
"continue",
"if",
"not",
"isinstance",
"(",
"ftype",
",",
"tf",
".",
"FixedLenFeature",
")",
":",
"# Only FixedLenFeatures are required",
"continue",
"if",
"ftype",
".",
"default_value",
"is",
"not",
"None",
":",
"# If there's a default value, no need to fill it in",
"continue",
"num_elements",
"=",
"functools",
".",
"reduce",
"(",
"lambda",
"acc",
",",
"el",
":",
"acc",
"*",
"el",
",",
"ftype",
".",
"shape",
",",
"1",
")",
"if",
"ftype",
".",
"dtype",
"in",
"[",
"tf",
".",
"int32",
",",
"tf",
".",
"int64",
"]",
":",
"value",
"=",
"tf",
".",
"train",
".",
"Feature",
"(",
"int64_list",
"=",
"tf",
".",
"train",
".",
"Int64List",
"(",
"value",
"=",
"[",
"0",
"]",
"*",
"num_elements",
")",
")",
"if",
"ftype",
".",
"dtype",
"in",
"[",
"tf",
".",
"float32",
",",
"tf",
".",
"float64",
"]",
":",
"value",
"=",
"tf",
".",
"train",
".",
"Feature",
"(",
"float_list",
"=",
"tf",
".",
"train",
".",
"FloatList",
"(",
"value",
"=",
"[",
"0.",
"]",
"*",
"num_elements",
")",
")",
"if",
"ftype",
".",
"dtype",
"==",
"tf",
".",
"bytes",
":",
"value",
"=",
"tf",
".",
"train",
".",
"Feature",
"(",
"bytes_list",
"=",
"tf",
".",
"train",
".",
"BytesList",
"(",
"value",
"=",
"[",
"\"\"",
"]",
"*",
"num_elements",
")",
")",
"tf",
".",
"logging",
".",
"info",
"(",
"\"Adding dummy value for feature %s as it is required by \"",
"\"the Problem.\"",
",",
"fname",
")",
"features",
"[",
"fname",
"]",
"=",
"value",
"return",
"tf",
".",
"train",
".",
"Example",
"(",
"features",
"=",
"tf",
".",
"train",
".",
"Features",
"(",
"feature",
"=",
"features",
")",
")"
] |
Make a tf.train.Example for the problem.
features[input_feature_name] = input_ids
Also fills in any other required features with dummy values.
Args:
input_ids: list<int>.
problem: Problem.
input_feature_name: name of feature for input_ids.
Returns:
tf.train.Example
|
[
"Make",
"a",
"tf",
".",
"train",
".",
"Example",
"for",
"the",
"problem",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/serving/serving_utils.py#L36-L81
|
train
|
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uw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + '\x6f' + chr(49) + chr(2656 - 2603) + chr(50), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + '\x33' + chr(51) + chr(54), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1100110 + 0o11) + chr(49) + chr(0b110001 + 0o5), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110011) + chr(2072 - 2023) + chr(0b11100 + 0o33), ord("\x08")), ehT0Px3KOsy9('\060' + chr(7924 - 7813) + chr(1780 - 1726) + chr(0b100101 + 0o16), 0o10), ehT0Px3KOsy9('\x30' + chr(9249 - 9138) + chr(49) + chr(0b110011) + chr(0b110011), 22890 - 22882), ehT0Px3KOsy9(chr(0b110 + 0o52) + chr(0b1101000 + 0o7) + chr(0b1000 + 0o53) + '\066' + chr(52), ord("\x08")), ehT0Px3KOsy9(chr(1351 - 1303) + '\157' + chr(864 - 813) + chr(119 - 64), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\061' + chr(50) + '\x31', 0o10), ehT0Px3KOsy9(chr(329 - 281) + chr(0b1101100 + 0o3) + chr(0b101111 + 0o2) + '\x35' + chr(54), 0o10), ehT0Px3KOsy9('\060' + '\157' + '\x31' + chr(0b110011) + chr(51), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(53) + '\063', 0o10), ehT0Px3KOsy9('\x30' + chr(10947 - 10836) + chr(976 - 926) + chr(51) + chr(0b11010 + 0o35), 27917 - 27909), ehT0Px3KOsy9(chr(0b1001 + 0o47) + chr(0b111110 + 0o61) + '\x33' + '\x36' + '\065', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x33' + chr(48) + '\x37', 0b1000), ehT0Px3KOsy9('\x30' + '\157' + chr(49) + chr(84 - 29) + chr(50), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\061' + chr(0b11 + 0o62) + chr(53), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b110011) + '\063' + chr(0b1101 + 0o45), 46726 - 46718), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(50) + chr(0b1110 + 0o51) + '\x36', 53873 - 53865), ehT0Px3KOsy9('\060' + chr(0b10110 + 0o131) + chr(780 - 730) + '\060' + chr(0b11010 + 0o35), 34712 - 34704), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b100001 + 0o21) + chr(55) + chr(55), 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(0b10001 + 0o42) + '\067', 8), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110 + 0o54) + '\064' + chr(0b110110), 40277 - 40269), ehT0Px3KOsy9(chr(1499 - 1451) + chr(0b1101111) + chr(0b11111 + 0o24) + chr(0b110101) + chr(0b110000), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1100100 + 0o13) + '\067' + chr(0b10101 + 0o33), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(11785 - 11674) + '\x31' + chr(0b110100) + chr(0b101001 + 0o12), 51383 - 51375), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b101101 + 0o5) + chr(0b101010 + 0o14) + chr(0b10101 + 0o42), 52996 - 52988), ehT0Px3KOsy9(chr(0b110000) + chr(0b11011 + 0o124) + chr(0b11101 + 0o24) + chr(0b110110) + chr(0b110001), 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x33' + chr(1275 - 1223) + '\x31', 0o10), ehT0Px3KOsy9(chr(2195 - 2147) + chr(0b110010 + 0o75) + chr(0b110111) + '\x37', 0o10), ehT0Px3KOsy9(chr(0b10011 + 0o35) + chr(9163 - 9052) + chr(0b1 + 0o62) + '\x34' + chr(622 - 571), 56400 - 56392), ehT0Px3KOsy9(chr(0b11011 + 0o25) + chr(0b1101111) + '\x34' + chr(297 - 246), 0o10), ehT0Px3KOsy9(chr(1565 - 1517) + '\157' + '\064', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(0b110110 + 0o71) + chr(0b110011) + chr(52) + '\x32', 0b1000), ehT0Px3KOsy9(chr(0b110000) + '\157' + '\062', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b101001 + 0o10) + '\061' + chr(52), 0b1000), ehT0Px3KOsy9(chr(2044 - 1996) + chr(0b1001100 + 0o43) + chr(51) + '\067', 8), ehT0Px3KOsy9(chr(0b101 + 0o53) + chr(6266 - 6155) + chr(0b100000 + 0o22) + chr(52) + chr(52), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(0b100010 + 0o21) + chr(48) + '\x33', 46831 - 46823), ehT0Px3KOsy9(chr(48) + chr(6493 - 6382) + chr(51) + '\x33' + chr(0b110100), 30344 - 30336)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(1526 - 1473) + chr(0b110000), 62020 - 62012)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'D'), '\144' + '\145' + chr(0b1100011) + '\157' + chr(0b1100100) + chr(101))(chr(0b1110101) + '\164' + chr(0b1000101 + 0o41) + chr(0b11001 + 0o24) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def sGFKIyInQebX(CyiZkgWrlgA9, sO7e1A_Mor6Q, FPqzqJYkUjxv=xafqLlk3kkUe(SXOLrMavuUCe(b'\x03\xb0~\xbaG('), chr(0b1100100) + chr(101) + chr(0b10111 + 0o114) + chr(0b1101111) + chr(0b1100100) + chr(0b100101 + 0o100))(chr(9045 - 8928) + chr(0b11010 + 0o132) + chr(102) + chr(45) + '\070')):
EEf4r9nUvta_ = {FPqzqJYkUjxv: IDJ2eXGCBCDu.train.Feature(int64_list=IDJ2eXGCBCDu.train.Int64List(value=CyiZkgWrlgA9))}
(NcaloodHmi5p, VNGQdHSFPrso) = sO7e1A_Mor6Q.example_reading_spec()
for (t3WbF0Ae42Pu, p6zC2lcXhNky) in xafqLlk3kkUe(NcaloodHmi5p, xafqLlk3kkUe(SXOLrMavuUCe(b'$\xa4x\xaaz\x01\xc7V==\x13\x12'), chr(100) + '\x65' + chr(0b1001010 + 0o31) + '\157' + chr(100) + chr(101))(chr(0b1100100 + 0o21) + chr(8323 - 8207) + chr(102) + chr(45) + '\070'))():
if t3WbF0Ae42Pu == FPqzqJYkUjxv:
continue
if not PlSM16l2KDPD(p6zC2lcXhNky, xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b',\xb7v\xaaW\x17\x91q\x17\x0b:_\xea\x87\xa2'), chr(8077 - 7977) + chr(6845 - 6744) + '\143' + chr(0b1101111) + chr(100) + chr(0b1011101 + 0o10))(chr(2454 - 2337) + '\x74' + chr(5092 - 4990) + chr(710 - 665) + chr(56)))):
continue
if xafqLlk3kkUe(p6zC2lcXhNky, xafqLlk3kkUe(SXOLrMavuUCe(b"\x0e\xbbh\xaeF7\x80@'\x0f7^\xfa"), '\x64' + '\145' + chr(0b1100011) + chr(0b1101111) + chr(100) + chr(0b1100101))(chr(117) + chr(0b1110100) + chr(5830 - 5728) + '\x2d' + chr(0b111000))) is not None:
continue
PaxqU7YOKruN = E6ula8_Zv1yl.reduce(lambda jIDym3yABcdT, cWbTN_IfhLP1: jIDym3yABcdT * cWbTN_IfhLP1, p6zC2lcXhNky.nauYfLglTpcb, ehT0Px3KOsy9('\060' + chr(6966 - 6855) + chr(49), 0o10))
if xafqLlk3kkUe(p6zC2lcXhNky, xafqLlk3kkUe(SXOLrMavuUCe(b'\x00\x8dX\xf6z\x10\x9az<&l`'), '\x64' + '\145' + chr(0b1100011) + chr(0b1101111) + '\x64' + chr(0b1001 + 0o134))(chr(117) + '\x74' + chr(102) + chr(45) + chr(0b100110 + 0o22))) in [xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x03\xb0z\xfc\x01'), '\x64' + '\145' + chr(0b1100011) + chr(111) + chr(100) + chr(101))(chr(0b101110 + 0o107) + chr(0b111000 + 0o74) + chr(102) + chr(0b100 + 0o51) + chr(56))), xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x03\xb0z\xf9\x07'), '\144' + chr(101) + chr(99) + chr(0b11100 + 0o123) + chr(100) + chr(6074 - 5973))(chr(117) + '\x74' + chr(102) + chr(1107 - 1062) + chr(0b100010 + 0o26)))]:
QmmgWUB13VCJ = IDJ2eXGCBCDu.train.Feature(int64_list=IDJ2eXGCBCDu.train.Int64List(value=[ehT0Px3KOsy9(chr(48) + chr(0b111010 + 0o65) + chr(0b110000), 45938 - 45930)] * PaxqU7YOKruN))
if xafqLlk3kkUe(p6zC2lcXhNky, xafqLlk3kkUe(SXOLrMavuUCe(b'\x00\x8dX\xf6z\x10\x9az<&l`'), chr(100) + chr(0b11101 + 0o110) + chr(99) + chr(0b10 + 0o155) + chr(100) + '\145')('\x75' + '\x74' + '\x66' + chr(0b100001 + 0o14) + '\x38')) in [xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x0c\xb2a\xaeGh\xc6'), chr(9129 - 9029) + '\x65' + '\143' + chr(5480 - 5369) + chr(204 - 104) + chr(8129 - 8028))(chr(0b1110101) + chr(0b1110100) + chr(8665 - 8563) + chr(49 - 4) + '\x38')), xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x0c\xb2a\xaeGm\xc0'), chr(4890 - 4790) + chr(0b1100101) + chr(0b1100011) + '\157' + '\144' + chr(6346 - 6245))('\x75' + chr(0b1110100) + chr(102) + chr(45) + chr(1220 - 1164)))]:
QmmgWUB13VCJ = IDJ2eXGCBCDu.train.Feature(float_list=IDJ2eXGCBCDu.train.FloatList(value=[0.0] * PaxqU7YOKruN))
if xafqLlk3kkUe(p6zC2lcXhNky, xafqLlk3kkUe(SXOLrMavuUCe(b'\x00\x8dX\xf6z\x10\x9az<&l`'), '\144' + '\x65' + chr(0b1100011) + chr(0b1010010 + 0o35) + chr(0b1100100) + chr(3444 - 3343))(chr(0b1110101) + '\x74' + chr(0b1100110) + chr(575 - 530) + chr(56))) == xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\x08\xa7z\xaa@'), chr(7745 - 7645) + chr(0b1100101) + '\x63' + chr(0b1101111) + '\144' + '\x65')(chr(117) + chr(116) + chr(0b100010 + 0o104) + chr(0b101101) + chr(56))):
QmmgWUB13VCJ = IDJ2eXGCBCDu.train.Feature(bytes_list=IDJ2eXGCBCDu.train.BytesList(value=[xafqLlk3kkUe(SXOLrMavuUCe(b''), chr(100) + '\145' + '\x63' + chr(0b1101111) + '\144' + '\145')(chr(0b1001110 + 0o47) + '\164' + '\146' + chr(655 - 610) + chr(56))] * PaxqU7YOKruN))
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b'9\xe9F\xb7F8\x93(;\x02\x01@'), '\144' + '\145' + chr(0b1100011) + chr(1530 - 1419) + chr(0b100010 + 0o102) + '\145')(chr(0b1110101) + chr(11520 - 11404) + chr(0b1100110) + chr(0b100101 + 0o10) + chr(1833 - 1777)))(xafqLlk3kkUe(SXOLrMavuUCe(b'+\xbaj\xa6]<\xd4{$\x036R\xbf\x83\xa6\x16\x18\xbf\x9e\xe1\xd0m\x86\x8e]\x02\xc3\x04\x93Z\xc3\x06w\xc2c??\xcd\xb7\xfc\x03\xad.\xbdV*\x81v#\x0b?\x0b\xfd\x8c\xe7\x0e\x05\xbf\x9e\xd7\xcdp\xc4\x84]\x0e\x99'), '\144' + chr(7307 - 7206) + '\x63' + chr(0b1101111) + '\144' + chr(0b1100101))(chr(0b1110101) + chr(116) + chr(102) + chr(0b101101) + '\070'), t3WbF0Ae42Pu)
EEf4r9nUvta_[t3WbF0Ae42Pu] = QmmgWUB13VCJ
return xafqLlk3kkUe(IDJ2eXGCBCDu.train, xafqLlk3kkUe(SXOLrMavuUCe(b'/\xa6o\xa2C7\x91'), chr(100) + '\x65' + chr(99) + chr(0b1101110 + 0o1) + chr(5838 - 5738) + '\145')(chr(10854 - 10737) + chr(0b101001 + 0o113) + chr(2156 - 2054) + chr(0b111 + 0o46) + chr(0b110111 + 0o1)))(features=xafqLlk3kkUe(IDJ2eXGCBCDu.train, xafqLlk3kkUe(SXOLrMavuUCe(b',\xbbo\xbbF)\x91l'), chr(100) + '\145' + '\x63' + '\157' + '\144' + chr(0b1100101))(chr(0b101 + 0o160) + chr(0b1110100) + chr(3848 - 3746) + chr(0b100001 + 0o14) + chr(754 - 698)))(feature=EEf4r9nUvta_))
|
tensorflow/tensor2tensor
|
tensor2tensor/serving/serving_utils.py
|
make_grpc_request_fn
|
def make_grpc_request_fn(servable_name, server, timeout_secs):
"""Wraps function to make grpc requests with runtime args."""
stub = _create_stub(server)
def _make_grpc_request(examples):
"""Builds and sends request to TensorFlow model server."""
request = predict_pb2.PredictRequest()
request.model_spec.name = servable_name
request.inputs["input"].CopyFrom(
tf.make_tensor_proto(
[ex.SerializeToString() for ex in examples], shape=[len(examples)]))
response = stub.Predict(request, timeout_secs)
outputs = tf.make_ndarray(response.outputs["outputs"])
scores = tf.make_ndarray(response.outputs["scores"])
assert len(outputs) == len(scores)
return [{ # pylint: disable=g-complex-comprehension
"outputs": output,
"scores": score
} for output, score in zip(outputs, scores)]
return _make_grpc_request
|
python
|
def make_grpc_request_fn(servable_name, server, timeout_secs):
"""Wraps function to make grpc requests with runtime args."""
stub = _create_stub(server)
def _make_grpc_request(examples):
"""Builds and sends request to TensorFlow model server."""
request = predict_pb2.PredictRequest()
request.model_spec.name = servable_name
request.inputs["input"].CopyFrom(
tf.make_tensor_proto(
[ex.SerializeToString() for ex in examples], shape=[len(examples)]))
response = stub.Predict(request, timeout_secs)
outputs = tf.make_ndarray(response.outputs["outputs"])
scores = tf.make_ndarray(response.outputs["scores"])
assert len(outputs) == len(scores)
return [{ # pylint: disable=g-complex-comprehension
"outputs": output,
"scores": score
} for output, score in zip(outputs, scores)]
return _make_grpc_request
|
[
"def",
"make_grpc_request_fn",
"(",
"servable_name",
",",
"server",
",",
"timeout_secs",
")",
":",
"stub",
"=",
"_create_stub",
"(",
"server",
")",
"def",
"_make_grpc_request",
"(",
"examples",
")",
":",
"\"\"\"Builds and sends request to TensorFlow model server.\"\"\"",
"request",
"=",
"predict_pb2",
".",
"PredictRequest",
"(",
")",
"request",
".",
"model_spec",
".",
"name",
"=",
"servable_name",
"request",
".",
"inputs",
"[",
"\"input\"",
"]",
".",
"CopyFrom",
"(",
"tf",
".",
"make_tensor_proto",
"(",
"[",
"ex",
".",
"SerializeToString",
"(",
")",
"for",
"ex",
"in",
"examples",
"]",
",",
"shape",
"=",
"[",
"len",
"(",
"examples",
")",
"]",
")",
")",
"response",
"=",
"stub",
".",
"Predict",
"(",
"request",
",",
"timeout_secs",
")",
"outputs",
"=",
"tf",
".",
"make_ndarray",
"(",
"response",
".",
"outputs",
"[",
"\"outputs\"",
"]",
")",
"scores",
"=",
"tf",
".",
"make_ndarray",
"(",
"response",
".",
"outputs",
"[",
"\"scores\"",
"]",
")",
"assert",
"len",
"(",
"outputs",
")",
"==",
"len",
"(",
"scores",
")",
"return",
"[",
"{",
"# pylint: disable=g-complex-comprehension",
"\"outputs\"",
":",
"output",
",",
"\"scores\"",
":",
"score",
"}",
"for",
"output",
",",
"score",
"in",
"zip",
"(",
"outputs",
",",
"scores",
")",
"]",
"return",
"_make_grpc_request"
] |
Wraps function to make grpc requests with runtime args.
|
[
"Wraps",
"function",
"to",
"make",
"grpc",
"requests",
"with",
"runtime",
"args",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/serving/serving_utils.py#L105-L125
|
train
|
Wraps function to make grpc requests with runtime args.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5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ttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\060' + chr(0b1001010 + 0o45) + '\062' + chr(268 - 214) + '\x30', 22691 - 22683), ehT0Px3KOsy9(chr(0b1001 + 0o47) + '\x6f' + chr(0b11111 + 0o24) + '\x32' + chr(0b1000 + 0o54), 0b1000), ehT0Px3KOsy9('\060' + '\x6f' + '\x35' + '\x34', 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(1471 - 1420) + chr(1391 - 1341) + '\x35', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(476 - 365) + '\x32' + chr(591 - 539) + '\x35', 54063 - 54055), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b100111 + 0o13) + chr(0b1101 + 0o45) + '\065', ord("\x08")), ehT0Px3KOsy9(chr(48) + '\157' + chr(49) + '\x36' + chr(2063 - 2008), ord("\x08")), ehT0Px3KOsy9('\060' + chr(10801 - 10690) + chr(457 - 408) + chr(0b110111), 0b1000), ehT0Px3KOsy9('\060' + chr(0b1101111) + chr(0b101 + 0o56) + chr(48) + chr(0b110111), 2774 - 2766), ehT0Px3KOsy9('\060' + chr(0b1101011 + 0o4) + chr(859 - 808) + chr(0b110111) + chr(0b110111), ord("\x08")), ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(111) + chr(0b110001) + chr(53) + '\060', 0o10), ehT0Px3KOsy9(chr(0b101001 + 0o7) + '\157' + '\062' + '\067' + chr(54), 25045 - 25037), ehT0Px3KOsy9(chr(48) + chr(0b1011001 + 0o26) + '\063' + chr(0b10110 + 0o33) + chr(165 - 114), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b110001) + chr(48), 0b1000), ehT0Px3KOsy9(chr(0b101001 + 0o7) + '\x6f' + chr(0b110001) + '\067' + chr(0b110110), 63492 - 63484), ehT0Px3KOsy9(chr(0b100 + 0o54) + chr(3304 - 3193) + chr(368 - 317) + chr(1566 - 1517) + '\063', 8), ehT0Px3KOsy9('\060' + chr(5654 - 5543) + chr(0b110110) + chr(0b110011), 38012 - 38004), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(0b110010) + chr(51) + chr(0b110010), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(49) + chr(705 - 653) + '\060', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1001000 + 0o47) + chr(50) + chr(2589 - 2536) + '\x34', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1000110 + 0o51) + chr(0b110001) + '\x36' + chr(55), 8), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(2394 - 2343) + chr(0b110110) + chr(443 - 394), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(327 - 277) + chr(0b110000) + chr(0b101100 + 0o10), 62762 - 62754), ehT0Px3KOsy9(chr(1938 - 1890) + '\157' + chr(50) + chr(121 - 69) + chr(0b110110 + 0o0), 25620 - 25612), ehT0Px3KOsy9(chr(1865 - 1817) + chr(8357 - 8246) + '\x31' + chr(0b11000 + 0o30) + '\066', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1011100 + 0o23) + '\x35' + chr(0b110101), 61484 - 61476), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\066' + chr(0b110000 + 0o2), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(2054 - 1943) + chr(813 - 762) + chr(0b110 + 0o53) + chr(55), ord("\x08")), ehT0Px3KOsy9(chr(0b10101 + 0o33) + '\x6f' + chr(0b1100 + 0o47) + chr(0b100010 + 0o16) + chr(0b100001 + 0o22), 0o10), ehT0Px3KOsy9(chr(1753 - 1705) + chr(0b100001 + 0o116) + '\x31' + chr(0b1011 + 0o54) + chr(54), 8), ehT0Px3KOsy9('\060' + chr(0b11111 + 0o120) + '\x33' + '\x31' + chr(48), 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(614 - 564) + '\067' + '\x35', 0o10), ehT0Px3KOsy9('\060' + '\157' + '\062', 0o10), ehT0Px3KOsy9(chr(1814 - 1766) + chr(4634 - 4523) + chr(0b110011) + chr(0b110100) + chr(0b110101), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\x33' + chr(0b11 + 0o56) + chr(49), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b101011 + 0o6) + '\x31', 0o10), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b1010 + 0o50) + chr(0b110000) + chr(2112 - 2058), 6526 - 6518), ehT0Px3KOsy9(chr(1826 - 1778) + '\157' + chr(50) + chr(0b110010) + chr(49), 0o10), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + '\x36' + chr(1287 - 1232), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(4856 - 4745) + chr(2570 - 2519) + chr(0b110101) + '\x31', 43706 - 43698)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(0b110000) + chr(9743 - 9632) + chr(985 - 932) + '\x30', ord("\x08"))] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\x9e'), chr(0b101110 + 0o66) + chr(0b1100011 + 0o2) + chr(7804 - 7705) + chr(111) + '\x64' + chr(0b1100101))(chr(0b1110101) + chr(0b1110100) + '\x66' + '\x2d' + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def SGc4rF4jW8w0(mYZNlR1iSjpU, Ut41WBgpnv2R, LPLo6qsIxjnV):
L1RUU6SApjE_ = LWx11ZK7eScW(Ut41WBgpnv2R)
def lUM0jlReGma6(uyAR7jUe1VQb):
r9Xp41HGNpwj = We5CXr7K4LKi.PredictRequest()
r9Xp41HGNpwj.model_spec.AIvJRzLdDfgF = mYZNlR1iSjpU
xafqLlk3kkUe(r9Xp41HGNpwj.inputs[xafqLlk3kkUe(SXOLrMavuUCe(b'\xd9\xba\\\xa0\xd1'), '\x64' + chr(101) + chr(99) + chr(0b1101110 + 0o1) + chr(5888 - 5788) + '\x65')(chr(5767 - 5650) + chr(116) + chr(2388 - 2286) + chr(45) + chr(1217 - 1161))], xafqLlk3kkUe(SXOLrMavuUCe(b'\xf3\xbb\\\xac\xe3\xe7\x18b'), chr(6038 - 5938) + chr(9577 - 9476) + chr(6929 - 6830) + chr(111) + chr(100) + '\x65')(chr(117) + chr(116) + '\146' + chr(45) + '\x38'))(xafqLlk3kkUe(IDJ2eXGCBCDu, xafqLlk3kkUe(SXOLrMavuUCe(b'\xdd\xb5G\xb0\xfa\xe1\x12a\xb4\x90\x1a\xe1\xbbz\x11\xbf\\'), chr(0b1100100) + '\145' + chr(8950 - 8851) + chr(0b100101 + 0o112) + chr(0b11100 + 0o110) + '\x65')('\165' + chr(3417 - 3301) + '\x66' + chr(258 - 213) + chr(0b1001 + 0o57)))([xafqLlk3kkUe(DfdhY28yEwAF, xafqLlk3kkUe(SXOLrMavuUCe(b'\xe3\xb1^\xbc\xc4\xf9\x1eu\xa2\xab\x07\xed\xbfz\x17\xa5T'), chr(0b1111 + 0o125) + chr(1527 - 1426) + chr(0b1100011) + '\157' + '\144' + chr(0b10011 + 0o122))(chr(117) + '\164' + chr(0b1000001 + 0o45) + chr(45) + '\x38'))() for DfdhY28yEwAF in uyAR7jUe1VQb], shape=[c2A0yzQpDQB3(uyAR7jUe1VQb)]))
ekFGDFIe9V8v = L1RUU6SApjE_.Predict(r9Xp41HGNpwj, LPLo6qsIxjnV)
Dx_DllZ8uCko = IDJ2eXGCBCDu.make_ndarray(ekFGDFIe9V8v.Dx_DllZ8uCko[xafqLlk3kkUe(SXOLrMavuUCe(b'\xdf\xa1X\xa5\xd0\xe1\x04'), chr(1687 - 1587) + chr(7593 - 7492) + chr(99) + chr(111) + chr(0b1100100) + chr(9614 - 9513))('\x75' + '\164' + chr(0b110100 + 0o62) + '\055' + chr(56))])
b8rpGniBNUPr = IDJ2eXGCBCDu.make_ndarray(ekFGDFIe9V8v.Dx_DllZ8uCko[xafqLlk3kkUe(SXOLrMavuUCe(b'\xc3\xb7C\xa7\xc0\xe6'), chr(100) + chr(8188 - 8087) + chr(99) + chr(0b1101111) + '\x64' + chr(3398 - 3297))(chr(0b110100 + 0o101) + chr(116) + chr(0b111110 + 0o50) + chr(1123 - 1078) + chr(135 - 79))])
assert c2A0yzQpDQB3(Dx_DllZ8uCko) == c2A0yzQpDQB3(b8rpGniBNUPr)
return [{xafqLlk3kkUe(SXOLrMavuUCe(b'\xdf\xa1X\xa5\xd0\xe1\x04'), '\144' + chr(0b1100101) + chr(366 - 267) + chr(111) + '\x64' + chr(101))(chr(0b1110101) + chr(0b1110100) + '\x66' + chr(0b101101) + chr(0b1010 + 0o56)): e1jVqMSBZ01Y, xafqLlk3kkUe(SXOLrMavuUCe(b'\xc3\xb7C\xa7\xc0\xe6'), chr(7859 - 7759) + '\145' + '\x63' + chr(10109 - 9998) + chr(100) + chr(0b1100101))(chr(117) + chr(116) + chr(0b1100110) + '\x2d' + '\x38'): n9fd4FsgoqFs} for (e1jVqMSBZ01Y, n9fd4FsgoqFs) in pZ0NK2y6HRbn(Dx_DllZ8uCko, b8rpGniBNUPr)]
return lUM0jlReGma6
|
tensorflow/tensor2tensor
|
tensor2tensor/serving/serving_utils.py
|
make_cloud_mlengine_request_fn
|
def make_cloud_mlengine_request_fn(credentials, model_name, version):
"""Wraps function to make CloudML Engine requests with runtime args."""
def _make_cloud_mlengine_request(examples):
"""Builds and sends requests to Cloud ML Engine."""
api = discovery.build("ml", "v1", credentials=credentials)
parent = "projects/%s/models/%s/versions/%s" % (cloud.default_project(),
model_name, version)
input_data = {
"instances": [{ # pylint: disable=g-complex-comprehension
"input": {
"b64": base64.b64encode(ex.SerializeToString())
}
} for ex in examples]
}
prediction = api.projects().predict(body=input_data, name=parent).execute()
return prediction["predictions"]
return _make_cloud_mlengine_request
|
python
|
def make_cloud_mlengine_request_fn(credentials, model_name, version):
"""Wraps function to make CloudML Engine requests with runtime args."""
def _make_cloud_mlengine_request(examples):
"""Builds and sends requests to Cloud ML Engine."""
api = discovery.build("ml", "v1", credentials=credentials)
parent = "projects/%s/models/%s/versions/%s" % (cloud.default_project(),
model_name, version)
input_data = {
"instances": [{ # pylint: disable=g-complex-comprehension
"input": {
"b64": base64.b64encode(ex.SerializeToString())
}
} for ex in examples]
}
prediction = api.projects().predict(body=input_data, name=parent).execute()
return prediction["predictions"]
return _make_cloud_mlengine_request
|
[
"def",
"make_cloud_mlengine_request_fn",
"(",
"credentials",
",",
"model_name",
",",
"version",
")",
":",
"def",
"_make_cloud_mlengine_request",
"(",
"examples",
")",
":",
"\"\"\"Builds and sends requests to Cloud ML Engine.\"\"\"",
"api",
"=",
"discovery",
".",
"build",
"(",
"\"ml\"",
",",
"\"v1\"",
",",
"credentials",
"=",
"credentials",
")",
"parent",
"=",
"\"projects/%s/models/%s/versions/%s\"",
"%",
"(",
"cloud",
".",
"default_project",
"(",
")",
",",
"model_name",
",",
"version",
")",
"input_data",
"=",
"{",
"\"instances\"",
":",
"[",
"{",
"# pylint: disable=g-complex-comprehension",
"\"input\"",
":",
"{",
"\"b64\"",
":",
"base64",
".",
"b64encode",
"(",
"ex",
".",
"SerializeToString",
"(",
")",
")",
"}",
"}",
"for",
"ex",
"in",
"examples",
"]",
"}",
"prediction",
"=",
"api",
".",
"projects",
"(",
")",
".",
"predict",
"(",
"body",
"=",
"input_data",
",",
"name",
"=",
"parent",
")",
".",
"execute",
"(",
")",
"return",
"prediction",
"[",
"\"predictions\"",
"]",
"return",
"_make_cloud_mlengine_request"
] |
Wraps function to make CloudML Engine requests with runtime args.
|
[
"Wraps",
"function",
"to",
"make",
"CloudML",
"Engine",
"requests",
"with",
"runtime",
"args",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/serving/serving_utils.py#L128-L146
|
train
|
Wraps function to make CloudML Engine requests with runtime args.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9Dhh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zcpInYwBvYW,iDQ_gSK8V7h0,Rurm1zTRfSmY,reqGiMiVQ77y,bsS9P6_LpdIe,sbGAZlkZOtyh,Cf_Qef15s3_F,eX02hlZjMfR0,wLqBDw8l0eIm,g1Uy6IV0tyJQ,f9CsFWzvg0Vq,YlkZvXL8qwsX,MCqssyYhLtLC,bpgWCAbiJWkL,CMUdZtaORwo4,hi1V0ySZcNds,kkSX4ccExqw4,V4roHaS3Ppej,o8rvoPw8ep3k,xafqLlk3kkUe,h0qciNl3EEEj,lot1PSoAwYhj,xfhwxiBOH72k,HcyiPkCViZiX,fOIXYo9a1WNS,z8EhBlYI2Bx4,Y3jVKaC8LEDU,ehT0Px3KOsy9,PlSM16l2KDPD,J6u1YyThfhgG,ZdP978XkGspL,c2A0yzQpDQB3,I7ZO3Ma9cXBb,YyaZ4tpXu4lf,eHmS9durw_Vs,abA97kOQKaLo,tsdjvlgh9gDP,VTYZGD68sBIs,Dx22bkKPdt5d,nSwwHEeM4cxI,sR_24x3xd4bh,xmV2riMOClNT,_fwkIVCGgtAN,Jp8aZ6mjyZZT,eO8Xfv8UVFey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9('\x30' + chr(0b1001 + 0o146) + chr(1094 - 1044) + '\x32' + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x31' + chr(0b110100 + 0o1) + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b10100 + 0o133) + '\x32' + chr(2036 - 1982) + chr(54), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110000 + 0o1) + chr(0b110101) + chr(1562 - 1514), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + chr(1472 - 1421) + '\063' + '\x35', ord("\x08")), ehT0Px3KOsy9('\060' + '\x6f' + '\062' + chr(0b110001) + '\x31', 0o10), ehT0Px3KOsy9(chr(806 - 758) + '\157' + '\063' + chr(0b110110) + chr(52), 5095 - 5087), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(204 - 154) + '\066', ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b1101010 + 0o5) + chr(51) + chr(0b1011 + 0o47) + chr(55), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b10101 + 0o132) + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110010) + '\x34' + '\x32', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110010) + '\065' + chr(0b110111), 62405 - 62397), ehT0Px3KOsy9('\x30' + '\157' + chr(0b101 + 0o54) + chr(0b1 + 0o63) + chr(54), 0b1000), ehT0Px3KOsy9(chr(0b101111 + 0o1) + '\157' + chr(0b110010) + '\x34' + chr(0b1001 + 0o56), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(1832 - 1782) + '\060', 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1011110 + 0o21) + '\062' + chr(1032 - 978) + chr(0b101010 + 0o15), 54965 - 54957), ehT0Px3KOsy9(chr(1282 - 1234) + chr(0b1000011 + 0o54) + '\062' + '\x37' + chr(0b110101), 0b1000), ehT0Px3KOsy9(chr(0b11111 + 0o21) + '\157' + chr(50) + '\063' + chr(0b110110), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + chr(0b110001) + chr(0b110110) + chr(0b101011 + 0o7), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(0b11110 + 0o31) + chr(55), ord("\x08")), ehT0Px3KOsy9('\060' + chr(0b110000 + 0o77) + chr(50) + chr(53) + chr(48), 25085 - 25077), ehT0Px3KOsy9(chr(0b100001 + 0o17) + chr(111) + chr(0b10111 + 0o32) + chr(0b110011 + 0o0), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\064' + '\060', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(1197 - 1086) + chr(0b110001) + '\062' + chr(906 - 855), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + '\x32' + chr(53) + '\x30', 8), ehT0Px3KOsy9(chr(549 - 501) + '\157' + chr(0b100011 + 0o20) + chr(0b110000) + chr(0b110010), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1 + 0o156) + chr(0b100100 + 0o16) + '\x30' + chr(0b110000), 0o10), ehT0Px3KOsy9('\x30' + '\157' + chr(0b111 + 0o53) + chr(51) + chr(52), 53635 - 53627), ehT0Px3KOsy9('\x30' + chr(111) + '\062' + chr(54) + '\060', 31012 - 31004), ehT0Px3KOsy9(chr(48) + chr(11482 - 11371) + chr(1624 - 1573) + chr(1447 - 1396) + chr(0b110 + 0o60), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(3202 - 3091) + chr(2241 - 2191) + chr(2608 - 2556) + chr(0b110000), 0o10), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1443 - 1391) + chr(1560 - 1511), 0o10), ehT0Px3KOsy9(chr(428 - 380) + chr(0b100100 + 0o113) + chr(53) + chr(0b110101), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(961 - 910) + chr(1019 - 968) + chr(48), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(0b110010) + chr(0b100110 + 0o17) + chr(55), 8), ehT0Px3KOsy9(chr(934 - 886) + chr(3723 - 3612) + chr(49) + chr(0b110111) + chr(0b1000 + 0o55), 0b1000), ehT0Px3KOsy9('\x30' + chr(497 - 386) + chr(49) + chr(0b100001 + 0o24) + '\062', 0o10), ehT0Px3KOsy9(chr(48) + chr(111) + chr(1763 - 1714) + chr(53) + '\065', ord("\x08")), ehT0Px3KOsy9(chr(0b100001 + 0o17) + chr(0b10 + 0o155) + '\063' + chr(54) + chr(54), ord("\x08")), ehT0Px3KOsy9(chr(0b100011 + 0o15) + chr(111) + '\x33' + chr(53) + '\064', 0o10)][WVxHKyX45z_L % ehT0Px3KOsy9('\060' + '\x6f' + chr(2482 - 2429) + '\060', 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'\xbc'), chr(0b1100100) + chr(0b1100101) + chr(0b100110 + 0o75) + chr(0b1101111) + chr(100) + chr(101))('\x75' + chr(0b1101010 + 0o12) + '\146' + chr(0b0 + 0o55) + '\x38') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def PrVPqytAYTo8(Pj1cXaT_Euh0, yJFe33rl9i_r, cpMfQ_4_Vb7C):
def KQoumQEI3fB9(uyAR7jUe1VQb):
M8HTx_I8VoWH = ljKINYizAukk.build(xafqLlk3kkUe(SXOLrMavuUCe(b'\xff\x02'), '\144' + chr(0b10001 + 0o124) + chr(0b10010 + 0o121) + '\157' + chr(100) + chr(101))(chr(0b1110101) + chr(0b1110100) + '\x66' + '\x2d' + chr(275 - 219)), xafqLlk3kkUe(SXOLrMavuUCe(b'\xe4_'), '\144' + chr(101) + chr(0b1001100 + 0o27) + chr(0b1101111) + '\x64' + '\x65')(chr(0b1110101) + '\x74' + chr(102) + '\055' + '\x38'), credentials=Pj1cXaT_Euh0)
KojYgxZ3VIQZ = xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2\x1c\xd9\x02\xb8\xea\x80e\xf8 \xd1\x80\x0b\xc8t\xd2\xd1\xed]\x1a\xdb$V6\xda\xb1\xe9\xf3\xde\xad\x8f\x04^'), chr(0b1100100) + chr(101) + chr(0b111 + 0o134) + '\157' + chr(0b1100100) + chr(101))(chr(0b1110101) + chr(117 - 1) + chr(0b1100110) + '\x2d' + chr(2180 - 2124)) % (vGuSXaefydoS.default_project(), yJFe33rl9i_r, cpMfQ_4_Vb7C)
CE7M9xPq0X8s = {xafqLlk3kkUe(SXOLrMavuUCe(b'\xfb\x00\xc5\x1c\xbc\xe7\x97s\xa4'), chr(0b1010110 + 0o16) + '\x65' + '\x63' + chr(111) + chr(0b10100 + 0o120) + chr(7900 - 7799))(chr(117) + '\x74' + chr(1401 - 1299) + '\x2d' + chr(3020 - 2964)): [{xafqLlk3kkUe(SXOLrMavuUCe(b'\xfb\x00\xc6\x1d\xa9'), '\x64' + '\145' + '\143' + chr(10430 - 10319) + chr(0b1011110 + 0o6) + chr(5902 - 5801))('\165' + chr(116) + '\146' + chr(0b101101) + chr(0b111000)): {xafqLlk3kkUe(SXOLrMavuUCe(b'\xf0X\x82'), chr(0b1100100) + chr(0b111110 + 0o47) + chr(0b1100011) + chr(0b111001 + 0o66) + chr(0b1100100) + '\x65')(chr(0b1001100 + 0o51) + chr(13272 - 13156) + chr(102) + '\055' + chr(0b101000 + 0o20)): w4uTFQps09Ty.b64encode(DfdhY28yEwAF.SerializeToString())}} for DfdhY28yEwAF in uyAR7jUe1VQb]}
ys6Y0jo7ObhM = M8HTx_I8VoWH.projects().predict(body=CE7M9xPq0X8s, name=KojYgxZ3VIQZ).execute()
return ys6Y0jo7ObhM[xafqLlk3kkUe(SXOLrMavuUCe(b'\xe2\x1c\xd3\x0c\xb4\xea\x80\x7f\xb8k\xd1'), '\144' + '\x65' + '\x63' + chr(0b1111 + 0o140) + '\144' + chr(0b1100101))('\x75' + chr(12902 - 12786) + chr(0b1001101 + 0o31) + '\x2d' + '\x38')]
return KQoumQEI3fB9
|
tensorflow/tensor2tensor
|
tensor2tensor/serving/serving_utils.py
|
predict
|
def predict(inputs_list, problem, request_fn):
"""Encodes inputs, makes request to deployed TF model, and decodes outputs."""
assert isinstance(inputs_list, list)
fname = "inputs" if problem.has_inputs else "targets"
input_encoder = problem.feature_info[fname].encoder
input_ids_list = [
_encode(inputs, input_encoder, add_eos=problem.has_inputs)
for inputs in inputs_list
]
examples = [_make_example(input_ids, problem, fname)
for input_ids in input_ids_list]
predictions = request_fn(examples)
output_decoder = problem.feature_info["targets"].encoder
outputs = [
(_decode(prediction["outputs"], output_decoder),
prediction["scores"])
for prediction in predictions
]
return outputs
|
python
|
def predict(inputs_list, problem, request_fn):
"""Encodes inputs, makes request to deployed TF model, and decodes outputs."""
assert isinstance(inputs_list, list)
fname = "inputs" if problem.has_inputs else "targets"
input_encoder = problem.feature_info[fname].encoder
input_ids_list = [
_encode(inputs, input_encoder, add_eos=problem.has_inputs)
for inputs in inputs_list
]
examples = [_make_example(input_ids, problem, fname)
for input_ids in input_ids_list]
predictions = request_fn(examples)
output_decoder = problem.feature_info["targets"].encoder
outputs = [
(_decode(prediction["outputs"], output_decoder),
prediction["scores"])
for prediction in predictions
]
return outputs
|
[
"def",
"predict",
"(",
"inputs_list",
",",
"problem",
",",
"request_fn",
")",
":",
"assert",
"isinstance",
"(",
"inputs_list",
",",
"list",
")",
"fname",
"=",
"\"inputs\"",
"if",
"problem",
".",
"has_inputs",
"else",
"\"targets\"",
"input_encoder",
"=",
"problem",
".",
"feature_info",
"[",
"fname",
"]",
".",
"encoder",
"input_ids_list",
"=",
"[",
"_encode",
"(",
"inputs",
",",
"input_encoder",
",",
"add_eos",
"=",
"problem",
".",
"has_inputs",
")",
"for",
"inputs",
"in",
"inputs_list",
"]",
"examples",
"=",
"[",
"_make_example",
"(",
"input_ids",
",",
"problem",
",",
"fname",
")",
"for",
"input_ids",
"in",
"input_ids_list",
"]",
"predictions",
"=",
"request_fn",
"(",
"examples",
")",
"output_decoder",
"=",
"problem",
".",
"feature_info",
"[",
"\"targets\"",
"]",
".",
"encoder",
"outputs",
"=",
"[",
"(",
"_decode",
"(",
"prediction",
"[",
"\"outputs\"",
"]",
",",
"output_decoder",
")",
",",
"prediction",
"[",
"\"scores\"",
"]",
")",
"for",
"prediction",
"in",
"predictions",
"]",
"return",
"outputs"
] |
Encodes inputs, makes request to deployed TF model, and decodes outputs.
|
[
"Encodes",
"inputs",
"makes",
"request",
"to",
"deployed",
"TF",
"model",
"and",
"decodes",
"outputs",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/serving/serving_utils.py#L149-L167
|
train
|
Encodes inputs makes request to deployed TF model and decodes outputs.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSbbqk,pz9FlfzsWoy1,BXIwDASQ0Qkq,NL8dtWOpbcjF,_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NKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(0b110000) + '\157' + chr(1668 - 1619) + chr(51) + chr(0b11101 + 0o32), ord("\x08")), ehT0Px3KOsy9('\060' + chr(1278 - 1167) + '\062' + chr(52) + '\x37', 0o10), ehT0Px3KOsy9(chr(560 - 512) + chr(7600 - 7489) + '\x31' + '\067' + chr(0b110110), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(1782 - 1732) + chr(0b11110 + 0o31) + chr(873 - 822), 0b1000), ehT0Px3KOsy9(chr(0b11011 + 0o25) + chr(0b1101111) + chr(0b110000 + 0o2) + '\x36' + '\x30', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(2130 - 2081) + '\065' + chr(49), ord("\x08")), ehT0Px3KOsy9('\x30' + '\157' + '\063' + '\x33', 0b1000), ehT0Px3KOsy9(chr(0b101011 + 0o5) + chr(3338 - 3227) + chr(834 - 783) + chr(51) + '\065', 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b1001 + 0o55), 0o10), ehT0Px3KOsy9('\x30' + chr(0b111 + 0o150) + '\x31' + '\063' + chr(0b110110 + 0o1), 8), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(2362 - 2311) + chr(49) + '\066', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(0b11101 + 0o24) + '\066' + chr(55), 50277 - 50269), ehT0Px3KOsy9(chr(2085 - 2037) + chr(0b1101111) + chr(1175 - 1126) + '\x32' + chr(2335 - 2284), 11347 - 11339), ehT0Px3KOsy9(chr(48) + chr(0b11100 + 0o123) + chr(0b110011) + '\x31', 0o10), ehT0Px3KOsy9(chr(0b1111 + 0o41) + '\x6f' + chr(954 - 905) + chr(55) + chr(94 - 46), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b1110 + 0o43) + '\067' + chr(52), 0b1000), ehT0Px3KOsy9(chr(1352 - 1304) + '\x6f' + chr(2576 - 2525) + chr(0b110100) + chr(705 - 653), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\064', 0o10), ehT0Px3KOsy9(chr(48) + chr(6061 - 5950) + chr(0b110001) + chr(0b101000 + 0o13) + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(1584 - 1536) + chr(111) + chr(0b110010) + chr(48), 7089 - 7081), ehT0Px3KOsy9('\060' + chr(2061 - 1950) + chr(0b110100) + '\x31', ord("\x08")), ehT0Px3KOsy9(chr(859 - 811) + '\x6f' + chr(0b10011 + 0o37) + chr(1907 - 1856) + chr(48), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(0b100000 + 0o23) + chr(0b100001 + 0o23) + chr(55), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + '\x35' + '\x36', ord("\x08")), ehT0Px3KOsy9(chr(0b1100 + 0o44) + '\157' + '\063' + '\x31', 8), ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110100) + '\061', 8), ehT0Px3KOsy9('\060' + '\157' + chr(0b110101), ord("\x08")), ehT0Px3KOsy9(chr(1203 - 1155) + chr(0b110001 + 0o76) + '\062' + chr(2375 - 2320), 0o10), ehT0Px3KOsy9(chr(2199 - 2151) + '\157' + chr(0b111 + 0o53) + '\067' + chr(0b110001), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(51) + '\066' + '\066', 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(51) + chr(0b110 + 0o61) + chr(0b110000), ord("\x08")), ehT0Px3KOsy9(chr(0b11010 + 0o26) + chr(0b1101111) + '\061' + chr(519 - 469) + chr(0b110110), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1001111 + 0o40) + '\063' + chr(0b101 + 0o53) + chr(0b10010 + 0o40), 0b1000), ehT0Px3KOsy9(chr(0b1111 + 0o41) + chr(0b1101111) + '\x33' + chr(49) + chr(0b11010 + 0o26), 0b1000), ehT0Px3KOsy9(chr(569 - 521) + '\157' + '\x32' + chr(0b110101) + '\x32', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(2059 - 2008) + chr(0b100001 + 0o24) + '\x34', 0b1000), ehT0Px3KOsy9('\060' + '\157' + chr(1876 - 1825) + '\x33' + chr(416 - 365), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x33' + chr(48) + '\x30', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(111) + '\x37' + '\x34', 0b1000), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(49) + chr(53) + '\063', 0b1000)][WVxHKyX45z_L % ehT0Px3KOsy9(chr(48) + chr(7653 - 7542) + chr(0b110101) + chr(0b11101 + 0o23), 0o10)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'q'), '\144' + chr(0b1100101) + '\143' + chr(0b1101111) + chr(0b110011 + 0o61) + '\x65')(chr(693 - 576) + chr(116) + chr(102) + '\x2d' + chr(56)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def POyImYQwg5VB(z4VZIwhw1Vpr, sO7e1A_Mor6Q, zHJVBMKPML9S):
assert PlSM16l2KDPD(z4VZIwhw1Vpr, YyaZ4tpXu4lf)
t3WbF0Ae42Pu = xafqLlk3kkUe(SXOLrMavuUCe(b'6\xc9\x0e\xce\xc4\x1a'), chr(0b1100100) + chr(0b1100101) + chr(576 - 477) + chr(4646 - 4535) + '\x64' + '\145')('\x75' + chr(116) + chr(0b1100110) + chr(0b100111 + 0o6) + '\x38') if sO7e1A_Mor6Q.has_inputs else xafqLlk3kkUe(SXOLrMavuUCe(b'+\xc6\x0c\xdc\xd5\x1dh'), chr(0b1100100) + chr(0b110011 + 0o62) + '\143' + chr(0b1101111) + '\144' + chr(0b1100101))(chr(1558 - 1441) + chr(116) + '\x66' + '\055' + '\070')
deasXRn8f7yR = sO7e1A_Mor6Q.feature_info[t3WbF0Ae42Pu].hoK3K1TwFlkr
Juajon1TYlv4 = [fz8Voi0qb2km(vXoupepMtCXU, deasXRn8f7yR, add_eos=sO7e1A_Mor6Q.has_inputs) for vXoupepMtCXU in z4VZIwhw1Vpr]
uyAR7jUe1VQb = [sGFKIyInQebX(CyiZkgWrlgA9, sO7e1A_Mor6Q, t3WbF0Ae42Pu) for CyiZkgWrlgA9 in Juajon1TYlv4]
qIQi_VFCIFZL = zHJVBMKPML9S(uyAR7jUe1VQb)
R9ACy7X6T4pM = sO7e1A_Mor6Q.feature_info[xafqLlk3kkUe(SXOLrMavuUCe(b'+\xc6\x0c\xdc\xd5\x1dh'), '\144' + '\145' + '\x63' + chr(0b10011 + 0o134) + chr(0b100001 + 0o103) + chr(9490 - 9389))('\x75' + '\164' + chr(5976 - 5874) + chr(45) + chr(0b11 + 0o65))].hoK3K1TwFlkr
Dx_DllZ8uCko = [(e2_MW5rgHy_B(ys6Y0jo7ObhM[xafqLlk3kkUe(SXOLrMavuUCe(b'0\xd2\n\xcb\xc5\x1dh'), '\x64' + '\145' + '\x63' + '\157' + chr(0b1100100) + chr(101))(chr(0b1110101) + chr(116) + '\146' + '\055' + chr(0b110101 + 0o3))], R9ACy7X6T4pM), ys6Y0jo7ObhM[xafqLlk3kkUe(SXOLrMavuUCe(b',\xc4\x11\xc9\xd5\x1a'), chr(0b101010 + 0o72) + chr(6724 - 6623) + chr(7935 - 7836) + chr(5736 - 5625) + chr(0b1100100) + chr(0b1010000 + 0o25))(chr(0b1110101) + chr(12458 - 12342) + chr(0b101010 + 0o74) + chr(0b1001 + 0o44) + chr(602 - 546))]) for ys6Y0jo7ObhM in qIQi_VFCIFZL]
return Dx_DllZ8uCko
|
tensorflow/tensor2tensor
|
tensor2tensor/models/video/basic_recurrent.py
|
next_frame_basic_recurrent
|
def next_frame_basic_recurrent():
"""Basic 2-frame recurrent model with stochastic tower."""
hparams = basic_stochastic.next_frame_basic_stochastic_discrete()
hparams.filter_double_steps = 2
hparams.hidden_size = 64
hparams.video_num_input_frames = 4
hparams.video_num_target_frames = 4
hparams.concat_internal_states = False
hparams.add_hparam("num_lstm_layers", 2)
hparams.add_hparam("num_lstm_filters", 256)
return hparams
|
python
|
def next_frame_basic_recurrent():
"""Basic 2-frame recurrent model with stochastic tower."""
hparams = basic_stochastic.next_frame_basic_stochastic_discrete()
hparams.filter_double_steps = 2
hparams.hidden_size = 64
hparams.video_num_input_frames = 4
hparams.video_num_target_frames = 4
hparams.concat_internal_states = False
hparams.add_hparam("num_lstm_layers", 2)
hparams.add_hparam("num_lstm_filters", 256)
return hparams
|
[
"def",
"next_frame_basic_recurrent",
"(",
")",
":",
"hparams",
"=",
"basic_stochastic",
".",
"next_frame_basic_stochastic_discrete",
"(",
")",
"hparams",
".",
"filter_double_steps",
"=",
"2",
"hparams",
".",
"hidden_size",
"=",
"64",
"hparams",
".",
"video_num_input_frames",
"=",
"4",
"hparams",
".",
"video_num_target_frames",
"=",
"4",
"hparams",
".",
"concat_internal_states",
"=",
"False",
"hparams",
".",
"add_hparam",
"(",
"\"num_lstm_layers\"",
",",
"2",
")",
"hparams",
".",
"add_hparam",
"(",
"\"num_lstm_filters\"",
",",
"256",
")",
"return",
"hparams"
] |
Basic 2-frame recurrent model with stochastic tower.
|
[
"Basic",
"2",
"-",
"frame",
"recurrent",
"model",
"with",
"stochastic",
"tower",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/models/video/basic_recurrent.py#L52-L62
|
train
|
Basic 2 -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uw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110011) + chr(55), 0b1000), ehT0Px3KOsy9(chr(0b100001 + 0o17) + chr(0b1101011 + 0o4) + '\062' + chr(2744 - 2689), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(0b1101111) + chr(1411 - 1361) + '\x32' + chr(0b110100), ord("\x08")), ehT0Px3KOsy9('\x30' + chr(516 - 405) + '\063' + '\064' + chr(0b1 + 0o60), 0o10), ehT0Px3KOsy9('\060' + chr(111) + '\x32' + chr(0b110000) + chr(54), 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + chr(1911 - 1862) + '\064' + chr(52), 0o10), ehT0Px3KOsy9(chr(48) + '\157' + '\x31' + chr(0b110011) + '\x34', 0o10), ehT0Px3KOsy9(chr(48) + '\x6f' + '\062' + chr(0b110001) + '\061', 0b1000), ehT0Px3KOsy9('\x30' + chr(111) + '\x33' + chr(0b101101 + 0o11) + chr(53), 31192 - 31184), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110011) + chr(2254 - 2206), ord("\x08")), ehT0Px3KOsy9(chr(2140 - 2092) + '\157' + '\x32' + chr(52) + '\x36', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(10225 - 10114) + '\063' + chr(0b1100 + 0o46) + chr(204 - 154), 0b1000), ehT0Px3KOsy9(chr(0b11010 + 0o26) + chr(111) + chr(0b110011) + chr(0b110110) + chr(1350 - 1301), ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b111000 + 0o67) + '\x32' + '\x30' + chr(53), 0o10), ehT0Px3KOsy9('\060' + chr(0b1101111) + '\062' + chr(52) + chr(0b110000 + 0o6), 8), ehT0Px3KOsy9('\060' + chr(0b11101 + 0o122) + chr(50) + '\065' + chr(0b101 + 0o61), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b110100) + '\065', 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\x32' + chr(0b110 + 0o53) + chr(718 - 663), 0b1000), ehT0Px3KOsy9('\x30' + '\157' + '\x35' + chr(1185 - 1131), 28981 - 28973), ehT0Px3KOsy9(chr(0b11110 + 0o22) + chr(111) + chr(235 - 180) + '\060', 54196 - 54188), ehT0Px3KOsy9(chr(0b110000) + chr(111) + '\061' + chr(0b110000) + chr(0b110000 + 0o0), 0o10), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(50) + chr(745 - 696) + '\067', 8), ehT0Px3KOsy9(chr(392 - 344) + chr(0b100011 + 0o114) + chr(0b1000 + 0o52) + '\067' + chr(0b110110), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1001101 + 0o42) + '\x32' + chr(0b110010), 31584 - 31576), ehT0Px3KOsy9(chr(0b100001 + 0o17) + '\157' + '\061' + '\063' + chr(1065 - 1013), 8), ehT0Px3KOsy9(chr(627 - 579) + '\x6f' + chr(0b100010 + 0o22) + chr(0b10100 + 0o41), 8), ehT0Px3KOsy9(chr(48) + chr(0b1001000 + 0o47) + chr(52) + chr(0b110011), ord("\x08")), ehT0Px3KOsy9('\x30' + '\x6f' + chr(597 - 547) + '\x30' + '\x32', 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\063' + chr(1343 - 1288) + '\064', 33638 - 33630), ehT0Px3KOsy9('\060' + chr(3294 - 3183) + '\x32' + chr(0b1100 + 0o50) + chr(1632 - 1584), 0b1000), ehT0Px3KOsy9(chr(48) + '\157' + chr(1811 - 1761) + chr(1787 - 1737), 8), ehT0Px3KOsy9(chr(0b1101 + 0o43) + '\157' + chr(0b100100 + 0o17) + chr(0b100000 + 0o23), 4385 - 4377), ehT0Px3KOsy9('\x30' + chr(0b11001 + 0o126) + chr(144 - 95) + chr(0b110001) + '\065', 17824 - 17816), ehT0Px3KOsy9(chr(2292 - 2244) + chr(0b10010 + 0o135) + chr(1021 - 970) + chr(1508 - 1454), 0o10), ehT0Px3KOsy9(chr(2262 - 2214) + '\x6f' + chr(50) + '\064', 43844 - 43836), ehT0Px3KOsy9(chr(1436 - 1388) + chr(9982 - 9871) + '\x33' + chr(54) + chr(0b100011 + 0o22), 8), ehT0Px3KOsy9(chr(0b11011 + 0o25) + '\157' + chr(0b101 + 0o56) + '\060' + chr(0b110001), 58051 - 58043), ehT0Px3KOsy9(chr(0b11010 + 0o26) + '\157' + chr(0b11011 + 0o26) + '\x31' + chr(1877 - 1823), ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(12079 - 11968) + chr(0b110111 + 0o0) + '\064', 0b1000), ehT0Px3KOsy9('\x30' + chr(5892 - 5781) + chr(0b110101) + '\064', ord("\x08"))][WVxHKyX45z_L % ehT0Px3KOsy9(chr(1729 - 1681) + chr(1760 - 1649) + chr(0b10110 + 0o37) + chr(1062 - 1014), 2396 - 2388)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'1'), chr(7051 - 6951) + chr(0b1100101) + chr(8598 - 8499) + '\x6f' + '\x64' + chr(101))(chr(117) + chr(116) + '\x66' + chr(0b101000 + 0o5) + '\070') + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def yCTrkKKSAIgU():
n4ljua2gi1Pr = RvMzMhQ9W7ZW.next_frame_basic_stochastic_discrete()
n4ljua2gi1Pr.l3Jb92JIYIRX = ehT0Px3KOsy9(chr(771 - 723) + chr(5488 - 5377) + chr(1563 - 1513), 0b1000)
n4ljua2gi1Pr.qzoyXN3kdhDL = ehT0Px3KOsy9('\x30' + chr(111) + '\x31' + chr(0b110000) + '\x30', 8)
n4ljua2gi1Pr.UUXW9NWPZxPI = ehT0Px3KOsy9(chr(0b100110 + 0o12) + chr(111) + chr(0b110100), ord("\x08"))
n4ljua2gi1Pr.UxYiT0ZFW2SZ = ehT0Px3KOsy9('\060' + '\157' + '\x34', 8)
n4ljua2gi1Pr.xt8TSTUNLPTf = ehT0Px3KOsy9('\x30' + chr(111) + chr(0b110000), 0b1000)
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'~s\xf0\xbe\xee\x14=\xfb\x94u'), chr(5319 - 5219) + chr(0b1100101) + chr(0b1100011 + 0o0) + '\x6f' + chr(0b1100100) + '\145')(chr(0b1000111 + 0o56) + chr(11467 - 11351) + chr(6779 - 6677) + chr(45) + chr(0b110010 + 0o6)))(xafqLlk3kkUe(SXOLrMavuUCe(b'qb\xf9\xbe\xea\x17(\xe4\xaat\xc7\xab\x94\xf7\xd5'), '\x64' + chr(9358 - 9257) + chr(99) + '\157' + '\x64' + '\x65')('\165' + chr(12674 - 12558) + '\146' + chr(0b10101 + 0o30) + '\x38'), ehT0Px3KOsy9(chr(0b110000) + '\x6f' + chr(1995 - 1945), 8))
xafqLlk3kkUe(n4ljua2gi1Pr, xafqLlk3kkUe(SXOLrMavuUCe(b'~s\xf0\xbe\xee\x14=\xfb\x94u'), chr(100) + chr(0b1000111 + 0o36) + '\x63' + '\x6f' + '\x64' + chr(0b10011 + 0o122))('\x75' + chr(0b11101 + 0o127) + chr(0b100 + 0o142) + chr(1992 - 1947) + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'qb\xf9\xbe\xea\x17(\xe4\xaa~\xcf\xbe\x85\xe0\xd4\xdd'), chr(0b1100100) + chr(0b110100 + 0o61) + '\143' + '\x6f' + chr(7890 - 7790) + '\x65')('\165' + chr(116) + '\146' + '\x2d' + chr(0b101000 + 0o20)), ehT0Px3KOsy9('\060' + chr(111) + chr(52) + chr(0b110000) + '\060', 0o10))
return n4ljua2gi1Pr
|
tensorflow/tensor2tensor
|
tensor2tensor/bin/t2t_distill.py
|
create_teacher_experiment
|
def create_teacher_experiment(run_config, hparams, argv):
"""Creates experiment function."""
tf.logging.info("training teacher")
tf.logging.set_verbosity(tf.logging.INFO)
trainer_lib.set_random_seed(FLAGS.random_seed)
usr_dir.import_usr_dir(FLAGS.t2t_usr_dir)
t2t_trainer.maybe_log_registry_and_exit()
if FLAGS.cloud_mlengine:
return cloud_mlengine.launch()
if FLAGS.generate_data:
t2t_trainer.generate_data()
if cloud_mlengine.job_dir():
FLAGS.output_dir = cloud_mlengine.job_dir()
if argv:
t2t_trainer.set_hparams_from_args(argv[1:])
hparams.distill_phase = "train"
exp_fn = t2t_trainer.create_experiment_fn()
exp = exp_fn(run_config, hparams)
return exp
|
python
|
def create_teacher_experiment(run_config, hparams, argv):
"""Creates experiment function."""
tf.logging.info("training teacher")
tf.logging.set_verbosity(tf.logging.INFO)
trainer_lib.set_random_seed(FLAGS.random_seed)
usr_dir.import_usr_dir(FLAGS.t2t_usr_dir)
t2t_trainer.maybe_log_registry_and_exit()
if FLAGS.cloud_mlengine:
return cloud_mlengine.launch()
if FLAGS.generate_data:
t2t_trainer.generate_data()
if cloud_mlengine.job_dir():
FLAGS.output_dir = cloud_mlengine.job_dir()
if argv:
t2t_trainer.set_hparams_from_args(argv[1:])
hparams.distill_phase = "train"
exp_fn = t2t_trainer.create_experiment_fn()
exp = exp_fn(run_config, hparams)
return exp
|
[
"def",
"create_teacher_experiment",
"(",
"run_config",
",",
"hparams",
",",
"argv",
")",
":",
"tf",
".",
"logging",
".",
"info",
"(",
"\"training teacher\"",
")",
"tf",
".",
"logging",
".",
"set_verbosity",
"(",
"tf",
".",
"logging",
".",
"INFO",
")",
"trainer_lib",
".",
"set_random_seed",
"(",
"FLAGS",
".",
"random_seed",
")",
"usr_dir",
".",
"import_usr_dir",
"(",
"FLAGS",
".",
"t2t_usr_dir",
")",
"t2t_trainer",
".",
"maybe_log_registry_and_exit",
"(",
")",
"if",
"FLAGS",
".",
"cloud_mlengine",
":",
"return",
"cloud_mlengine",
".",
"launch",
"(",
")",
"if",
"FLAGS",
".",
"generate_data",
":",
"t2t_trainer",
".",
"generate_data",
"(",
")",
"if",
"cloud_mlengine",
".",
"job_dir",
"(",
")",
":",
"FLAGS",
".",
"output_dir",
"=",
"cloud_mlengine",
".",
"job_dir",
"(",
")",
"if",
"argv",
":",
"t2t_trainer",
".",
"set_hparams_from_args",
"(",
"argv",
"[",
"1",
":",
"]",
")",
"hparams",
".",
"distill_phase",
"=",
"\"train\"",
"exp_fn",
"=",
"t2t_trainer",
".",
"create_experiment_fn",
"(",
")",
"exp",
"=",
"exp_fn",
"(",
"run_config",
",",
"hparams",
")",
"return",
"exp"
] |
Creates experiment function.
|
[
"Creates",
"experiment",
"function",
"."
] |
272500b6efe353aeb638d2745ed56e519462ca31
|
https://github.com/tensorflow/tensor2tensor/blob/272500b6efe353aeb638d2745ed56e519462ca31/tensor2tensor/bin/t2t_distill.py#L91-L114
|
train
|
Creates experiment function.
|
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGLtp_O,sR2sPcm7Zrfn,yROw0HWBk0Qc,j9rjMYnN2BMp,hIlP7994qj8O,_fsda0v2_OKU,o0CgT5HPthxA,DXjfarvgFnbl,RQ6CSRrFArYB,RouZF7bjEXAv,jIl9qoALCRyb,bdLuls3EQFSd,FXUco0R3m83n,V5s4UV3vwoyK,Q6d3QdTENfxw,sbc9gub6LIFp,QWgp4ELTmqy4,_zJ24Vce7wp0,KlPSljPzIJ_u,N5Ee6d9YGQ_x,yDcnbVVBZ5VZ,OTstrxJfIC1n,GXwwnDRMCHJX,a9IKoVgO_m3w,GNd6AVvhYicE,ixtrydDuthdu,n0ZkatoveZpF,eh4BeXwijHpf,ZMHESMWYyt8h,hr2QaoivbFQ2,Iiw8L0MH5qfg,koCeDPYTrOFe,qqrhSmCSb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Fey,zLUzGokYBM2Z,FL7SmUoxlR9h,k6bl9sLammpH,vQr8gNKaIaWE,S6hV9M2g7fO0,RFiwrCZH9Ie6,jB_HdqgHmVpI,MVEN8G6CxlvR,t0rOMsrOC7R_,W3g84rNiEdDQ,vUlqIvNSaRMa,gDnh40_OUDCn,M8_cKLkHVB2V,xkxBmo49x2An,KNx0Ujaz9UM0,KNyTy8rYcwji,wmQmyeWBmUpv,p1G5VS3dE_Ss,pZ0NK2y6HRbn,HByLaO1XdVEe,pgRJLRS7Iy8j,OZYzwAeSQh7N,tmzuw0hjv33u,RwRZiUMA3VWp,Gbej4oZqKLA6,TqkAMbUz4aLg,rw68imZ2Ikxp=ArithmeticError,AssertionError,AttributeError,BaseException,BlockingIOError,BrokenPipeError,BufferError,BytesWarning,ChildProcessError,ConnectionAbortedError,ConnectionError,ConnectionRefusedError,ConnectionResetError,DeprecationWarning,EOFError,Ellipsis,EncodingWarning,EnvironmentError,Exception,False,FileExistsError,FileNotFoundError,FloatingPointError,FutureWarning,GeneratorExit,IOError,ImportError,ImportWarning,IndentationError,IndexError,InterruptedError,IsADirectoryError,KeyError,KeyboardInterrupt,LookupError,MemoryError,ModuleNotFoundError,NameError,None,NotADirectoryError,NotImplemented,NotImplementedError,OSError,OverflowError,PendingDeprecationWarning,PermissionError,ProcessLookupError,RecursionError,ReferenceError,ResourceWarning,RuntimeError,RuntimeWarning,StopAsyncIteration,StopIteration,SyntaxError,SyntaxWarning,SystemError,SystemExit,TabError,TimeoutError,True,TypeError,UnboundLocalError,UnicodeDecodeError,UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,UserWarning,ValueError,Warning,WindowsError,ZeroDivisionError,__build_class__,__debug__,__doc__,__import__,__loader__,__name__,__package__,__spec__,abs,aiter,all,anext,any,ascii,bin,bool,breakpoint,bytearray,bytes,callable,chr,classmethod,compile,complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,exec,exit,filter,float,format,frozenset,getattr,globals,hasattr,hash,help,hex,id,input,int,isinstance,issubclass,iter,len,license,list,locals,map,max,memoryview,min,next,object,oct,open,ord,pow,print,property,quit,range,repr,reversed,round,set,setattr,slice,sorted,staticmethod,str,sum,super,tuple,type,vars,zip,__builtins__,__cached__,__doc__,__file__,__loader__,__name__,__package__,__spec__
SXOLrMavuUCe = lambda XbwU38w7NW8n: QOfmzcVJsrp8([OeWW0F1dBPRQ ^ [ehT0Px3KOsy9(chr(1527 - 1479) + '\157' + chr(0b101101 + 0o4) + chr(0b110000) + chr(0b110100), 0b1000), ehT0Px3KOsy9(chr(983 - 935) + chr(111) + chr(1087 - 1036) + '\x33', ord("\x08")), ehT0Px3KOsy9('\x30' + chr(111) + chr(1418 - 1367) + chr(0b110001) + chr(52), 0o10), ehT0Px3KOsy9(chr(1131 - 1083) + chr(4430 - 4319) + chr(49) + chr(51) + '\061', 0o10), ehT0Px3KOsy9('\x30' + chr(0b1101111) + '\x31' + '\x34' + chr(656 - 608), 0o10), ehT0Px3KOsy9(chr(0b101011 + 0o5) + '\x6f' + chr(1004 - 954) + '\061' + chr(0b100001 + 0o26), 65242 - 65234), ehT0Px3KOsy9(chr(48) + chr(6991 - 6880) + chr(0b110001) + '\x35' + chr(0b11010 + 0o32), 0b1000), ehT0Px3KOsy9(chr(0b111 + 0o51) + chr(0b1101111) + chr(0b101010 + 0o11) + chr(308 - 256) + '\x36', 0o10), ehT0Px3KOsy9('\060' + '\x6f' + chr(0b110 + 0o54) + '\x36' + '\060', 41018 - 41010), ehT0Px3KOsy9('\060' + '\157' + chr(811 - 762) + '\x33' + chr(796 - 744), ord("\x08")), ehT0Px3KOsy9('\060' + chr(111) + chr(49) + '\x30' + '\066', 5157 - 5149), ehT0Px3KOsy9(chr(48) + chr(111) + chr(0b101100 + 0o7) + chr(49) + chr(51), 0b1000), ehT0Px3KOsy9(chr(48) + chr(111) + chr(336 - 286) + chr(54), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b110111 + 0o70) + chr(0b110000 + 0o1) + chr(2793 - 2740) + chr(0b110010), ord("\x08")), ehT0Px3KOsy9('\060' + chr(11007 - 10896) + chr(1511 - 1458), 0o10), ehT0Px3KOsy9(chr(0b0 + 0o60) + chr(0b1101110 + 0o1) + chr(0b10111 + 0o35), ord("\x08")), ehT0Px3KOsy9(chr(1635 - 1587) + chr(111) + chr(231 - 180) + '\065' + '\065', ord("\x08")), ehT0Px3KOsy9(chr(0b110000) + chr(1621 - 1510) + chr(1931 - 1881) + chr(195 - 145) + chr(2249 - 2201), 0b1000), ehT0Px3KOsy9('\x30' + chr(0b1001110 + 0o41) + chr(877 - 826) + chr(48) + chr(0b101010 + 0o14), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(649 - 600) + chr(48) + chr(54), 8), ehT0Px3KOsy9(chr(0b101001 + 0o7) + '\157' + chr(0b110011) + chr(0b110011) + '\067', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(49) + chr(0b110001) + '\x30', 0b1000), ehT0Px3KOsy9('\x30' + '\x6f' + '\x31' + chr(52) + chr(418 - 365), 0b1000), ehT0Px3KOsy9(chr(48) + chr(0b1000101 + 0o52) + '\x33' + chr(386 - 332) + '\x33', ord("\x08")), ehT0Px3KOsy9(chr(1751 - 1703) + chr(0b1101111) + chr(1234 - 1185) + chr(54) + chr(50), 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + '\x31' + '\062', 0o10), ehT0Px3KOsy9(chr(1193 - 1145) + chr(0b101 + 0o152) + '\x37' + chr(0b1010 + 0o53), ord("\x08")), ehT0Px3KOsy9('\060' + chr(7660 - 7549) + chr(0b100011 + 0o17) + chr(0b11010 + 0o33) + '\067', 0o10), ehT0Px3KOsy9(chr(0b110000) + chr(111) + chr(0b110011) + chr(0b100011 + 0o22) + '\x33', ord("\x08")), ehT0Px3KOsy9(chr(48) + chr(0b1101111) + chr(0b110110) + chr(48), 56760 - 56752), ehT0Px3KOsy9('\x30' + '\x6f' + '\x31' + chr(914 - 862) + '\x36', 0b1000), ehT0Px3KOsy9(chr(0b11010 + 0o26) + chr(0b1101111) + chr(1569 - 1520) + '\x33' + chr(0b100001 + 0o25), 0b1000), ehT0Px3KOsy9(chr(1379 - 1331) + chr(111) + chr(0b110010) + '\x34' + chr(0b11100 + 0o30), 62750 - 62742), ehT0Px3KOsy9(chr(0b110000) + chr(0b1011000 + 0o27) + chr(758 - 708) + chr(0b110111) + chr(439 - 391), 0o10), ehT0Px3KOsy9('\x30' + chr(0b1001010 + 0o45) + chr(50) + '\066' + chr(0b110010), 0b1000), ehT0Px3KOsy9(chr(1745 - 1697) + chr(0b11101 + 0o122) + chr(0b110001) + chr(0b110011) + '\066', 8), ehT0Px3KOsy9(chr(48) + '\x6f' + chr(51) + chr(2106 - 2053) + chr(55), 0b1000), ehT0Px3KOsy9('\060' + chr(11134 - 11023) + chr(0b110111) + chr(0b110111), 0b1000), ehT0Px3KOsy9(chr(0b110000) + chr(0b1101111) + chr(1737 - 1686) + chr(1503 - 1452) + chr(0b101000 + 0o13), 52324 - 52316), ehT0Px3KOsy9('\x30' + '\157' + chr(658 - 608) + chr(48) + chr(0b11011 + 0o34), 56195 - 56187)][WVxHKyX45z_L % ehT0Px3KOsy9('\x30' + '\x6f' + '\065' + chr(664 - 616), 0b1000)] for (WVxHKyX45z_L, OeWW0F1dBPRQ) in YlkZvXL8qwsX(XbwU38w7NW8n)])
def NPPHb59961Bv(RqocVGOryNPv, _CF03Rifpmdh):
try:
return jFWsnpHpAUWz(RqocVGOryNPv + xafqLlk3kkUe(SXOLrMavuUCe(b'j'), '\144' + chr(6565 - 6464) + chr(0b1100011) + chr(0b101 + 0o152) + chr(100) + chr(0b1100101))(chr(0b1110101) + '\x74' + chr(3446 - 3344) + chr(0b100101 + 0o10) + chr(0b111000)) + _CF03Rifpmdh)
except yROw0HWBk0Qc:
return jFWsnpHpAUWz(RqocVGOryNPv)
def HWZicVbDcDoW(XwFhQmkvbPWZ, n4ljua2gi1Pr, Dw9NS1vKj6EW):
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b'\x17,\x84!\x15\xec\x0b\xd1\xda0\x1c\xa0'), chr(0b100100 + 0o100) + '\x65' + chr(0b1010000 + 0o23) + chr(111) + '\x64' + chr(101))(chr(0b1110101) + chr(0b1001010 + 0o52) + chr(4309 - 4207) + '\055' + chr(0b111000)))(xafqLlk3kkUe(SXOLrMavuUCe(b'0i\xad0\x0e\xe6\x02\x81\x90(#\xaau\x02`v'), chr(100) + '\145' + chr(0b1100011) + chr(111) + '\144' + '\x65')(chr(11031 - 10914) + '\164' + chr(4127 - 4025) + '\055' + '\x38'))
xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b'7~\xb8\x06\x16\xea\x1e\x84\xdf//\xbfo'), chr(0b1100100) + chr(3063 - 2962) + chr(0b1011100 + 0o7) + '\x6f' + chr(0b1100100) + chr(7067 - 6966))(chr(0b1110101) + chr(9107 - 8991) + '\x66' + chr(0b0 + 0o55) + chr(495 - 439)))(xafqLlk3kkUe(IDJ2eXGCBCDu.logging, xafqLlk3kkUe(SXOLrMavuUCe(b'\rU\x8a\x16'), chr(0b1100100) + chr(0b1100101) + chr(4423 - 4324) + chr(2251 - 2140) + '\x64' + chr(0b1100101))(chr(0b1110101) + chr(0b1100 + 0o150) + '\x66' + chr(0b101101) + chr(0b111000))))
xafqLlk3kkUe(KvtIAVGi33Ty, xafqLlk3kkUe(SXOLrMavuUCe(b'7~\xb8\x06\x12\xee\x02\x82\xdf1\x19\xb8s\x0fa'), chr(0b1000010 + 0o42) + '\x65' + '\143' + chr(5215 - 5104) + chr(100) + chr(7760 - 7659))(chr(117) + '\164' + '\146' + chr(0b1 + 0o54) + chr(0b111000)))(xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'6z\xa2=\x0f\xe23\x95\xd59"'), chr(0b1100100) + '\x65' + '\x63' + '\x6f' + '\x64' + chr(254 - 153))(chr(117) + chr(116) + '\146' + chr(45) + '\070')))
xafqLlk3kkUe(Ee2uuYhe3rVI, xafqLlk3kkUe(SXOLrMavuUCe(b'-v\xbc6\x12\xfb3\x93\xc3.\x19\xaf\x7f\x18'), chr(202 - 102) + chr(0b1100000 + 0o5) + chr(99) + chr(111) + chr(1338 - 1238) + chr(101))(chr(6452 - 6335) + '\x74' + chr(870 - 768) + chr(0b101101) + chr(0b111000)))(xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b'0)\xb8\x06\x15\xfc\x1e\xb9\xd454'), chr(2888 - 2788) + chr(0b1100101) + chr(0b1100011) + chr(1827 - 1716) + '\x64' + chr(0b1111 + 0o126))('\x75' + '\x74' + chr(102) + chr(0b101101) + chr(56))))
xafqLlk3kkUe(iSWMRIfmjO0x, xafqLlk3kkUe(SXOLrMavuUCe(b")z\xb5;\x05\xd0\x00\x89\xd7\x034\xaeq\x03vp\x9f\xe9\x99'\xb1,:\x96\ncI"), '\144' + chr(101) + '\x63' + '\x6f' + '\x64' + '\145')(chr(0b1110101) + chr(0b111111 + 0o65) + chr(0b1100010 + 0o4) + chr(328 - 283) + chr(0b100111 + 0o21)))()
if xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b"'w\xa3,\x04\xd0\x01\x8a\xd52!\xa2x\x0f"), chr(0b1100100) + chr(0b10 + 0o143) + chr(99) + chr(5939 - 5828) + chr(100) + chr(0b1100101))('\165' + chr(0b1110100) + chr(102) + chr(281 - 236) + chr(0b111000))):
return xafqLlk3kkUe(ol_YtLsZz01h, xafqLlk3kkUe(SXOLrMavuUCe(b'(z\xb97\x03\xe7'), chr(100) + '\145' + chr(0b11111 + 0o104) + '\x6f' + chr(0b101101 + 0o67) + chr(101))(chr(117) + '\x74' + chr(102) + chr(0b1110 + 0o37) + chr(0b1111 + 0o51)))()
if xafqLlk3kkUe(vUTZFbqN0o8F, xafqLlk3kkUe(SXOLrMavuUCe(b"#~\xa2<\x12\xee\x18\x83\xef8'\xbfw"), chr(0b1100100) + chr(3964 - 3863) + chr(0b1110 + 0o125) + '\x6f' + chr(0b10110 + 0o116) + chr(0b1100101))(chr(0b1110101) + '\x74' + '\146' + chr(45) + chr(0b111000))):
xafqLlk3kkUe(iSWMRIfmjO0x, xafqLlk3kkUe(SXOLrMavuUCe(b"#~\xa2<\x12\xee\x18\x83\xef8'\xbfw"), '\144' + chr(8158 - 8057) + '\x63' + '\x6f' + chr(100) + '\145')(chr(0b1110101) + chr(7385 - 7269) + chr(0b1011100 + 0o12) + chr(45) + '\070'))()
if xafqLlk3kkUe(ol_YtLsZz01h, xafqLlk3kkUe(SXOLrMavuUCe(b'.t\xae\x06\x04\xe6\x1e'), chr(0b1100100) + '\145' + '\x63' + chr(0b10110 + 0o131) + '\x64' + chr(0b101001 + 0o74))(chr(0b1110011 + 0o2) + chr(0b10100 + 0o140) + chr(0b1100110) + '\055' + chr(56)))():
vUTZFbqN0o8F.nd0OX_BS6_o4 = ol_YtLsZz01h.job_dir()
if Dw9NS1vKj6EW:
xafqLlk3kkUe(iSWMRIfmjO0x, xafqLlk3kkUe(SXOLrMavuUCe(b'7~\xb8\x06\x08\xff\r\x94\xd115\x94p\x18ji\xb2\xf1\xb4!\xac'), chr(0b10001 + 0o123) + chr(1669 - 1568) + '\143' + chr(527 - 416) + chr(0b110110 + 0o56) + chr(101))('\165' + chr(8535 - 8419) + '\146' + '\055' + chr(56)))(Dw9NS1vKj6EW[ehT0Px3KOsy9(chr(917 - 869) + '\x6f' + chr(0b10 + 0o57), ord("\x08")):])
n4ljua2gi1Pr.HM0SzqqE9LNm = xafqLlk3kkUe(SXOLrMavuUCe(b'0i\xad0\x0e'), chr(100) + '\145' + chr(3968 - 3869) + chr(0b1101111) + chr(0b110001 + 0o63) + chr(2817 - 2716))(chr(8682 - 8565) + chr(0b111101 + 0o67) + chr(0b1100110) + '\x2d' + chr(0b111000))
Ozdedat8cP7v = iSWMRIfmjO0x.create_experiment_fn()
quvessij56om = Ozdedat8cP7v(XwFhQmkvbPWZ, n4ljua2gi1Pr)
return quvessij56om
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.