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
sequencelengths 20
28.4k
| docstring
stringlengths 1
46.3k
| docstring_tokens
sequencelengths 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
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
BerkeleyAutomation/perception | perception/image.py | BinaryImage.add_frame | def add_frame(
self,
left_boundary,
right_boundary,
upper_boundary,
lower_boundary):
""" Adds a frame to the image, e.g. turns the boundaries white
Parameters
----------
left_boundary : int
the leftmost boundary of the frame
right_boundary : int
the rightmost boundary of the frame (must be greater than left_boundary)
upper_boundary : int
the upper boundary of the frame
lower_boundary : int
the lower boundary of the frame (must be greater than upper_boundary)
Returns
-------
:obj:`BinaryImage`
binary image with white (BINARY_IM_MAX_VAL) on the boundaries
"""
# check valid boundary pixels
left_boundary = max(0, left_boundary)
right_boundary = min(self.width - 1, right_boundary)
upper_boundary = max(0, upper_boundary)
lower_boundary = min(self.height - 1, lower_boundary)
if right_boundary < left_boundary:
raise ValueError(
'Left boundary must be smaller than the right boundary')
if upper_boundary > lower_boundary:
raise ValueError(
'Upper boundary must be smaller than the lower boundary')
# fill in border pixels
bordered_data = self.data.copy()
bordered_data[:upper_boundary, :] = BINARY_IM_MAX_VAL
bordered_data[lower_boundary:, :] = BINARY_IM_MAX_VAL
bordered_data[:, :left_boundary] = BINARY_IM_MAX_VAL
bordered_data[:, right_boundary:] = BINARY_IM_MAX_VAL
return BinaryImage(bordered_data, frame=self._frame) | python | def add_frame(
self,
left_boundary,
right_boundary,
upper_boundary,
lower_boundary):
""" Adds a frame to the image, e.g. turns the boundaries white
Parameters
----------
left_boundary : int
the leftmost boundary of the frame
right_boundary : int
the rightmost boundary of the frame (must be greater than left_boundary)
upper_boundary : int
the upper boundary of the frame
lower_boundary : int
the lower boundary of the frame (must be greater than upper_boundary)
Returns
-------
:obj:`BinaryImage`
binary image with white (BINARY_IM_MAX_VAL) on the boundaries
"""
# check valid boundary pixels
left_boundary = max(0, left_boundary)
right_boundary = min(self.width - 1, right_boundary)
upper_boundary = max(0, upper_boundary)
lower_boundary = min(self.height - 1, lower_boundary)
if right_boundary < left_boundary:
raise ValueError(
'Left boundary must be smaller than the right boundary')
if upper_boundary > lower_boundary:
raise ValueError(
'Upper boundary must be smaller than the lower boundary')
# fill in border pixels
bordered_data = self.data.copy()
bordered_data[:upper_boundary, :] = BINARY_IM_MAX_VAL
bordered_data[lower_boundary:, :] = BINARY_IM_MAX_VAL
bordered_data[:, :left_boundary] = BINARY_IM_MAX_VAL
bordered_data[:, right_boundary:] = BINARY_IM_MAX_VAL
return BinaryImage(bordered_data, frame=self._frame) | [
"def",
"add_frame",
"(",
"self",
",",
"left_boundary",
",",
"right_boundary",
",",
"upper_boundary",
",",
"lower_boundary",
")",
":",
"# check valid boundary pixels",
"left_boundary",
"=",
"max",
"(",
"0",
",",
"left_boundary",
")",
"right_boundary",
"=",
"min",
"(",
"self",
".",
"width",
"-",
"1",
",",
"right_boundary",
")",
"upper_boundary",
"=",
"max",
"(",
"0",
",",
"upper_boundary",
")",
"lower_boundary",
"=",
"min",
"(",
"self",
".",
"height",
"-",
"1",
",",
"lower_boundary",
")",
"if",
"right_boundary",
"<",
"left_boundary",
":",
"raise",
"ValueError",
"(",
"'Left boundary must be smaller than the right boundary'",
")",
"if",
"upper_boundary",
">",
"lower_boundary",
":",
"raise",
"ValueError",
"(",
"'Upper boundary must be smaller than the lower boundary'",
")",
"# fill in border pixels",
"bordered_data",
"=",
"self",
".",
"data",
".",
"copy",
"(",
")",
"bordered_data",
"[",
":",
"upper_boundary",
",",
":",
"]",
"=",
"BINARY_IM_MAX_VAL",
"bordered_data",
"[",
"lower_boundary",
":",
",",
":",
"]",
"=",
"BINARY_IM_MAX_VAL",
"bordered_data",
"[",
":",
",",
":",
"left_boundary",
"]",
"=",
"BINARY_IM_MAX_VAL",
"bordered_data",
"[",
":",
",",
"right_boundary",
":",
"]",
"=",
"BINARY_IM_MAX_VAL",
"return",
"BinaryImage",
"(",
"bordered_data",
",",
"frame",
"=",
"self",
".",
"_frame",
")"
] | Adds a frame to the image, e.g. turns the boundaries white
Parameters
----------
left_boundary : int
the leftmost boundary of the frame
right_boundary : int
the rightmost boundary of the frame (must be greater than left_boundary)
upper_boundary : int
the upper boundary of the frame
lower_boundary : int
the lower boundary of the frame (must be greater than upper_boundary)
Returns
-------
:obj:`BinaryImage`
binary image with white (BINARY_IM_MAX_VAL) on the boundaries | [
"Adds",
"a",
"frame",
"to",
"the",
"image",
"e",
".",
"g",
".",
"turns",
"the",
"boundaries",
"white"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2544-L2587 | train | Adds a frame to the image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB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,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\060' + chr(0b1101111) + chr(1235 - 1182) + chr(2022 - 1971), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(49) + '\063' + '\066', 0o10), nzTpIcepk0o8(chr(1175 - 1127) + chr(8018 - 7907) + '\x34' + '\x37', 0b1000), nzTpIcepk0o8(chr(0b11001 + 0o27) + chr(0b1101111) + chr(0b110001) + chr(53) + chr(0b101 + 0o54), 0o10), nzTpIcepk0o8(chr(0b100000 + 0o20) + chr(0b1101111) + chr(1215 - 1166) + '\060' + chr(0b110101), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b100100 + 0o113) + chr(0b100010 + 0o21), 50305 - 50297), nzTpIcepk0o8('\060' + chr(4073 - 3962) + '\x32' + chr(0b110111) + chr(0b110000), 0o10), nzTpIcepk0o8('\x30' + '\157' + '\061' + chr(55) + chr(55), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110101) + chr(53), 0b1000), nzTpIcepk0o8(chr(943 - 895) + chr(11788 - 11677) + '\063' + '\x37' + chr(0b110011), 42517 - 42509), nzTpIcepk0o8('\x30' + chr(0b1010000 + 0o37) + chr(51) + chr(0b101010 + 0o11) + chr(0b110 + 0o53), 0b1000), nzTpIcepk0o8(chr(466 - 418) + '\157' + chr(51) + chr(0b10 + 0o60) + chr(2293 - 2241), 0o10), nzTpIcepk0o8('\x30' + chr(1472 - 1361) + '\064' + chr(0b1100 + 0o45), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110011) + '\067' + '\066', 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1532 - 1482) + chr(0b110001) + chr(2240 - 2189), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1011011 + 0o24) + '\x33' + chr(53) + chr(0b110010), 6028 - 6020), nzTpIcepk0o8('\060' + chr(0b1010010 + 0o35) + chr(265 - 215) + chr(0b100110 + 0o12) + chr(49), 26081 - 26073), nzTpIcepk0o8('\x30' + '\157' + chr(51) + chr(747 - 692) + '\066', 8), nzTpIcepk0o8(chr(0b100100 + 0o14) + chr(0b1101111) + chr(0b10111 + 0o33) + chr(0b110010) + '\062', 38269 - 38261), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(50 - 0) + chr(0b110111) + chr(51), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\063' + chr(961 - 910) + chr(0b110111), 0o10), nzTpIcepk0o8(chr(1792 - 1744) + chr(3189 - 3078) + chr(49) + '\x36' + '\061', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1010111 + 0o30) + chr(0b110001) + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(50) + chr(0b110001) + '\066', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110010 + 0o1) + '\067' + chr(0b11110 + 0o26), 13551 - 13543), nzTpIcepk0o8(chr(1162 - 1114) + chr(111) + chr(191 - 142) + chr(0b110011) + '\x31', 24981 - 24973), nzTpIcepk0o8(chr(0b10011 + 0o35) + chr(0b1101111 + 0o0) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\061' + '\x35' + chr(54), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1854 - 1805) + '\061' + '\061', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b1011 + 0o46) + '\x33' + '\x30', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\061' + '\061', 8), nzTpIcepk0o8(chr(0b11100 + 0o24) + chr(111) + chr(0b11011 + 0o30) + chr(791 - 737) + chr(0b101 + 0o55), 24009 - 24001), nzTpIcepk0o8(chr(48) + '\x6f' + '\x35' + chr(0b110000), ord("\x08")), nzTpIcepk0o8('\x30' + chr(1917 - 1806) + '\x32' + chr(1197 - 1144) + chr(1632 - 1584), 0b1000), nzTpIcepk0o8(chr(0b1100 + 0o44) + '\x6f' + chr(0b110101) + chr(0b11101 + 0o25), 51193 - 51185), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(1079 - 1029) + chr(1222 - 1170), 0o10), nzTpIcepk0o8('\x30' + chr(8245 - 8134) + chr(0b110010) + chr(55), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b100 + 0o57) + '\066' + chr(53), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b111000 + 0o67) + '\x31' + '\x33' + chr(1243 - 1189), 8), nzTpIcepk0o8('\060' + chr(1460 - 1349) + '\x31' + chr(0b100001 + 0o17) + chr(2029 - 1975), 55636 - 55628)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(420 - 309) + chr(53) + '\x30', 8)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x05'), '\144' + chr(0b1100101) + chr(0b11011 + 0o110) + chr(0b1000 + 0o147) + '\x64' + chr(101))(chr(2637 - 2520) + chr(0b1110100) + chr(102) + chr(0b100001 + 0o14) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def SBaAB9en7G46(hXMPsSrOQzbh, tETBqd0TgBib, t4VW9cMLiY9T, YZWZ2vpoGSMQ, NtQQQuPjPDl0):
tETBqd0TgBib = KV9ckIhroIia(nzTpIcepk0o8('\x30' + chr(111) + '\x30', ord("\x08")), tETBqd0TgBib)
t4VW9cMLiY9T = XURpmPuEWCNF(hXMPsSrOQzbh.dH3vcKdvgBu0 - nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b100100 + 0o15), 0b1000), t4VW9cMLiY9T)
YZWZ2vpoGSMQ = KV9ckIhroIia(nzTpIcepk0o8(chr(834 - 786) + chr(0b1101111) + chr(569 - 521), 8), YZWZ2vpoGSMQ)
NtQQQuPjPDl0 = XURpmPuEWCNF(hXMPsSrOQzbh.PaEBmun9J0YJ - nzTpIcepk0o8(chr(81 - 33) + chr(1042 - 931) + chr(0b10001 + 0o40), 8), NtQQQuPjPDl0)
if t4VW9cMLiY9T < tETBqd0TgBib:
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'g;A\x1dea\xd7\nC\x9f\xb8\xa6X\xde\xe6\x9f\xf2\x8a\xb2\xd9\xbaQz\xe3\x9d5n\x0b;x}\x9aI\xc6\n`\x7f\x90~4B9O\x1dea\xd7\nC\x9f\xb8\xa6X'), chr(0b1100100) + chr(9271 - 9170) + chr(0b1100011) + '\x6f' + '\x64' + '\145')('\x75' + '\x74' + chr(102) + chr(0b111 + 0o46) + '\x38'))
if YZWZ2vpoGSMQ > NtQQQuPjPDl0:
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'~.W\x0c7#\xda\x10X\x95\xbd\xb5S\x87\xab\x87\xf4\x8d\xe6\x9b\xbd\x14)\xfd\x918n\x02,*)\x86@\xc9D4c\x9d;fG1P\x0c7#\xda\x10X\x95\xbd\xb5S\x87'), chr(4321 - 4221) + chr(101) + chr(4847 - 4748) + chr(0b110100 + 0o73) + '\144' + chr(0b1100101))(chr(117) + chr(116) + chr(102) + chr(853 - 808) + '\070'))
jXlhv1wVnchL = hXMPsSrOQzbh.data.copy()
jXlhv1wVnchL[:YZWZ2vpoGSMQ, :] = cjb5BYlcknHL
jXlhv1wVnchL[NtQQQuPjPDl0:, :] = cjb5BYlcknHL
jXlhv1wVnchL[:, :tETBqd0TgBib] = cjb5BYlcknHL
jXlhv1wVnchL[:, t4VW9cMLiY9T:] = cjb5BYlcknHL
return GALFuDMu2Qth(jXlhv1wVnchL, frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'Ahd[+q\xcf\tX\xab\xe9\xe0'), chr(7458 - 7358) + chr(0b1100100 + 0o1) + '\143' + chr(111) + chr(0b1100100) + '\145')('\165' + chr(116) + chr(3596 - 3494) + '\055' + chr(56)))) |
BerkeleyAutomation/perception | perception/image.py | BinaryImage.most_free_pixel | def most_free_pixel(self):
""" Find the black pixel with the largest distance from the white pixels.
Returns
-------
:obj:`numpy.ndarray`
2-vector containing the most free pixel
"""
dist_tf = self.to_distance_im()
max_px = np.where(dist_tf == np.max(dist_tf))
free_pixel = np.array([max_px[0][0], max_px[1][0]])
return free_pixel | python | def most_free_pixel(self):
""" Find the black pixel with the largest distance from the white pixels.
Returns
-------
:obj:`numpy.ndarray`
2-vector containing the most free pixel
"""
dist_tf = self.to_distance_im()
max_px = np.where(dist_tf == np.max(dist_tf))
free_pixel = np.array([max_px[0][0], max_px[1][0]])
return free_pixel | [
"def",
"most_free_pixel",
"(",
"self",
")",
":",
"dist_tf",
"=",
"self",
".",
"to_distance_im",
"(",
")",
"max_px",
"=",
"np",
".",
"where",
"(",
"dist_tf",
"==",
"np",
".",
"max",
"(",
"dist_tf",
")",
")",
"free_pixel",
"=",
"np",
".",
"array",
"(",
"[",
"max_px",
"[",
"0",
"]",
"[",
"0",
"]",
",",
"max_px",
"[",
"1",
"]",
"[",
"0",
"]",
"]",
")",
"return",
"free_pixel"
] | Find the black pixel with the largest distance from the white pixels.
Returns
-------
:obj:`numpy.ndarray`
2-vector containing the most free pixel | [
"Find",
"the",
"black",
"pixel",
"with",
"the",
"largest",
"distance",
"from",
"the",
"white",
"pixels",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2599-L2610 | train | Find the black pixel with the largest distance from the white pixels. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5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uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b1101 + 0o43) + chr(0b1110 + 0o141) + '\062' + chr(50) + '\x32', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110010 + 0o1) + chr(50) + '\067', 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b10110 + 0o35) + chr(55) + chr(0b1 + 0o63), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + '\062' + chr(0b110000) + '\x35', 0b1000), nzTpIcepk0o8(chr(48) + chr(10920 - 10809) + chr(0b10010 + 0o41) + chr(0b110010 + 0o1) + '\061', 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\061' + chr(0b110010) + chr(1803 - 1753), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(105 - 55) + '\066' + chr(49), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(50) + '\x33' + chr(0b110011), 0o10), nzTpIcepk0o8('\060' + chr(11081 - 10970) + chr(0b110011) + chr(531 - 476) + chr(1746 - 1698), 17116 - 17108), nzTpIcepk0o8(chr(1361 - 1313) + chr(0b1101111) + chr(0b1001 + 0o51) + chr(50) + chr(55), 0o10), nzTpIcepk0o8('\060' + chr(111) + chr(1028 - 978) + chr(55) + '\067', 0o10), nzTpIcepk0o8(chr(0b100011 + 0o15) + chr(0b1101111) + '\x37', ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(49) + '\x33' + chr(2379 - 2327), 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(49) + '\067' + '\x31', ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(2090 - 2040) + '\063' + chr(0b110100), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(2513 - 2458) + '\067', 0o10), nzTpIcepk0o8(chr(974 - 926) + '\157' + '\x31' + chr(1948 - 1897) + chr(2298 - 2249), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + '\x31' + '\x36', 0b1000), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(0b1010110 + 0o31) + chr(0b110011) + '\x30' + '\063', 61431 - 61423), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b10001 + 0o40) + '\x37' + chr(245 - 191), 0b1000), nzTpIcepk0o8('\060' + '\157' + '\063' + '\x36', ord("\x08")), nzTpIcepk0o8(chr(0b10101 + 0o33) + '\157' + chr(1539 - 1489) + chr(0b110000 + 0o5) + '\x34', 27775 - 27767), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(2253 - 2202) + '\x36' + chr(0b1100 + 0o45), 0o10), nzTpIcepk0o8(chr(0b10110 + 0o32) + '\157' + chr(0b101101 + 0o6), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1100011 + 0o14) + chr(803 - 754) + chr(1333 - 1280) + '\x37', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110011) + chr(0b110011) + chr(1009 - 958), 0o10), nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(0b1101111) + chr(0b110010) + '\x31' + chr(1284 - 1229), 46453 - 46445), nzTpIcepk0o8(chr(48) + chr(3894 - 3783) + chr(50) + '\061' + chr(174 - 125), 6812 - 6804), nzTpIcepk0o8('\x30' + '\157' + '\x32' + '\063' + chr(0b110001), 5570 - 5562), nzTpIcepk0o8(chr(48) + '\x6f' + '\x31' + chr(1041 - 990), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(51) + chr(955 - 904) + chr(0b1010 + 0o52), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1011000 + 0o27) + chr(0b11001 + 0o30) + chr(1269 - 1218) + chr(0b101000 + 0o15), 11267 - 11259), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110011), 8), nzTpIcepk0o8(chr(0b101 + 0o53) + '\157' + '\067', 8), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110010) + '\060' + chr(182 - 133), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(2377 - 2327) + chr(0b11100 + 0o24) + chr(0b10 + 0o56), 0b1000), nzTpIcepk0o8(chr(62 - 14) + '\157' + chr(0b100000 + 0o21) + chr(0b110011) + chr(0b100011 + 0o20), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(49) + chr(0b11101 + 0o23) + chr(2259 - 2210), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(50) + '\x32' + '\x30', 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(528 - 478) + chr(370 - 318) + chr(0b101000 + 0o12), 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b110000) + chr(10339 - 10228) + chr(0b10011 + 0o42) + chr(48), 65482 - 65474)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xbc'), chr(7223 - 7123) + '\145' + chr(0b101001 + 0o72) + '\157' + chr(0b101001 + 0o73) + chr(0b110010 + 0o63))(chr(9072 - 8955) + chr(4934 - 4818) + chr(0b1100010 + 0o4) + chr(45) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def eOYdDqOmbjW0(hXMPsSrOQzbh):
C7xYFel4hzcW = hXMPsSrOQzbh.to_distance_im()
o4343169t641 = nDF4gVNx0u9Q.xWH4M7K6Qbd3(C7xYFel4hzcW == nDF4gVNx0u9Q.KV9ckIhroIia(C7xYFel4hzcW))
KyIBcn1_8coR = nDF4gVNx0u9Q.Tn6rGr7XTM7t([o4343169t641[nzTpIcepk0o8('\060' + '\x6f' + chr(0b110000), 33706 - 33698)][nzTpIcepk0o8(chr(2093 - 2045) + chr(111) + chr(485 - 437), 8)], o4343169t641[nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110001), 0b1000)][nzTpIcepk0o8('\060' + chr(0b10001 + 0o136) + '\060', 8)]])
return KyIBcn1_8coR |
BerkeleyAutomation/perception | perception/image.py | BinaryImage.diff_with_target | def diff_with_target(self, binary_im):
""" Creates a color image to visualize the overlap between two images.
Nonzero pixels that match in both images are green.
Nonzero pixels of this image that aren't in the other image are yellow
Nonzero pixels of the other image that aren't in this image are red
Parameters
----------
binary_im : :obj:`BinaryImage`
binary image to take the difference with
Returns
-------
:obj:`ColorImage`
color image to visualize the image difference
"""
red = np.array([BINARY_IM_MAX_VAL, 0, 0])
yellow = np.array([BINARY_IM_MAX_VAL, BINARY_IM_MAX_VAL, 0])
green = np.array([0, BINARY_IM_MAX_VAL, 0])
overlap_data = np.zeros([self.height, self.width, 3])
unfilled_px = np.where((self.data == 0) & (binary_im.data > 0))
overlap_data[unfilled_px[0], unfilled_px[1], :] = red
filled_px = np.where((self.data > 0) & (binary_im.data > 0))
overlap_data[filled_px[0], filled_px[1], :] = green
spurious_px = np.where((self.data > 0) & (binary_im.data == 0))
overlap_data[spurious_px[0], spurious_px[1], :] = yellow
return ColorImage(overlap_data.astype(np.uint8), frame=self.frame) | python | def diff_with_target(self, binary_im):
""" Creates a color image to visualize the overlap between two images.
Nonzero pixels that match in both images are green.
Nonzero pixels of this image that aren't in the other image are yellow
Nonzero pixels of the other image that aren't in this image are red
Parameters
----------
binary_im : :obj:`BinaryImage`
binary image to take the difference with
Returns
-------
:obj:`ColorImage`
color image to visualize the image difference
"""
red = np.array([BINARY_IM_MAX_VAL, 0, 0])
yellow = np.array([BINARY_IM_MAX_VAL, BINARY_IM_MAX_VAL, 0])
green = np.array([0, BINARY_IM_MAX_VAL, 0])
overlap_data = np.zeros([self.height, self.width, 3])
unfilled_px = np.where((self.data == 0) & (binary_im.data > 0))
overlap_data[unfilled_px[0], unfilled_px[1], :] = red
filled_px = np.where((self.data > 0) & (binary_im.data > 0))
overlap_data[filled_px[0], filled_px[1], :] = green
spurious_px = np.where((self.data > 0) & (binary_im.data == 0))
overlap_data[spurious_px[0], spurious_px[1], :] = yellow
return ColorImage(overlap_data.astype(np.uint8), frame=self.frame) | [
"def",
"diff_with_target",
"(",
"self",
",",
"binary_im",
")",
":",
"red",
"=",
"np",
".",
"array",
"(",
"[",
"BINARY_IM_MAX_VAL",
",",
"0",
",",
"0",
"]",
")",
"yellow",
"=",
"np",
".",
"array",
"(",
"[",
"BINARY_IM_MAX_VAL",
",",
"BINARY_IM_MAX_VAL",
",",
"0",
"]",
")",
"green",
"=",
"np",
".",
"array",
"(",
"[",
"0",
",",
"BINARY_IM_MAX_VAL",
",",
"0",
"]",
")",
"overlap_data",
"=",
"np",
".",
"zeros",
"(",
"[",
"self",
".",
"height",
",",
"self",
".",
"width",
",",
"3",
"]",
")",
"unfilled_px",
"=",
"np",
".",
"where",
"(",
"(",
"self",
".",
"data",
"==",
"0",
")",
"&",
"(",
"binary_im",
".",
"data",
">",
"0",
")",
")",
"overlap_data",
"[",
"unfilled_px",
"[",
"0",
"]",
",",
"unfilled_px",
"[",
"1",
"]",
",",
":",
"]",
"=",
"red",
"filled_px",
"=",
"np",
".",
"where",
"(",
"(",
"self",
".",
"data",
">",
"0",
")",
"&",
"(",
"binary_im",
".",
"data",
">",
"0",
")",
")",
"overlap_data",
"[",
"filled_px",
"[",
"0",
"]",
",",
"filled_px",
"[",
"1",
"]",
",",
":",
"]",
"=",
"green",
"spurious_px",
"=",
"np",
".",
"where",
"(",
"(",
"self",
".",
"data",
">",
"0",
")",
"&",
"(",
"binary_im",
".",
"data",
"==",
"0",
")",
")",
"overlap_data",
"[",
"spurious_px",
"[",
"0",
"]",
",",
"spurious_px",
"[",
"1",
"]",
",",
":",
"]",
"=",
"yellow",
"return",
"ColorImage",
"(",
"overlap_data",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
",",
"frame",
"=",
"self",
".",
"frame",
")"
] | Creates a color image to visualize the overlap between two images.
Nonzero pixels that match in both images are green.
Nonzero pixels of this image that aren't in the other image are yellow
Nonzero pixels of the other image that aren't in this image are red
Parameters
----------
binary_im : :obj:`BinaryImage`
binary image to take the difference with
Returns
-------
:obj:`ColorImage`
color image to visualize the image difference | [
"Creates",
"a",
"color",
"image",
"to",
"visualize",
"the",
"overlap",
"between",
"two",
"images",
".",
"Nonzero",
"pixels",
"that",
"match",
"in",
"both",
"images",
"are",
"green",
".",
"Nonzero",
"pixels",
"of",
"this",
"image",
"that",
"aren",
"t",
"in",
"the",
"other",
"image",
"are",
"yellow",
"Nonzero",
"pixels",
"of",
"the",
"other",
"image",
"that",
"aren",
"t",
"in",
"this",
"image",
"are",
"red"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2612-L2638 | train | Creates a color image that visualizes the overlap between two images. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,Nfw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w,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(0b1101010 + 0o5) + '\062' + chr(0b110010) + chr(0b110000), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x31' + chr(0b101101 + 0o6) + chr(49), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b11111 + 0o23) + '\x34' + '\066', 928 - 920), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(950 - 900) + '\x35' + chr(0b100010 + 0o22), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1000111 + 0o50) + chr(0b10110 + 0o34) + chr(885 - 834) + chr(366 - 318), ord("\x08")), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(111) + '\061' + chr(0b110011) + chr(2193 - 2143), 0b1000), nzTpIcepk0o8(chr(0b11 + 0o55) + chr(0b1101111) + chr(0b110011) + chr(0b110001) + chr(0b1001 + 0o53), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b110001 + 0o76) + chr(51) + '\060' + chr(0b1101 + 0o47), 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(1631 - 1580) + '\063' + '\067', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(51) + chr(0b11101 + 0o25) + chr(0b110110), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + '\061' + chr(1861 - 1812), 0b1000), nzTpIcepk0o8(chr(48) + '\157' + '\062' + chr(0b110000) + '\062', 0b1000), nzTpIcepk0o8(chr(1634 - 1586) + chr(8132 - 8021) + chr(51) + chr(1066 - 1017) + '\062', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\062' + chr(50) + chr(0b110111), 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(0b110001) + chr(54) + '\x35', 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b10011 + 0o40), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1010111 + 0o30) + '\x33' + chr(605 - 557) + chr(989 - 938), ord("\x08")), nzTpIcepk0o8(chr(0b10010 + 0o36) + chr(0b1101111) + chr(50) + chr(0b110101) + chr(0b10110 + 0o40), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1011000 + 0o27) + '\x31' + chr(1477 - 1422) + chr(0b101 + 0o62), 0b1000), nzTpIcepk0o8('\060' + chr(111) + chr(50) + chr(53) + chr(0b110011 + 0o1), 8), nzTpIcepk0o8('\x30' + chr(0b1101101 + 0o2) + '\062' + chr(0b10101 + 0o36) + chr(0b110010), 23401 - 23393), nzTpIcepk0o8('\x30' + chr(111) + chr(1171 - 1120) + '\x35' + chr(0b1010 + 0o53), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(51) + '\x36' + chr(0b100001 + 0o24), ord("\x08")), nzTpIcepk0o8(chr(149 - 101) + chr(0b1101111) + '\063' + chr(50) + '\x33', 0o10), nzTpIcepk0o8(chr(1638 - 1590) + chr(0b1101111) + chr(1825 - 1776) + '\x35' + '\065', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(6301 - 6190) + chr(50) + chr(0b110100) + '\x31', 28362 - 28354), nzTpIcepk0o8(chr(0b110000) + chr(0b1001101 + 0o42) + '\064' + chr(49), 14719 - 14711), nzTpIcepk0o8(chr(0b11101 + 0o23) + chr(0b1101111) + chr(50) + '\x32' + chr(0b100101 + 0o13), 8), nzTpIcepk0o8(chr(1744 - 1696) + '\x6f' + chr(0b110001) + chr(54) + chr(1502 - 1448), 21407 - 21399), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110001) + chr(52) + chr(0b110 + 0o56), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110011) + chr(0b101110 + 0o7) + chr(0b10001 + 0o46), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(51) + chr(0b110110), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(0b110001) + chr(0b110111), 35431 - 35423), nzTpIcepk0o8(chr(0b10001 + 0o37) + chr(111) + chr(206 - 155) + '\x30' + chr(0b100110 + 0o17), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1100010 + 0o15) + chr(588 - 538) + chr(0b10100 + 0o41) + chr(0b101001 + 0o12), 21543 - 21535), nzTpIcepk0o8(chr(531 - 483) + '\157' + chr(0b110000 + 0o6) + chr(54), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b11011 + 0o30) + chr(671 - 620) + chr(2588 - 2535), 38265 - 38257), nzTpIcepk0o8('\x30' + '\x6f' + '\062' + '\x33' + chr(0b110100), 0b1000), nzTpIcepk0o8(chr(1259 - 1211) + chr(8624 - 8513) + chr(1297 - 1246) + '\065' + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110010) + chr(55) + chr(620 - 571), 51949 - 51941)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b110000) + chr(8774 - 8663) + chr(0b110101) + chr(48), ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xbe'), chr(100) + '\145' + '\x63' + chr(111) + '\x64' + chr(0b1100101))(chr(0b1100111 + 0o16) + chr(8123 - 8007) + chr(0b10 + 0o144) + '\055' + chr(0b111000)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def qmTPXi4fFoWf(hXMPsSrOQzbh, yMN3wUHEhDLY):
vnzna5Cq7Bhs = nDF4gVNx0u9Q.Tn6rGr7XTM7t([cjb5BYlcknHL, nzTpIcepk0o8(chr(0b0 + 0o60) + chr(0b1101111) + chr(0b10100 + 0o34), 1305 - 1297), nzTpIcepk0o8(chr(0b10010 + 0o36) + '\157' + chr(0b101101 + 0o3), 8)])
QrmBe3ZDjYbF = nDF4gVNx0u9Q.Tn6rGr7XTM7t([cjb5BYlcknHL, cjb5BYlcknHL, nzTpIcepk0o8('\x30' + chr(111) + chr(0b101101 + 0o3), 8)])
uOamIxLmZxmm = nDF4gVNx0u9Q.Tn6rGr7XTM7t([nzTpIcepk0o8(chr(0b1110 + 0o42) + chr(111) + chr(0b1100 + 0o44), 8), cjb5BYlcknHL, nzTpIcepk0o8(chr(0b101011 + 0o5) + chr(111) + chr(48), 8)])
gu33mKSK0Axp = nDF4gVNx0u9Q.UmwwEp7MzR6q([hXMPsSrOQzbh.PaEBmun9J0YJ, hXMPsSrOQzbh.dH3vcKdvgBu0, nzTpIcepk0o8('\x30' + '\x6f' + chr(2325 - 2274), 8)])
nCIORtOo_DA2 = nDF4gVNx0u9Q.xWH4M7K6Qbd3((hXMPsSrOQzbh.FfKOThdpoDTb == nzTpIcepk0o8(chr(0b11011 + 0o25) + chr(0b100011 + 0o114) + chr(0b101011 + 0o5), 8)) & (yMN3wUHEhDLY.FfKOThdpoDTb > nzTpIcepk0o8(chr(0b101100 + 0o4) + chr(111) + chr(48), 8)))
gu33mKSK0Axp[nCIORtOo_DA2[nzTpIcepk0o8('\060' + chr(0b1101111) + chr(48), 8)], nCIORtOo_DA2[nzTpIcepk0o8(chr(1729 - 1681) + '\157' + chr(856 - 807), 40401 - 40393)], :] = vnzna5Cq7Bhs
V4ZC10by0C5c = nDF4gVNx0u9Q.xWH4M7K6Qbd3((hXMPsSrOQzbh.FfKOThdpoDTb > nzTpIcepk0o8('\060' + '\157' + '\x30', 8)) & (yMN3wUHEhDLY.FfKOThdpoDTb > nzTpIcepk0o8('\x30' + chr(111) + chr(0b1 + 0o57), 8)))
gu33mKSK0Axp[V4ZC10by0C5c[nzTpIcepk0o8(chr(2020 - 1972) + chr(0b101101 + 0o102) + '\060', 8)], V4ZC10by0C5c[nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110001), 8)], :] = uOamIxLmZxmm
O1L1sh0ccZ5L = nDF4gVNx0u9Q.xWH4M7K6Qbd3((hXMPsSrOQzbh.FfKOThdpoDTb > nzTpIcepk0o8('\060' + chr(111) + chr(0b110000), 8)) & (yMN3wUHEhDLY.FfKOThdpoDTb == nzTpIcepk0o8('\060' + chr(0b111101 + 0o62) + chr(56 - 8), 8)))
gu33mKSK0Axp[O1L1sh0ccZ5L[nzTpIcepk0o8('\x30' + '\157' + chr(2203 - 2155), 8)], O1L1sh0ccZ5L[nzTpIcepk0o8('\060' + chr(7280 - 7169) + chr(0b100110 + 0o13), 8)], :] = QrmBe3ZDjYbF
return lPn7XfHAFaXG(roI3spqORKae(gu33mKSK0Axp, roI3spqORKae(ES5oEprVxulp(b'\xe8(\xe7\xef\xf0*\xaf\x86\xb4\xa5z\xe0'), '\x64' + '\145' + chr(99) + '\157' + '\144' + '\x65')(chr(117) + chr(0b1100000 + 0o24) + '\146' + '\055' + chr(56)))(roI3spqORKae(nDF4gVNx0u9Q, roI3spqORKae(ES5oEprVxulp(b'\xf1\x03\xe4\x9d\xee-\xa1\xa0\x88\x83V\xcf'), chr(8950 - 8850) + '\x65' + chr(0b1100000 + 0o3) + '\x6f' + chr(0b1011011 + 0o11) + chr(4493 - 4392))(chr(117) + '\164' + '\x66' + chr(0b101101) + '\070'))), frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xdb\x03\x92\xc9\xefh\xbd\xb7\xee\x9e]\xcd'), chr(0b1100100) + chr(0b1100101) + chr(0b1100011) + chr(10254 - 10143) + chr(100) + chr(6551 - 6450))('\165' + chr(5662 - 5546) + chr(0b1001100 + 0o32) + '\055' + chr(598 - 542)))) |
BerkeleyAutomation/perception | perception/image.py | BinaryImage.num_adjacent | def num_adjacent(self, i, j):
""" Counts the number of adjacent nonzero pixels to a given pixel.
Parameters
----------
i : int
row index of query pixel
j : int
col index of query pixel
Returns
-------
int
number of adjacent nonzero pixels
"""
# check values
if i < 1 or i > self.height - 2 or j < 1 and j > self.width - 2:
raise ValueError('Pixels out of bounds')
# count the number of blacks
count = 0
diffs = [[-1, 0], [1, 0], [0, -1], [0, 1]]
for d in diffs:
if self.data[i + d[0]][j + d[1]] > self._threshold:
count += 1
return count | python | def num_adjacent(self, i, j):
""" Counts the number of adjacent nonzero pixels to a given pixel.
Parameters
----------
i : int
row index of query pixel
j : int
col index of query pixel
Returns
-------
int
number of adjacent nonzero pixels
"""
# check values
if i < 1 or i > self.height - 2 or j < 1 and j > self.width - 2:
raise ValueError('Pixels out of bounds')
# count the number of blacks
count = 0
diffs = [[-1, 0], [1, 0], [0, -1], [0, 1]]
for d in diffs:
if self.data[i + d[0]][j + d[1]] > self._threshold:
count += 1
return count | [
"def",
"num_adjacent",
"(",
"self",
",",
"i",
",",
"j",
")",
":",
"# check values",
"if",
"i",
"<",
"1",
"or",
"i",
">",
"self",
".",
"height",
"-",
"2",
"or",
"j",
"<",
"1",
"and",
"j",
">",
"self",
".",
"width",
"-",
"2",
":",
"raise",
"ValueError",
"(",
"'Pixels out of bounds'",
")",
"# count the number of blacks",
"count",
"=",
"0",
"diffs",
"=",
"[",
"[",
"-",
"1",
",",
"0",
"]",
",",
"[",
"1",
",",
"0",
"]",
",",
"[",
"0",
",",
"-",
"1",
"]",
",",
"[",
"0",
",",
"1",
"]",
"]",
"for",
"d",
"in",
"diffs",
":",
"if",
"self",
".",
"data",
"[",
"i",
"+",
"d",
"[",
"0",
"]",
"]",
"[",
"j",
"+",
"d",
"[",
"1",
"]",
"]",
">",
"self",
".",
"_threshold",
":",
"count",
"+=",
"1",
"return",
"count"
] | Counts the number of adjacent nonzero pixels to a given pixel.
Parameters
----------
i : int
row index of query pixel
j : int
col index of query pixel
Returns
-------
int
number of adjacent nonzero pixels | [
"Counts",
"the",
"number",
"of",
"adjacent",
"nonzero",
"pixels",
"to",
"a",
"given",
"pixel",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2640-L2665 | train | Counts the number of adjacent nonzero pixels to a given pixel. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,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XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + chr(111) + chr(0b101101 + 0o6) + chr(0b10110 + 0o35) + chr(0b110110), 63412 - 63404), nzTpIcepk0o8('\060' + chr(0b1101111) + '\063' + chr(0b11000 + 0o35) + chr(0b110001 + 0o6), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b100011 + 0o20) + '\063' + '\065', ord("\x08")), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(10154 - 10043) + '\x32' + '\x30', 0b1000), nzTpIcepk0o8(chr(527 - 479) + chr(0b111101 + 0o62) + chr(0b1011 + 0o47) + chr(51) + '\061', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b11110 + 0o24), ord("\x08")), nzTpIcepk0o8(chr(0b1101 + 0o43) + chr(111) + '\063' + '\x34' + chr(49), 0b1000), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(111) + chr(0b110010) + '\060' + '\x30', 0b1000), nzTpIcepk0o8(chr(996 - 948) + chr(9917 - 9806) + chr(0b11 + 0o57) + '\062' + '\066', ord("\x08")), nzTpIcepk0o8(chr(2032 - 1984) + '\x6f' + chr(50) + '\066' + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b10001 + 0o136) + '\x31' + '\x31' + '\066', 0o10), nzTpIcepk0o8(chr(0b101 + 0o53) + chr(111) + chr(1179 - 1129) + '\060' + chr(624 - 570), 44210 - 44202), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(889 - 835) + chr(51), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\062' + chr(52), 47661 - 47653), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(2492 - 2442) + chr(0b110100), 8), nzTpIcepk0o8('\060' + chr(0b10 + 0o155) + '\061' + chr(0b11100 + 0o27), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(50) + '\x30' + chr(2129 - 2078), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + '\062' + chr(0b110110), 58486 - 58478), nzTpIcepk0o8('\060' + chr(0b1001100 + 0o43) + chr(0b11 + 0o60) + '\064' + chr(49), 8), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\062' + chr(53) + '\065', 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110010) + '\x30' + '\064', 0b1000), nzTpIcepk0o8(chr(542 - 494) + chr(111) + '\062' + chr(0b110001) + chr(0b1101 + 0o46), 0o10), nzTpIcepk0o8(chr(0b10111 + 0o31) + chr(111) + chr(0b101010 + 0o11) + '\x33', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(11948 - 11837) + chr(1652 - 1601) + chr(49) + chr(53), 0o10), nzTpIcepk0o8('\060' + '\x6f' + '\062' + chr(0b110100) + chr(48), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110011 + 0o4) + chr(48), 0b1000), nzTpIcepk0o8('\x30' + chr(3333 - 3222) + chr(0b100101 + 0o16) + chr(53) + chr(0b110111), 8), nzTpIcepk0o8(chr(194 - 146) + chr(0b110111 + 0o70) + chr(0b11 + 0o60) + chr(0b100101 + 0o14) + '\x30', 59400 - 59392), nzTpIcepk0o8(chr(1847 - 1799) + chr(1175 - 1064) + chr(939 - 890) + chr(0b11010 + 0o32) + '\067', 0o10), nzTpIcepk0o8(chr(1422 - 1374) + chr(111) + '\064' + '\062', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(1896 - 1841) + chr(0b111 + 0o52), 0o10), nzTpIcepk0o8('\x30' + chr(111) + '\x31' + chr(1522 - 1474) + chr(0b10000 + 0o43), 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(542 - 492) + chr(0b11000 + 0o35) + '\065', 8), nzTpIcepk0o8('\x30' + '\157' + chr(1779 - 1728) + '\064' + '\060', 0o10), nzTpIcepk0o8('\060' + '\x6f' + '\063' + chr(52) + chr(0b110101 + 0o1), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + '\x33' + chr(0b110101) + chr(51), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b110010) + chr(0b110101) + chr(0b110111), 31630 - 31622), nzTpIcepk0o8(chr(48) + '\x6f' + '\061' + chr(0b101010 + 0o13) + chr(0b110111), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110001) + '\064' + '\x34', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110000 + 0o3) + chr(0b100110 + 0o17) + '\x36', ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + chr(111) + '\065' + chr(0b10 + 0o56), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xf0'), '\144' + '\145' + chr(0b1100011) + chr(769 - 658) + chr(191 - 91) + chr(0b100110 + 0o77))('\x75' + chr(116) + chr(9811 - 9709) + chr(45) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def DlqwRroARQ3Z(hXMPsSrOQzbh, ZlbFMSG8gCoF, sChW4gUsXrIC):
if ZlbFMSG8gCoF < nzTpIcepk0o8(chr(2268 - 2220) + chr(5517 - 5406) + chr(0b100011 + 0o16), 41489 - 41481) or ZlbFMSG8gCoF > roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\x8e\x8e\x98R\xf4w\x8f\xb9\xdc\x82\x17\xcc'), chr(0b1011010 + 0o12) + chr(0b1001101 + 0o30) + '\x63' + chr(0b1101111) + chr(0b1100100) + chr(101))(chr(117) + '\x74' + '\x66' + chr(0b1101 + 0o40) + chr(2951 - 2895))) - nzTpIcepk0o8('\060' + '\x6f' + chr(50), 8) or (sChW4gUsXrIC < nzTpIcepk0o8(chr(48) + '\157' + chr(0b110001), 8) and sChW4gUsXrIC > roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xba\xa7\xeef\xfaI\x85\xf6\xf1\xf0;\xb6'), '\144' + '\145' + chr(740 - 641) + chr(111) + chr(0b1011100 + 0o10) + chr(9929 - 9828))(chr(0b1000000 + 0o65) + chr(0b1001011 + 0o51) + '\x66' + chr(0b100000 + 0o15) + chr(56))) - nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(50), 8)):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\x8e\x86\xa5u\xf5q\xc1\xef\xe3\xc6n\xe9U4vd\xf6x\x85\xde'), chr(8494 - 8394) + chr(101) + chr(5819 - 5720) + chr(0b1101111) + '\x64' + chr(0b1100101))(chr(4868 - 4751) + '\x74' + chr(2689 - 2587) + chr(0b11110 + 0o17) + '\x38'))
sQSWKlURp7QK = nzTpIcepk0o8(chr(0b110000) + '\157' + chr(48), ord("\x08"))
itfruDOg_HI1 = [[-nzTpIcepk0o8('\060' + chr(0b1101111) + '\x31', 8), nzTpIcepk0o8('\060' + '\157' + chr(48), 8)], [nzTpIcepk0o8('\060' + chr(0b1010111 + 0o30) + chr(1719 - 1670), 8), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b1100 + 0o44), 8)], [nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b10101 + 0o33), 8), -nzTpIcepk0o8(chr(0b11011 + 0o25) + chr(0b1101111) + chr(49), 8)], [nzTpIcepk0o8('\060' + chr(0b1101111) + '\x30', 8), nzTpIcepk0o8(chr(0b101110 + 0o2) + '\157' + chr(0b110001), 8)]]
for vPPlOXQgR3SM in itfruDOg_HI1:
if roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\x98\x89\x96_\xcdj\x85\xf0\xf9\xf6\x1a\xe4'), chr(0b100111 + 0o75) + chr(101) + '\x63' + chr(0b1101111) + chr(0b1000001 + 0o43) + chr(6163 - 6062))('\165' + chr(116) + '\x66' + '\x2d' + '\x38'))[ZlbFMSG8gCoF + vPPlOXQgR3SM[nzTpIcepk0o8(chr(0b100010 + 0o16) + '\157' + chr(0b101000 + 0o10), 8)]][sChW4gUsXrIC + vPPlOXQgR3SM[nzTpIcepk0o8('\060' + chr(111) + '\061', 8)]] > roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xb8\x8c\xadQ\xc9T\xb9\xd6\xae\xcb/\xe7'), chr(698 - 598) + '\145' + '\x63' + chr(0b11 + 0o154) + chr(0b1100100) + chr(101))('\165' + chr(4239 - 4123) + chr(0b10100 + 0o122) + '\055' + chr(0b1011 + 0o55))):
sQSWKlURp7QK += nzTpIcepk0o8('\060' + '\x6f' + chr(0b110001), 8)
return sQSWKlURp7QK |
BerkeleyAutomation/perception | perception/image.py | BinaryImage.to_sdf | def to_sdf(self):
""" Converts the 2D image to a 2D signed distance field.
Returns
-------
:obj:`numpy.ndarray`
2D float array of the signed distance field
"""
# compute medial axis transform
skel, sdf_in = morph.medial_axis(self.data, return_distance=True)
useless_skel, sdf_out = morph.medial_axis(
np.iinfo(np.uint8).max - self.data, return_distance=True)
# convert to true sdf
sdf = sdf_out - sdf_in
return sdf | python | def to_sdf(self):
""" Converts the 2D image to a 2D signed distance field.
Returns
-------
:obj:`numpy.ndarray`
2D float array of the signed distance field
"""
# compute medial axis transform
skel, sdf_in = morph.medial_axis(self.data, return_distance=True)
useless_skel, sdf_out = morph.medial_axis(
np.iinfo(np.uint8).max - self.data, return_distance=True)
# convert to true sdf
sdf = sdf_out - sdf_in
return sdf | [
"def",
"to_sdf",
"(",
"self",
")",
":",
"# compute medial axis transform",
"skel",
",",
"sdf_in",
"=",
"morph",
".",
"medial_axis",
"(",
"self",
".",
"data",
",",
"return_distance",
"=",
"True",
")",
"useless_skel",
",",
"sdf_out",
"=",
"morph",
".",
"medial_axis",
"(",
"np",
".",
"iinfo",
"(",
"np",
".",
"uint8",
")",
".",
"max",
"-",
"self",
".",
"data",
",",
"return_distance",
"=",
"True",
")",
"# convert to true sdf",
"sdf",
"=",
"sdf_out",
"-",
"sdf_in",
"return",
"sdf"
] | Converts the 2D image to a 2D signed distance field.
Returns
-------
:obj:`numpy.ndarray`
2D float array of the signed distance field | [
"Converts",
"the",
"2D",
"image",
"to",
"a",
"2D",
"signed",
"distance",
"field",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2667-L2682 | train | Converts the 2D image to a 2D signed distance field. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,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7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(111) + '\x36' + chr(0b110101), 0b1000), nzTpIcepk0o8(chr(828 - 780) + chr(0b1101111) + chr(2158 - 2108) + chr(49) + '\066', 0o10), nzTpIcepk0o8(chr(0b100 + 0o54) + chr(0b1101111) + '\x35' + '\067', 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(0b110011) + chr(0b110111) + '\063', 38656 - 38648), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b11101 + 0o26) + chr(0b0 + 0o64) + '\067', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + '\x32' + chr(0b100011 + 0o16) + chr(360 - 305), ord("\x08")), nzTpIcepk0o8(chr(475 - 427) + '\x6f' + '\063' + chr(0b110111) + chr(2676 - 2621), 0b1000), nzTpIcepk0o8(chr(1329 - 1281) + chr(111) + chr(0b110011) + '\063' + '\062', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(277 - 228) + '\x37' + chr(53), 0o10), nzTpIcepk0o8('\x30' + chr(3821 - 3710) + '\x32' + chr(0b110000) + '\x36', 42676 - 42668), nzTpIcepk0o8('\060' + chr(0b10011 + 0o134) + '\x35' + '\x32', 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(54) + '\x31', 0b1000), nzTpIcepk0o8(chr(0b1010 + 0o46) + chr(6204 - 6093) + '\x33' + '\061' + '\067', ord("\x08")), nzTpIcepk0o8(chr(999 - 951) + chr(111) + '\062' + '\063' + chr(0b10111 + 0o34), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110110) + chr(54), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b11010 + 0o125) + chr(0b110001 + 0o0) + '\x35' + chr(52), 0o10), nzTpIcepk0o8(chr(0b100 + 0o54) + '\x6f' + chr(238 - 189) + '\060' + '\061', 0o10), nzTpIcepk0o8('\060' + '\157' + chr(1551 - 1502) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b101111 + 0o4) + chr(0b100001 + 0o25) + chr(0b101000 + 0o10), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(51) + chr(2357 - 2307) + '\065', 8831 - 8823), nzTpIcepk0o8(chr(0b11010 + 0o26) + '\x6f' + '\062' + chr(0b110011) + chr(638 - 585), 0o10), nzTpIcepk0o8(chr(2005 - 1957) + chr(7852 - 7741) + chr(974 - 924) + chr(0b10010 + 0o37) + '\061', 482 - 474), nzTpIcepk0o8(chr(0b10 + 0o56) + '\157' + chr(54) + '\064', ord("\x08")), nzTpIcepk0o8('\060' + chr(7738 - 7627) + '\x32' + '\x33' + chr(48), 0o10), nzTpIcepk0o8('\060' + '\157' + chr(0b100110 + 0o14) + '\x36', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x31' + chr(1097 - 1049) + chr(53), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b111111 + 0o60) + chr(52) + '\x34', ord("\x08")), nzTpIcepk0o8(chr(1153 - 1105) + '\x6f' + chr(0b110001) + chr(52) + '\x37', 56410 - 56402), nzTpIcepk0o8('\060' + '\x6f' + chr(0b11011 + 0o26) + chr(48) + chr(425 - 376), 8), nzTpIcepk0o8(chr(48) + chr(0b1011111 + 0o20) + chr(0b11001 + 0o31) + chr(0b10001 + 0o46) + '\x36', 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(359 - 309) + chr(0b100 + 0o60) + '\060', 45412 - 45404), nzTpIcepk0o8(chr(258 - 210) + chr(0b1101111) + chr(515 - 465) + '\x37' + chr(51), 0b1000), nzTpIcepk0o8(chr(722 - 674) + chr(111) + '\x31' + '\x34' + '\064', ord("\x08")), nzTpIcepk0o8(chr(0b11010 + 0o26) + '\x6f' + chr(51) + '\060' + chr(463 - 412), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(51) + '\063' + chr(48), 0o10), nzTpIcepk0o8(chr(1835 - 1787) + chr(0b1101111) + chr(2019 - 1970) + chr(416 - 367) + chr(0b110000), 42206 - 42198), nzTpIcepk0o8(chr(0b110000) + '\157' + '\063' + chr(0b10110 + 0o37) + chr(0b100011 + 0o20), 0o10), nzTpIcepk0o8(chr(1652 - 1604) + '\x6f' + chr(818 - 768) + chr(0b1110 + 0o42) + '\x34', 8324 - 8316), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x36' + chr(50), 34820 - 34812), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\066' + '\x33', ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(1060 - 1012) + chr(0b1010010 + 0o35) + '\065' + '\060', ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x1b'), chr(0b1100100) + chr(0b10101 + 0o120) + chr(0b1100011) + chr(111) + chr(0b1100100) + '\x65')(chr(0b1110101) + '\x74' + chr(102) + chr(1306 - 1261) + chr(0b110100 + 0o4)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def znxAWNaIkRC5(hXMPsSrOQzbh):
(Vc4NUK7So9bs, TE2QllRWD8Ft) = bidyZ2KoRSBT.medial_axis(hXMPsSrOQzbh.FfKOThdpoDTb, return_distance=nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x31', 31609 - 31601))
(M3coMNtfKTGH, Ao8BbMDgxTQD) = bidyZ2KoRSBT.medial_axis(nDF4gVNx0u9Q.iinfo(nDF4gVNx0u9Q.uint8).KV9ckIhroIia - hXMPsSrOQzbh.FfKOThdpoDTb, return_distance=nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110001), 8))
xPFSHTHCBiQf = Ao8BbMDgxTQD - TE2QllRWD8Ft
return xPFSHTHCBiQf |
BerkeleyAutomation/perception | perception/image.py | BinaryImage.to_color | def to_color(self):
"""Creates a ColorImage from the binary image.
Returns
-------
:obj:`ColorImage`
The newly-created color image.
"""
color_data = np.zeros([self.height, self.width, 3])
color_data[:, :, 0] = self.data
color_data[:, :, 1] = self.data
color_data[:, :, 2] = self.data
return ColorImage(color_data.astype(np.uint8), self._frame) | python | def to_color(self):
"""Creates a ColorImage from the binary image.
Returns
-------
:obj:`ColorImage`
The newly-created color image.
"""
color_data = np.zeros([self.height, self.width, 3])
color_data[:, :, 0] = self.data
color_data[:, :, 1] = self.data
color_data[:, :, 2] = self.data
return ColorImage(color_data.astype(np.uint8), self._frame) | [
"def",
"to_color",
"(",
"self",
")",
":",
"color_data",
"=",
"np",
".",
"zeros",
"(",
"[",
"self",
".",
"height",
",",
"self",
".",
"width",
",",
"3",
"]",
")",
"color_data",
"[",
":",
",",
":",
",",
"0",
"]",
"=",
"self",
".",
"data",
"color_data",
"[",
":",
",",
":",
",",
"1",
"]",
"=",
"self",
".",
"data",
"color_data",
"[",
":",
",",
":",
",",
"2",
"]",
"=",
"self",
".",
"data",
"return",
"ColorImage",
"(",
"color_data",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
",",
"self",
".",
"_frame",
")"
] | Creates a ColorImage from the binary image.
Returns
-------
:obj:`ColorImage`
The newly-created color image. | [
"Creates",
"a",
"ColorImage",
"from",
"the",
"binary",
"image",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2684-L2696 | train | Creates a ColorImage from the binary image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQF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OS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(0b1101111) + chr(0b110011) + chr(0b1100 + 0o52) + chr(52), 0b1000), nzTpIcepk0o8('\060' + chr(7582 - 7471) + chr(0b110011) + '\066' + '\062', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + '\x33' + chr(51) + '\066', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x32' + chr(0b10 + 0o62) + chr(50), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + '\x32' + chr(0b1101 + 0o43), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(584 - 473) + chr(49) + '\x37' + '\062', ord("\x08")), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(0b101011 + 0o104) + chr(0b110010) + chr(51) + '\060', 18099 - 18091), nzTpIcepk0o8('\060' + chr(1388 - 1277) + '\x32' + '\x32' + '\x33', 0o10), nzTpIcepk0o8(chr(0b11001 + 0o27) + '\x6f' + '\064' + chr(2354 - 2302), 0o10), nzTpIcepk0o8(chr(48) + '\157' + chr(2587 - 2536) + chr(0b101110 + 0o5) + chr(0b110111), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(6484 - 6373) + chr(0b110011) + chr(2694 - 2639) + chr(2738 - 2684), 0b1000), nzTpIcepk0o8(chr(1219 - 1171) + chr(0b110011 + 0o74) + '\063' + chr(0b101110 + 0o2) + '\064', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110010) + chr(1906 - 1858) + chr(0b110010), 0b1000), nzTpIcepk0o8(chr(2192 - 2144) + chr(0b1101111) + '\062' + chr(49) + chr(49), ord("\x08")), nzTpIcepk0o8('\060' + chr(8438 - 8327) + chr(981 - 930) + chr(51) + chr(0b110101), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(960 - 909) + '\060' + '\066', 0o10), nzTpIcepk0o8('\x30' + chr(8926 - 8815) + chr(0b110001) + chr(2724 - 2670) + chr(2027 - 1976), ord("\x08")), nzTpIcepk0o8(chr(1824 - 1776) + chr(0b1011001 + 0o26) + '\062' + chr(0b110111) + '\062', 0b1000), nzTpIcepk0o8(chr(48) + chr(7726 - 7615) + chr(0b110001) + '\065' + '\x31', 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + '\x33' + chr(1620 - 1570) + chr(2553 - 2500), ord("\x08")), nzTpIcepk0o8('\060' + chr(6711 - 6600) + '\x32' + chr(0b10000 + 0o44) + '\064', 0b1000), nzTpIcepk0o8(chr(2017 - 1969) + chr(0b1101101 + 0o2) + chr(0b110010) + '\063' + chr(0b100000 + 0o26), 61004 - 60996), nzTpIcepk0o8(chr(48) + chr(2721 - 2610) + chr(50) + chr(0b11000 + 0o33) + '\x32', 22666 - 22658), nzTpIcepk0o8(chr(48) + chr(0b100101 + 0o112) + chr(0b110010) + chr(0b110001) + '\x34', 49316 - 49308), nzTpIcepk0o8(chr(48) + '\x6f' + chr(49) + chr(0b110110) + chr(73 - 24), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1101010 + 0o5) + chr(0b110011) + chr(2339 - 2287) + '\062', 0o10), nzTpIcepk0o8('\060' + chr(111) + '\061' + chr(0b110100) + '\062', ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + '\x33' + '\x36' + chr(0b110111), 0b1000), nzTpIcepk0o8('\x30' + '\157' + '\x32' + chr(0b110110) + '\x30', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(59 - 9) + chr(0b100000 + 0o26) + chr(0b110011), 42985 - 42977), nzTpIcepk0o8(chr(0b101111 + 0o1) + '\x6f' + '\x32' + chr(49), 0b1000), nzTpIcepk0o8(chr(0b100011 + 0o15) + chr(0b111001 + 0o66) + chr(0b110 + 0o53) + chr(49) + '\x36', 0o10), nzTpIcepk0o8(chr(48) + chr(4404 - 4293) + chr(50) + chr(0b110010) + chr(0b101010 + 0o6), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(49) + chr(0b11111 + 0o26) + '\x34', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b101100 + 0o6) + chr(923 - 871) + chr(0b100110 + 0o21), 0b1000), nzTpIcepk0o8(chr(48) + chr(11542 - 11431) + '\x32' + '\066' + chr(54), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b1110 + 0o43) + chr(0b110010) + '\x34', 15256 - 15248), nzTpIcepk0o8('\060' + '\157' + chr(0b100101 + 0o16) + chr(0b11100 + 0o25), 0o10), nzTpIcepk0o8(chr(2283 - 2235) + '\157' + chr(0b110011) + chr(0b110000) + '\x32', 40270 - 40262), nzTpIcepk0o8(chr(276 - 228) + '\157' + '\063' + '\x37', 53871 - 53863)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b101000 + 0o10) + '\157' + chr(0b110101) + chr(538 - 490), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xda'), chr(0b1111 + 0o125) + chr(0b1100101) + chr(8774 - 8675) + '\x6f' + chr(100) + '\x65')(chr(2410 - 2293) + chr(0b1110100) + chr(0b10100 + 0o122) + '\x2d' + chr(56)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def J54CSohScQ3Y(hXMPsSrOQzbh):
KS4vAHvzjPYC = nDF4gVNx0u9Q.UmwwEp7MzR6q([hXMPsSrOQzbh.PaEBmun9J0YJ, hXMPsSrOQzbh.dH3vcKdvgBu0, nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b100010 + 0o21), 0o10)])
KS4vAHvzjPYC[:, :, nzTpIcepk0o8(chr(0b110000) + chr(5365 - 5254) + chr(951 - 903), 37683 - 37675)] = hXMPsSrOQzbh.FfKOThdpoDTb
KS4vAHvzjPYC[:, :, nzTpIcepk0o8(chr(0b111 + 0o51) + '\x6f' + chr(1771 - 1722), 42735 - 42727)] = hXMPsSrOQzbh.FfKOThdpoDTb
KS4vAHvzjPYC[:, :, nzTpIcepk0o8(chr(0b10100 + 0o34) + '\157' + '\062', 0o10)] = hXMPsSrOQzbh.FfKOThdpoDTb
return lPn7XfHAFaXG(roI3spqORKae(KS4vAHvzjPYC, roI3spqORKae(ES5oEprVxulp(b'\x8c\x83\x9f\xe1x\n\xfb\xd1O\xac\x8d\xa6'), chr(100) + chr(0b1011011 + 0o12) + chr(0b1100011) + chr(111) + '\x64' + chr(101))('\x75' + chr(116) + '\146' + chr(1661 - 1616) + '\x38'))(roI3spqORKae(nDF4gVNx0u9Q, roI3spqORKae(ES5oEprVxulp(b'\x95\xa8\x9c\x93f\r\xf5\xf7s\x8a\xa1\x89'), chr(0b1010000 + 0o24) + chr(8558 - 8457) + chr(0b1100011) + chr(111) + chr(0b100100 + 0o100) + chr(0b1100101))('\165' + chr(7052 - 6936) + chr(0b1100110) + chr(0b101101) + chr(0b111000)))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\x9e\xc4\x9d\x90~\x08\xef\xe5Q\x8f\xce\xf0'), chr(0b1100100) + '\x65' + '\143' + chr(0b111101 + 0o62) + chr(1125 - 1025) + chr(0b1100101 + 0o0))(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + '\055' + chr(0b101011 + 0o15)))) |
BerkeleyAutomation/perception | perception/image.py | BinaryImage.open | def open(filename, frame='unspecified'):
"""Creates a BinaryImage from a file.
Parameters
----------
filename : :obj:`str`
The file to load the data from. Must be one of .png, .jpg,
.npy, or .npz.
frame : :obj:`str`
A string representing the frame of reference in which the new image
lies.
Returns
-------
:obj:`BinaryImage`
The new binary image.
"""
data = Image.load_data(filename)
if len(data.shape) > 2 and data.shape[2] > 1:
data = data[:, :, 0]
return BinaryImage(data, frame) | python | def open(filename, frame='unspecified'):
"""Creates a BinaryImage from a file.
Parameters
----------
filename : :obj:`str`
The file to load the data from. Must be one of .png, .jpg,
.npy, or .npz.
frame : :obj:`str`
A string representing the frame of reference in which the new image
lies.
Returns
-------
:obj:`BinaryImage`
The new binary image.
"""
data = Image.load_data(filename)
if len(data.shape) > 2 and data.shape[2] > 1:
data = data[:, :, 0]
return BinaryImage(data, frame) | [
"def",
"open",
"(",
"filename",
",",
"frame",
"=",
"'unspecified'",
")",
":",
"data",
"=",
"Image",
".",
"load_data",
"(",
"filename",
")",
"if",
"len",
"(",
"data",
".",
"shape",
")",
">",
"2",
"and",
"data",
".",
"shape",
"[",
"2",
"]",
">",
"1",
":",
"data",
"=",
"data",
"[",
":",
",",
":",
",",
"0",
"]",
"return",
"BinaryImage",
"(",
"data",
",",
"frame",
")"
] | Creates a BinaryImage from a file.
Parameters
----------
filename : :obj:`str`
The file to load the data from. Must be one of .png, .jpg,
.npy, or .npz.
frame : :obj:`str`
A string representing the frame of reference in which the new image
lies.
Returns
-------
:obj:`BinaryImage`
The new binary image. | [
"Creates",
"a",
"BinaryImage",
"from",
"a",
"file",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2699-L2720 | train | Creates a BinaryImage from a file. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,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K_Doaa,znjnJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b110000) + chr(0b101010 + 0o105) + chr(2064 - 2013) + chr(50) + '\063', ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110010) + chr(793 - 738) + chr(0b1001 + 0o56), 58560 - 58552), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(50) + chr(0b110110), 20076 - 20068), nzTpIcepk0o8(chr(48) + '\157' + '\061' + chr(0b110111) + chr(0b101100 + 0o6), 62032 - 62024), nzTpIcepk0o8('\x30' + '\157' + chr(0b10 + 0o60) + '\x31' + chr(0b101 + 0o54), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(50) + '\x35' + chr(0b110000), 62307 - 62299), nzTpIcepk0o8(chr(48) + chr(0b100101 + 0o112) + chr(769 - 720) + '\x35', 0b1000), nzTpIcepk0o8('\060' + chr(0b1011100 + 0o23) + '\061' + chr(0b110001 + 0o5) + chr(2429 - 2376), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + '\067', 32582 - 32574), nzTpIcepk0o8('\x30' + '\157' + '\063' + '\x33', 0b1000), nzTpIcepk0o8('\060' + chr(111) + '\x33' + '\x37', 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + '\x31' + chr(0b1011 + 0o46) + chr(2235 - 2187), 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\062' + chr(0b110101) + '\x37', 52435 - 52427), nzTpIcepk0o8('\x30' + '\157' + chr(2302 - 2253) + chr(540 - 490) + '\x36', 0b1000), nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(0b1101111) + chr(0b110001) + chr(0b110011) + chr(0b110011), 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(945 - 894) + chr(55) + chr(0b1010 + 0o52), 0o10), nzTpIcepk0o8('\060' + '\157' + '\x35' + chr(1836 - 1783), 22377 - 22369), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(49) + chr(51) + '\066', 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(0b110010), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x36' + '\063', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b101101 + 0o5) + '\x31' + chr(0b110110), 16117 - 16109), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110011) + '\x34' + '\x33', ord("\x08")), nzTpIcepk0o8(chr(685 - 637) + chr(0b1011 + 0o144) + chr(0b1 + 0o62) + chr(468 - 414) + chr(49), 52963 - 52955), nzTpIcepk0o8(chr(0b110000) + chr(4773 - 4662) + '\x34' + '\066', 0o10), nzTpIcepk0o8('\060' + chr(111) + '\062' + chr(2281 - 2230) + chr(0b100000 + 0o24), 0b1000), nzTpIcepk0o8('\x30' + chr(0b110111 + 0o70) + chr(49) + chr(195 - 143) + '\x30', 0b1000), nzTpIcepk0o8('\x30' + '\157' + '\061' + chr(0b1111 + 0o45) + '\x36', 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(941 - 888) + chr(0b110111), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110001) + chr(260 - 208) + chr(0b110010), 0o10), nzTpIcepk0o8(chr(318 - 270) + chr(296 - 185) + chr(49) + chr(49) + '\067', 0b1000), nzTpIcepk0o8(chr(2086 - 2038) + chr(9373 - 9262) + chr(0b11010 + 0o31) + chr(756 - 701) + '\063', 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x33' + '\063' + chr(0b110011 + 0o0), 17060 - 17052), nzTpIcepk0o8('\060' + '\x6f' + chr(1404 - 1355) + chr(55) + chr(0b10010 + 0o37), 0b1000), nzTpIcepk0o8('\060' + chr(0b10011 + 0o134) + chr(53) + chr(801 - 753), 0b1000), nzTpIcepk0o8(chr(1592 - 1544) + '\157' + '\x31' + chr(0b110110) + chr(0b110010), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110011) + chr(0b110101) + '\x34', ord("\x08")), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(0b1101111) + chr(1478 - 1428), 8), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b11001 + 0o32) + chr(0b100111 + 0o15) + chr(51), 8), nzTpIcepk0o8('\060' + '\157' + '\x33' + chr(48) + chr(0b100000 + 0o23), 0o10), nzTpIcepk0o8(chr(0b101100 + 0o4) + '\157' + chr(0b11001 + 0o30) + '\067' + '\067', 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(11838 - 11727) + chr(0b110101) + '\x30', 8)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xfd'), '\x64' + chr(101) + '\x63' + '\x6f' + chr(100) + chr(101))(chr(0b101101 + 0o110) + '\164' + '\146' + chr(0b101101) + chr(88 - 32)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def DnU3Rq9N5ala(FxZHtXEolYsL, KZ4ew2qs1HTO=roI3spqORKae(ES5oEprVxulp(b'\xa6\xd1e\n\xec\xcbd\x13n~{'), chr(0b1010101 + 0o17) + chr(7008 - 6907) + chr(99) + chr(0b1101111) + '\x64' + chr(0b1100101))(chr(117) + chr(11718 - 11602) + chr(0b1100110) + chr(45) + chr(0b110010 + 0o6))):
FfKOThdpoDTb = RvV7ueTH51Uy.load_data(FxZHtXEolYsL)
if ftfygxgFas5X(roI3spqORKae(FfKOThdpoDTb, roI3spqORKae(ES5oEprVxulp(b"\xbf\xd7t7\xb9\x91?4AL'."), '\144' + chr(0b10011 + 0o122) + chr(0b1100010 + 0o1) + chr(111) + chr(1075 - 975) + chr(0b1100101))('\165' + chr(0b1110100) + '\146' + chr(0b101101) + chr(56)))) > nzTpIcepk0o8(chr(735 - 687) + chr(0b111010 + 0o65) + '\062', 8) and roI3spqORKae(FfKOThdpoDTb, roI3spqORKae(ES5oEprVxulp(b"\xbf\xd7t7\xb9\x91?4AL'."), chr(0b1100100) + chr(0b1000000 + 0o45) + chr(99) + '\x6f' + chr(100) + '\x65')(chr(117) + chr(0b11111 + 0o125) + '\x66' + '\x2d' + chr(1020 - 964)))[nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(678 - 628), 8)] > nzTpIcepk0o8(chr(191 - 143) + chr(111) + chr(49), 0b1000):
FfKOThdpoDTb = FfKOThdpoDTb[:, :, nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110000), ord("\x08"))]
return GALFuDMu2Qth(FfKOThdpoDTb, KZ4ew2qs1HTO) |
BerkeleyAutomation/perception | perception/image.py | RgbdImage._check_valid_data | def _check_valid_data(self, data):
"""Checks that the given data is a float array with four channels.
Parameters
----------
data : :obj:`numpy.ndarray`
The data to check.
Raises
------
ValueError
If the data is invalid.
"""
if data.dtype.type is not np.float32 and \
data.dtype.type is not np.float64:
raise ValueError(
'Illegal data type. RGB-D images only support float arrays')
if len(data.shape) != 3 and data.shape[2] != 4:
raise ValueError(
'Illegal data type. RGB-D images only support four channel')
color_data = data[:, :, :3]
if np.any((color_data < 0) | (color_data > BINARY_IM_MAX_VAL)):
raise ValueError(
'Color channels must be in the range (0, BINARY_IM_MAX_VAL)') | python | def _check_valid_data(self, data):
"""Checks that the given data is a float array with four channels.
Parameters
----------
data : :obj:`numpy.ndarray`
The data to check.
Raises
------
ValueError
If the data is invalid.
"""
if data.dtype.type is not np.float32 and \
data.dtype.type is not np.float64:
raise ValueError(
'Illegal data type. RGB-D images only support float arrays')
if len(data.shape) != 3 and data.shape[2] != 4:
raise ValueError(
'Illegal data type. RGB-D images only support four channel')
color_data = data[:, :, :3]
if np.any((color_data < 0) | (color_data > BINARY_IM_MAX_VAL)):
raise ValueError(
'Color channels must be in the range (0, BINARY_IM_MAX_VAL)') | [
"def",
"_check_valid_data",
"(",
"self",
",",
"data",
")",
":",
"if",
"data",
".",
"dtype",
".",
"type",
"is",
"not",
"np",
".",
"float32",
"and",
"data",
".",
"dtype",
".",
"type",
"is",
"not",
"np",
".",
"float64",
":",
"raise",
"ValueError",
"(",
"'Illegal data type. RGB-D images only support float arrays'",
")",
"if",
"len",
"(",
"data",
".",
"shape",
")",
"!=",
"3",
"and",
"data",
".",
"shape",
"[",
"2",
"]",
"!=",
"4",
":",
"raise",
"ValueError",
"(",
"'Illegal data type. RGB-D images only support four channel'",
")",
"color_data",
"=",
"data",
"[",
":",
",",
":",
",",
":",
"3",
"]",
"if",
"np",
".",
"any",
"(",
"(",
"color_data",
"<",
"0",
")",
"|",
"(",
"color_data",
">",
"BINARY_IM_MAX_VAL",
")",
")",
":",
"raise",
"ValueError",
"(",
"'Color channels must be in the range (0, BINARY_IM_MAX_VAL)'",
")"
] | Checks that the given data is a float array with four channels.
Parameters
----------
data : :obj:`numpy.ndarray`
The data to check.
Raises
------
ValueError
If the data is invalid. | [
"Checks",
"that",
"the",
"given",
"data",
"is",
"a",
"float",
"array",
"with",
"four",
"channels",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2751-L2776 | train | Checks that the given data is a float array with four channels. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g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TqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(111) + '\x32' + chr(0b11 + 0o62) + '\x30', 0b1000), nzTpIcepk0o8(chr(770 - 722) + '\157' + chr(541 - 492) + chr(0b110100) + chr(0b110010), 26645 - 26637), nzTpIcepk0o8(chr(1424 - 1376) + chr(9946 - 9835) + chr(727 - 678) + '\x30', 52262 - 52254), nzTpIcepk0o8(chr(48) + chr(111) + chr(1778 - 1729) + '\x31' + '\x37', 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(0b110001) + '\061' + '\060', 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(49) + chr(48) + chr(2233 - 2185), 39459 - 39451), nzTpIcepk0o8(chr(0b101011 + 0o5) + '\x6f' + '\062' + chr(2227 - 2174) + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x33' + chr(51) + chr(0b100000 + 0o27), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b100100 + 0o16) + chr(55) + '\063', 52904 - 52896), nzTpIcepk0o8(chr(1685 - 1637) + chr(0b1000 + 0o147) + chr(0b110001) + chr(0b1100 + 0o50) + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(273 - 225) + '\x6f' + chr(51) + '\x31' + '\065', 0b1000), nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(0b1101111) + '\x33' + chr(50) + chr(0b110111), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(0b1101 + 0o51) + chr(2452 - 2402), 9643 - 9635), nzTpIcepk0o8('\060' + '\157' + chr(0b10011 + 0o36) + chr(1612 - 1561) + '\x35', 45887 - 45879), nzTpIcepk0o8('\060' + chr(0b1001011 + 0o44) + '\062' + chr(1818 - 1770) + chr(49), ord("\x08")), nzTpIcepk0o8(chr(2257 - 2209) + chr(0b1001010 + 0o45) + chr(1463 - 1413) + '\x30' + '\x30', 58351 - 58343), nzTpIcepk0o8(chr(280 - 232) + chr(0b1101111) + chr(0b111 + 0o54) + chr(51) + '\067', 8), nzTpIcepk0o8(chr(48) + '\157' + '\062' + chr(0b1110 + 0o47) + chr(0b110011), 43074 - 43066), nzTpIcepk0o8('\x30' + '\x6f' + '\x32' + chr(245 - 193) + chr(1168 - 1118), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x33' + chr(0b110111) + chr(48), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110001) + chr(48) + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(1645 - 1597) + chr(0b1010100 + 0o33) + chr(0b110010) + '\x32' + chr(0b110000), ord("\x08")), nzTpIcepk0o8(chr(1940 - 1892) + chr(111) + chr(1549 - 1498) + '\x35' + '\x35', ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b11110 + 0o24) + '\060' + chr(0b11101 + 0o32), 33544 - 33536), nzTpIcepk0o8('\060' + chr(0b100110 + 0o111) + chr(51) + chr(0b110010) + chr(0b110101), 0b1000), nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(111) + '\x33' + '\061' + chr(0b110111), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + '\x33' + chr(51) + chr(2793 - 2739), 0b1000), nzTpIcepk0o8('\060' + chr(0b1011000 + 0o27) + chr(0b110010) + '\x35' + chr(0b0 + 0o63), 8), nzTpIcepk0o8(chr(48) + chr(0b1100110 + 0o11) + chr(90 - 40) + chr(55) + chr(0b110001 + 0o6), 0o10), nzTpIcepk0o8(chr(619 - 571) + chr(0b1101100 + 0o3) + '\062' + chr(397 - 345) + '\x32', 8), nzTpIcepk0o8(chr(547 - 499) + '\x6f' + chr(0b110010) + '\065' + chr(75 - 22), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b10110 + 0o35) + chr(1581 - 1533) + chr(0b110100), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + '\062' + chr(0b1101 + 0o43) + chr(0b110101), 45014 - 45006), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b11010 + 0o27) + chr(456 - 405) + '\x30', ord("\x08")), nzTpIcepk0o8(chr(1576 - 1528) + chr(0b1100010 + 0o15) + chr(0b11001 + 0o30) + chr(54) + chr(0b1011 + 0o52), 0b1000), nzTpIcepk0o8(chr(48) + chr(2483 - 2372) + chr(51) + chr(50) + chr(55), 8), nzTpIcepk0o8(chr(48) + '\157' + '\x35' + chr(344 - 293), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110001) + chr(0b110100) + chr(49), 8), nzTpIcepk0o8(chr(0b100 + 0o54) + '\157' + chr(0b10010 + 0o40) + chr(0b11100 + 0o32) + chr(1660 - 1611), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + '\x36', 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x35' + chr(2258 - 2210), 5454 - 5446)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x86'), chr(0b1011100 + 0o10) + chr(0b1001100 + 0o31) + chr(0b100010 + 0o101) + chr(111) + '\144' + chr(0b1001111 + 0o26))(chr(10358 - 10241) + '\x74' + '\x66' + '\x2d' + chr(0b111000)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def YkUBmLegAtNr(hXMPsSrOQzbh, FfKOThdpoDTb):
if roI3spqORKae(FfKOThdpoDTb.dtype, roI3spqORKae(ES5oEprVxulp(b"\xe5(8x\x103\xe7\xea\xce'\xaa\x80"), chr(0b1100100) + chr(0b1010011 + 0o22) + chr(1750 - 1651) + chr(0b1101111) + chr(1533 - 1433) + '\145')('\165' + chr(0b1110100) + '\146' + chr(0b101101 + 0o0) + chr(0b10000 + 0o50))) is not roI3spqORKae(nDF4gVNx0u9Q, roI3spqORKae(ES5oEprVxulp(b'\xce\x0eg.<s\x9b'), '\144' + chr(0b1100101) + '\143' + chr(12138 - 12027) + '\x64' + chr(0b1011010 + 0o13))(chr(0b1110101) + '\164' + '\x66' + chr(0b101101 + 0o0) + chr(0b10011 + 0o45))) and roI3spqORKae(FfKOThdpoDTb.dtype, roI3spqORKae(ES5oEprVxulp(b"\xe5(8x\x103\xe7\xea\xce'\xaa\x80"), chr(100) + '\145' + chr(0b10111 + 0o114) + chr(0b101 + 0o152) + chr(0b1100100) + '\x65')('\x75' + '\x74' + chr(0b1100110) + chr(0b100000 + 0o15) + chr(0b100 + 0o64))) is not roI3spqORKae(nDF4gVNx0u9Q, roI3spqORKae(ES5oEprVxulp(b'\xce\x0eg.<v\x9d'), chr(502 - 402) + '\x65' + '\x63' + '\157' + chr(0b1100100) + '\145')(chr(0b1110101) + chr(116) + chr(0b1100110) + chr(1856 - 1811) + chr(0b101110 + 0o12))):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xe1\x0ed*/!\xc5\xff\xdf\x00\xb9\xb6\x12)\xf8\xf0\xba\x85\x82\xaa\x06\xd2\xc0\xc3\xf5\xa6\xb3\xca\xd8\xc7\xde\xe4\xea6\x19\xae\x0b\x12\xc4v\xd8\rz;h&\xc5\xb0\xda\x15\xed\xb6@/\xe0\xf9\xac'), chr(0b1100100) + chr(0b1100101) + chr(99) + chr(0b1101011 + 0o4) + chr(0b110 + 0o136) + chr(1363 - 1262))('\165' + chr(0b1110100) + '\146' + '\055' + chr(1592 - 1536)))
if ftfygxgFas5X(roI3spqORKae(FfKOThdpoDTb, roI3spqORKae(ES5oEprVxulp(b'\xc4\nj\x02xy\x9b\x9e\xfd6\xf5\xb1'), chr(8939 - 8839) + chr(0b1100101) + chr(0b1100010 + 0o1) + chr(111) + chr(100) + chr(101))(chr(117) + chr(0b1011010 + 0o32) + '\x66' + '\055' + chr(2374 - 2318)))) != nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b100 + 0o57), 23870 - 23862) and roI3spqORKae(FfKOThdpoDTb, roI3spqORKae(ES5oEprVxulp(b'\xc4\nj\x02xy\x9b\x9e\xfd6\xf5\xb1'), chr(3876 - 3776) + '\x65' + chr(5941 - 5842) + chr(0b1100 + 0o143) + chr(0b101000 + 0o74) + chr(0b1010100 + 0o21))(chr(117) + chr(2408 - 2292) + chr(0b1100001 + 0o5) + chr(354 - 309) + chr(56)))[nzTpIcepk0o8(chr(48) + '\x6f' + '\062', 8263 - 8255)] != nzTpIcepk0o8('\x30' + chr(111) + chr(0b10000 + 0o44), ord("\x08")):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xe1\x0ed*/!\xc5\xff\xdf\x00\xb9\xb6\x12)\xf8\xf0\xba\x85\x82\xaa\x06\xd2\xc0\xc3\xf5\xa6\xb3\xca\xd8\xc7\xde\xe4\xea6\x19\xae\x0b\x12\xc4v\xd8\rz;h&\xc6\xaa\xc9A\xae\xbfS3\xef\xe5\xb3'), chr(0b1100100) + chr(0b1100011 + 0o2) + '\x63' + '\157' + '\144' + chr(101))(chr(117) + chr(0b10110 + 0o136) + '\x66' + chr(0b11000 + 0o25) + chr(56)))
KS4vAHvzjPYC = FfKOThdpoDTb[:, :, :nzTpIcepk0o8('\060' + chr(5870 - 5759) + chr(0b1100 + 0o47), 8)]
if roI3spqORKae(nDF4gVNx0u9Q, roI3spqORKae(ES5oEprVxulp(b'\xfe$<?\x03\x0f\xe6\xbd\xcf\r\x9d\xb4'), '\144' + '\x65' + '\x63' + chr(0b1101111) + chr(2105 - 2005) + chr(1447 - 1346))(chr(117) + chr(116) + chr(0b1100110) + chr(0b101101) + chr(0b111000)))((KS4vAHvzjPYC < nzTpIcepk0o8('\x30' + '\x6f' + chr(716 - 668), 0b1000)) | (KS4vAHvzjPYC > cjb5BYlcknHL)):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xeb\rd :`\xca\xb7\xda\x0f\xa3\xb2^.\xa1\xed\xaa\xd8\xd6\xd8#\xf5\xcd\xee\xbb\xef\xaa\xc3\xda\x82\xdf\xa5\xeb?\x10\xf7\x03Q\x9d&\xea+F\x0e\x1a\x19\xf6\x96\xf6>\x80\x96j\x02\xd7\xc1\x93\x82'), chr(0b1100100) + '\145' + chr(0b1100011) + chr(111) + '\144' + '\145')(chr(117) + '\164' + '\x66' + chr(45) + '\x38')) |
BerkeleyAutomation/perception | perception/image.py | RgbdImage.from_color_and_depth | def from_color_and_depth(color_im, depth_im):
""" Creates an RGB-D image from a separate color and depth image. """
# check shape
if color_im.height != depth_im.height or color_im.width != depth_im.width:
raise ValueError('Color and depth images must have the same shape')
# check frame
if color_im.frame != depth_im.frame:
raise ValueError('Color and depth images must have the same frame')
# form composite data
rgbd_data = np.zeros([color_im.height, color_im.width, 4])
rgbd_data[:, :, :3] = color_im.data.astype(np.float64)
rgbd_data[:, :, 3] = depth_im.data
return RgbdImage(rgbd_data, frame=color_im.frame) | python | def from_color_and_depth(color_im, depth_im):
""" Creates an RGB-D image from a separate color and depth image. """
# check shape
if color_im.height != depth_im.height or color_im.width != depth_im.width:
raise ValueError('Color and depth images must have the same shape')
# check frame
if color_im.frame != depth_im.frame:
raise ValueError('Color and depth images must have the same frame')
# form composite data
rgbd_data = np.zeros([color_im.height, color_im.width, 4])
rgbd_data[:, :, :3] = color_im.data.astype(np.float64)
rgbd_data[:, :, 3] = depth_im.data
return RgbdImage(rgbd_data, frame=color_im.frame) | [
"def",
"from_color_and_depth",
"(",
"color_im",
",",
"depth_im",
")",
":",
"# check shape",
"if",
"color_im",
".",
"height",
"!=",
"depth_im",
".",
"height",
"or",
"color_im",
".",
"width",
"!=",
"depth_im",
".",
"width",
":",
"raise",
"ValueError",
"(",
"'Color and depth images must have the same shape'",
")",
"# check frame",
"if",
"color_im",
".",
"frame",
"!=",
"depth_im",
".",
"frame",
":",
"raise",
"ValueError",
"(",
"'Color and depth images must have the same frame'",
")",
"# form composite data",
"rgbd_data",
"=",
"np",
".",
"zeros",
"(",
"[",
"color_im",
".",
"height",
",",
"color_im",
".",
"width",
",",
"4",
"]",
")",
"rgbd_data",
"[",
":",
",",
":",
",",
":",
"3",
"]",
"=",
"color_im",
".",
"data",
".",
"astype",
"(",
"np",
".",
"float64",
")",
"rgbd_data",
"[",
":",
",",
":",
",",
"3",
"]",
"=",
"depth_im",
".",
"data",
"return",
"RgbdImage",
"(",
"rgbd_data",
",",
"frame",
"=",
"color_im",
".",
"frame",
")"
] | Creates an RGB-D image from a separate color and depth image. | [
"Creates",
"an",
"RGB",
"-",
"D",
"image",
"from",
"a",
"separate",
"color",
"and",
"depth",
"image",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2779-L2793 | train | Creates an RGB - D image from a separate color and depth image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,Es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ae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b11110 + 0o22) + '\157' + chr(0b1111 + 0o44) + '\x34' + chr(2067 - 2014), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x33' + chr(847 - 794) + chr(1438 - 1389), 57660 - 57652), nzTpIcepk0o8('\060' + chr(0b1111 + 0o140) + chr(0b110001) + chr(0b1001 + 0o50) + chr(1013 - 960), 2037 - 2029), nzTpIcepk0o8('\x30' + '\157' + '\061' + chr(0b100101 + 0o17) + chr(0b11010 + 0o34), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\063' + chr(48) + chr(48), ord("\x08")), nzTpIcepk0o8(chr(0b100110 + 0o12) + chr(111) + chr(0b110010 + 0o0) + chr(0b110110) + chr(54), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(7009 - 6898) + '\063' + chr(2725 - 2670) + chr(55), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(1727 - 1616) + '\067' + chr(51), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(50) + '\x31' + chr(49), 0b1000), nzTpIcepk0o8('\060' + chr(4059 - 3948) + chr(0b110110), 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\062' + chr(55), ord("\x08")), nzTpIcepk0o8(chr(300 - 252) + '\x6f' + chr(49) + chr(0b1 + 0o65) + chr(0b110011), 0o10), nzTpIcepk0o8(chr(0b101111 + 0o1) + chr(111) + chr(0b10000 + 0o44) + chr(54), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(50) + chr(0b11 + 0o63) + chr(0b110100), 0o10), nzTpIcepk0o8('\060' + chr(111) + '\x32' + chr(1503 - 1451), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(1258 - 1208) + '\061' + chr(48), 46376 - 46368), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b1000 + 0o52) + chr(1686 - 1636), 41998 - 41990), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b11 + 0o60) + chr(488 - 439), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x32' + chr(0b1001 + 0o53) + '\x35', 53931 - 53923), nzTpIcepk0o8('\x30' + '\157' + '\064' + chr(0b110111), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + '\062' + chr(48) + chr(0b110011), ord("\x08")), nzTpIcepk0o8(chr(0b1011 + 0o45) + '\157' + chr(0b11111 + 0o23) + chr(0b1 + 0o60) + '\063', ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110101) + '\063', 0b1000), nzTpIcepk0o8('\060' + chr(8466 - 8355) + chr(110 - 60) + chr(437 - 388) + '\067', 0b1000), nzTpIcepk0o8('\x30' + chr(111) + '\x31' + '\064', 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(51) + '\x34' + '\x33', ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(253 - 204) + chr(51) + chr(0b100011 + 0o21), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x32' + chr(0b110011) + chr(49), 48933 - 48925), nzTpIcepk0o8(chr(0b11001 + 0o27) + chr(9524 - 9413) + chr(735 - 684) + chr(0b110101) + chr(603 - 553), 0b1000), nzTpIcepk0o8(chr(950 - 902) + chr(111) + chr(51) + chr(0b1010 + 0o46) + '\x33', 7171 - 7163), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\062' + chr(0b110010) + '\x34', 8569 - 8561), nzTpIcepk0o8('\x30' + '\157' + chr(0b110001) + '\x30' + chr(54 - 6), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(50) + chr(0b110000) + chr(429 - 376), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b10001 + 0o41) + chr(2668 - 2614) + chr(0b110001 + 0o4), 50113 - 50105), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(50) + chr(52) + '\064', 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\062' + chr(0b110100) + chr(0b110010), 0b1000), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(111) + '\x32' + chr(0b101010 + 0o13) + '\x37', ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110010) + chr(292 - 240) + '\x33', ord("\x08")), nzTpIcepk0o8(chr(0b10001 + 0o37) + chr(0b1101111) + chr(1706 - 1657) + '\067' + '\x35', 31746 - 31738), nzTpIcepk0o8(chr(0b110000) + chr(5155 - 5044) + chr(2487 - 2436) + '\x36', 41699 - 41691)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(771 - 723) + chr(1588 - 1477) + '\x35' + chr(48), 12960 - 12952)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xcb'), '\144' + '\145' + '\x63' + chr(0b1101101 + 0o2) + chr(100) + chr(6964 - 6863))(chr(117) + chr(0b101010 + 0o112) + '\x66' + '\055' + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def XNb8Z9jnQrWt(GFVgEmwvG0jZ, WZcCXRnThfxU):
if roI3spqORKae(GFVgEmwvG0jZ, roI3spqORKae(ES5oEprVxulp(b'\xb5\x88\x08$\xad\xc3\x91\x02\xc36N9'), chr(0b100000 + 0o104) + '\145' + '\x63' + chr(111) + '\x64' + '\145')('\165' + chr(0b1011 + 0o151) + chr(1377 - 1275) + '\x2d' + chr(0b1001 + 0o57))) != roI3spqORKae(WZcCXRnThfxU, roI3spqORKae(ES5oEprVxulp(b'\xb5\x88\x08$\xad\xc3\x91\x02\xc36N9'), chr(0b101 + 0o137) + chr(101) + '\x63' + '\x6f' + chr(8658 - 8558) + '\x65')('\165' + chr(0b1110100) + chr(4284 - 4182) + chr(0b101101) + chr(2192 - 2136))) or roI3spqORKae(GFVgEmwvG0jZ, roI3spqORKae(ES5oEprVxulp(b'\x81\xa1~\x10\xa3\xfd\x9bM\xeeDbC'), chr(0b1100100) + chr(0b101100 + 0o71) + chr(99) + '\x6f' + chr(2220 - 2120) + chr(1380 - 1279))('\165' + '\x74' + '\146' + chr(0b101101) + chr(916 - 860))) != roI3spqORKae(WZcCXRnThfxU, roI3spqORKae(ES5oEprVxulp(b'\x81\xa1~\x10\xa3\xfd\x9bM\xeeDbC'), chr(0b1010000 + 0o24) + '\145' + chr(99) + '\x6f' + '\144' + chr(3200 - 3099))(chr(9826 - 9709) + chr(0b1110100) + '\146' + chr(0b10011 + 0o32) + '\070')):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xa6\x86!\t\xb2\x96\x9eU\xed&s\x16V\xc0|\xa8{t\xc4@\xe6\xf8\x0b\xe2y\x90(\xb9\x82\xa2\xe2%\xa5\xc1\xcc\xc7\x8f\xd0\x1cs\x80\xc9>\x0e\xa1\xc6\x9a'), chr(0b1100100) + '\145' + chr(9674 - 9575) + chr(0b1101111) + '\x64' + chr(101))('\x75' + '\164' + chr(0b101100 + 0o72) + chr(0b110 + 0o47) + chr(0b110000 + 0o10)))
if roI3spqORKae(GFVgEmwvG0jZ, roI3spqORKae(ES5oEprVxulp(b'\xae\xb3y\x03\xb7\x84\x8eH\xb8NC<'), chr(100) + '\x65' + chr(99) + chr(0b1101111) + chr(100) + chr(3871 - 3770))('\165' + chr(0b1100111 + 0o15) + '\x66' + chr(0b101101) + '\x38')) != roI3spqORKae(WZcCXRnThfxU, roI3spqORKae(ES5oEprVxulp(b'\xae\xb3y\x03\xb7\x84\x8eH\xb8NC<'), chr(0b1011 + 0o131) + chr(0b1100101) + chr(0b1011101 + 0o6) + '\x6f' + chr(100) + '\145')(chr(117) + chr(116) + chr(0b1100110) + chr(172 - 127) + '\070')):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xa6\x86!\t\xb2\x96\x9eU\xed&s\x16V\xc0|\xa8{t\xc4@\xe6\xf8\x0b\xe2y\x90(\xb9\x82\xa2\xe2%\xa5\xc1\xcc\xc7\x8f\xd0\x1cs\x80\xc9+\x14\xa1\xdb\x9a'), '\x64' + chr(0b1101 + 0o130) + chr(345 - 246) + '\157' + '\x64' + '\x65')(chr(117) + chr(0b1110100) + '\x66' + '\055' + chr(0b111000)))
RcA9ekxesuMa = nDF4gVNx0u9Q.UmwwEp7MzR6q([GFVgEmwvG0jZ.PaEBmun9J0YJ, GFVgEmwvG0jZ.dH3vcKdvgBu0, nzTpIcepk0o8(chr(468 - 420) + chr(111) + chr(0b11100 + 0o30), 0b1000)])
RcA9ekxesuMa[:, :, :nzTpIcepk0o8(chr(1229 - 1181) + '\157' + chr(0b110011), 64348 - 64340)] = GFVgEmwvG0jZ.data.xqAChpcBkssb(nDF4gVNx0u9Q.float64)
RcA9ekxesuMa[:, :, nzTpIcepk0o8('\x30' + '\x6f' + chr(51), 8)] = WZcCXRnThfxU.FfKOThdpoDTb
return rT56Piz0yFTL(RcA9ekxesuMa, frame=roI3spqORKae(GFVgEmwvG0jZ, roI3spqORKae(ES5oEprVxulp(b'\xae\xb3y\x03\xb7\x84\x8eH\xb8NC<'), chr(1525 - 1425) + chr(0b1100000 + 0o5) + chr(1137 - 1038) + '\x6f' + chr(100) + chr(0b1100101))(chr(0b1110101) + chr(0b1110100) + '\146' + chr(203 - 158) + '\070'))) |
BerkeleyAutomation/perception | perception/image.py | RgbdImage.color | def color(self):
""" Returns the color image. """
return ColorImage(self.raw_data[:, :, :3].astype(
np.uint8), frame=self.frame) | python | def color(self):
""" Returns the color image. """
return ColorImage(self.raw_data[:, :, :3].astype(
np.uint8), frame=self.frame) | [
"def",
"color",
"(",
"self",
")",
":",
"return",
"ColorImage",
"(",
"self",
".",
"raw_data",
"[",
":",
",",
":",
",",
":",
"3",
"]",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
",",
"frame",
"=",
"self",
".",
"frame",
")"
] | Returns the color image. | [
"Returns",
"the",
"color",
"image",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2796-L2799 | train | Returns the color image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j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qORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110011) + chr(577 - 524) + chr(0b1011 + 0o51), 11027 - 11019), nzTpIcepk0o8(chr(48) + chr(111) + '\061' + chr(0b110110) + chr(48), 0b1000), nzTpIcepk0o8(chr(48) + chr(5676 - 5565) + '\061' + '\064' + '\061', 0o10), nzTpIcepk0o8(chr(863 - 815) + chr(0b1100001 + 0o16) + chr(2183 - 2134) + chr(0b101000 + 0o16) + chr(0b11 + 0o60), 0b1000), nzTpIcepk0o8(chr(0b101011 + 0o5) + chr(0b110 + 0o151) + chr(0b111 + 0o54) + chr(635 - 584) + chr(0b101101 + 0o6), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + '\062' + chr(0b110011) + '\x35', 13287 - 13279), nzTpIcepk0o8('\060' + '\x6f' + '\x31' + chr(0b110010) + '\067', 0o10), nzTpIcepk0o8(chr(184 - 136) + chr(8968 - 8857) + chr(49) + chr(0b110001) + chr(472 - 419), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + '\x33' + '\062' + chr(0b100000 + 0o26), ord("\x08")), nzTpIcepk0o8(chr(0b1100 + 0o44) + chr(6154 - 6043) + chr(49) + chr(1082 - 1031) + chr(49), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b10011 + 0o43) + chr(1193 - 1142), 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(141 - 90) + chr(50) + '\063', 0o10), nzTpIcepk0o8(chr(0b10110 + 0o32) + chr(0b110000 + 0o77) + '\063' + chr(0b110010) + chr(0b110100), 0o10), nzTpIcepk0o8('\060' + chr(2916 - 2805) + '\x32' + '\064' + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(0b11001 + 0o32) + chr(54) + chr(0b0 + 0o65), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(0b100001 + 0o21) + '\065' + chr(0b100110 + 0o21), 0o10), nzTpIcepk0o8('\x30' + '\157' + '\x33' + chr(0b110100) + chr(0b110011), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(1947 - 1836) + chr(0b110001) + chr(48) + chr(0b110010), 42005 - 41997), nzTpIcepk0o8(chr(0b101111 + 0o1) + chr(0b11100 + 0o123) + chr(842 - 788) + chr(51), 8), nzTpIcepk0o8(chr(0b110000) + chr(0b11000 + 0o127) + chr(0b101100 + 0o7) + '\x33' + '\x33', 8), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x31' + chr(0b100100 + 0o23) + chr(0b110110), 16689 - 16681), nzTpIcepk0o8(chr(0b11110 + 0o22) + chr(111) + '\x31' + chr(52) + chr(55), 0b1000), nzTpIcepk0o8(chr(378 - 330) + chr(7565 - 7454) + chr(562 - 511) + '\x34' + chr(0b110000), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(1960 - 1909) + '\064', ord("\x08")), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(111) + chr(298 - 249) + '\063' + chr(55), 0b1000), nzTpIcepk0o8(chr(0b100001 + 0o17) + '\x6f' + chr(49) + '\x31' + chr(0b110100), 0o10), nzTpIcepk0o8('\060' + chr(5207 - 5096) + chr(55) + '\061', 8337 - 8329), nzTpIcepk0o8(chr(48) + chr(0b1001010 + 0o45) + chr(0b101101 + 0o10) + chr(0b10011 + 0o40), 39503 - 39495), nzTpIcepk0o8(chr(48) + '\157' + '\x32' + chr(0b110001) + '\x36', 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b100001 + 0o22) + chr(0b11 + 0o63) + '\x34', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b100110 + 0o111) + chr(50) + '\x37' + chr(0b1010 + 0o53), 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(0b110011) + chr(0b110011 + 0o2) + '\x36', 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b111 + 0o53) + chr(49) + chr(1286 - 1231), 0o10), nzTpIcepk0o8('\x30' + chr(7994 - 7883) + chr(0b110010) + chr(52), ord("\x08")), nzTpIcepk0o8(chr(1922 - 1874) + chr(0b1100 + 0o143) + chr(0b110001) + chr(52) + chr(530 - 481), 8), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(1025 - 975) + '\x35' + '\065', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101110 + 0o1) + '\062' + chr(52) + chr(0b110010), 8), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(2286 - 2237) + '\x31' + chr(0b110100), 8), nzTpIcepk0o8('\x30' + chr(11378 - 11267) + chr(0b11001 + 0o30) + chr(0b111 + 0o55) + chr(0b11001 + 0o31), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(50) + chr(51) + chr(0b110100), 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b100 + 0o54) + chr(0b1101111) + chr(53) + '\x30', 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xc2'), '\x64' + chr(7077 - 6976) + chr(1012 - 913) + chr(0b1101111) + chr(3745 - 3645) + chr(101))(chr(0b1110101) + chr(7743 - 7627) + chr(925 - 823) + chr(45) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def s93qyRHd7l1y(hXMPsSrOQzbh):
return lPn7XfHAFaXG(roI3spqORKae(hXMPsSrOQzbh.raw_data[:, :, :nzTpIcepk0o8(chr(48) + chr(111) + '\x33', ord("\x08"))], roI3spqORKae(ES5oEprVxulp(b'\x94\x01 0\xb3\xed4\x0f\xbd*@\xb1'), chr(0b1100100) + '\145' + chr(0b1100011) + '\x6f' + chr(100) + chr(0b1100101))('\x75' + chr(0b10000 + 0o144) + chr(0b1100110) + chr(45) + chr(0b111 + 0o61)))(roI3spqORKae(nDF4gVNx0u9Q, roI3spqORKae(ES5oEprVxulp(b'\x8d*#B\xad\xea:)\x81\x0cl\x9e'), '\x64' + '\145' + '\143' + chr(11408 - 11297) + chr(100) + chr(0b1100101))(chr(0b1110101) + chr(0b1110100) + chr(0b101001 + 0o75) + chr(0b10010 + 0o33) + '\070'))), frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xa7*U\x16\xac\xaf&>\xe7\x11g\x9c'), chr(7301 - 7201) + '\145' + chr(0b11001 + 0o112) + '\157' + '\144' + '\145')(chr(6643 - 6526) + '\164' + chr(0b1100110) + '\x2d' + '\x38'))) |
BerkeleyAutomation/perception | perception/image.py | RgbdImage.mask_binary | def mask_binary(self, binary_im):
"""Create a new image by zeroing out data at locations
where binary_im == 0.0.
Parameters
----------
binary_im : :obj:`BinaryImage`
A BinaryImage of the same size as this image, with pixel values of either
zero or one. Wherever this image has zero pixels, we'll zero out the
pixels of the new image.
Returns
-------
:obj:`Image`
A new Image of the same type, masked by the given binary image.
"""
color = self.color.mask_binary(binary_im)
depth = self.depth.mask_binary(binary_im)
return RgbdImage.from_color_and_depth(color, depth) | python | def mask_binary(self, binary_im):
"""Create a new image by zeroing out data at locations
where binary_im == 0.0.
Parameters
----------
binary_im : :obj:`BinaryImage`
A BinaryImage of the same size as this image, with pixel values of either
zero or one. Wherever this image has zero pixels, we'll zero out the
pixels of the new image.
Returns
-------
:obj:`Image`
A new Image of the same type, masked by the given binary image.
"""
color = self.color.mask_binary(binary_im)
depth = self.depth.mask_binary(binary_im)
return RgbdImage.from_color_and_depth(color, depth) | [
"def",
"mask_binary",
"(",
"self",
",",
"binary_im",
")",
":",
"color",
"=",
"self",
".",
"color",
".",
"mask_binary",
"(",
"binary_im",
")",
"depth",
"=",
"self",
".",
"depth",
".",
"mask_binary",
"(",
"binary_im",
")",
"return",
"RgbdImage",
".",
"from_color_and_depth",
"(",
"color",
",",
"depth",
")"
] | Create a new image by zeroing out data at locations
where binary_im == 0.0.
Parameters
----------
binary_im : :obj:`BinaryImage`
A BinaryImage of the same size as this image, with pixel values of either
zero or one. Wherever this image has zero pixels, we'll zero out the
pixels of the new image.
Returns
-------
:obj:`Image`
A new Image of the same type, masked by the given binary image. | [
"Create",
"a",
"new",
"image",
"by",
"zeroing",
"out",
"data",
"at",
"locations",
"where",
"binary_im",
"==",
"0",
".",
"0",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2824-L2842 | train | Create a new image by zeroing out the pixels of the given binary image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9N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myaCTbWD,AtYHTsImz86v,pWZq9QOaZbhU,lI5UiuqoXdKZ,qZ4DivK_Doaa,znjnJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\060' + '\x6f' + chr(159 - 110) + '\064' + chr(0b110101), ord("\x08")), nzTpIcepk0o8(chr(2232 - 2184) + chr(0b1101001 + 0o6) + chr(78 - 23) + chr(48), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + '\x32' + chr(0b110011) + chr(50), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(49) + chr(54) + chr(48), 64711 - 64703), nzTpIcepk0o8(chr(0b110000) + chr(0b111100 + 0o63) + '\x37' + chr(49), 0b1000), nzTpIcepk0o8(chr(1252 - 1204) + '\157' + '\067' + '\063', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1100000 + 0o17) + '\x37' + '\x34', 0b1000), nzTpIcepk0o8('\060' + chr(0b1101000 + 0o7) + chr(2573 - 2522) + '\x34' + '\065', ord("\x08")), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(111) + chr(0b110011) + chr(2999 - 2944) + '\064', 0o10), nzTpIcepk0o8(chr(1495 - 1447) + chr(0b1101111) + chr(730 - 681) + '\x30' + chr(51), 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(0b1001 + 0o52) + chr(0b110110) + chr(0b1000 + 0o56), ord("\x08")), nzTpIcepk0o8('\x30' + chr(5150 - 5039) + '\061' + chr(0b101100 + 0o5) + chr(0b110000), 0b1000), nzTpIcepk0o8(chr(0b1000 + 0o50) + '\157' + chr(0b100 + 0o55) + chr(50) + '\x30', 0b1000), nzTpIcepk0o8('\x30' + chr(5963 - 5852) + chr(984 - 934) + chr(0b1111 + 0o44) + chr(2317 - 2262), 6939 - 6931), nzTpIcepk0o8(chr(48) + '\157' + chr(49) + '\x32' + chr(50), 64237 - 64229), nzTpIcepk0o8(chr(0b110000) + chr(0b101011 + 0o104) + chr(0b110011) + chr(0b110110) + chr(0b101011 + 0o13), 8), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\063' + '\061' + chr(0b1010 + 0o50), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b100110 + 0o13) + '\x34' + chr(0b10011 + 0o43), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b1 + 0o62) + chr(2601 - 2548) + chr(0b10 + 0o63), 10143 - 10135), nzTpIcepk0o8('\060' + chr(0b11010 + 0o125) + '\063' + chr(0b110010), 59885 - 59877), nzTpIcepk0o8(chr(1558 - 1510) + '\157' + chr(50) + chr(49) + '\x32', 61795 - 61787), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(0b1101111) + chr(0b110100) + '\067', 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(0b110011) + '\x36' + '\x33', 0b1000), nzTpIcepk0o8(chr(0b11001 + 0o27) + '\157' + '\x35' + chr(0b110101), 14359 - 14351), nzTpIcepk0o8('\060' + chr(0b110011 + 0o74) + chr(0b0 + 0o67) + chr(0b101100 + 0o12), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b101 + 0o152) + chr(0b100001 + 0o20), 5569 - 5561), nzTpIcepk0o8('\x30' + chr(0b1011001 + 0o26) + '\061' + '\x34' + '\061', 0b1000), nzTpIcepk0o8(chr(1937 - 1889) + '\x6f' + chr(0b101110 + 0o3) + chr(0b10000 + 0o45), 53078 - 53070), nzTpIcepk0o8('\x30' + chr(111) + chr(691 - 640) + chr(0b110010) + '\067', ord("\x08")), nzTpIcepk0o8('\x30' + chr(7635 - 7524) + chr(344 - 294) + '\x35', ord("\x08")), nzTpIcepk0o8('\060' + chr(2280 - 2169) + '\066' + chr(52), 32788 - 32780), nzTpIcepk0o8(chr(256 - 208) + '\x6f' + chr(0b110011) + chr(2202 - 2147) + chr(48), 22804 - 22796), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b101001 + 0o10) + chr(0b0 + 0o60) + '\x32', 40475 - 40467), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b101001 + 0o10) + chr(0b110110), 15524 - 15516), nzTpIcepk0o8(chr(981 - 933) + chr(0b10 + 0o155) + chr(0b110010) + chr(48) + '\x36', 46617 - 46609), nzTpIcepk0o8('\060' + chr(0b1001000 + 0o47) + '\065' + '\x36', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(2869 - 2758) + chr(0b110011) + '\061' + '\x34', ord("\x08")), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(0b1011000 + 0o27) + chr(0b110010) + chr(1955 - 1907) + chr(0b110110), 8), nzTpIcepk0o8('\x30' + '\157' + '\061' + chr(0b110101) + '\x34', 17738 - 17730), nzTpIcepk0o8(chr(0b1 + 0o57) + chr(6532 - 6421) + chr(0b11000 + 0o33) + chr(0b1010 + 0o51), 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + '\157' + chr(0b110101) + chr(0b110000), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'K'), '\144' + chr(0b10101 + 0o120) + chr(0b101010 + 0o71) + chr(0b1101101 + 0o2) + '\x64' + '\x65')('\165' + '\164' + chr(0b1100110) + chr(0b101101) + chr(0b10000 + 0o50)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def e8xvDKUROJ0j(hXMPsSrOQzbh, yMN3wUHEhDLY):
s93qyRHd7l1y = hXMPsSrOQzbh.color.mask_binary(yMN3wUHEhDLY)
UH0YjwuI_XzX = hXMPsSrOQzbh.depth.mask_binary(yMN3wUHEhDLY)
return roI3spqORKae(rT56Piz0yFTL, roI3spqORKae(ES5oEprVxulp(b'\x03J\xf5\x1dfXS\x89\x931\xa9)>\xfb\r\x92\xaf\x16\x99r'), chr(6038 - 5938) + chr(0b1100101) + chr(5229 - 5130) + chr(8975 - 8864) + '\144' + chr(8155 - 8054))(chr(117) + chr(0b1110100) + chr(7992 - 7890) + '\x2d' + chr(3062 - 3006)))(s93qyRHd7l1y, UH0YjwuI_XzX) |
BerkeleyAutomation/perception | perception/image.py | RgbdImage.resize | def resize(self, size, interp='bilinear'):
"""Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic')
"""
# resize channels separately
color_im_resized = self.color.resize(size, interp)
depth_im_resized = self.depth.resize(size, interp)
# return combination of resized data
return RgbdImage.from_color_and_depth(
color_im_resized, depth_im_resized) | python | def resize(self, size, interp='bilinear'):
"""Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic')
"""
# resize channels separately
color_im_resized = self.color.resize(size, interp)
depth_im_resized = self.depth.resize(size, interp)
# return combination of resized data
return RgbdImage.from_color_and_depth(
color_im_resized, depth_im_resized) | [
"def",
"resize",
"(",
"self",
",",
"size",
",",
"interp",
"=",
"'bilinear'",
")",
":",
"# resize channels separately",
"color_im_resized",
"=",
"self",
".",
"color",
".",
"resize",
"(",
"size",
",",
"interp",
")",
"depth_im_resized",
"=",
"self",
".",
"depth",
".",
"resize",
"(",
"size",
",",
"interp",
")",
"# return combination of resized data",
"return",
"RgbdImage",
".",
"from_color_and_depth",
"(",
"color_im_resized",
",",
"depth_im_resized",
")"
] | Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic') | [
"Resize",
"the",
"image",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2844-L2864 | train | Resizes the image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89t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bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b11100 + 0o24) + '\157' + chr(49) + chr(0b110010) + chr(52), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x31' + chr(0b10000 + 0o45) + '\060', 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(1471 - 1421) + chr(501 - 448) + '\067', 39055 - 39047), nzTpIcepk0o8(chr(0b110000) + '\157' + '\061' + '\x34' + '\063', 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(54) + '\063', ord("\x08")), nzTpIcepk0o8(chr(0b11100 + 0o24) + '\x6f' + '\061' + chr(0b101000 + 0o11) + chr(0b10110 + 0o33), 43024 - 43016), nzTpIcepk0o8('\060' + chr(111) + chr(50) + chr(2070 - 2019) + chr(1079 - 1029), ord("\x08")), nzTpIcepk0o8(chr(1264 - 1216) + chr(9577 - 9466) + chr(49) + '\064', 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(0b110011) + '\x33', 0o10), nzTpIcepk0o8('\060' + chr(111) + '\x33' + chr(0b110010) + chr(0b110011), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + '\x35', 3637 - 3629), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x32' + chr(0b101110 + 0o10) + chr(1182 - 1133), 0b1000), nzTpIcepk0o8(chr(0b10111 + 0o31) + chr(11949 - 11838) + chr(0b110011) + chr(0b11011 + 0o31) + chr(0b10 + 0o60), 0o10), nzTpIcepk0o8(chr(0b101011 + 0o5) + chr(111) + chr(51) + chr(55) + chr(1368 - 1314), 63084 - 63076), nzTpIcepk0o8(chr(48) + chr(111) + chr(2815 - 2760) + '\x36', 0o10), nzTpIcepk0o8(chr(48) + chr(0b10010 + 0o135) + '\061' + chr(1776 - 1727), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + '\061' + chr(2007 - 1958) + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(6828 - 6717) + '\062' + chr(0b10101 + 0o34) + '\x33', 0b1000), nzTpIcepk0o8('\x30' + chr(7108 - 6997) + chr(0b110110), 0o10), nzTpIcepk0o8(chr(48) + chr(0b10101 + 0o132) + chr(1406 - 1355) + chr(0b110010) + chr(0b11001 + 0o34), 52213 - 52205), nzTpIcepk0o8(chr(54 - 6) + chr(0b1101111) + chr(0b100100 + 0o17) + '\x35' + chr(0b110111), 0o10), nzTpIcepk0o8(chr(1020 - 972) + chr(7913 - 7802) + chr(1997 - 1948) + chr(1836 - 1783) + chr(0b110000), 8), nzTpIcepk0o8('\060' + '\x6f' + '\x33' + chr(1488 - 1433) + '\x36', 8), nzTpIcepk0o8(chr(562 - 514) + chr(0b1011100 + 0o23) + '\x32' + chr(52) + chr(0b110101), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + '\063' + chr(189 - 136), 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(369 - 320) + chr(50) + '\063', 0b1000), nzTpIcepk0o8(chr(48) + chr(7301 - 7190) + chr(217 - 163) + '\x31', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110010) + chr(53) + '\062', 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b1110 + 0o44) + '\065' + chr(49), ord("\x08")), nzTpIcepk0o8(chr(0b101100 + 0o4) + chr(111) + '\x32' + '\060', 43632 - 43624), nzTpIcepk0o8('\060' + '\157' + chr(0b101000 + 0o13) + chr(0b100011 + 0o24), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b101 + 0o152) + chr(0b1 + 0o64) + '\062', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b101001 + 0o12) + chr(0b110010), 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(0b100 + 0o57) + '\066' + '\x36', 0b1000), nzTpIcepk0o8(chr(532 - 484) + chr(0b1101111) + chr(50) + chr(54) + chr(0b1000 + 0o57), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(55) + chr(51), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1 + 0o156) + '\x31' + chr(0b110011) + chr(171 - 123), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(49) + '\065' + chr(53), 0o10), nzTpIcepk0o8(chr(0b1101 + 0o43) + '\x6f' + chr(595 - 546) + chr(0b110001) + chr(751 - 703), 12379 - 12371), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b100111 + 0o14) + chr(1608 - 1558) + chr(1145 - 1093), ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(2610 - 2557) + chr(485 - 437), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'z'), chr(9581 - 9481) + chr(0b1100101) + '\x63' + chr(0b1101111) + chr(0b1100100) + chr(0b1100101))('\x75' + chr(0b1110100) + '\x66' + '\055' + chr(56)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def ar68gq7_06Hs(hXMPsSrOQzbh, e1HrJaQHACnl, Cz8seJYyklrn=roI3spqORKae(ES5oEprVxulp(b'6\x01\xc3\n],\xfb~'), '\x64' + '\x65' + chr(7762 - 7663) + chr(0b1010011 + 0o34) + chr(0b1100100) + chr(101))(chr(7309 - 7192) + '\164' + '\146' + chr(0b101101) + chr(0b1101 + 0o53))):
BxYnDnt2cx4a = hXMPsSrOQzbh.color.resize(e1HrJaQHACnl, Cz8seJYyklrn)
bnJLvuh7D53M = hXMPsSrOQzbh.depth.resize(e1HrJaQHACnl, Cz8seJYyklrn)
return roI3spqORKae(rT56Piz0yFTL, roI3spqORKae(ES5oEprVxulp(b'2\x1a\xc0\x0el*\xf5`t\xa1Z\xd0\x8c\x9aam/\xfbr\xbd'), '\x64' + '\x65' + chr(0b1100011) + chr(0b1101111) + chr(100) + chr(9467 - 9366))(chr(8589 - 8472) + chr(116) + chr(102) + chr(0b100101 + 0o10) + '\070'))(BxYnDnt2cx4a, bnJLvuh7D53M) |
BerkeleyAutomation/perception | perception/image.py | RgbdImage.crop | def crop(self, height, width, center_i=None, center_j=None):
"""Crop the image centered around center_i, center_j.
Parameters
----------
height : int
The height of the desired image.
width : int
The width of the desired image.
center_i : int
The center height point at which to crop. If not specified, the center
of the image is used.
center_j : int
The center width point at which to crop. If not specified, the center
of the image is used.
Returns
-------
:obj:`Image`
A cropped Image of the same type.
"""
# crop channels separately
color_im_cropped = self.color.crop(height, width,
center_i=center_i,
center_j=center_j)
depth_im_cropped = self.depth.crop(height, width,
center_i=center_i,
center_j=center_j)
# return combination of cropped data
return RgbdImage.from_color_and_depth(
color_im_cropped, depth_im_cropped) | python | def crop(self, height, width, center_i=None, center_j=None):
"""Crop the image centered around center_i, center_j.
Parameters
----------
height : int
The height of the desired image.
width : int
The width of the desired image.
center_i : int
The center height point at which to crop. If not specified, the center
of the image is used.
center_j : int
The center width point at which to crop. If not specified, the center
of the image is used.
Returns
-------
:obj:`Image`
A cropped Image of the same type.
"""
# crop channels separately
color_im_cropped = self.color.crop(height, width,
center_i=center_i,
center_j=center_j)
depth_im_cropped = self.depth.crop(height, width,
center_i=center_i,
center_j=center_j)
# return combination of cropped data
return RgbdImage.from_color_and_depth(
color_im_cropped, depth_im_cropped) | [
"def",
"crop",
"(",
"self",
",",
"height",
",",
"width",
",",
"center_i",
"=",
"None",
",",
"center_j",
"=",
"None",
")",
":",
"# crop channels separately",
"color_im_cropped",
"=",
"self",
".",
"color",
".",
"crop",
"(",
"height",
",",
"width",
",",
"center_i",
"=",
"center_i",
",",
"center_j",
"=",
"center_j",
")",
"depth_im_cropped",
"=",
"self",
".",
"depth",
".",
"crop",
"(",
"height",
",",
"width",
",",
"center_i",
"=",
"center_i",
",",
"center_j",
"=",
"center_j",
")",
"# return combination of cropped data",
"return",
"RgbdImage",
".",
"from_color_and_depth",
"(",
"color_im_cropped",
",",
"depth_im_cropped",
")"
] | Crop the image centered around center_i, center_j.
Parameters
----------
height : int
The height of the desired image.
width : int
The width of the desired image.
center_i : int
The center height point at which to crop. If not specified, the center
of the image is used.
center_j : int
The center width point at which to crop. If not specified, the center
of the image is used.
Returns
-------
:obj:`Image`
A cropped Image of the same type. | [
"Crop",
"the",
"image",
"centered",
"around",
"center_i",
"center_j",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2866-L2900 | train | Crop the image centered around center_i and center_j. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2Cl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enPipeError,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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + '\x6f' + '\x33' + chr(0b101100 + 0o5) + '\066', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x32' + '\066' + chr(77 - 24), ord("\x08")), nzTpIcepk0o8(chr(1228 - 1180) + '\x6f' + '\062' + '\065' + '\x30', ord("\x08")), nzTpIcepk0o8(chr(0b1010 + 0o46) + chr(0b1101111) + chr(0b110111) + chr(2336 - 2284), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b101111 + 0o4) + '\x36' + chr(0b110101), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(1541 - 1492) + '\x31' + chr(1637 - 1585), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110110) + chr(0b11100 + 0o27), 0o10), nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(0b1101111) + chr(0b10011 + 0o36) + chr(2097 - 2044) + chr(0b110111), 1017 - 1009), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x33' + chr(0b110101) + chr(0b11000 + 0o36), ord("\x08")), nzTpIcepk0o8(chr(1117 - 1069) + '\x6f' + '\x33' + chr(52) + chr(52), 0b1000), nzTpIcepk0o8(chr(0b101101 + 0o3) + '\x6f' + chr(465 - 416) + chr(0b110011) + chr(50), 0o10), nzTpIcepk0o8(chr(0b11110 + 0o22) + '\157' + chr(0b10000 + 0o41) + chr(1038 - 990) + '\061', 21726 - 21718), nzTpIcepk0o8(chr(796 - 748) + '\x6f' + chr(0b101010 + 0o10), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110001) + '\067' + chr(0b10011 + 0o44), 0o10), nzTpIcepk0o8(chr(0b111 + 0o51) + chr(8974 - 8863) + chr(54) + chr(0b110110), 0b1000), nzTpIcepk0o8('\060' + chr(9585 - 9474) + chr(1902 - 1851) + chr(0b11101 + 0o24) + '\x35', 0o10), nzTpIcepk0o8(chr(1240 - 1192) + chr(8429 - 8318) + chr(0b110011) + chr(1260 - 1206) + chr(0b10001 + 0o41), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1000010 + 0o55) + '\062' + chr(49) + chr(0b101110 + 0o5), 30431 - 30423), nzTpIcepk0o8('\x30' + chr(7103 - 6992) + '\x31' + chr(0b110000) + chr(1985 - 1933), 20581 - 20573), nzTpIcepk0o8('\060' + chr(8209 - 8098) + '\x34' + chr(0b100001 + 0o22), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(0b11001 + 0o32) + chr(0b110010) + chr(0b110001 + 0o4), 0b1000), nzTpIcepk0o8('\060' + chr(3822 - 3711) + chr(0b101100 + 0o13) + '\x35', 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\062' + chr(1223 - 1168) + '\x33', 0o10), nzTpIcepk0o8(chr(48) + chr(0b11100 + 0o123) + '\x32' + chr(1545 - 1492) + '\060', 8), nzTpIcepk0o8(chr(48) + chr(0b111000 + 0o67) + chr(1058 - 1009) + chr(53) + chr(52), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(51) + '\061' + chr(0b110110), 8), nzTpIcepk0o8(chr(0b101110 + 0o2) + chr(8782 - 8671) + chr(0b110011) + chr(55) + chr(659 - 609), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b110110 + 0o71) + chr(0b110010) + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(1862 - 1814) + chr(111) + chr(1501 - 1450) + chr(2318 - 2266) + chr(0b110011), 0o10), nzTpIcepk0o8(chr(1904 - 1856) + chr(0b1101111) + chr(0b11 + 0o56) + chr(0b100001 + 0o24) + chr(585 - 537), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + '\062', 8), nzTpIcepk0o8(chr(0b111 + 0o51) + chr(111) + chr(0b110001) + chr(397 - 343) + '\x30', 14304 - 14296), nzTpIcepk0o8(chr(211 - 163) + chr(0b1101111) + '\062' + '\062' + chr(53), 0o10), nzTpIcepk0o8(chr(0b11011 + 0o25) + chr(0b1101111) + chr(1237 - 1187) + chr(0b110101) + chr(0b100000 + 0o21), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(49) + '\067' + chr(0b1010 + 0o55), 8), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(154 - 104) + '\061', 0b1000), nzTpIcepk0o8(chr(48) + '\157' + '\x32' + chr(634 - 583) + chr(0b110110), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(614 - 503) + '\x34' + chr(52), 0o10), nzTpIcepk0o8(chr(0b110 + 0o52) + '\157' + chr(51) + '\064' + chr(383 - 331), 8), nzTpIcepk0o8(chr(0b1001 + 0o47) + chr(0b1101111) + '\061' + chr(0b110100) + chr(48), 36568 - 36560)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(2021 - 1973) + chr(111) + chr(2075 - 2022) + chr(2130 - 2082), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xe0'), '\x64' + chr(101) + '\143' + chr(2906 - 2795) + chr(0b1010100 + 0o20) + chr(0b1100101))(chr(0b1010 + 0o153) + chr(0b1011 + 0o151) + '\x66' + '\055' + chr(0b111000)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def Q3RN9461D0Pv(hXMPsSrOQzbh, PaEBmun9J0YJ, dH3vcKdvgBu0, BuIaelM_UIs8=None, rTQGUmAdZW1q=None):
EMJPXwvIjz2e = hXMPsSrOQzbh.color.crop(PaEBmun9J0YJ, dH3vcKdvgBu0, center_i=BuIaelM_UIs8, center_j=rTQGUmAdZW1q)
pt1gedYaWycb = hXMPsSrOQzbh.depth.crop(PaEBmun9J0YJ, dH3vcKdvgBu0, center_i=BuIaelM_UIs8, center_j=rTQGUmAdZW1q)
return roI3spqORKae(rT56Piz0yFTL, roI3spqORKae(ES5oEprVxulp(b'\xa8\xc7\xc7Q\xaa/\\\x03\x81\x96\x05 l\x1bi\xa9\x97\xfb0K'), chr(100) + chr(0b1100101) + '\x63' + chr(8179 - 8068) + '\144' + chr(0b1100101))(chr(117) + '\x74' + chr(0b101010 + 0o74) + '\x2d' + chr(0b10100 + 0o44)))(EMJPXwvIjz2e, pt1gedYaWycb) |
BerkeleyAutomation/perception | perception/image.py | RgbdImage.transform | def transform(self, translation, theta, method='opencv'):
"""Create a new image by translating and rotating the current image.
Parameters
----------
translation : :obj:`numpy.ndarray` of float
The XY translation vector.
theta : float
Rotation angle in radians, with positive meaning counter-clockwise.
method : :obj:`str`
Method to use for image transformations (opencv or scipy)
Returns
-------
:obj:`Image`
An image of the same type that has been rotated and translated.
"""
# transform channels separately
color_im_tf = self.color.transform(translation, theta, method=method)
depth_im_tf = self.depth.transform(translation, theta, method=method)
# return combination of cropped data
return RgbdImage.from_color_and_depth(color_im_tf, depth_im_tf) | python | def transform(self, translation, theta, method='opencv'):
"""Create a new image by translating and rotating the current image.
Parameters
----------
translation : :obj:`numpy.ndarray` of float
The XY translation vector.
theta : float
Rotation angle in radians, with positive meaning counter-clockwise.
method : :obj:`str`
Method to use for image transformations (opencv or scipy)
Returns
-------
:obj:`Image`
An image of the same type that has been rotated and translated.
"""
# transform channels separately
color_im_tf = self.color.transform(translation, theta, method=method)
depth_im_tf = self.depth.transform(translation, theta, method=method)
# return combination of cropped data
return RgbdImage.from_color_and_depth(color_im_tf, depth_im_tf) | [
"def",
"transform",
"(",
"self",
",",
"translation",
",",
"theta",
",",
"method",
"=",
"'opencv'",
")",
":",
"# transform channels separately",
"color_im_tf",
"=",
"self",
".",
"color",
".",
"transform",
"(",
"translation",
",",
"theta",
",",
"method",
"=",
"method",
")",
"depth_im_tf",
"=",
"self",
".",
"depth",
".",
"transform",
"(",
"translation",
",",
"theta",
",",
"method",
"=",
"method",
")",
"# return combination of cropped data",
"return",
"RgbdImage",
".",
"from_color_and_depth",
"(",
"color_im_tf",
",",
"depth_im_tf",
")"
] | Create a new image by translating and rotating the current image.
Parameters
----------
translation : :obj:`numpy.ndarray` of float
The XY translation vector.
theta : float
Rotation angle in radians, with positive meaning counter-clockwise.
method : :obj:`str`
Method to use for image transformations (opencv or scipy)
Returns
-------
:obj:`Image`
An image of the same type that has been rotated and translated. | [
"Create",
"a",
"new",
"image",
"by",
"translating",
"and",
"rotating",
"the",
"current",
"image",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2902-L2924 | train | Create a new image by translating and rotating the current image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOVzf,YikXQdxs3VoO,UBvEeZymp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nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + '\x6f' + '\063' + chr(0b110000), 0b1000), nzTpIcepk0o8(chr(870 - 822) + chr(0b1101111) + '\x32' + '\x37' + chr(1302 - 1247), 33265 - 33257), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b100 + 0o57) + chr(51) + chr(55), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(50) + '\063' + '\065', 0o10), nzTpIcepk0o8('\x30' + chr(0b1101011 + 0o4) + '\x31' + '\x35' + chr(0b100111 + 0o16), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(1831 - 1780) + '\065' + chr(0b100011 + 0o17), ord("\x08")), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(1811 - 1700) + chr(598 - 547) + chr(53) + '\060', 0b1000), nzTpIcepk0o8('\060' + chr(0b101111 + 0o100) + '\x32' + '\x32' + chr(48), 0o10), nzTpIcepk0o8(chr(2086 - 2038) + '\157' + '\061' + chr(48) + chr(2273 - 2220), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(0b110011) + chr(53), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(2663 - 2610) + chr(0b10110 + 0o40), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x32' + chr(0b11 + 0o61) + chr(0b110100), 0o10), nzTpIcepk0o8(chr(0b101111 + 0o1) + chr(0b1101100 + 0o3) + '\063' + chr(51) + chr(48), 45099 - 45091), nzTpIcepk0o8(chr(48) + '\157' + '\x33' + '\x34' + '\062', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x33' + chr(0b100101 + 0o15) + chr(1232 - 1182), 0o10), nzTpIcepk0o8(chr(373 - 325) + chr(111) + chr(0b110110) + chr(55), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\061' + '\x30' + '\x34', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(8999 - 8888) + '\x33' + '\x32' + chr(0b110001), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110010) + chr(0b101111 + 0o7) + chr(50), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1348 - 1297) + chr(51) + chr(0b110011), 0b1000), nzTpIcepk0o8(chr(599 - 551) + chr(0b1101111) + chr(0b110 + 0o55) + '\x33', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(50) + chr(0b100000 + 0o25) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(0b0 + 0o60) + chr(0b1001 + 0o146) + '\062' + chr(302 - 253) + '\061', 0b1000), nzTpIcepk0o8(chr(0b10000 + 0o40) + chr(0b1010111 + 0o30) + '\x33' + chr(52) + chr(2273 - 2222), 0b1000), nzTpIcepk0o8('\060' + chr(2903 - 2792) + '\063' + chr(560 - 512) + '\062', 34935 - 34927), nzTpIcepk0o8('\060' + chr(111) + '\061' + chr(0b110000) + '\x35', 8), nzTpIcepk0o8(chr(0b1 + 0o57) + chr(111) + chr(49) + '\061' + chr(51), 0b1000), nzTpIcepk0o8('\060' + chr(111) + chr(0b101001 + 0o10) + chr(50) + '\x33', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b110001 + 0o76) + chr(0b110011) + chr(0b110111) + chr(1969 - 1916), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b11010 + 0o31) + '\x34' + chr(387 - 339), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(593 - 538), 4364 - 4356), nzTpIcepk0o8(chr(870 - 822) + chr(0b1101111) + chr(0b110010) + '\066', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x32' + chr(49) + chr(1620 - 1565), 0o10), nzTpIcepk0o8('\x30' + chr(1556 - 1445) + chr(0b110001) + chr(2261 - 2213) + chr(534 - 480), ord("\x08")), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(0b1011100 + 0o23) + '\x31' + chr(1508 - 1459) + chr(863 - 815), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(1149 - 1099) + chr(560 - 512) + chr(53), ord("\x08")), nzTpIcepk0o8(chr(2249 - 2201) + '\157' + chr(0b110111) + chr(50), 2561 - 2553), nzTpIcepk0o8(chr(0b1100 + 0o44) + '\157' + chr(1161 - 1106) + chr(0b101010 + 0o12), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(50) + chr(0b101110 + 0o5) + chr(594 - 540), 62641 - 62633), nzTpIcepk0o8('\060' + '\x6f' + chr(1617 - 1567) + chr(48) + chr(0b101 + 0o55), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(7954 - 7843) + chr(0b110101) + chr(63 - 15), 42151 - 42143)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'6'), chr(0b10111 + 0o115) + chr(101) + '\x63' + '\x6f' + chr(0b111000 + 0o54) + chr(101))(chr(0b1110101) + chr(0b1110100) + '\146' + '\055' + chr(0b111000)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def ioI6nQEObAZT(hXMPsSrOQzbh, cZKo5HdKdwkJ, ncDYK9LWVfBn, e5rcHW8hR5dL=roI3spqORKae(ES5oEprVxulp(b'w\xcf\xba\xf3\x0e\x9c'), chr(9903 - 9803) + '\145' + chr(0b1100011) + chr(111) + '\x64' + chr(0b1100101))(chr(8592 - 8475) + chr(10512 - 10396) + chr(0b1001000 + 0o36) + '\x2d' + '\070')):
NTri0g_dIwYD = hXMPsSrOQzbh.color.ioI6nQEObAZT(cZKo5HdKdwkJ, ncDYK9LWVfBn, method=e5rcHW8hR5dL)
kPA68W_hQrhk = hXMPsSrOQzbh.depth.ioI6nQEObAZT(cZKo5HdKdwkJ, ncDYK9LWVfBn, method=e5rcHW8hR5dL)
return roI3spqORKae(rT56Piz0yFTL, roI3spqORKae(ES5oEprVxulp(b'~\xcd\xb0\xf02\x89\x87\xfc*oq\xc5\xb6\x86\x8dS!\xa1\xc6\xb3'), chr(0b1010101 + 0o17) + '\x65' + '\143' + chr(0b1101111) + chr(100) + chr(4466 - 4365))('\x75' + '\164' + chr(8646 - 8544) + chr(0b11100 + 0o21) + chr(580 - 524)))(NTri0g_dIwYD, kPA68W_hQrhk) |
BerkeleyAutomation/perception | perception/image.py | RgbdImage.to_grayscale_depth | def to_grayscale_depth(self):
""" Converts to a grayscale and depth (G-D) image. """
gray = self.color.to_grayscale()
return GdImage.from_grayscale_and_depth(gray, self.depth) | python | def to_grayscale_depth(self):
""" Converts to a grayscale and depth (G-D) image. """
gray = self.color.to_grayscale()
return GdImage.from_grayscale_and_depth(gray, self.depth) | [
"def",
"to_grayscale_depth",
"(",
"self",
")",
":",
"gray",
"=",
"self",
".",
"color",
".",
"to_grayscale",
"(",
")",
"return",
"GdImage",
".",
"from_grayscale_and_depth",
"(",
"gray",
",",
"self",
".",
"depth",
")"
] | Converts to a grayscale and depth (G-D) image. | [
"Converts",
"to",
"a",
"grayscale",
"and",
"depth",
"(",
"G",
"-",
"D",
")",
"image",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2926-L2929 | train | Converts to a grayscale and depth image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,W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U,lI5UiuqoXdKZ,qZ4DivK_Doaa,znjnJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b1100 + 0o44) + chr(0b1101111) + chr(0b100111 + 0o12) + chr(0b110111) + chr(0b10101 + 0o40), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(1991 - 1940) + '\063' + chr(0b0 + 0o61), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b11000 + 0o32) + chr(52), 0b1000), nzTpIcepk0o8(chr(1056 - 1008) + chr(0b1010100 + 0o33) + chr(50) + chr(0b110111) + '\x37', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\061' + chr(0b110101) + chr(2179 - 2125), 0o10), nzTpIcepk0o8('\x30' + '\157' + '\061' + chr(0b10010 + 0o45) + chr(213 - 164), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(49) + chr(48) + chr(48), 32834 - 32826), nzTpIcepk0o8(chr(514 - 466) + chr(111) + '\062' + chr(0b110111) + chr(1811 - 1756), 8), nzTpIcepk0o8('\x30' + chr(0b110001 + 0o76) + chr(0b101001 + 0o10) + '\x37' + chr(49), 8), nzTpIcepk0o8(chr(0b100001 + 0o17) + chr(0b1101111) + '\062' + chr(50) + chr(860 - 812), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1100000 + 0o17) + chr(0b110011) + '\x32' + chr(1798 - 1745), 0o10), nzTpIcepk0o8(chr(625 - 577) + '\x6f' + chr(0b110010) + chr(2735 - 2680) + chr(53), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + '\x32' + chr(801 - 750) + '\x37', 0b1000), nzTpIcepk0o8(chr(0b100110 + 0o12) + chr(111) + chr(2477 - 2426) + '\060' + '\064', 51520 - 51512), nzTpIcepk0o8('\060' + chr(7059 - 6948) + chr(51) + chr(0b110110) + chr(0b110001), 54356 - 54348), nzTpIcepk0o8('\060' + chr(0b100111 + 0o110) + chr(54) + chr(74 - 22), 23419 - 23411), nzTpIcepk0o8(chr(767 - 719) + '\x6f' + chr(0b10110 + 0o37) + '\x30', 0b1000), nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(0b1110 + 0o141) + chr(0b110101) + '\061', ord("\x08")), nzTpIcepk0o8('\x30' + chr(9048 - 8937) + '\063' + chr(1070 - 1018) + chr(52), 0b1000), nzTpIcepk0o8(chr(0b101010 + 0o6) + chr(0b11110 + 0o121) + chr(49) + chr(0b110100) + chr(1820 - 1768), 18799 - 18791), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(51 - 1) + chr(0b110110) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + '\063' + chr(55) + '\x36', 0o10), nzTpIcepk0o8('\x30' + chr(111) + '\x35', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1011011 + 0o24) + chr(0b1101 + 0o52) + '\067', 3601 - 3593), nzTpIcepk0o8(chr(0b1100 + 0o44) + '\157' + chr(49) + '\x34' + chr(0b110001), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(0b10001 + 0o42) + '\060' + chr(55), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + chr(49) + chr(0b110110) + chr(0b110101), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1127 - 1078) + chr(0b101100 + 0o12) + chr(0b110101), 8), nzTpIcepk0o8(chr(0b10000 + 0o40) + '\157' + chr(0b110100) + chr(54), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + '\x31' + '\062' + chr(1993 - 1940), 25806 - 25798), nzTpIcepk0o8(chr(0b11110 + 0o22) + '\x6f' + chr(0b1 + 0o61) + chr(53) + chr(55), 0b1000), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110001 + 0o1) + chr(0b110001) + chr(51), ord("\x08")), nzTpIcepk0o8(chr(413 - 365) + chr(0b1101111) + chr(1516 - 1466) + chr(1864 - 1813) + chr(2289 - 2238), 9352 - 9344), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b1 + 0o62) + chr(2942 - 2887) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(0b10111 + 0o31) + chr(203 - 92) + chr(0b110001) + chr(55), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1100100 + 0o13) + chr(1070 - 1019) + '\061', 0b1000), nzTpIcepk0o8('\x30' + chr(7570 - 7459) + chr(0b11011 + 0o27) + chr(0b11011 + 0o30) + '\066', ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + chr(49) + chr(0b101101 + 0o11) + '\061', ord("\x08")), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(0b1101111) + chr(463 - 412) + chr(55) + chr(1350 - 1302), 0b1000), nzTpIcepk0o8('\x30' + chr(0b10000 + 0o137) + '\x33' + chr(53) + chr(0b110111), ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(1552 - 1504) + chr(0b1001 + 0o146) + '\065' + '\060', 8)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'S'), chr(0b1100100) + chr(0b110001 + 0o64) + '\143' + '\157' + chr(0b101101 + 0o67) + chr(4831 - 4730))('\x75' + chr(116) + chr(102) + chr(45) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def KSsbg7Oe4pBU(hXMPsSrOQzbh):
l1tLZ_eVduZ6 = hXMPsSrOQzbh.color.to_grayscale()
return roI3spqORKae(W2rsyliIhYRo, roI3spqORKae(ES5oEprVxulp(b'\x1b\xab{\xd21\x1e2\xde\x00\xe3\xb6\xdc\xf3\xa1\xaeUFM\xbb\x00\xd7\x8eqW'), chr(0b1100100) + chr(5446 - 5345) + chr(9779 - 9680) + chr(0b1101111) + chr(100) + '\x65')('\165' + chr(0b11110 + 0o126) + chr(0b111001 + 0o55) + chr(0b11001 + 0o24) + '\070'))(l1tLZ_eVduZ6, roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'(\x91$\xe6\x04\x0e5\xf6&\xc8\xaf\xe5'), chr(100) + chr(0b1011001 + 0o14) + chr(6641 - 6542) + chr(111) + chr(100) + chr(0b1100101))('\165' + '\164' + chr(9140 - 9038) + chr(45) + chr(56)))) |
BerkeleyAutomation/perception | perception/image.py | RgbdImage.combine_with | def combine_with(self, rgbd_im):
"""
Replaces all zeros in the source rgbd image with the values of a different rgbd image
Parameters
----------
rgbd_im : :obj:`RgbdImage`
rgbd image to combine with
Returns
-------
:obj:`RgbdImage`
the combined rgbd image
"""
new_data = self.data.copy()
depth_data = self.depth.data
other_depth_data = rgbd_im.depth.data
depth_zero_px = self.depth.zero_pixels()
depth_replace_px = np.where(
(other_depth_data != 0) & (
other_depth_data < depth_data))
depth_replace_px = np.c_[depth_replace_px[0], depth_replace_px[1]]
# replace zero pixels
new_data[depth_zero_px[:, 0], depth_zero_px[:, 1],
:] = rgbd_im.data[depth_zero_px[:, 0], depth_zero_px[:, 1], :]
# take closest pixel
new_data[depth_replace_px[:, 0], depth_replace_px[:, 1],
:] = rgbd_im.data[depth_replace_px[:, 0], depth_replace_px[:, 1], :]
return RgbdImage(new_data, frame=self.frame) | python | def combine_with(self, rgbd_im):
"""
Replaces all zeros in the source rgbd image with the values of a different rgbd image
Parameters
----------
rgbd_im : :obj:`RgbdImage`
rgbd image to combine with
Returns
-------
:obj:`RgbdImage`
the combined rgbd image
"""
new_data = self.data.copy()
depth_data = self.depth.data
other_depth_data = rgbd_im.depth.data
depth_zero_px = self.depth.zero_pixels()
depth_replace_px = np.where(
(other_depth_data != 0) & (
other_depth_data < depth_data))
depth_replace_px = np.c_[depth_replace_px[0], depth_replace_px[1]]
# replace zero pixels
new_data[depth_zero_px[:, 0], depth_zero_px[:, 1],
:] = rgbd_im.data[depth_zero_px[:, 0], depth_zero_px[:, 1], :]
# take closest pixel
new_data[depth_replace_px[:, 0], depth_replace_px[:, 1],
:] = rgbd_im.data[depth_replace_px[:, 0], depth_replace_px[:, 1], :]
return RgbdImage(new_data, frame=self.frame) | [
"def",
"combine_with",
"(",
"self",
",",
"rgbd_im",
")",
":",
"new_data",
"=",
"self",
".",
"data",
".",
"copy",
"(",
")",
"depth_data",
"=",
"self",
".",
"depth",
".",
"data",
"other_depth_data",
"=",
"rgbd_im",
".",
"depth",
".",
"data",
"depth_zero_px",
"=",
"self",
".",
"depth",
".",
"zero_pixels",
"(",
")",
"depth_replace_px",
"=",
"np",
".",
"where",
"(",
"(",
"other_depth_data",
"!=",
"0",
")",
"&",
"(",
"other_depth_data",
"<",
"depth_data",
")",
")",
"depth_replace_px",
"=",
"np",
".",
"c_",
"[",
"depth_replace_px",
"[",
"0",
"]",
",",
"depth_replace_px",
"[",
"1",
"]",
"]",
"# replace zero pixels",
"new_data",
"[",
"depth_zero_px",
"[",
":",
",",
"0",
"]",
",",
"depth_zero_px",
"[",
":",
",",
"1",
"]",
",",
":",
"]",
"=",
"rgbd_im",
".",
"data",
"[",
"depth_zero_px",
"[",
":",
",",
"0",
"]",
",",
"depth_zero_px",
"[",
":",
",",
"1",
"]",
",",
":",
"]",
"# take closest pixel",
"new_data",
"[",
"depth_replace_px",
"[",
":",
",",
"0",
"]",
",",
"depth_replace_px",
"[",
":",
",",
"1",
"]",
",",
":",
"]",
"=",
"rgbd_im",
".",
"data",
"[",
"depth_replace_px",
"[",
":",
",",
"0",
"]",
",",
"depth_replace_px",
"[",
":",
",",
"1",
"]",
",",
":",
"]",
"return",
"RgbdImage",
"(",
"new_data",
",",
"frame",
"=",
"self",
".",
"frame",
")"
] | Replaces all zeros in the source rgbd image with the values of a different rgbd image
Parameters
----------
rgbd_im : :obj:`RgbdImage`
rgbd image to combine with
Returns
-------
:obj:`RgbdImage`
the combined rgbd image | [
"Replaces",
"all",
"zeros",
"in",
"the",
"source",
"rgbd",
"image",
"with",
"the",
"values",
"of",
"a",
"different",
"rgbd",
"image"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2931-L2962 | train | Returns a new rgbd image with the values of a different rgbd image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz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nJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\060' + chr(0b1101111) + '\062' + '\060' + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b1100 + 0o46) + chr(58 - 4), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b0 + 0o157) + '\062' + chr(0b110010) + chr(0b101 + 0o60), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + '\x33' + chr(0b110010) + chr(54), 0o10), nzTpIcepk0o8(chr(848 - 800) + chr(111) + '\x32' + chr(54) + chr(50), 53979 - 53971), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(1978 - 1928) + '\061' + chr(457 - 405), 0b1000), nzTpIcepk0o8(chr(0b11001 + 0o27) + '\157' + '\066', 30939 - 30931), nzTpIcepk0o8(chr(0b110000) + chr(9383 - 9272) + '\063' + chr(55), 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(49) + chr(0b110100) + chr(1190 - 1140), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x32' + chr(1096 - 1045) + chr(1308 - 1257), 8485 - 8477), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(51) + '\064' + '\x33', ord("\x08")), nzTpIcepk0o8(chr(0b100110 + 0o12) + '\x6f' + chr(50) + '\065' + '\x33', 0o10), nzTpIcepk0o8(chr(48) + chr(0b111001 + 0o66) + chr(0b101110 + 0o4) + chr(0b110101) + chr(1223 - 1170), 36504 - 36496), nzTpIcepk0o8(chr(48) + '\157' + chr(0b11011 + 0o27) + chr(0b101 + 0o61) + chr(52), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101 + 0o142) + chr(2323 - 2274) + chr(53) + chr(1949 - 1900), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\063' + chr(987 - 932), 8), nzTpIcepk0o8(chr(48) + '\x6f' + '\x36' + chr(2561 - 2507), 50583 - 50575), nzTpIcepk0o8('\x30' + chr(0b0 + 0o157) + chr(226 - 176) + chr(1702 - 1653) + chr(0b110001), 58931 - 58923), nzTpIcepk0o8('\x30' + '\157' + '\x32' + chr(48) + chr(53), ord("\x08")), nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(0b1001001 + 0o46) + chr(0b110100) + chr(51), 0b1000), nzTpIcepk0o8(chr(48) + chr(11004 - 10893) + chr(0b100100 + 0o17) + '\061', 0b1000), nzTpIcepk0o8(chr(1333 - 1285) + '\x6f' + chr(0b110100) + chr(50), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110111) + '\067', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x30', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1001010 + 0o45) + chr(0b100001 + 0o22) + chr(891 - 839) + chr(0b10110 + 0o35), 8), nzTpIcepk0o8('\060' + chr(111) + '\066' + '\x30', 0b1000), nzTpIcepk0o8(chr(0b10011 + 0o35) + chr(7033 - 6922) + chr(0b101101 + 0o5) + chr(0b110001), 40779 - 40771), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110110) + '\x35', 0o10), nzTpIcepk0o8(chr(2248 - 2200) + chr(111) + chr(1554 - 1502) + '\x37', 0o10), nzTpIcepk0o8(chr(0b11001 + 0o27) + '\x6f' + chr(54) + chr(0b110111), ord("\x08")), nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(3285 - 3174) + '\x33', 39265 - 39257), nzTpIcepk0o8(chr(196 - 148) + chr(111) + chr(0b100010 + 0o17) + '\067' + chr(0b110101), 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(105 - 53) + chr(0b100111 + 0o20), 8), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x33' + '\x31' + chr(0b1100 + 0o50), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(2394 - 2283) + chr(2107 - 2052) + chr(1050 - 1000), 0o10), nzTpIcepk0o8(chr(318 - 270) + '\x6f' + '\061' + chr(0b110110) + chr(0b100001 + 0o22), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(1725 - 1674) + chr(0b1010 + 0o55) + chr(49), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(11046 - 10935) + chr(0b110011) + '\x37' + '\x30', 38709 - 38701), nzTpIcepk0o8(chr(281 - 233) + chr(111) + chr(1828 - 1778) + chr(2405 - 2350) + chr(0b1110 + 0o43), 27091 - 27083), nzTpIcepk0o8('\060' + '\x6f' + chr(49) + chr(1568 - 1517) + chr(0b10110 + 0o34), ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + chr(111) + chr(2430 - 2377) + chr(0b100 + 0o54), ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xa9'), '\x64' + chr(0b10 + 0o143) + chr(2188 - 2089) + chr(111) + chr(0b1100100) + chr(2361 - 2260))(chr(0b100010 + 0o123) + chr(116) + '\x66' + chr(45) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def WmLEu4EZjk19(hXMPsSrOQzbh, wTVndMlHFTt7):
ypHZ5ZvlVZBP = hXMPsSrOQzbh.data.copy()
gTJczuG2gUhu = hXMPsSrOQzbh.depth.FfKOThdpoDTb
L1zxinXZos3r = wTVndMlHFTt7.depth.FfKOThdpoDTb
Uo41xi2JxcK7 = hXMPsSrOQzbh.depth.zero_pixels()
reBetRbS0w7c = nDF4gVNx0u9Q.xWH4M7K6Qbd3((L1zxinXZos3r != nzTpIcepk0o8('\060' + '\x6f' + '\060', 8)) & (L1zxinXZos3r < gTJczuG2gUhu))
reBetRbS0w7c = nDF4gVNx0u9Q.c_[reBetRbS0w7c[nzTpIcepk0o8('\060' + chr(4188 - 4077) + chr(868 - 820), 8)], reBetRbS0w7c[nzTpIcepk0o8(chr(0b110000) + chr(11662 - 11551) + chr(49), 0b1000)]]
ypHZ5ZvlVZBP[Uo41xi2JxcK7[:, nzTpIcepk0o8(chr(355 - 307) + chr(7333 - 7222) + '\060', 8)], Uo41xi2JxcK7[:, nzTpIcepk0o8('\x30' + '\157' + '\x31', 8)], :] = wTVndMlHFTt7.FfKOThdpoDTb[Uo41xi2JxcK7[:, nzTpIcepk0o8(chr(585 - 537) + '\157' + chr(0b101100 + 0o4), 8)], Uo41xi2JxcK7[:, nzTpIcepk0o8(chr(734 - 686) + '\157' + chr(0b101000 + 0o11), 8)], :]
ypHZ5ZvlVZBP[reBetRbS0w7c[:, nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(531 - 483), 8)], reBetRbS0w7c[:, nzTpIcepk0o8(chr(0b110000) + '\157' + '\061', 8)], :] = wTVndMlHFTt7.FfKOThdpoDTb[reBetRbS0w7c[:, nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(1160 - 1112), 8)], reBetRbS0w7c[:, nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b11000 + 0o31), 8)], :]
return rT56Piz0yFTL(ypHZ5ZvlVZBP, frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xccL\xa1\xb3\xc5\xbewlS\xd3\xb7\xe4'), chr(7714 - 7614) + '\x65' + '\x63' + '\157' + chr(100) + '\145')(chr(8102 - 7985) + chr(0b110 + 0o156) + chr(0b1100110) + chr(45) + chr(1472 - 1416)))) |
BerkeleyAutomation/perception | perception/image.py | RgbdImage.crop | def crop(self, height, width, center_i=None, center_j=None):
"""Crop the image centered around center_i, center_j.
Parameters
----------
height : int
The height of the desired image.
width : int
The width of the desired image.
center_i : int
The center height point at which to crop. If not specified, the center
of the image is used.
center_j : int
The center width point at which to crop. If not specified, the center
of the image is used.
Returns
-------
:obj:`Image`
A cropped Image of the same type.
"""
color_im_crop = self.color.crop(height, width, center_i, center_j)
depth_im_crop = self.depth.crop(height, width, center_i, center_j)
return RgbdImage.from_color_and_depth(color_im_crop, depth_im_crop) | python | def crop(self, height, width, center_i=None, center_j=None):
"""Crop the image centered around center_i, center_j.
Parameters
----------
height : int
The height of the desired image.
width : int
The width of the desired image.
center_i : int
The center height point at which to crop. If not specified, the center
of the image is used.
center_j : int
The center width point at which to crop. If not specified, the center
of the image is used.
Returns
-------
:obj:`Image`
A cropped Image of the same type.
"""
color_im_crop = self.color.crop(height, width, center_i, center_j)
depth_im_crop = self.depth.crop(height, width, center_i, center_j)
return RgbdImage.from_color_and_depth(color_im_crop, depth_im_crop) | [
"def",
"crop",
"(",
"self",
",",
"height",
",",
"width",
",",
"center_i",
"=",
"None",
",",
"center_j",
"=",
"None",
")",
":",
"color_im_crop",
"=",
"self",
".",
"color",
".",
"crop",
"(",
"height",
",",
"width",
",",
"center_i",
",",
"center_j",
")",
"depth_im_crop",
"=",
"self",
".",
"depth",
".",
"crop",
"(",
"height",
",",
"width",
",",
"center_i",
",",
"center_j",
")",
"return",
"RgbdImage",
".",
"from_color_and_depth",
"(",
"color_im_crop",
",",
"depth_im_crop",
")"
] | Crop the image centered around center_i, center_j.
Parameters
----------
height : int
The height of the desired image.
width : int
The width of the desired image.
center_i : int
The center height point at which to crop. If not specified, the center
of the image is used.
center_j : int
The center width point at which to crop. If not specified, the center
of the image is used.
Returns
-------
:obj:`Image`
A cropped Image of the same type. | [
"Crop",
"the",
"image",
"centered",
"around",
"center_i",
"center_j",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L2964-L2990 | train | Crop the image centered around center_i center_j. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8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SkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b10001 + 0o37) + chr(3617 - 3506) + chr(411 - 361) + '\x33' + chr(54), ord("\x08")), nzTpIcepk0o8(chr(777 - 729) + chr(8043 - 7932) + chr(641 - 591) + chr(0b0 + 0o60) + chr(0b110001), 31178 - 31170), nzTpIcepk0o8('\060' + '\157' + '\x31' + '\x31' + chr(1369 - 1314), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + '\x31' + '\x34', ord("\x08")), nzTpIcepk0o8(chr(233 - 185) + chr(10411 - 10300) + chr(50) + chr(0b110 + 0o53) + chr(51), ord("\x08")), nzTpIcepk0o8(chr(995 - 947) + '\157' + '\061' + chr(0b110010) + chr(0b110001), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + '\062' + '\x32' + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(1716 - 1668) + chr(1526 - 1415) + '\063' + '\x34' + chr(757 - 702), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(51) + chr(0b100001 + 0o23) + '\x30', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1100000 + 0o17) + '\x31' + chr(1491 - 1440) + chr(0b110010 + 0o0), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + '\061' + chr(1756 - 1707) + '\x36', 53406 - 53398), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b100101 + 0o15) + chr(0b11 + 0o56) + chr(2303 - 2255), 0b1000), nzTpIcepk0o8(chr(2008 - 1960) + '\x6f' + chr(1265 - 1216) + chr(0b110001) + chr(0b1011 + 0o45), 34136 - 34128), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(2524 - 2473) + chr(0b11101 + 0o25), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x32' + '\x35', 0o10), nzTpIcepk0o8(chr(1896 - 1848) + chr(111) + chr(1852 - 1801) + '\x34' + '\064', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110001) + '\x30' + chr(52), 32867 - 32859), nzTpIcepk0o8(chr(0b101101 + 0o3) + '\157' + '\x31' + '\061' + chr(49), 0b1000), nzTpIcepk0o8(chr(1557 - 1509) + '\x6f' + chr(0b110010) + chr(0b110110) + chr(1894 - 1841), 0o10), nzTpIcepk0o8(chr(48) + chr(8804 - 8693) + chr(0b110010) + chr(54) + chr(53), 8), nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(111) + chr(1529 - 1479) + chr(0b110110) + chr(0b110010), 0o10), nzTpIcepk0o8(chr(0b10 + 0o56) + '\x6f' + '\064' + '\061', 0b1000), nzTpIcepk0o8(chr(1293 - 1245) + chr(0b1101111) + chr(1287 - 1236) + chr(0b110001) + chr(2007 - 1956), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b11011 + 0o124) + chr(51) + chr(0b110001) + chr(0b110011), 8), nzTpIcepk0o8('\060' + '\x6f' + chr(1994 - 1943) + chr(0b110101) + chr(52), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x35' + chr(0b110111), 58035 - 58027), nzTpIcepk0o8(chr(0b110000) + chr(0b10001 + 0o136) + chr(725 - 674) + chr(2497 - 2446) + chr(0b110011), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(0b101100 + 0o11) + chr(0b10100 + 0o41), 0b1000), nzTpIcepk0o8('\x30' + chr(7438 - 7327) + chr(49) + chr(2145 - 2091) + '\x37', 0o10), nzTpIcepk0o8('\060' + chr(111) + '\061' + chr(55) + chr(0b1011 + 0o47), 0o10), nzTpIcepk0o8(chr(0b100011 + 0o15) + chr(0b1101100 + 0o3) + chr(0b110110) + chr(52), ord("\x08")), nzTpIcepk0o8('\060' + chr(713 - 602) + chr(0b10001 + 0o42) + chr(0b1011 + 0o53) + chr(0b110000), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110010) + chr(0b110001), 13941 - 13933), nzTpIcepk0o8(chr(0b11101 + 0o23) + chr(0b1101111) + chr(0b110100) + chr(0b110100), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + '\x33' + chr(2874 - 2819) + chr(2011 - 1962), 25133 - 25125), nzTpIcepk0o8(chr(775 - 727) + '\157' + '\063' + chr(2105 - 2051), 0b1000), nzTpIcepk0o8('\x30' + chr(111) + '\x31' + '\x31' + chr(53), 9634 - 9626), nzTpIcepk0o8(chr(0b10000 + 0o40) + '\x6f' + chr(0b110010) + chr(359 - 304) + chr(147 - 97), ord("\x08")), nzTpIcepk0o8(chr(643 - 595) + '\x6f' + chr(0b11 + 0o56) + chr(0b110000) + chr(0b101100 + 0o7), 0b1000), nzTpIcepk0o8(chr(0b101 + 0o53) + chr(111) + chr(52 - 2) + '\x35', 8)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x35' + '\x30', 64746 - 64738)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xb0'), chr(100) + chr(101) + chr(99) + '\x6f' + '\x64' + '\145')(chr(0b1110101) + chr(0b1110100) + chr(5381 - 5279) + chr(0b101101) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def Q3RN9461D0Pv(hXMPsSrOQzbh, PaEBmun9J0YJ, dH3vcKdvgBu0, BuIaelM_UIs8=None, rTQGUmAdZW1q=None):
mjn1yAqeCrxS = hXMPsSrOQzbh.color.crop(PaEBmun9J0YJ, dH3vcKdvgBu0, BuIaelM_UIs8, rTQGUmAdZW1q)
r54KeBYQ_TpW = hXMPsSrOQzbh.depth.crop(PaEBmun9J0YJ, dH3vcKdvgBu0, BuIaelM_UIs8, rTQGUmAdZW1q)
return roI3spqORKae(rT56Piz0yFTL, roI3spqORKae(ES5oEprVxulp(b'\xf8\xf3 a\xd42\xf8\x8b\x8f(\x11\xe9&~J\x80!9\xc1\xdd'), chr(100) + chr(0b10001 + 0o124) + chr(99) + '\x6f' + '\144' + chr(0b1011010 + 0o13))(chr(0b11111 + 0o126) + chr(5522 - 5406) + chr(0b1100110) + chr(45) + '\x38'))(mjn1yAqeCrxS, r54KeBYQ_TpW) |
BerkeleyAutomation/perception | perception/image.py | GdImage.from_grayscale_and_depth | def from_grayscale_and_depth(gray_im, depth_im):
""" Creates an G-D image from a separate grayscale and depth image. """
# check shape
if gray_im.height != depth_im.height or gray_im.width != depth_im.width:
raise ValueError(
'Grayscale and depth images must have the same shape')
# check frame
if gray_im.frame != depth_im.frame:
raise ValueError(
'Grayscale and depth images must have the same frame')
# form composite data
gd_data = np.zeros([gray_im.height, gray_im.width, 2])
gd_data[:, :, 0] = gray_im.data.astype(np.float64)
gd_data[:, :, 1] = depth_im.data
return GdImage(gd_data, frame=gray_im.frame) | python | def from_grayscale_and_depth(gray_im, depth_im):
""" Creates an G-D image from a separate grayscale and depth image. """
# check shape
if gray_im.height != depth_im.height or gray_im.width != depth_im.width:
raise ValueError(
'Grayscale and depth images must have the same shape')
# check frame
if gray_im.frame != depth_im.frame:
raise ValueError(
'Grayscale and depth images must have the same frame')
# form composite data
gd_data = np.zeros([gray_im.height, gray_im.width, 2])
gd_data[:, :, 0] = gray_im.data.astype(np.float64)
gd_data[:, :, 1] = depth_im.data
return GdImage(gd_data, frame=gray_im.frame) | [
"def",
"from_grayscale_and_depth",
"(",
"gray_im",
",",
"depth_im",
")",
":",
"# check shape",
"if",
"gray_im",
".",
"height",
"!=",
"depth_im",
".",
"height",
"or",
"gray_im",
".",
"width",
"!=",
"depth_im",
".",
"width",
":",
"raise",
"ValueError",
"(",
"'Grayscale and depth images must have the same shape'",
")",
"# check frame",
"if",
"gray_im",
".",
"frame",
"!=",
"depth_im",
".",
"frame",
":",
"raise",
"ValueError",
"(",
"'Grayscale and depth images must have the same frame'",
")",
"# form composite data",
"gd_data",
"=",
"np",
".",
"zeros",
"(",
"[",
"gray_im",
".",
"height",
",",
"gray_im",
".",
"width",
",",
"2",
"]",
")",
"gd_data",
"[",
":",
",",
":",
",",
"0",
"]",
"=",
"gray_im",
".",
"data",
".",
"astype",
"(",
"np",
".",
"float64",
")",
"gd_data",
"[",
":",
",",
":",
",",
"1",
"]",
"=",
"depth_im",
".",
"data",
"return",
"GdImage",
"(",
"gd_data",
",",
"frame",
"=",
"gray_im",
".",
"frame",
")"
] | Creates an G-D image from a separate grayscale and depth image. | [
"Creates",
"an",
"G",
"-",
"D",
"image",
"from",
"a",
"separate",
"grayscale",
"and",
"depth",
"image",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3049-L3065 | train | Creates an G - D image from a separate grayscale and depth image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdk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aZbhU,lI5UiuqoXdKZ,qZ4DivK_Doaa,znjnJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + chr(0b1101111) + '\062' + chr(0b110001) + chr(0b10100 + 0o35), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + '\x32' + chr(1266 - 1218) + '\065', 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\063' + chr(0b110010) + '\x35', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110011) + chr(0b110010) + '\x31', ord("\x08")), nzTpIcepk0o8(chr(0b101 + 0o53) + chr(0b111001 + 0o66) + '\063' + '\x36', ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + '\x32' + '\060' + '\x37', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1100 + 0o143) + '\064' + chr(2592 - 2537), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b110 + 0o151) + chr(0b110000), 23223 - 23215), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(111) + chr(51) + chr(0b110110) + '\065', 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110001) + '\067' + '\060', 0o10), nzTpIcepk0o8(chr(2025 - 1977) + chr(8981 - 8870) + chr(0b110010) + chr(0b110110 + 0o0) + chr(0b101010 + 0o13), 0b1000), nzTpIcepk0o8(chr(48) + chr(4377 - 4266) + chr(0b101 + 0o55) + chr(0b101000 + 0o17) + '\064', 0o10), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(111) + chr(0b110001) + '\067' + '\x35', 28754 - 28746), nzTpIcepk0o8(chr(704 - 656) + '\157' + chr(1246 - 1196) + chr(650 - 596) + chr(0b110011), 0b1000), nzTpIcepk0o8(chr(0b10100 + 0o34) + '\157' + '\x35' + chr(309 - 257), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110011) + '\x34' + chr(555 - 500), 55630 - 55622), nzTpIcepk0o8(chr(1815 - 1767) + '\157' + chr(51) + chr(49) + chr(0b110110), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + '\x33' + chr(0b110100) + chr(2494 - 2443), ord("\x08")), nzTpIcepk0o8(chr(0b110 + 0o52) + '\157' + '\x37' + '\x35', 0b1000), nzTpIcepk0o8(chr(0b1 + 0o57) + '\157' + chr(55) + chr(0b10100 + 0o35), 0o10), nzTpIcepk0o8(chr(1260 - 1212) + chr(6661 - 6550) + chr(0b110010) + chr(52) + '\x30', 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x32' + chr(0b110101 + 0o2), ord("\x08")), nzTpIcepk0o8(chr(2159 - 2111) + chr(0b1101111) + '\063' + '\x34' + '\x37', 8), nzTpIcepk0o8('\x30' + '\x6f' + '\063' + '\064' + '\061', 0o10), nzTpIcepk0o8('\060' + chr(0b1011001 + 0o26) + chr(0b10000 + 0o43) + chr(2072 - 2017) + chr(2323 - 2273), 0o10), nzTpIcepk0o8('\060' + chr(6850 - 6739) + chr(49) + chr(1077 - 1028) + chr(0b10111 + 0o37), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110010) + chr(0b110000 + 0o0) + chr(55), 8), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(50) + '\x32', 0o10), nzTpIcepk0o8(chr(830 - 782) + chr(10316 - 10205) + chr(0b101 + 0o55) + chr(2829 - 2775), ord("\x08")), nzTpIcepk0o8(chr(376 - 328) + chr(8413 - 8302) + chr(0b110100) + chr(0b110000), 0o10), nzTpIcepk0o8(chr(0b11100 + 0o24) + chr(0b11101 + 0o122) + chr(49) + '\x31' + chr(0b110011), 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(0b10101 + 0o40), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\062' + '\063' + '\x31', 0b1000), nzTpIcepk0o8('\060' + chr(0b11000 + 0o127) + chr(50) + '\062' + '\066', 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110101) + chr(1620 - 1571), ord("\x08")), nzTpIcepk0o8(chr(490 - 442) + chr(111) + chr(0b110011) + chr(0b11111 + 0o25) + '\067', 8), nzTpIcepk0o8('\x30' + chr(111) + chr(0b110100) + chr(55), 8), nzTpIcepk0o8(chr(1474 - 1426) + '\157' + chr(51) + '\x34', 0b1000), nzTpIcepk0o8(chr(470 - 422) + chr(0b1101111) + chr(0b11110 + 0o30) + chr(0b110110), ord("\x08")), nzTpIcepk0o8(chr(1076 - 1028) + chr(1260 - 1149) + '\x37' + '\x31', 8)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(0b1101111) + chr(1778 - 1725) + '\060', ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xa7'), chr(100) + chr(0b100111 + 0o76) + chr(0b1100011) + '\157' + '\x64' + '\145')(chr(0b110000 + 0o105) + '\164' + '\x66' + chr(0b101101) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def V3TkfwTXqIXM(btqDf4BJxMsC, WZcCXRnThfxU):
if roI3spqORKae(btqDf4BJxMsC, roI3spqORKae(ES5oEprVxulp(b'\xd9\xe4\x90\x93s\xf2I9\xbfH\xec\xf6'), chr(0b1100100) + chr(0b1001101 + 0o30) + '\x63' + chr(0b101110 + 0o101) + '\144' + chr(0b1100101))(chr(12147 - 12030) + chr(0b1110100) + chr(102) + chr(851 - 806) + '\x38')) != roI3spqORKae(WZcCXRnThfxU, roI3spqORKae(ES5oEprVxulp(b'\xd9\xe4\x90\x93s\xf2I9\xbfH\xec\xf6'), chr(0b100001 + 0o103) + chr(101) + chr(0b1100011) + '\x6f' + '\x64' + chr(0b1100101))('\x75' + chr(116) + '\x66' + chr(0b100100 + 0o11) + '\070')) or roI3spqORKae(btqDf4BJxMsC, roI3spqORKae(ES5oEprVxulp(b'\xed\xcd\xe6\xa7}\xccCv\x92:\xc0\x8c'), '\x64' + chr(0b1011011 + 0o12) + '\x63' + '\157' + '\144' + '\x65')('\x75' + chr(7876 - 7760) + chr(0b1100110) + '\055' + '\x38')) != roI3spqORKae(WZcCXRnThfxU, roI3spqORKae(ES5oEprVxulp(b'\xed\xcd\xe6\xa7}\xccCv\x92:\xc0\x8c'), chr(0b1100100) + chr(101) + '\143' + chr(0b1101111) + chr(100) + '\145')('\x75' + chr(116) + chr(102) + '\x2d' + '\070')):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xce\xf7\xb4\xa8m\xe4Fl\x90X\xd4\xd2\x19\x93H\x82\xbe\x97U\x19\xc9z\x86\x86\x9f=\xa7\x7fcS?%\xf1\xf7_\x82\x07h^\\\xa9\xf6\xb4\xbc{\xa7Th\x94\x08\xd0'), chr(100) + '\145' + chr(4256 - 4157) + chr(0b1101111) + chr(3799 - 3699) + chr(0b1111 + 0o126))(chr(1824 - 1707) + '\x74' + '\x66' + chr(0b100 + 0o51) + chr(66 - 10)))
if roI3spqORKae(btqDf4BJxMsC, roI3spqORKae(ES5oEprVxulp(b'\xc2\xdf\xe1\xb4i\xb5Vs\xc40\xe1\xf3'), chr(0b1100100) + '\x65' + '\x63' + chr(5873 - 5762) + '\144' + chr(7806 - 7705))('\x75' + '\164' + chr(0b1100110) + '\055' + chr(0b111000))) != roI3spqORKae(WZcCXRnThfxU, roI3spqORKae(ES5oEprVxulp(b'\xc2\xdf\xe1\xb4i\xb5Vs\xc40\xe1\xf3'), '\144' + chr(101) + '\x63' + '\157' + '\144' + chr(0b1100101))('\165' + '\164' + '\146' + chr(0b101101) + '\070')):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xce\xf7\xb4\xa8m\xe4Fl\x90X\xd4\xd2\x19\x93H\x82\xbe\x97U\x19\xc9z\x86\x86\x9f=\xa7\x7fcS?%\xf1\xf7_\x82\x07h^\\\xa9\xf6\xb4\xbc{\xa7Ar\x94\x15\xd0'), chr(0b1100100) + chr(9164 - 9063) + '\143' + '\157' + chr(100) + chr(0b1100101))('\165' + chr(0b1110100) + chr(0b1100110) + chr(0b101011 + 0o2) + chr(0b111000)))
B1Qj5zZs8Gvw = nDF4gVNx0u9Q.UmwwEp7MzR6q([btqDf4BJxMsC.PaEBmun9J0YJ, btqDf4BJxMsC.dH3vcKdvgBu0, nzTpIcepk0o8(chr(48) + chr(111) + '\x32', 0o10)])
B1Qj5zZs8Gvw[:, :, nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(48), 8)] = btqDf4BJxMsC.data.xqAChpcBkssb(nDF4gVNx0u9Q.float64)
B1Qj5zZs8Gvw[:, :, nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110001), 0b1000)] = WZcCXRnThfxU.FfKOThdpoDTb
return W2rsyliIhYRo(B1Qj5zZs8Gvw, frame=roI3spqORKae(btqDf4BJxMsC, roI3spqORKae(ES5oEprVxulp(b'\xc2\xdf\xe1\xb4i\xb5Vs\xc40\xe1\xf3'), '\x64' + chr(9115 - 9014) + '\143' + '\x6f' + chr(100) + chr(101))('\x75' + '\164' + '\146' + '\055' + chr(2701 - 2645)))) |
BerkeleyAutomation/perception | perception/image.py | GdImage.gray | def gray(self):
""" Returns the grayscale image. """
return GrayscaleImage(
self.raw_data[:, :, 0].astype(np.uint8), frame=self.frame) | python | def gray(self):
""" Returns the grayscale image. """
return GrayscaleImage(
self.raw_data[:, :, 0].astype(np.uint8), frame=self.frame) | [
"def",
"gray",
"(",
"self",
")",
":",
"return",
"GrayscaleImage",
"(",
"self",
".",
"raw_data",
"[",
":",
",",
":",
",",
"0",
"]",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
",",
"frame",
"=",
"self",
".",
"frame",
")"
] | Returns the grayscale image. | [
"Returns",
"the",
"grayscale",
"image",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3068-L3071 | train | Returns the grayscale image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,Zn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Z4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110010) + chr(0b1011 + 0o53) + chr(0b110011 + 0o2), 0b1000), nzTpIcepk0o8(chr(1579 - 1531) + chr(111) + chr(0b11100 + 0o27) + chr(0b10100 + 0o36) + chr(566 - 518), ord("\x08")), nzTpIcepk0o8('\x30' + chr(5133 - 5022) + chr(883 - 834) + chr(2148 - 2095) + '\x30', ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110001) + '\062' + chr(1599 - 1544), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x31' + '\x35' + '\x30', 8), nzTpIcepk0o8('\x30' + chr(0b11011 + 0o124) + '\062' + '\067' + '\x32', 0b1000), nzTpIcepk0o8(chr(1502 - 1454) + chr(0b1100000 + 0o17) + '\x32' + '\066' + chr(0b1110 + 0o50), 0o10), nzTpIcepk0o8(chr(0b11000 + 0o30) + '\157' + chr(51) + chr(52) + chr(52), 52139 - 52131), nzTpIcepk0o8('\060' + chr(2541 - 2430) + '\x35' + chr(0b101101 + 0o7), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1010101 + 0o32) + chr(48), ord("\x08")), nzTpIcepk0o8(chr(1889 - 1841) + chr(0b1010101 + 0o32) + '\065' + chr(0b110010), 9738 - 9730), nzTpIcepk0o8('\060' + '\x6f' + chr(0b101010 + 0o11) + chr(1234 - 1183), 4139 - 4131), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(1301 - 1250), 62140 - 62132), nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(0b1011010 + 0o25) + '\062' + chr(0b100000 + 0o22) + '\061', 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(2246 - 2196) + chr(0b110000) + chr(0b100110 + 0o13), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(8846 - 8735) + chr(828 - 779) + chr(488 - 437) + chr(141 - 93), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b101001 + 0o11) + '\065' + chr(1392 - 1342), 0o10), nzTpIcepk0o8(chr(0b100 + 0o54) + chr(9465 - 9354) + chr(0b101100 + 0o12) + '\063', 0o10), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(0b100011 + 0o114) + '\x31' + '\067' + chr(0b11011 + 0o26), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(51) + '\x31' + chr(66 - 11), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + '\065' + chr(0b110101), ord("\x08")), nzTpIcepk0o8(chr(0b100001 + 0o17) + '\x6f' + chr(789 - 740) + chr(55) + chr(0b110001), 8), nzTpIcepk0o8('\060' + '\157' + '\063' + chr(0b100111 + 0o15) + chr(0b110101), ord("\x08")), nzTpIcepk0o8(chr(654 - 606) + chr(0b1101111) + chr(0b1110 + 0o44) + chr(50) + '\061', 8), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110011) + chr(0b110011) + chr(52), ord("\x08")), nzTpIcepk0o8(chr(1919 - 1871) + chr(0b1101111) + '\x37' + '\x37', 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(2272 - 2222) + chr(148 - 96) + chr(1597 - 1543), 54761 - 54753), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\064' + chr(2104 - 2049), 24566 - 24558), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(1665 - 1611) + chr(0b110011), 8), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(111) + '\062' + chr(0b110010) + chr(0b111 + 0o56), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(50) + chr(2663 - 2610) + '\065', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1001110 + 0o41) + '\061' + chr(49) + '\062', 61048 - 61040), nzTpIcepk0o8(chr(48) + '\157' + chr(49) + chr(0b1010 + 0o50) + chr(2994 - 2939), 8), nzTpIcepk0o8(chr(48) + chr(111) + chr(1305 - 1256) + '\064' + chr(49), 0b1000), nzTpIcepk0o8(chr(383 - 335) + chr(1827 - 1716) + chr(0b110010) + '\x33' + '\062', 28175 - 28167), nzTpIcepk0o8('\x30' + chr(111) + chr(0b110011) + '\x33' + chr(54), 0b1000), nzTpIcepk0o8('\060' + chr(10272 - 10161) + '\067' + chr(0b1000 + 0o54), ord("\x08")), nzTpIcepk0o8(chr(2244 - 2196) + chr(111) + '\x33' + chr(484 - 436) + chr(0b11001 + 0o35), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x31' + chr(1032 - 981) + chr(0b10111 + 0o40), 47828 - 47820), nzTpIcepk0o8(chr(0b110000) + chr(5873 - 5762) + chr(1464 - 1414) + chr(1331 - 1279), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110101) + chr(0b10001 + 0o37), 32906 - 32898)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x9b'), '\144' + chr(0b1100101) + chr(0b1100011) + chr(10336 - 10225) + chr(0b1100 + 0o130) + '\145')(chr(117) + chr(0b111001 + 0o73) + '\x66' + '\x2d' + chr(56)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def l1tLZ_eVduZ6(hXMPsSrOQzbh):
return Z1uLnGoVp7O0(roI3spqORKae(hXMPsSrOQzbh.raw_data[:, :, nzTpIcepk0o8('\x30' + chr(5237 - 5126) + chr(0b110000), 8)], roI3spqORKae(ES5oEprVxulp(b'\xcd\xa1)\x14\x00\xca\xd5\xa6GsYy'), '\144' + chr(0b1100101) + chr(99) + '\x6f' + '\x64' + chr(0b110000 + 0o65))(chr(7930 - 7813) + chr(0b1010 + 0o152) + chr(0b1100110) + chr(0b11101 + 0o20) + chr(1171 - 1115)))(roI3spqORKae(nDF4gVNx0u9Q, roI3spqORKae(ES5oEprVxulp(b'\xd4\x8a*f\x1e\xcd\xdb\x80{UuV'), chr(0b1100100) + '\145' + chr(0b1100011) + chr(111) + chr(0b1010011 + 0o21) + chr(9876 - 9775))('\x75' + '\164' + chr(6697 - 6595) + '\x2d' + '\x38'))), frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xfe\x8a\\2\x1f\x88\xc7\x97\x1dH~T'), chr(1723 - 1623) + chr(0b10010 + 0o123) + chr(0b1100011) + '\x6f' + '\x64' + chr(153 - 52))(chr(117) + chr(116) + chr(0b1100110) + chr(0b10 + 0o53) + chr(2291 - 2235)))) |
BerkeleyAutomation/perception | perception/image.py | GdImage.resize | def resize(self, size, interp='bilinear'):
"""Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic')
"""
# resize channels separately
gray_im_resized = self.gray.resize(size, interp)
depth_im_resized = self.depth.resize(size, interp)
# return combination of resized data
return GdImage.from_grayscale_and_depth(
gray_im_resized, depth_im_resized) | python | def resize(self, size, interp='bilinear'):
"""Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic')
"""
# resize channels separately
gray_im_resized = self.gray.resize(size, interp)
depth_im_resized = self.depth.resize(size, interp)
# return combination of resized data
return GdImage.from_grayscale_and_depth(
gray_im_resized, depth_im_resized) | [
"def",
"resize",
"(",
"self",
",",
"size",
",",
"interp",
"=",
"'bilinear'",
")",
":",
"# resize channels separately",
"gray_im_resized",
"=",
"self",
".",
"gray",
".",
"resize",
"(",
"size",
",",
"interp",
")",
"depth_im_resized",
"=",
"self",
".",
"depth",
".",
"resize",
"(",
"size",
",",
"interp",
")",
"# return combination of resized data",
"return",
"GdImage",
".",
"from_grayscale_and_depth",
"(",
"gray_im_resized",
",",
"depth_im_resized",
")"
] | Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic') | [
"Resize",
"the",
"image",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3096-L3116 | train | Resize the image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmq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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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b10111 + 0o31) + chr(0b1101111) + chr(50) + chr(739 - 686) + '\x35', ord("\x08")), nzTpIcepk0o8(chr(1537 - 1489) + chr(111) + chr(0b100100 + 0o16) + chr(50) + chr(48), ord("\x08")), nzTpIcepk0o8(chr(689 - 641) + chr(111) + chr(338 - 289) + chr(0b101100 + 0o5) + '\063', ord("\x08")), nzTpIcepk0o8(chr(1548 - 1500) + chr(0b1101111) + chr(50) + chr(0b110010) + '\x33', 30336 - 30328), nzTpIcepk0o8(chr(0b101010 + 0o6) + chr(5367 - 5256) + '\x31' + '\x33', 17052 - 17044), nzTpIcepk0o8('\060' + chr(0b1100100 + 0o13) + chr(0b110010) + chr(0b110100) + '\061', 0o10), nzTpIcepk0o8(chr(48) + '\157' + '\061' + chr(1336 - 1284) + '\067', 0b1000), nzTpIcepk0o8('\x30' + chr(2054 - 1943) + chr(0b110011) + chr(0b101001 + 0o12) + chr(54), 5635 - 5627), nzTpIcepk0o8(chr(1304 - 1256) + chr(0b10110 + 0o131) + chr(0b101101 + 0o5) + chr(0b110111) + chr(0b110010), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(49) + chr(0b110000) + chr(54), 0o10), nzTpIcepk0o8(chr(0b0 + 0o60) + chr(0b1100 + 0o143) + chr(49) + '\x30' + chr(928 - 876), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x31' + chr(374 - 320), ord("\x08")), nzTpIcepk0o8(chr(0b11 + 0o55) + chr(0b1011 + 0o144) + chr(0b11000 + 0o37) + chr(0b11111 + 0o25), 0b1000), nzTpIcepk0o8(chr(1744 - 1696) + chr(0b1101111) + chr(0b1010 + 0o50) + '\063' + '\x34', 0o10), nzTpIcepk0o8('\060' + '\x6f' + '\063' + chr(0b10011 + 0o42) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b10 + 0o57) + '\065' + '\x34', 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x32' + '\067' + chr(53), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(6766 - 6655) + chr(0b110110) + '\061', 55620 - 55612), nzTpIcepk0o8(chr(0b101 + 0o53) + '\x6f' + chr(51) + '\x35' + chr(0b110011), 14332 - 14324), nzTpIcepk0o8('\060' + chr(111) + '\x32' + chr(0b110111) + '\x32', 8), nzTpIcepk0o8(chr(48) + '\157' + chr(49) + chr(0b110001) + chr(48), 0o10), nzTpIcepk0o8('\x30' + chr(7992 - 7881) + '\x33' + chr(692 - 639) + '\062', 8), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b1111 + 0o42) + '\x30' + '\065', 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110011) + chr(0b110101) + '\x31', 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110001) + chr(0b110111) + '\x36', 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110011) + chr(0b11 + 0o61) + chr(0b110101 + 0o0), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(0b101101 + 0o4) + '\061' + chr(0b101111 + 0o10), 45660 - 45652), nzTpIcepk0o8('\x30' + chr(111) + '\x32' + chr(0b1010 + 0o54) + '\x36', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1000100 + 0o53) + chr(51) + '\x36' + chr(49), 0o10), nzTpIcepk0o8('\x30' + chr(0b101101 + 0o102) + chr(0b110011) + chr(1121 - 1071) + chr(49), ord("\x08")), nzTpIcepk0o8(chr(64 - 16) + '\157' + '\063' + chr(612 - 561) + chr(1655 - 1602), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(2386 - 2336) + chr(0b101101 + 0o6) + chr(0b110011), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + '\061' + chr(430 - 375) + chr(0b11110 + 0o26), 6664 - 6656), nzTpIcepk0o8(chr(48) + chr(0b1001110 + 0o41) + chr(0b101011 + 0o10) + chr(1626 - 1576) + chr(0b110110), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110010) + chr(2412 - 2359) + chr(0b101100 + 0o5), 0o10), nzTpIcepk0o8(chr(1078 - 1030) + chr(111) + chr(0b11101 + 0o31), 0o10), nzTpIcepk0o8(chr(221 - 173) + '\x6f' + chr(51) + '\064', 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x34' + chr(53), 16048 - 16040), nzTpIcepk0o8(chr(0b11010 + 0o26) + '\x6f' + chr(1844 - 1793) + chr(0b110001 + 0o1) + '\x32', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(55) + chr(0b110111), 29879 - 29871)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(1325 - 1277) + '\157' + chr(53) + chr(710 - 662), 23780 - 23772)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x83'), chr(0b1100100) + chr(0b1000011 + 0o42) + chr(0b1100011) + chr(0b10011 + 0o134) + '\x64' + '\145')('\x75' + '\x74' + chr(4853 - 4751) + chr(1168 - 1123) + chr(2853 - 2797)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def ar68gq7_06Hs(hXMPsSrOQzbh, e1HrJaQHACnl, Cz8seJYyklrn=roI3spqORKae(ES5oEprVxulp(b"\xcf\xf9'\xfae\xc4\x06\xac"), chr(0b1011111 + 0o5) + chr(0b1001110 + 0o27) + chr(99) + '\157' + chr(0b1100100) + chr(0b1100101))(chr(11340 - 11223) + chr(8524 - 8408) + chr(0b1100110) + chr(0b101000 + 0o5) + chr(0b111000))):
iu7oK67Vq9kf = hXMPsSrOQzbh.gray.resize(e1HrJaQHACnl, Cz8seJYyklrn)
bnJLvuh7D53M = hXMPsSrOQzbh.depth.resize(e1HrJaQHACnl, Cz8seJYyklrn)
return roI3spqORKae(W2rsyliIhYRo, roI3spqORKae(ES5oEprVxulp(b"\xcb\xe2$\xfeT\xc6\x15\xbf\xc35'oP\xf9\xb5\r\xd3U\xb4\xde-\x9a1\x81"), chr(100) + chr(0b1100101) + '\143' + chr(0b111000 + 0o67) + chr(100) + chr(6809 - 6708))('\165' + '\x74' + '\x66' + '\055' + chr(56)))(iu7oK67Vq9kf, bnJLvuh7D53M) |
BerkeleyAutomation/perception | perception/image.py | GdImage.crop | def crop(self, height, width, center_i=None, center_j=None):
"""Crop the image centered around center_i, center_j.
Parameters
----------
height : int
The height of the desired image.
width : int
The width of the desired image.
center_i : int
The center height point at which to crop. If not specified, the center
of the image is used.
center_j : int
The center width point at which to crop. If not specified, the center
of the image is used.
Returns
-------
:obj:`Image`
A cropped Image of the same type.
"""
gray_im_crop = self.gray.crop(height, width, center_i, center_j)
depth_im_crop = self.depth.crop(height, width, center_i, center_j)
return GdImage.from_grayscale_and_depth(gray_im_crop, depth_im_crop) | python | def crop(self, height, width, center_i=None, center_j=None):
"""Crop the image centered around center_i, center_j.
Parameters
----------
height : int
The height of the desired image.
width : int
The width of the desired image.
center_i : int
The center height point at which to crop. If not specified, the center
of the image is used.
center_j : int
The center width point at which to crop. If not specified, the center
of the image is used.
Returns
-------
:obj:`Image`
A cropped Image of the same type.
"""
gray_im_crop = self.gray.crop(height, width, center_i, center_j)
depth_im_crop = self.depth.crop(height, width, center_i, center_j)
return GdImage.from_grayscale_and_depth(gray_im_crop, depth_im_crop) | [
"def",
"crop",
"(",
"self",
",",
"height",
",",
"width",
",",
"center_i",
"=",
"None",
",",
"center_j",
"=",
"None",
")",
":",
"gray_im_crop",
"=",
"self",
".",
"gray",
".",
"crop",
"(",
"height",
",",
"width",
",",
"center_i",
",",
"center_j",
")",
"depth_im_crop",
"=",
"self",
".",
"depth",
".",
"crop",
"(",
"height",
",",
"width",
",",
"center_i",
",",
"center_j",
")",
"return",
"GdImage",
".",
"from_grayscale_and_depth",
"(",
"gray_im_crop",
",",
"depth_im_crop",
")"
] | Crop the image centered around center_i, center_j.
Parameters
----------
height : int
The height of the desired image.
width : int
The width of the desired image.
center_i : int
The center height point at which to crop. If not specified, the center
of the image is used.
center_j : int
The center width point at which to crop. If not specified, the center
of the image is used.
Returns
-------
:obj:`Image`
A cropped Image of the same type. | [
"Crop",
"the",
"image",
"centered",
"around",
"center_i",
"center_j",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3118-L3144 | train | Crop the image centered around center_i center_j. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOVzf,YikXQdxs3VoO,UBvEeZympYSz,mRTjFWUmjlQA,QhZR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oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(1606 - 1558) + chr(5150 - 5039) + chr(1620 - 1569) + '\065' + chr(0b1111 + 0o50), ord("\x08")), nzTpIcepk0o8('\060' + chr(8751 - 8640) + '\063' + chr(2137 - 2085) + chr(791 - 740), 0o10), nzTpIcepk0o8('\x30' + chr(0b1000110 + 0o51) + chr(50) + chr(55) + '\065', 60398 - 60390), nzTpIcepk0o8(chr(0b10000 + 0o40) + chr(7055 - 6944) + chr(0b110111) + '\x34', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b0 + 0o157) + chr(51) + chr(0b100111 + 0o11) + chr(54), 2238 - 2230), nzTpIcepk0o8('\x30' + '\x6f' + chr(50) + chr(0b1101 + 0o52) + chr(54), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b11010 + 0o125) + '\061' + '\063' + '\x37', 35430 - 35422), nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(3841 - 3730) + chr(0b110011) + chr(0b110001) + '\063', 22343 - 22335), nzTpIcepk0o8('\060' + chr(111) + chr(50) + chr(55) + chr(2312 - 2258), 8), nzTpIcepk0o8(chr(1208 - 1160) + chr(0b1101111) + chr(0b1011 + 0o46) + chr(0b10100 + 0o42) + chr(2254 - 2203), 0b1000), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110001) + '\067' + chr(49), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + chr(0b11 + 0o64) + '\060', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(1582 - 1471) + '\x32' + chr(2224 - 2170) + chr(1409 - 1359), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(1089 - 978) + chr(0b100010 + 0o24) + chr(0b100111 + 0o15), 0b1000), nzTpIcepk0o8('\060' + chr(1583 - 1472) + '\065' + chr(195 - 143), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b110010) + chr(1754 - 1702) + chr(0b110000), 0o10), nzTpIcepk0o8('\060' + chr(5236 - 5125) + '\x36' + chr(0b110000), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(51) + '\x35' + chr(0b110000 + 0o1), 0b1000), nzTpIcepk0o8(chr(48) + '\157' + '\062' + '\x32' + '\060', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110011) + chr(0b10 + 0o61) + chr(55), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x31' + chr(0b110100), 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(51) + chr(0b11001 + 0o35), 0o10), nzTpIcepk0o8(chr(0b11010 + 0o26) + '\157' + '\066' + chr(1437 - 1386), 50124 - 50116), nzTpIcepk0o8('\060' + '\x6f' + '\x32' + '\062' + chr(2222 - 2174), 8), nzTpIcepk0o8(chr(0b110000 + 0o0) + chr(6493 - 6382) + chr(0b110100) + chr(0b1111 + 0o42), ord("\x08")), nzTpIcepk0o8(chr(291 - 243) + chr(0b1101111) + chr(49) + chr(1171 - 1116) + chr(0b110000), 6609 - 6601), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(52) + '\x31', 8), nzTpIcepk0o8('\x30' + chr(111) + '\x33' + '\065' + '\x33', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1000000 + 0o57) + '\x37', 0o10), nzTpIcepk0o8('\060' + chr(6989 - 6878) + chr(49) + chr(707 - 656) + chr(74 - 25), 52780 - 52772), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(1608 - 1559) + chr(0b100101 + 0o15) + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(0b1010 + 0o46) + '\157' + chr(51) + '\x35' + chr(673 - 625), 0b1000), nzTpIcepk0o8('\060' + chr(111) + '\063' + chr(2504 - 2451) + chr(55), 8), nzTpIcepk0o8('\060' + chr(1860 - 1749) + chr(0b110001) + chr(0b110001) + chr(0b11000 + 0o30), 15235 - 15227), nzTpIcepk0o8(chr(48) + '\157' + '\062' + chr(55) + chr(0b100110 + 0o15), 0o10), nzTpIcepk0o8(chr(0b1000 + 0o50) + '\x6f' + '\062' + chr(62 - 9) + chr(1735 - 1683), 0o10), nzTpIcepk0o8(chr(0b100000 + 0o20) + '\x6f' + '\067' + chr(50), 0o10), nzTpIcepk0o8(chr(1304 - 1256) + '\x6f' + '\061' + '\x33' + chr(248 - 199), 8), nzTpIcepk0o8(chr(48) + '\157' + '\x37' + chr(0b110010), 8), nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(2233 - 2122) + '\x33' + '\x34' + chr(0b1011 + 0o53), ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(8939 - 8828) + '\x35' + chr(613 - 565), 3734 - 3726)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xc1'), chr(0b111010 + 0o52) + chr(0b111100 + 0o51) + chr(0b100111 + 0o74) + '\157' + '\x64' + '\x65')(chr(0b1110101) + chr(0b101 + 0o157) + chr(0b1100110) + chr(197 - 152) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def Q3RN9461D0Pv(hXMPsSrOQzbh, PaEBmun9J0YJ, dH3vcKdvgBu0, BuIaelM_UIs8=None, rTQGUmAdZW1q=None):
zzqsgkz_k2Tl = hXMPsSrOQzbh.gray.crop(PaEBmun9J0YJ, dH3vcKdvgBu0, BuIaelM_UIs8, rTQGUmAdZW1q)
r54KeBYQ_TpW = hXMPsSrOQzbh.depth.crop(PaEBmun9J0YJ, dH3vcKdvgBu0, BuIaelM_UIs8, rTQGUmAdZW1q)
return roI3spqORKae(W2rsyliIhYRo, roI3spqORKae(ES5oEprVxulp(b'\x89\x91\xd2Q\x99\xd9-\xaa\xc7\x00\x1aY\xdeQs\xc1^\x8d\xcf\xbbinG\xf8'), '\144' + chr(101) + chr(99) + chr(12084 - 11973) + chr(0b11 + 0o141) + '\145')(chr(117) + chr(7755 - 7639) + chr(102) + '\055' + chr(56)))(zzqsgkz_k2Tl, r54KeBYQ_TpW) |
BerkeleyAutomation/perception | perception/image.py | SegmentationImage.border_pixels | def border_pixels(
self,
grad_sigma=0.5,
grad_lower_thresh=0.1,
grad_upper_thresh=1.0):
"""
Returns the pixels on the boundary between all segments, excluding the zero segment.
Parameters
----------
grad_sigma : float
standard deviation used for gaussian gradient filter
grad_lower_thresh : float
lower threshold on gradient threshold used to determine the boundary pixels
grad_upper_thresh : float
upper threshold on gradient threshold used to determine the boundary pixels
Returns
-------
:obj:`numpy.ndarray`
Nx2 array of pixels on the boundary
"""
# boundary pixels
boundary_im = np.ones(self.shape)
for i in range(1, self.num_segments):
label_border_im = self.data.copy()
label_border_im[self.data == 0] = i
grad_mag = sf.gaussian_gradient_magnitude(
label_border_im.astype(np.float32), sigma=grad_sigma)
nonborder_px = np.where(
(grad_mag < grad_lower_thresh) | (
grad_mag > grad_upper_thresh))
boundary_im[nonborder_px[0], nonborder_px[1]] = 0
# return boundary pixels
border_px = np.where(boundary_im > 0)
border_px = np.c_[border_px[0], border_px[1]]
return border_px | python | def border_pixels(
self,
grad_sigma=0.5,
grad_lower_thresh=0.1,
grad_upper_thresh=1.0):
"""
Returns the pixels on the boundary between all segments, excluding the zero segment.
Parameters
----------
grad_sigma : float
standard deviation used for gaussian gradient filter
grad_lower_thresh : float
lower threshold on gradient threshold used to determine the boundary pixels
grad_upper_thresh : float
upper threshold on gradient threshold used to determine the boundary pixels
Returns
-------
:obj:`numpy.ndarray`
Nx2 array of pixels on the boundary
"""
# boundary pixels
boundary_im = np.ones(self.shape)
for i in range(1, self.num_segments):
label_border_im = self.data.copy()
label_border_im[self.data == 0] = i
grad_mag = sf.gaussian_gradient_magnitude(
label_border_im.astype(np.float32), sigma=grad_sigma)
nonborder_px = np.where(
(grad_mag < grad_lower_thresh) | (
grad_mag > grad_upper_thresh))
boundary_im[nonborder_px[0], nonborder_px[1]] = 0
# return boundary pixels
border_px = np.where(boundary_im > 0)
border_px = np.c_[border_px[0], border_px[1]]
return border_px | [
"def",
"border_pixels",
"(",
"self",
",",
"grad_sigma",
"=",
"0.5",
",",
"grad_lower_thresh",
"=",
"0.1",
",",
"grad_upper_thresh",
"=",
"1.0",
")",
":",
"# boundary pixels",
"boundary_im",
"=",
"np",
".",
"ones",
"(",
"self",
".",
"shape",
")",
"for",
"i",
"in",
"range",
"(",
"1",
",",
"self",
".",
"num_segments",
")",
":",
"label_border_im",
"=",
"self",
".",
"data",
".",
"copy",
"(",
")",
"label_border_im",
"[",
"self",
".",
"data",
"==",
"0",
"]",
"=",
"i",
"grad_mag",
"=",
"sf",
".",
"gaussian_gradient_magnitude",
"(",
"label_border_im",
".",
"astype",
"(",
"np",
".",
"float32",
")",
",",
"sigma",
"=",
"grad_sigma",
")",
"nonborder_px",
"=",
"np",
".",
"where",
"(",
"(",
"grad_mag",
"<",
"grad_lower_thresh",
")",
"|",
"(",
"grad_mag",
">",
"grad_upper_thresh",
")",
")",
"boundary_im",
"[",
"nonborder_px",
"[",
"0",
"]",
",",
"nonborder_px",
"[",
"1",
"]",
"]",
"=",
"0",
"# return boundary pixels",
"border_px",
"=",
"np",
".",
"where",
"(",
"boundary_im",
">",
"0",
")",
"border_px",
"=",
"np",
".",
"c_",
"[",
"border_px",
"[",
"0",
"]",
",",
"border_px",
"[",
"1",
"]",
"]",
"return",
"border_px"
] | Returns the pixels on the boundary between all segments, excluding the zero segment.
Parameters
----------
grad_sigma : float
standard deviation used for gaussian gradient filter
grad_lower_thresh : float
lower threshold on gradient threshold used to determine the boundary pixels
grad_upper_thresh : float
upper threshold on gradient threshold used to determine the boundary pixels
Returns
-------
:obj:`numpy.ndarray`
Nx2 array of pixels on the boundary | [
"Returns",
"the",
"pixels",
"on",
"the",
"boundary",
"between",
"all",
"segments",
"excluding",
"the",
"zero",
"segment",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3192-L3230 | train | Returns the pixels on the boundary between all segments excluding the zero segment. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOVzf,YikXQdxs3VoO,UBvEeZympYSz,mRTjFWUmjlQA,QhZRiM1qvaW7,WbNHlDKpyPtQ,z18h6a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qtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(2082 - 2034) + '\157' + '\063' + '\065' + '\x35', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + '\x32' + chr(2091 - 2038) + chr(156 - 108), 26283 - 26275), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(0b1101111) + chr(1226 - 1172) + '\x34', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\062' + chr(0b1001 + 0o50) + chr(0b110100), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(7238 - 7127) + chr(1036 - 986) + chr(0b0 + 0o64) + chr(0b101101 + 0o12), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1000101 + 0o52) + chr(2076 - 2026) + chr(2604 - 2549), 51200 - 51192), nzTpIcepk0o8(chr(2213 - 2165) + chr(4456 - 4345) + chr(0b110001), 31096 - 31088), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(905 - 856) + chr(49), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(6528 - 6417) + chr(1585 - 1536) + chr(55) + chr(0b101 + 0o54), 0o10), nzTpIcepk0o8('\060' + chr(0b1000111 + 0o50) + chr(0b11 + 0o57) + chr(1856 - 1808) + chr(50), 51347 - 51339), nzTpIcepk0o8('\x30' + '\x6f' + chr(1297 - 1247) + chr(212 - 163) + chr(1425 - 1376), 62166 - 62158), nzTpIcepk0o8(chr(1100 - 1052) + '\157' + chr(1395 - 1346) + '\x30', 0o10), nzTpIcepk0o8('\060' + chr(111) + chr(0b110011) + chr(50) + '\x35', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\061' + chr(163 - 110) + '\x30', 65043 - 65035), nzTpIcepk0o8(chr(48) + '\x6f' + chr(843 - 792) + '\064' + chr(52), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(50) + chr(49) + chr(55), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(55) + chr(0b110000), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b10001 + 0o42) + '\061', 0o10), nzTpIcepk0o8(chr(2023 - 1975) + chr(111) + '\x31' + chr(50) + '\062', 44277 - 44269), nzTpIcepk0o8(chr(48) + chr(8084 - 7973) + chr(2171 - 2120) + chr(676 - 624) + chr(1071 - 1020), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(52), 0o10), nzTpIcepk0o8('\060' + chr(0b1100011 + 0o14) + '\x36' + '\064', 8), nzTpIcepk0o8(chr(0b1000 + 0o50) + chr(0b11000 + 0o127) + chr(0b101111 + 0o3) + chr(48) + chr(0b110000), ord("\x08")), nzTpIcepk0o8(chr(1764 - 1716) + '\x6f' + chr(0b110011) + chr(50) + chr(0b1011 + 0o50), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x33', 0b1000), nzTpIcepk0o8('\x30' + chr(1190 - 1079) + '\062' + '\065' + '\066', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b11110 + 0o24) + '\x30', 0o10), nzTpIcepk0o8('\060' + chr(0b101011 + 0o104) + '\x32' + chr(0b11001 + 0o30) + chr(0b100011 + 0o15), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + '\063' + '\x36' + '\x32', 62095 - 62087), nzTpIcepk0o8(chr(735 - 687) + chr(111) + '\x32' + '\067' + chr(53), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b1101 + 0o44) + chr(0b110110), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1 + 0o156) + chr(51) + '\x33' + chr(0b101001 + 0o11), ord("\x08")), nzTpIcepk0o8('\x30' + chr(4843 - 4732) + chr(0b10011 + 0o37) + '\x37' + chr(53), 8), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(51) + '\x36', 19560 - 19552), nzTpIcepk0o8(chr(1131 - 1083) + chr(0b11100 + 0o123) + chr(50) + '\060' + chr(50), 8), nzTpIcepk0o8(chr(0b110000) + chr(11773 - 11662) + chr(0b110001) + '\061' + chr(2326 - 2271), 17656 - 17648), nzTpIcepk0o8(chr(1341 - 1293) + chr(0b1001100 + 0o43) + '\062' + chr(0b110011) + chr(48), 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(49) + '\x34' + chr(1820 - 1770), 13774 - 13766), nzTpIcepk0o8('\x30' + chr(0b1001110 + 0o41) + chr(0b110011) + chr(0b110001) + chr(0b10010 + 0o37), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\061' + chr(0b110001) + '\x37', 8)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + chr(111) + '\x35' + chr(59 - 11), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xc3'), '\144' + chr(101) + '\143' + chr(111) + chr(100) + chr(101))(chr(0b1010011 + 0o42) + chr(7412 - 7296) + chr(3906 - 3804) + chr(1386 - 1341) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def awdjtzvkuGDz(hXMPsSrOQzbh, GZqejm7tsJvj=0.5, fDjfOqrTKWjB=0.1, mkrqVITrCdKf=1.0):
F9lgxYXQhIio = nDF4gVNx0u9Q.rYPkZ8_2D0X1(hXMPsSrOQzbh.lhbM092AFW8f)
for ZlbFMSG8gCoF in bbT2xIe5pzk7(nzTpIcepk0o8('\060' + '\157' + '\x31', 8), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\x83\xddY\xd3\xd4rfd\x1c\xec\xfd{'), '\x64' + chr(0b1100101) + chr(99) + chr(111) + chr(100) + '\145')('\165' + chr(12912 - 12796) + '\x66' + '\055' + '\070'))):
q4X8J4iJp3wT = hXMPsSrOQzbh.data.copy()
q4X8J4iJp3wT[hXMPsSrOQzbh.FfKOThdpoDTb == nzTpIcepk0o8(chr(0b10011 + 0o35) + chr(12132 - 12021) + chr(0b1000 + 0o50), 0b1000)] = ZlbFMSG8gCoF
p5AqGbqWyIGo = S2RSmMFKiMNa.gaussian_gradient_magnitude(q4X8J4iJp3wT.xqAChpcBkssb(nDF4gVNx0u9Q.float32), sigma=GZqejm7tsJvj)
JN3pBDwWwc9e = nDF4gVNx0u9Q.xWH4M7K6Qbd3((p5AqGbqWyIGo < fDjfOqrTKWjB) | (p5AqGbqWyIGo > mkrqVITrCdKf))
F9lgxYXQhIio[JN3pBDwWwc9e[nzTpIcepk0o8(chr(2033 - 1985) + chr(0b1101111) + chr(48), 8)], JN3pBDwWwc9e[nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110001), 8)]] = nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(7743 - 7632) + chr(0b1101 + 0o43), 8)
nNIBKXh1mmF9 = nDF4gVNx0u9Q.xWH4M7K6Qbd3(F9lgxYXQhIio > nzTpIcepk0o8('\060' + '\157' + chr(0b11000 + 0o30), 8))
nNIBKXh1mmF9 = nDF4gVNx0u9Q.c_[nNIBKXh1mmF9[nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b11010 + 0o26), 8)], nNIBKXh1mmF9[nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b101111 + 0o2), 8)]]
return nNIBKXh1mmF9 |
BerkeleyAutomation/perception | perception/image.py | SegmentationImage.segment_mask | def segment_mask(self, segnum):
""" Returns a binary image of just the segment corresponding to the given number.
Parameters
----------
segnum : int
the number of the segment to generate a mask for
Returns
-------
:obj:`BinaryImage`
binary image data
"""
binary_data = np.zeros(self.shape)
binary_data[self.data == segnum] = BINARY_IM_MAX_VAL
return BinaryImage(binary_data.astype(np.uint8), frame=self.frame) | python | def segment_mask(self, segnum):
""" Returns a binary image of just the segment corresponding to the given number.
Parameters
----------
segnum : int
the number of the segment to generate a mask for
Returns
-------
:obj:`BinaryImage`
binary image data
"""
binary_data = np.zeros(self.shape)
binary_data[self.data == segnum] = BINARY_IM_MAX_VAL
return BinaryImage(binary_data.astype(np.uint8), frame=self.frame) | [
"def",
"segment_mask",
"(",
"self",
",",
"segnum",
")",
":",
"binary_data",
"=",
"np",
".",
"zeros",
"(",
"self",
".",
"shape",
")",
"binary_data",
"[",
"self",
".",
"data",
"==",
"segnum",
"]",
"=",
"BINARY_IM_MAX_VAL",
"return",
"BinaryImage",
"(",
"binary_data",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
",",
"frame",
"=",
"self",
".",
"frame",
")"
] | Returns a binary image of just the segment corresponding to the given number.
Parameters
----------
segnum : int
the number of the segment to generate a mask for
Returns
-------
:obj:`BinaryImage`
binary image data | [
"Returns",
"a",
"binary",
"image",
"of",
"just",
"the",
"segment",
"corresponding",
"to",
"the",
"given",
"number",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3232-L3247 | train | Returns a binary image of just the segment corresponding to the given number. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9re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,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b110000) + chr(5533 - 5422) + '\x32' + '\x35' + chr(2334 - 2285), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x32' + '\x32' + '\x36', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x33', 0o10), nzTpIcepk0o8(chr(0b11001 + 0o27) + '\x6f' + '\061' + chr(55) + '\064', 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + chr(51) + '\063' + chr(1181 - 1127), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(1261 - 1150) + '\x31' + chr(49 - 1) + chr(988 - 935), 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(1146 - 1095) + '\x34' + chr(0b110010), 64021 - 64013), nzTpIcepk0o8('\x30' + chr(5871 - 5760) + chr(1361 - 1312) + chr(0b1001 + 0o47) + '\x37', ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(0b101110 + 0o4) + chr(0b110001 + 0o5) + '\x35', 61408 - 61400), nzTpIcepk0o8(chr(0b100100 + 0o14) + chr(111) + chr(0b110010) + '\060' + chr(503 - 455), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(50) + chr(998 - 949) + chr(0b110110), 48849 - 48841), nzTpIcepk0o8(chr(2275 - 2227) + chr(0b1101111) + chr(1225 - 1174) + chr(0b100111 + 0o16) + '\x35', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(51) + '\063' + '\060', 0o10), nzTpIcepk0o8(chr(1847 - 1799) + chr(0b1011 + 0o144) + chr(1520 - 1470) + chr(0b111 + 0o56) + '\x34', 0o10), nzTpIcepk0o8('\060' + '\157' + '\x31' + chr(213 - 164) + chr(52), 0o10), nzTpIcepk0o8('\060' + '\157' + chr(50) + chr(1456 - 1406) + chr(52), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110001 + 0o2) + chr(48) + '\065', ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b0 + 0o62) + '\066' + '\x33', 0o10), nzTpIcepk0o8(chr(48) + chr(0b10101 + 0o132) + '\062' + chr(1033 - 983) + '\x33', 28451 - 28443), nzTpIcepk0o8(chr(410 - 362) + chr(111) + '\x31' + chr(49) + chr(55), 0b1000), nzTpIcepk0o8(chr(48) + chr(9267 - 9156) + chr(0b11001 + 0o31) + chr(48), ord("\x08")), nzTpIcepk0o8('\x30' + chr(1345 - 1234) + chr(0b100010 + 0o21) + '\x30' + chr(52), 57186 - 57178), nzTpIcepk0o8(chr(536 - 488) + chr(0b1101111) + chr(49) + chr(0b110100) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(1256 - 1205) + '\065' + '\x35', 8), nzTpIcepk0o8('\x30' + '\x6f' + chr(162 - 112) + chr(0b11110 + 0o27) + chr(0b100011 + 0o21), 8), nzTpIcepk0o8(chr(0b11111 + 0o21) + chr(11356 - 11245) + chr(2570 - 2516) + '\x33', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\062' + chr(57 - 9) + chr(48), 8), nzTpIcepk0o8(chr(0b100011 + 0o15) + '\157' + chr(912 - 862) + chr(0b110010) + chr(51), 8), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(51) + '\x31', 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x31' + '\064', 35545 - 35537), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x31' + chr(0b110001) + '\x35', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1011011 + 0o24) + '\063' + '\x36' + chr(819 - 764), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + '\061' + chr(53) + chr(0b10111 + 0o34), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(762 - 712) + chr(1492 - 1444) + '\066', 48603 - 48595), nzTpIcepk0o8(chr(0b110000) + chr(0b101000 + 0o107) + chr(52) + chr(0b1011 + 0o46), 16228 - 16220), nzTpIcepk0o8('\x30' + '\157' + '\x32' + chr(54) + chr(69 - 18), 8), nzTpIcepk0o8('\060' + chr(0b1101111) + '\062' + '\064' + chr(0b11100 + 0o25), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x31' + chr(0b110110) + '\060', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110011) + chr(720 - 669) + chr(2097 - 2049), 8), nzTpIcepk0o8(chr(1986 - 1938) + '\157' + chr(0b110010) + '\067' + chr(535 - 487), 6497 - 6489)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(0b1101111) + '\065' + chr(48), 56882 - 56874)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x87'), chr(7745 - 7645) + chr(0b10111 + 0o116) + chr(0b1000011 + 0o40) + '\x6f' + chr(3276 - 3176) + chr(0b1100101))(chr(117) + chr(0b1100101 + 0o17) + chr(6811 - 6709) + chr(845 - 800) + chr(929 - 873)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def jEg_5aj57LYM(hXMPsSrOQzbh, BUv3fwj_5yFD):
Lk6HDQ8HFSCK = nDF4gVNx0u9Q.UmwwEp7MzR6q(hXMPsSrOQzbh.lhbM092AFW8f)
Lk6HDQ8HFSCK[hXMPsSrOQzbh.FfKOThdpoDTb == BUv3fwj_5yFD] = cjb5BYlcknHL
return GALFuDMu2Qth(roI3spqORKae(Lk6HDQ8HFSCK, roI3spqORKae(ES5oEprVxulp(b'\xd1\xe7B?\xb65\x81\x05\xde\xf3\xfd\x8f'), chr(0b1110 + 0o126) + '\145' + '\x63' + '\x6f' + '\144' + chr(5344 - 5243))(chr(0b110010 + 0o103) + chr(116) + chr(8209 - 8107) + '\x2d' + chr(1668 - 1612)))(roI3spqORKae(nDF4gVNx0u9Q, roI3spqORKae(ES5oEprVxulp(b'\xc8\xccAM\xa82\x8f#\xe2\xd5\xd1\xa0'), chr(7157 - 7057) + chr(0b100111 + 0o76) + chr(0b1010110 + 0o15) + '\x6f' + '\144' + chr(0b1100101))(chr(0b1110101) + chr(0b1110100) + chr(102) + chr(0b1110 + 0o37) + chr(471 - 415)))), frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xe2\xcc7\x19\xa9w\x934\x84\xc8\xda\xa2'), '\x64' + chr(7841 - 7740) + chr(4654 - 4555) + chr(11536 - 11425) + chr(0b100000 + 0o104) + chr(0b10000 + 0o125))(chr(0b1101011 + 0o12) + chr(0b100010 + 0o122) + '\x66' + chr(1818 - 1773) + chr(56)))) |
BerkeleyAutomation/perception | perception/image.py | SegmentationImage.mask_binary | def mask_binary(self, binary_im):
"""Create a new image by zeroing out data at locations
where binary_im == 0.0.
Parameters
----------
binary_im : :obj:`BinaryImage`
A BinaryImage of the same size as this image, with pixel values of either
zero or one. Wherever this image has zero pixels, we'll zero out the
pixels of the new image.
Returns
-------
:obj:`Image`
A new Image of the same type, masked by the given binary image.
"""
data = np.copy(self._data)
ind = np.where(binary_im.data == 0)
data[ind[0], ind[1], :] = 0
return SegmentationImage(data, self._frame) | python | def mask_binary(self, binary_im):
"""Create a new image by zeroing out data at locations
where binary_im == 0.0.
Parameters
----------
binary_im : :obj:`BinaryImage`
A BinaryImage of the same size as this image, with pixel values of either
zero or one. Wherever this image has zero pixels, we'll zero out the
pixels of the new image.
Returns
-------
:obj:`Image`
A new Image of the same type, masked by the given binary image.
"""
data = np.copy(self._data)
ind = np.where(binary_im.data == 0)
data[ind[0], ind[1], :] = 0
return SegmentationImage(data, self._frame) | [
"def",
"mask_binary",
"(",
"self",
",",
"binary_im",
")",
":",
"data",
"=",
"np",
".",
"copy",
"(",
"self",
".",
"_data",
")",
"ind",
"=",
"np",
".",
"where",
"(",
"binary_im",
".",
"data",
"==",
"0",
")",
"data",
"[",
"ind",
"[",
"0",
"]",
",",
"ind",
"[",
"1",
"]",
",",
":",
"]",
"=",
"0",
"return",
"SegmentationImage",
"(",
"data",
",",
"self",
".",
"_frame",
")"
] | Create a new image by zeroing out data at locations
where binary_im == 0.0.
Parameters
----------
binary_im : :obj:`BinaryImage`
A BinaryImage of the same size as this image, with pixel values of either
zero or one. Wherever this image has zero pixels, we'll zero out the
pixels of the new image.
Returns
-------
:obj:`Image`
A new Image of the same type, masked by the given binary image. | [
"Create",
"a",
"new",
"image",
"by",
"zeroing",
"out",
"data",
"at",
"locations",
"where",
"binary_im",
"==",
"0",
".",
"0",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3249-L3268 | train | Create a new image by zeroing out the data at locations
where binary_im == 0. 0. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByL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_BbS,WtdkIpFeYozM,MdkNqd1bagO6,QNQS9e6tJqMV,typojWN5Phrq,gufQJgTAhMnI,uPAcezIXzQNA,i739myaCTbWD,AtYHTsImz86v,pWZq9QOaZbhU,lI5UiuqoXdKZ,qZ4DivK_Doaa,znjnJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(502 - 454) + chr(0b1010001 + 0o36) + chr(52) + '\064', ord("\x08")), nzTpIcepk0o8('\060' + chr(2263 - 2152) + chr(0b110011) + chr(2622 - 2568) + chr(0b11111 + 0o25), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110011) + '\x31' + chr(49), ord("\x08")), nzTpIcepk0o8(chr(1035 - 987) + chr(4643 - 4532) + chr(737 - 688) + '\065' + chr(0b110100), 37559 - 37551), nzTpIcepk0o8(chr(48) + '\x6f' + '\x32' + chr(1364 - 1313) + chr(0b110101), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x33' + chr(51) + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\062' + '\066' + chr(0b110100), 0o10), nzTpIcepk0o8(chr(48) + '\157' + '\x33' + chr(53) + chr(0b110011), 55551 - 55543), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(50) + chr(298 - 247), 0b1000), nzTpIcepk0o8(chr(118 - 70) + chr(0b1100000 + 0o17) + chr(50) + chr(0b110111) + '\060', 0o10), nzTpIcepk0o8(chr(48) + '\157' + '\061' + chr(52) + '\062', ord("\x08")), nzTpIcepk0o8(chr(0b1000 + 0o50) + chr(0b1011110 + 0o21) + chr(0b110011) + chr(50), ord("\x08")), nzTpIcepk0o8(chr(0b1111 + 0o41) + '\x6f' + '\x33' + chr(53) + '\061', 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(0b110010 + 0o0) + chr(52) + chr(0b110101), 0b1000), nzTpIcepk0o8(chr(1051 - 1003) + chr(111) + chr(0b110010) + '\066' + chr(2411 - 2361), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x31' + chr(0b101 + 0o62) + '\x34', 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + '\x32' + chr(54) + chr(313 - 265), ord("\x08")), nzTpIcepk0o8(chr(0b101111 + 0o1) + chr(111) + chr(0b1010 + 0o47) + chr(2459 - 2408) + chr(50), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(50) + chr(48) + chr(0b110 + 0o57), 43110 - 43102), nzTpIcepk0o8(chr(48) + chr(111) + '\063' + chr(0b111 + 0o52) + chr(347 - 296), 6228 - 6220), nzTpIcepk0o8(chr(370 - 322) + '\157' + chr(0b11110 + 0o23) + '\x34' + chr(0b110 + 0o61), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(1698 - 1647), 10168 - 10160), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b11 + 0o56) + '\062' + chr(0b11000 + 0o34), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x33' + '\064' + chr(2824 - 2770), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(51) + chr(672 - 622) + chr(51), 0b1000), nzTpIcepk0o8(chr(0b101000 + 0o10) + chr(111) + chr(0b100101 + 0o16) + '\x30' + '\064', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(53) + '\x34', 0b1000), nzTpIcepk0o8(chr(1079 - 1031) + chr(0b1010001 + 0o36) + '\061' + chr(55) + chr(0b110100), 8), nzTpIcepk0o8(chr(48) + '\x6f' + chr(51) + chr(52) + chr(0b101100 + 0o7), 36389 - 36381), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(51) + chr(2134 - 2079), 10455 - 10447), nzTpIcepk0o8('\060' + chr(9563 - 9452) + chr(0b1111 + 0o42) + '\064' + '\065', 9478 - 9470), nzTpIcepk0o8('\x30' + '\157' + chr(1451 - 1401) + chr(1018 - 963) + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1011010 + 0o25) + '\061' + '\x35', 38424 - 38416), nzTpIcepk0o8(chr(1535 - 1487) + chr(6269 - 6158) + '\x32' + chr(53) + chr(48), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + '\x33' + chr(55) + '\067', 47118 - 47110), nzTpIcepk0o8('\060' + '\157' + chr(49) + '\x32', 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(49) + chr(54) + chr(1569 - 1517), 65491 - 65483), nzTpIcepk0o8(chr(826 - 778) + chr(0b1011011 + 0o24) + '\061' + chr(2464 - 2410), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x33' + '\067' + '\064', 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + chr(1642 - 1591) + '\x36' + '\x31', 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x35' + chr(0b0 + 0o60), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\n'), chr(1166 - 1066) + '\145' + chr(5757 - 5658) + '\x6f' + chr(100) + chr(0b1100101))(chr(0b1110101) + '\x74' + '\x66' + chr(0b101101) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def e8xvDKUROJ0j(hXMPsSrOQzbh, yMN3wUHEhDLY):
FfKOThdpoDTb = nDF4gVNx0u9Q.copy(hXMPsSrOQzbh.Fb5XNYcWu0O5)
w5vcgUzFN3bF = nDF4gVNx0u9Q.xWH4M7K6Qbd3(yMN3wUHEhDLY.FfKOThdpoDTb == nzTpIcepk0o8(chr(659 - 611) + '\157' + chr(0b110000), ord("\x08")))
FfKOThdpoDTb[w5vcgUzFN3bF[nzTpIcepk0o8(chr(0b110000) + chr(0b1001100 + 0o43) + '\060', 8)], w5vcgUzFN3bF[nzTpIcepk0o8('\060' + chr(111) + chr(49), 0o10)], :] = nzTpIcepk0o8(chr(653 - 605) + chr(0b1101111) + chr(0b110000), 8)
return CecfF1IUWy9L(FfKOThdpoDTb, roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'N\xc2\x8a^\xf3\xab\xc3\x9df\xe8R.'), chr(100) + chr(101) + chr(0b10010 + 0o121) + chr(0b1101111) + chr(100) + chr(101))('\x75' + chr(8383 - 8267) + '\146' + chr(0b11010 + 0o23) + '\070'))) |
BerkeleyAutomation/perception | perception/image.py | SegmentationImage.resize | def resize(self, size, interp='nearest'):
"""Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic')
"""
resized_data = sm.imresize(self.data, size, interp=interp, mode='L')
return SegmentationImage(resized_data, self._frame) | python | def resize(self, size, interp='nearest'):
"""Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic')
"""
resized_data = sm.imresize(self.data, size, interp=interp, mode='L')
return SegmentationImage(resized_data, self._frame) | [
"def",
"resize",
"(",
"self",
",",
"size",
",",
"interp",
"=",
"'nearest'",
")",
":",
"resized_data",
"=",
"sm",
".",
"imresize",
"(",
"self",
".",
"data",
",",
"size",
",",
"interp",
"=",
"interp",
",",
"mode",
"=",
"'L'",
")",
"return",
"SegmentationImage",
"(",
"resized_data",
",",
"self",
".",
"_frame",
")"
] | Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic') | [
"Resize",
"the",
"image",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3270-L3285 | train | Resizes the image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ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64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(610 - 562) + chr(111) + chr(0b110010) + chr(635 - 586), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x33' + chr(0b110010) + chr(0b110 + 0o57), 0b1000), nzTpIcepk0o8(chr(0b0 + 0o60) + '\157' + chr(422 - 371) + chr(49) + '\x34', 0o10), nzTpIcepk0o8(chr(0b10010 + 0o36) + chr(111) + chr(0b11110 + 0o24) + chr(52) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110011) + chr(58 - 10) + chr(0b110110), 0o10), nzTpIcepk0o8(chr(823 - 775) + chr(0b1101111) + chr(0b1111 + 0o44) + chr(50) + chr(0b1000 + 0o56), 0b1000), nzTpIcepk0o8(chr(1552 - 1504) + chr(0b110111 + 0o70) + '\062' + chr(0b110101), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + '\x32' + chr(2318 - 2266) + chr(0b110011 + 0o2), 0b1000), nzTpIcepk0o8('\x30' + chr(111) + '\061' + chr(0b110110) + chr(723 - 669), 0o10), nzTpIcepk0o8(chr(0b10000 + 0o40) + chr(111) + '\x33' + chr(2443 - 2389) + '\x31', 30283 - 30275), nzTpIcepk0o8(chr(759 - 711) + chr(0b1101111) + '\061' + '\x35' + '\065', ord("\x08")), nzTpIcepk0o8(chr(898 - 850) + chr(12038 - 11927) + chr(0b110000 + 0o1) + chr(1612 - 1559), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1010111 + 0o30) + '\062' + chr(2488 - 2434) + chr(53), 1599 - 1591), nzTpIcepk0o8(chr(48) + '\157' + chr(50) + chr(0b100010 + 0o23), 8), nzTpIcepk0o8(chr(48) + chr(0b1011 + 0o144) + chr(2484 - 2434) + chr(2066 - 2015) + chr(51), 43614 - 43606), nzTpIcepk0o8(chr(257 - 209) + '\x6f' + '\063' + chr(0b11111 + 0o21) + '\x34', 64297 - 64289), nzTpIcepk0o8(chr(2140 - 2092) + '\157' + chr(0b110011) + chr(49) + chr(55), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b0 + 0o66), ord("\x08")), nzTpIcepk0o8(chr(1351 - 1303) + chr(0b1101111) + chr(51) + chr(0b110111) + chr(816 - 765), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(49) + '\x33' + '\065', 18536 - 18528), nzTpIcepk0o8('\x30' + '\157' + chr(148 - 97) + chr(0b11011 + 0o32) + chr(55), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\066' + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\157' + '\063' + chr(0b110100) + '\x34', 50596 - 50588), nzTpIcepk0o8(chr(475 - 427) + chr(4536 - 4425) + chr(0b101001 + 0o10) + chr(0b10011 + 0o36) + chr(567 - 516), 0o10), nzTpIcepk0o8(chr(0b10011 + 0o35) + chr(0b1101111) + '\x32' + '\x32' + '\063', ord("\x08")), nzTpIcepk0o8(chr(0b101110 + 0o2) + chr(0b1101111) + '\x31' + chr(3005 - 2950), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + '\063' + '\064' + chr(0b110110), 0b1000), nzTpIcepk0o8(chr(1198 - 1150) + '\x6f' + chr(50) + chr(1734 - 1680) + chr(0b110110), 28324 - 28316), nzTpIcepk0o8(chr(0b1011 + 0o45) + '\x6f' + chr(0b110100), 0o10), nzTpIcepk0o8(chr(48) + chr(2979 - 2868) + chr(0b10111 + 0o36) + '\x34', ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + '\062' + chr(55), 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(0b10110 + 0o34) + '\060' + chr(0b110001), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(2363 - 2310) + '\x33', 0b1000), nzTpIcepk0o8('\060' + chr(0b1100100 + 0o13) + '\x33' + '\x35' + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(544 - 496) + chr(8499 - 8388) + chr(55), 45852 - 45844), nzTpIcepk0o8(chr(0b110000) + '\157' + '\065' + chr(51), 8), nzTpIcepk0o8(chr(1999 - 1951) + chr(0b1011010 + 0o25) + chr(0b110011) + '\064', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(1770 - 1721) + '\064' + chr(0b110 + 0o52), ord("\x08")), nzTpIcepk0o8(chr(0b11111 + 0o21) + chr(0b111011 + 0o64) + chr(2246 - 2197) + chr(566 - 514) + '\x34', 14435 - 14427), nzTpIcepk0o8(chr(584 - 536) + chr(0b1101111) + chr(2342 - 2292) + chr(0b110101), 8)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b110000) + chr(2677 - 2566) + '\065' + chr(0b110000), 39214 - 39206)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'?'), chr(100) + '\145' + chr(2179 - 2080) + chr(111) + chr(0b100011 + 0o101) + chr(101))('\x75' + chr(0b1110100) + chr(0b1100110) + '\055' + chr(0b110 + 0o62)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def ar68gq7_06Hs(hXMPsSrOQzbh, e1HrJaQHACnl, Cz8seJYyklrn=roI3spqORKae(ES5oEprVxulp(b'\x7f\xb0\xad\xd3\xa3\xa5a'), chr(0b1100 + 0o130) + chr(101) + '\x63' + chr(8143 - 8032) + chr(0b1100100) + chr(0b111110 + 0o47))(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + chr(0b11001 + 0o24) + chr(0b10 + 0o66))):
IaXcVfkPMBuQ = miZza6ggsjTu.imresize(hXMPsSrOQzbh.FfKOThdpoDTb, e1HrJaQHACnl, interp=Cz8seJYyklrn, mode=roI3spqORKae(ES5oEprVxulp(b']'), chr(0b1000001 + 0o43) + chr(101) + chr(0b1100011) + '\157' + '\144' + '\145')('\x75' + chr(0b1110100) + '\146' + chr(883 - 838) + chr(0b1000 + 0o60)))
return CecfF1IUWy9L(IaXcVfkPMBuQ, roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'{\xe3\x8f\x93\xa8\xa4b\xd3\x03\xa1]9'), chr(5889 - 5789) + '\145' + chr(99) + '\157' + '\144' + chr(101))(chr(0b110100 + 0o101) + chr(116) + chr(0b11101 + 0o111) + chr(0b101101) + chr(0b1011 + 0o55)))) |
BerkeleyAutomation/perception | perception/image.py | SegmentationImage.open | def open(filename, frame='unspecified'):
""" Opens a segmentation image """
data = Image.load_data(filename)
return SegmentationImage(data, frame) | python | def open(filename, frame='unspecified'):
""" Opens a segmentation image """
data = Image.load_data(filename)
return SegmentationImage(data, frame) | [
"def",
"open",
"(",
"filename",
",",
"frame",
"=",
"'unspecified'",
")",
":",
"data",
"=",
"Image",
".",
"load_data",
"(",
"filename",
")",
"return",
"SegmentationImage",
"(",
"data",
",",
"frame",
")"
] | Opens a segmentation image | [
"Opens",
"a",
"segmentation",
"image"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3288-L3291 | train | Opens a segmentation image from a file. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g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TqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + '\157' + chr(0b110111) + '\x34', 8363 - 8355), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(111) + chr(51) + chr(0b0 + 0o65) + chr(55), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(0b110010) + '\060' + '\066', 29613 - 29605), nzTpIcepk0o8(chr(0b110000) + chr(9526 - 9415) + '\061' + chr(1716 - 1663), 0o10), nzTpIcepk0o8(chr(0b101101 + 0o3) + chr(8193 - 8082) + '\062' + '\x34' + '\x34', 15098 - 15090), nzTpIcepk0o8(chr(48) + chr(0b110011 + 0o74) + '\061' + chr(0b110100) + '\x34', 36358 - 36350), nzTpIcepk0o8(chr(378 - 330) + chr(0b1101111) + chr(0b101101 + 0o5) + chr(0b100100 + 0o22) + chr(0b10000 + 0o47), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b101100 + 0o7) + chr(0b110100) + '\x35', 0b1000), nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(111) + '\x31' + '\x36' + chr(0b110011), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\157' + '\061' + chr(0b110101) + '\x34', 0b1000), nzTpIcepk0o8(chr(499 - 451) + chr(0b1101111) + chr(0b110001) + chr(0b101101 + 0o11) + '\x35', 0o10), nzTpIcepk0o8(chr(77 - 29) + chr(4296 - 4185) + chr(2592 - 2541) + chr(0b110011) + chr(0b1110 + 0o42), 0b1000), nzTpIcepk0o8('\060' + chr(9653 - 9542) + '\x31' + chr(51) + chr(54), 48279 - 48271), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(50) + chr(0b110000 + 0o0) + chr(2131 - 2082), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x32' + chr(2248 - 2193) + chr(0b110101), 15190 - 15182), nzTpIcepk0o8('\x30' + chr(3775 - 3664) + chr(0b110010) + chr(0b110101) + chr(48), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(1781 - 1731) + chr(516 - 463), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110001) + '\x33' + chr(0b10111 + 0o36), 0o10), nzTpIcepk0o8(chr(48) + chr(4685 - 4574) + chr(0b10011 + 0o36) + '\x34' + chr(0b1011 + 0o50), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(2236 - 2187) + chr(0b110001) + chr(51), 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(131 - 81) + '\061' + chr(1404 - 1350), 52219 - 52211), nzTpIcepk0o8(chr(595 - 547) + chr(111) + '\063', 24624 - 24616), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1075 - 1026) + chr(49) + chr(49), 64848 - 64840), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(2587 - 2536) + chr(1958 - 1908) + chr(54), 13935 - 13927), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b101 + 0o54) + chr(0b10 + 0o60) + chr(1997 - 1946), 0b1000), nzTpIcepk0o8(chr(890 - 842) + chr(111) + chr(50) + chr(1562 - 1511) + '\x36', 50938 - 50930), nzTpIcepk0o8(chr(439 - 391) + '\157' + chr(1082 - 1031) + chr(0b10111 + 0o33), 0b1000), nzTpIcepk0o8(chr(711 - 663) + '\x6f' + chr(0b110011) + '\065' + chr(0b100001 + 0o21), 9564 - 9556), nzTpIcepk0o8(chr(0b1110 + 0o42) + chr(0b1101111) + '\x33' + chr(2374 - 2323) + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(0b101111 + 0o1) + '\x6f' + '\x36' + chr(168 - 117), 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b100 + 0o55) + chr(54) + '\065', 8), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b1110 + 0o45) + chr(0b110101) + '\061', 1008 - 1000), nzTpIcepk0o8(chr(48) + chr(0b10110 + 0o131) + '\x32' + chr(0b110010) + chr(53), 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(0b110010) + chr(48), 19975 - 19967), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(50) + chr(0b110111) + chr(0b1101 + 0o51), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + chr(0b10 + 0o61) + chr(1587 - 1538) + '\x32', 0o10), nzTpIcepk0o8(chr(0b11001 + 0o27) + '\157' + chr(2176 - 2126) + chr(1456 - 1405) + chr(1901 - 1853), 0b1000), nzTpIcepk0o8(chr(1404 - 1356) + chr(111) + chr(0b110101) + '\x32', 29634 - 29626), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110010) + chr(52) + chr(0b110111), 27087 - 27079), nzTpIcepk0o8('\060' + '\157' + '\x32' + chr(0b11111 + 0o26) + chr(55), 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + '\x6f' + chr(2666 - 2613) + chr(0b100110 + 0o12), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x12'), chr(9057 - 8957) + chr(10174 - 10073) + chr(4835 - 4736) + chr(111) + chr(0b0 + 0o144) + chr(101))(chr(0b1110101) + '\x74' + chr(0b1100110) + '\055' + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def DnU3Rq9N5ala(FxZHtXEolYsL, KZ4ew2qs1HTO=roI3spqORKae(ES5oEprVxulp(b'I\x81\xf5}\xc1\x07\xde\x83\x1a\t\x11'), chr(0b11011 + 0o111) + chr(0b1011000 + 0o15) + chr(0b1010000 + 0o23) + chr(0b1101111) + '\x64' + chr(6293 - 6192))(chr(117) + chr(0b1110100) + chr(10259 - 10157) + chr(820 - 775) + chr(0b10110 + 0o42))):
FfKOThdpoDTb = RvV7ueTH51Uy.load_data(FxZHtXEolYsL)
return CecfF1IUWy9L(FfKOThdpoDTb, KZ4ew2qs1HTO) |
BerkeleyAutomation/perception | perception/image.py | PointCloudImage.resize | def resize(self, size, interp='nearest'):
"""Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic')
Returns
-------
:obj:`PointCloudImage`
The resized image.
"""
resized_data_0 = sm.imresize(self._data[:,:,0], size, interp=interp, mode='F')
resized_data_1 = sm.imresize(self._data[:,:,1], size, interp=interp, mode='F')
resized_data_2 = sm.imresize(self._data[:,:,2], size, interp=interp, mode='F')
resized_data = np.zeros([resized_data_0.shape[0],
resized_data_0.shape[1],
self.channels])
resized_data[:,:,0] = resized_data_0
resized_data[:,:,1] = resized_data_1
resized_data[:,:,2] = resized_data_2
return PointCloudImage(resized_data, self._frame) | python | def resize(self, size, interp='nearest'):
"""Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic')
Returns
-------
:obj:`PointCloudImage`
The resized image.
"""
resized_data_0 = sm.imresize(self._data[:,:,0], size, interp=interp, mode='F')
resized_data_1 = sm.imresize(self._data[:,:,1], size, interp=interp, mode='F')
resized_data_2 = sm.imresize(self._data[:,:,2], size, interp=interp, mode='F')
resized_data = np.zeros([resized_data_0.shape[0],
resized_data_0.shape[1],
self.channels])
resized_data[:,:,0] = resized_data_0
resized_data[:,:,1] = resized_data_1
resized_data[:,:,2] = resized_data_2
return PointCloudImage(resized_data, self._frame) | [
"def",
"resize",
"(",
"self",
",",
"size",
",",
"interp",
"=",
"'nearest'",
")",
":",
"resized_data_0",
"=",
"sm",
".",
"imresize",
"(",
"self",
".",
"_data",
"[",
":",
",",
":",
",",
"0",
"]",
",",
"size",
",",
"interp",
"=",
"interp",
",",
"mode",
"=",
"'F'",
")",
"resized_data_1",
"=",
"sm",
".",
"imresize",
"(",
"self",
".",
"_data",
"[",
":",
",",
":",
",",
"1",
"]",
",",
"size",
",",
"interp",
"=",
"interp",
",",
"mode",
"=",
"'F'",
")",
"resized_data_2",
"=",
"sm",
".",
"imresize",
"(",
"self",
".",
"_data",
"[",
":",
",",
":",
",",
"2",
"]",
",",
"size",
",",
"interp",
"=",
"interp",
",",
"mode",
"=",
"'F'",
")",
"resized_data",
"=",
"np",
".",
"zeros",
"(",
"[",
"resized_data_0",
".",
"shape",
"[",
"0",
"]",
",",
"resized_data_0",
".",
"shape",
"[",
"1",
"]",
",",
"self",
".",
"channels",
"]",
")",
"resized_data",
"[",
":",
",",
":",
",",
"0",
"]",
"=",
"resized_data_0",
"resized_data",
"[",
":",
",",
":",
",",
"1",
"]",
"=",
"resized_data_1",
"resized_data",
"[",
":",
",",
":",
",",
"2",
"]",
"=",
"resized_data_2",
"return",
"PointCloudImage",
"(",
"resized_data",
",",
"self",
".",
"_frame",
")"
] | Resize the image.
Parameters
----------
size : int, float, or tuple
* int - Percentage of current size.
* float - Fraction of current size.
* tuple - Size of the output image.
interp : :obj:`str`, optional
Interpolation to use for re-sizing ('nearest', 'lanczos', 'bilinear',
'bicubic', or 'cubic')
Returns
-------
:obj:`PointCloudImage`
The resized image. | [
"Resize",
"the",
"image",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3351-L3379 | train | Resizes the image. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p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lockingIOError,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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\060' + chr(0b1101111) + chr(1583 - 1534) + chr(1287 - 1239), 40979 - 40971), nzTpIcepk0o8(chr(0b110000) + chr(0b1001 + 0o146) + chr(0b10001 + 0o42) + '\x36' + chr(0b110110), 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(50) + '\065' + '\065', 0b1000), nzTpIcepk0o8(chr(0b101000 + 0o10) + chr(111) + chr(0b110010) + chr(0b110010), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110001) + chr(0b110111) + '\x31', 0b1000), nzTpIcepk0o8(chr(0b101000 + 0o10) + chr(8232 - 8121) + chr(2520 - 2469) + chr(0b110000) + chr(1737 - 1686), 0b1000), nzTpIcepk0o8(chr(0b100001 + 0o17) + '\157' + chr(634 - 583) + chr(0b100101 + 0o16) + chr(0b10111 + 0o33), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110011) + chr(1800 - 1747) + chr(0b110011), 47073 - 47065), nzTpIcepk0o8(chr(48) + chr(0b100100 + 0o113) + '\063' + '\061' + chr(349 - 298), 1666 - 1658), nzTpIcepk0o8(chr(2111 - 2063) + chr(0b110110 + 0o71) + '\x31' + chr(0b110100), 12751 - 12743), nzTpIcepk0o8(chr(1090 - 1042) + '\157' + '\x33' + chr(1493 - 1443) + chr(49), 0o10), nzTpIcepk0o8('\060' + '\x6f' + '\063' + chr(2724 - 2669) + chr(0b1000 + 0o57), 39208 - 39200), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(9463 - 9352) + chr(0b101100 + 0o7) + chr(0b110010) + '\x37', 0o10), nzTpIcepk0o8('\x30' + chr(9175 - 9064) + '\063' + chr(0b1101 + 0o47), 36199 - 36191), nzTpIcepk0o8('\x30' + chr(111) + chr(1210 - 1160) + '\x30' + chr(1628 - 1573), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(10293 - 10182) + chr(0b110110) + chr(949 - 901), 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110010) + '\066' + chr(0b0 + 0o60), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(49) + chr(1456 - 1402) + chr(2032 - 1980), 16170 - 16162), nzTpIcepk0o8(chr(48) + chr(111) + '\061' + chr(0b1010 + 0o52) + chr(0b110000 + 0o6), 0o10), nzTpIcepk0o8(chr(48) + chr(0b100010 + 0o115) + '\062' + chr(53) + '\x36', 16643 - 16635), nzTpIcepk0o8(chr(1777 - 1729) + '\157' + '\x33' + chr(0b10101 + 0o40) + chr(469 - 418), 8), nzTpIcepk0o8(chr(1958 - 1910) + chr(111) + '\061' + '\x34' + chr(50), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(888 - 833) + chr(53), 0o10), nzTpIcepk0o8('\060' + chr(0b1101001 + 0o6) + '\061' + '\065' + chr(1495 - 1446), 0b1000), nzTpIcepk0o8(chr(48) + '\157' + chr(55) + chr(0b110110), 20396 - 20388), nzTpIcepk0o8('\060' + '\x6f' + chr(376 - 327) + chr(53) + chr(2180 - 2125), ord("\x08")), nzTpIcepk0o8(chr(1706 - 1658) + '\x6f' + chr(51) + chr(1498 - 1447) + chr(0b110101), 20004 - 19996), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(2773 - 2719) + chr(614 - 566), 8), nzTpIcepk0o8(chr(0b11111 + 0o21) + chr(0b1001101 + 0o42) + chr(0b11110 + 0o24) + chr(49) + chr(0b110111), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110010) + chr(0b110011) + '\x33', 17272 - 17264), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x31' + chr(50) + chr(52), 0o10), nzTpIcepk0o8(chr(2215 - 2167) + chr(111) + chr(2222 - 2172) + '\060' + chr(0b110111), 8), nzTpIcepk0o8(chr(48) + '\157' + '\062' + chr(0b11101 + 0o24) + '\x31', ord("\x08")), nzTpIcepk0o8(chr(462 - 414) + chr(0b1101111) + chr(51) + '\x30' + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(49) + chr(2364 - 2310) + chr(0b110000), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\063' + '\067' + chr(0b0 + 0o66), 0b1000), nzTpIcepk0o8('\x30' + chr(0b101111 + 0o100) + chr(1538 - 1487) + '\x35', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(4069 - 3958) + chr(51) + chr(0b110000) + chr(0b10111 + 0o32), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(2418 - 2368) + chr(0b110111) + '\062', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x33' + chr(0b101000 + 0o10) + chr(0b100011 + 0o21), ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + '\x6f' + chr(1588 - 1535) + chr(0b110000), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'&'), chr(0b1100100) + chr(7677 - 7576) + chr(5596 - 5497) + '\157' + chr(9400 - 9300) + chr(0b1100101))(chr(0b11100 + 0o131) + '\x74' + '\146' + chr(0b101101) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def ar68gq7_06Hs(hXMPsSrOQzbh, e1HrJaQHACnl, Cz8seJYyklrn=roI3spqORKae(ES5oEprVxulp(b'f\x93\xcc`\x1c\xb0\xae'), chr(0b10100 + 0o120) + '\x65' + chr(2776 - 2677) + '\157' + chr(0b1111 + 0o125) + '\x65')(chr(117) + chr(116) + chr(0b1100110) + chr(45) + '\x38')):
PCkXhkuw14vx = miZza6ggsjTu.imresize(hXMPsSrOQzbh.Fb5XNYcWu0O5[:, :, nzTpIcepk0o8(chr(1509 - 1461) + chr(0b1000101 + 0o52) + chr(0b110000), ord("\x08"))], e1HrJaQHACnl, interp=Cz8seJYyklrn, mode=roI3spqORKae(ES5oEprVxulp(b'N'), chr(0b111010 + 0o52) + chr(6766 - 6665) + chr(2286 - 2187) + chr(111) + '\x64' + chr(101))(chr(930 - 813) + chr(8616 - 8500) + chr(102) + chr(0b11011 + 0o22) + chr(2259 - 2203)))
LYTX6DkbM_uo = miZza6ggsjTu.imresize(hXMPsSrOQzbh.Fb5XNYcWu0O5[:, :, nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(111) + chr(49), 0o10)], e1HrJaQHACnl, interp=Cz8seJYyklrn, mode=roI3spqORKae(ES5oEprVxulp(b'N'), '\144' + chr(7287 - 7186) + chr(1965 - 1866) + '\x6f' + chr(0b1011110 + 0o6) + chr(0b1100101))('\x75' + chr(12650 - 12534) + chr(0b1100110) + '\055' + '\070'))
FW1YgtifVkfz = miZza6ggsjTu.imresize(hXMPsSrOQzbh.Fb5XNYcWu0O5[:, :, nzTpIcepk0o8(chr(0b11111 + 0o21) + chr(0b1101111) + '\x32', 0b1000)], e1HrJaQHACnl, interp=Cz8seJYyklrn, mode=roI3spqORKae(ES5oEprVxulp(b'N'), chr(100) + chr(0b1100101) + chr(627 - 528) + '\157' + chr(100) + chr(0b1100101))(chr(0b10000 + 0o145) + chr(0b1000010 + 0o62) + chr(0b110110 + 0o60) + chr(108 - 63) + chr(56)))
IaXcVfkPMBuQ = nDF4gVNx0u9Q.UmwwEp7MzR6q([PCkXhkuw14vx.lhbM092AFW8f[nzTpIcepk0o8('\060' + chr(0b1101111) + '\x30', 8)], PCkXhkuw14vx.lhbM092AFW8f[nzTpIcepk0o8('\060' + chr(0b1101111) + chr(102 - 53), 8)], hXMPsSrOQzbh.oOCpoykUobsP])
IaXcVfkPMBuQ[:, :, nzTpIcepk0o8(chr(2011 - 1963) + chr(0b110000 + 0o77) + '\x30', 8)] = PCkXhkuw14vx
IaXcVfkPMBuQ[:, :, nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110001), 8)] = LYTX6DkbM_uo
IaXcVfkPMBuQ[:, :, nzTpIcepk0o8(chr(1555 - 1507) + '\x6f' + '\x32', 8)] = FW1YgtifVkfz
return GjCd2g1XhYiI(IaXcVfkPMBuQ, roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'b\xc0\xee \x17\xb1\xad\x9d\xbe\\\xe1\xcb'), chr(0b1100100) + chr(0b1100101) + chr(99) + '\157' + '\x64' + '\x65')('\x75' + chr(0b1110100) + '\x66' + chr(0b101101) + chr(0b111000 + 0o0)))) |
BerkeleyAutomation/perception | perception/image.py | PointCloudImage.to_mesh | def to_mesh(self, dist_thresh=0.01):
""" Convert the point cloud to a mesh.
Returns
-------
:obj:`trimesh.Trimesh`
mesh of the point cloud
"""
# init vertex and triangle buffers
vertices = []
triangles = []
vertex_indices = -1 * np.ones([self.height, self.width]).astype(np.int32)
for i in range(self.height-1):
for j in range(self.width-1):
# read corners of square
v0 = self.data[i,j,:]
v1 = self.data[i,j+1,:]
v2 = self.data[i+1,j,:]
v3 = self.data[i+1,j+1,:]
# check distances
d01 = np.abs(v0[2] - v1[2])
d02 = np.abs(v0[2] - v2[2])
d03 = np.abs(v0[2] - v3[2])
d13 = np.abs(v1[2] - v3[2])
d23 = np.abs(v2[2] - v3[2])
# add tri 1
if max(d01, d03, d13) < dist_thresh:
# add vertices
if vertex_indices[i,j] == -1:
vertices.append(v0)
vertex_indices[i,j] = len(vertices)-1
if vertex_indices[i,j+1] == -1:
vertices.append(v1)
vertex_indices[i,j+1] = len(vertices)-1
if vertex_indices[i+1,j+1] == -1:
vertices.append(v3)
vertex_indices[i+1,j+1] = len(vertices)-1
# add tri
i0 = vertex_indices[i,j]
i1 = vertex_indices[i,j+1]
i3 = vertex_indices[i+1,j+1]
triangles.append([i0, i1, i3])
# add tri 2
if max(d01, d03, d23) < dist_thresh:
# add vertices
if vertex_indices[i,j] == -1:
vertices.append(v0)
vertex_indices[i,j] = len(vertices)-1
if vertex_indices[i+1,j] == -1:
vertices.append(v2)
vertex_indices[i+1,j] = len(vertices)-1
if vertex_indices[i+1,j+1] == -1:
vertices.append(v3)
vertex_indices[i+1,j+1] = len(vertices)-1
# add tri
i0 = vertex_indices[i,j]
i2 = vertex_indices[i+1,j]
i3 = vertex_indices[i+1,j+1]
triangles.append([i0, i3, i2])
# return trimesh
import trimesh
mesh = trimesh.Trimesh(vertices, triangles)
return mesh | python | def to_mesh(self, dist_thresh=0.01):
""" Convert the point cloud to a mesh.
Returns
-------
:obj:`trimesh.Trimesh`
mesh of the point cloud
"""
# init vertex and triangle buffers
vertices = []
triangles = []
vertex_indices = -1 * np.ones([self.height, self.width]).astype(np.int32)
for i in range(self.height-1):
for j in range(self.width-1):
# read corners of square
v0 = self.data[i,j,:]
v1 = self.data[i,j+1,:]
v2 = self.data[i+1,j,:]
v3 = self.data[i+1,j+1,:]
# check distances
d01 = np.abs(v0[2] - v1[2])
d02 = np.abs(v0[2] - v2[2])
d03 = np.abs(v0[2] - v3[2])
d13 = np.abs(v1[2] - v3[2])
d23 = np.abs(v2[2] - v3[2])
# add tri 1
if max(d01, d03, d13) < dist_thresh:
# add vertices
if vertex_indices[i,j] == -1:
vertices.append(v0)
vertex_indices[i,j] = len(vertices)-1
if vertex_indices[i,j+1] == -1:
vertices.append(v1)
vertex_indices[i,j+1] = len(vertices)-1
if vertex_indices[i+1,j+1] == -1:
vertices.append(v3)
vertex_indices[i+1,j+1] = len(vertices)-1
# add tri
i0 = vertex_indices[i,j]
i1 = vertex_indices[i,j+1]
i3 = vertex_indices[i+1,j+1]
triangles.append([i0, i1, i3])
# add tri 2
if max(d01, d03, d23) < dist_thresh:
# add vertices
if vertex_indices[i,j] == -1:
vertices.append(v0)
vertex_indices[i,j] = len(vertices)-1
if vertex_indices[i+1,j] == -1:
vertices.append(v2)
vertex_indices[i+1,j] = len(vertices)-1
if vertex_indices[i+1,j+1] == -1:
vertices.append(v3)
vertex_indices[i+1,j+1] = len(vertices)-1
# add tri
i0 = vertex_indices[i,j]
i2 = vertex_indices[i+1,j]
i3 = vertex_indices[i+1,j+1]
triangles.append([i0, i3, i2])
# return trimesh
import trimesh
mesh = trimesh.Trimesh(vertices, triangles)
return mesh | [
"def",
"to_mesh",
"(",
"self",
",",
"dist_thresh",
"=",
"0.01",
")",
":",
"# init vertex and triangle buffers",
"vertices",
"=",
"[",
"]",
"triangles",
"=",
"[",
"]",
"vertex_indices",
"=",
"-",
"1",
"*",
"np",
".",
"ones",
"(",
"[",
"self",
".",
"height",
",",
"self",
".",
"width",
"]",
")",
".",
"astype",
"(",
"np",
".",
"int32",
")",
"for",
"i",
"in",
"range",
"(",
"self",
".",
"height",
"-",
"1",
")",
":",
"for",
"j",
"in",
"range",
"(",
"self",
".",
"width",
"-",
"1",
")",
":",
"# read corners of square",
"v0",
"=",
"self",
".",
"data",
"[",
"i",
",",
"j",
",",
":",
"]",
"v1",
"=",
"self",
".",
"data",
"[",
"i",
",",
"j",
"+",
"1",
",",
":",
"]",
"v2",
"=",
"self",
".",
"data",
"[",
"i",
"+",
"1",
",",
"j",
",",
":",
"]",
"v3",
"=",
"self",
".",
"data",
"[",
"i",
"+",
"1",
",",
"j",
"+",
"1",
",",
":",
"]",
"# check distances",
"d01",
"=",
"np",
".",
"abs",
"(",
"v0",
"[",
"2",
"]",
"-",
"v1",
"[",
"2",
"]",
")",
"d02",
"=",
"np",
".",
"abs",
"(",
"v0",
"[",
"2",
"]",
"-",
"v2",
"[",
"2",
"]",
")",
"d03",
"=",
"np",
".",
"abs",
"(",
"v0",
"[",
"2",
"]",
"-",
"v3",
"[",
"2",
"]",
")",
"d13",
"=",
"np",
".",
"abs",
"(",
"v1",
"[",
"2",
"]",
"-",
"v3",
"[",
"2",
"]",
")",
"d23",
"=",
"np",
".",
"abs",
"(",
"v2",
"[",
"2",
"]",
"-",
"v3",
"[",
"2",
"]",
")",
"# add tri 1",
"if",
"max",
"(",
"d01",
",",
"d03",
",",
"d13",
")",
"<",
"dist_thresh",
":",
"# add vertices",
"if",
"vertex_indices",
"[",
"i",
",",
"j",
"]",
"==",
"-",
"1",
":",
"vertices",
".",
"append",
"(",
"v0",
")",
"vertex_indices",
"[",
"i",
",",
"j",
"]",
"=",
"len",
"(",
"vertices",
")",
"-",
"1",
"if",
"vertex_indices",
"[",
"i",
",",
"j",
"+",
"1",
"]",
"==",
"-",
"1",
":",
"vertices",
".",
"append",
"(",
"v1",
")",
"vertex_indices",
"[",
"i",
",",
"j",
"+",
"1",
"]",
"=",
"len",
"(",
"vertices",
")",
"-",
"1",
"if",
"vertex_indices",
"[",
"i",
"+",
"1",
",",
"j",
"+",
"1",
"]",
"==",
"-",
"1",
":",
"vertices",
".",
"append",
"(",
"v3",
")",
"vertex_indices",
"[",
"i",
"+",
"1",
",",
"j",
"+",
"1",
"]",
"=",
"len",
"(",
"vertices",
")",
"-",
"1",
"# add tri",
"i0",
"=",
"vertex_indices",
"[",
"i",
",",
"j",
"]",
"i1",
"=",
"vertex_indices",
"[",
"i",
",",
"j",
"+",
"1",
"]",
"i3",
"=",
"vertex_indices",
"[",
"i",
"+",
"1",
",",
"j",
"+",
"1",
"]",
"triangles",
".",
"append",
"(",
"[",
"i0",
",",
"i1",
",",
"i3",
"]",
")",
"# add tri 2",
"if",
"max",
"(",
"d01",
",",
"d03",
",",
"d23",
")",
"<",
"dist_thresh",
":",
"# add vertices",
"if",
"vertex_indices",
"[",
"i",
",",
"j",
"]",
"==",
"-",
"1",
":",
"vertices",
".",
"append",
"(",
"v0",
")",
"vertex_indices",
"[",
"i",
",",
"j",
"]",
"=",
"len",
"(",
"vertices",
")",
"-",
"1",
"if",
"vertex_indices",
"[",
"i",
"+",
"1",
",",
"j",
"]",
"==",
"-",
"1",
":",
"vertices",
".",
"append",
"(",
"v2",
")",
"vertex_indices",
"[",
"i",
"+",
"1",
",",
"j",
"]",
"=",
"len",
"(",
"vertices",
")",
"-",
"1",
"if",
"vertex_indices",
"[",
"i",
"+",
"1",
",",
"j",
"+",
"1",
"]",
"==",
"-",
"1",
":",
"vertices",
".",
"append",
"(",
"v3",
")",
"vertex_indices",
"[",
"i",
"+",
"1",
",",
"j",
"+",
"1",
"]",
"=",
"len",
"(",
"vertices",
")",
"-",
"1",
"# add tri",
"i0",
"=",
"vertex_indices",
"[",
"i",
",",
"j",
"]",
"i2",
"=",
"vertex_indices",
"[",
"i",
"+",
"1",
",",
"j",
"]",
"i3",
"=",
"vertex_indices",
"[",
"i",
"+",
"1",
",",
"j",
"+",
"1",
"]",
"triangles",
".",
"append",
"(",
"[",
"i0",
",",
"i3",
",",
"i2",
"]",
")",
"# return trimesh",
"import",
"trimesh",
"mesh",
"=",
"trimesh",
".",
"Trimesh",
"(",
"vertices",
",",
"triangles",
")",
"return",
"mesh"
] | Convert the point cloud to a mesh.
Returns
-------
:obj:`trimesh.Trimesh`
mesh of the point cloud | [
"Convert",
"the",
"point",
"cloud",
"to",
"a",
"mesh",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3381-L3450 | train | Convert the point cloud to a mesh. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRy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,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b100011 + 0o17) + chr(0b110000) + chr(53), 0b1000), nzTpIcepk0o8(chr(1708 - 1660) + chr(111) + chr(2300 - 2245) + chr(49), ord("\x08")), nzTpIcepk0o8(chr(1835 - 1787) + chr(111) + chr(0b1110 + 0o45) + chr(0b1001 + 0o47) + chr(411 - 360), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + '\x31' + chr(0b110111) + '\065', 60706 - 60698), nzTpIcepk0o8(chr(0b110000) + chr(5085 - 4974) + '\063' + chr(1375 - 1320) + '\x34', 53928 - 53920), nzTpIcepk0o8(chr(0b110000) + chr(0b100010 + 0o115) + chr(361 - 312) + '\061' + chr(50), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(496 - 445) + chr(0b110000) + '\064', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(51) + chr(0b110010 + 0o5) + '\x34', 8), nzTpIcepk0o8('\060' + chr(0b1101110 + 0o1) + chr(0b10010 + 0o44) + chr(51), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1000000 + 0o57) + chr(0b10011 + 0o37) + '\063' + chr(0b110000 + 0o2), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + '\x31' + chr(0b110011 + 0o0) + chr(0b110011), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(1966 - 1855) + chr(0b110001) + chr(0b101111 + 0o2), 10937 - 10929), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(50) + chr(49), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b100111 + 0o110) + '\x31' + chr(0b110100) + chr(324 - 270), 0o10), nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(4563 - 4452) + '\x32' + '\066', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(2615 - 2504) + '\x33' + '\065' + chr(935 - 884), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b1000 + 0o53) + chr(1866 - 1817) + chr(2632 - 2580), 56625 - 56617), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110001) + chr(50) + chr(0b100001 + 0o22), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\063' + chr(1754 - 1704) + '\065', 22484 - 22476), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\063' + chr(53) + chr(0b110100), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(2453 - 2403) + '\061' + chr(0b110110), 0b1000), nzTpIcepk0o8(chr(101 - 53) + chr(348 - 237) + chr(51) + '\060', 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(50) + chr(1929 - 1881) + chr(1065 - 1015), 0b1000), nzTpIcepk0o8(chr(48) + chr(12191 - 12080) + chr(1225 - 1174) + '\063' + chr(52), 63362 - 63354), nzTpIcepk0o8(chr(1985 - 1937) + chr(0b1101111) + '\x34' + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(50) + chr(2980 - 2925) + chr(0b1001 + 0o53), 0o10), nzTpIcepk0o8(chr(0b101111 + 0o1) + '\x6f' + '\x33' + '\064', 36651 - 36643), nzTpIcepk0o8(chr(0b110000) + chr(0b1001100 + 0o43) + '\x33' + chr(48) + '\065', 0o10), nzTpIcepk0o8(chr(1234 - 1186) + chr(0b1 + 0o156) + chr(0b110011) + chr(0b11101 + 0o30), 48779 - 48771), nzTpIcepk0o8('\060' + '\x6f' + chr(51) + chr(1231 - 1181) + '\x32', 32789 - 32781), nzTpIcepk0o8('\060' + '\157' + '\x31' + '\061' + '\x32', 8), nzTpIcepk0o8(chr(472 - 424) + '\x6f' + chr(0b11011 + 0o30) + '\061' + chr(48), 57583 - 57575), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\063' + chr(51) + chr(48), 24708 - 24700), nzTpIcepk0o8(chr(1001 - 953) + chr(0b1000100 + 0o53) + chr(707 - 655) + '\066', 46663 - 46655), nzTpIcepk0o8(chr(893 - 845) + chr(0b1101111) + '\062' + '\x33' + chr(55), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\x31' + chr(0b110101 + 0o2) + chr(2306 - 2255), 0b1000), nzTpIcepk0o8(chr(569 - 521) + '\157' + '\062' + chr(0b110110) + chr(835 - 784), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b100011 + 0o114) + chr(627 - 575) + chr(143 - 90), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x37' + '\x31', 8), nzTpIcepk0o8('\x30' + '\x6f' + chr(217 - 167) + chr(776 - 722) + chr(2714 - 2661), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110101) + '\060', 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xab'), '\144' + chr(0b10111 + 0o116) + chr(0b101000 + 0o73) + chr(0b100110 + 0o111) + chr(251 - 151) + chr(101))('\x75' + '\164' + '\x66' + '\x2d' + chr(1587 - 1531)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def vp8E7Zmk7FEu(hXMPsSrOQzbh, La6JG2ZCQoGQ=0.01):
cB3g5EOJjEJS = []
tl5AEgx1IIHw = []
KDrTBsSS6rsI = -nzTpIcepk0o8('\060' + '\157' + '\x31', 0b1000) * nDF4gVNx0u9Q.ones([hXMPsSrOQzbh.height, hXMPsSrOQzbh.width]).xqAChpcBkssb(nDF4gVNx0u9Q.int32)
for ZlbFMSG8gCoF in bbT2xIe5pzk7(roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xd5X\x86?\x91?\xaa\xc5y\xaa\x02C'), '\144' + chr(101) + chr(99) + chr(550 - 439) + '\x64' + chr(9575 - 9474))('\x75' + chr(116) + '\146' + '\x2d' + '\x38')) - nzTpIcepk0o8('\060' + '\157' + chr(1612 - 1563), 8)):
for sChW4gUsXrIC in bbT2xIe5pzk7(roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xe1q\xf0\x0b\x9f\x01\xa0\x8aT\xd8.9'), chr(3781 - 3681) + chr(0b1100001 + 0o4) + '\x63' + chr(0b1101111) + chr(0b1000010 + 0o42) + '\145')(chr(117) + '\164' + '\146' + chr(45) + '\x38')) - nzTpIcepk0o8('\x30' + chr(9888 - 9777) + chr(0b110001), 8)):
a_25nCkImxKI = hXMPsSrOQzbh.FfKOThdpoDTb[ZlbFMSG8gCoF, sChW4gUsXrIC, :]
pDhUq4x6UMmH = hXMPsSrOQzbh.FfKOThdpoDTb[ZlbFMSG8gCoF, sChW4gUsXrIC + nzTpIcepk0o8(chr(48) + chr(5080 - 4969) + chr(808 - 759), 8), :]
uFA9Lk4IxvMH = hXMPsSrOQzbh.FfKOThdpoDTb[ZlbFMSG8gCoF + nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(0b1101111) + chr(434 - 385), 8), sChW4gUsXrIC, :]
oOkFbqn7XtpY = hXMPsSrOQzbh.FfKOThdpoDTb[ZlbFMSG8gCoF + nzTpIcepk0o8('\x30' + chr(0b101011 + 0o104) + chr(49), 8), sChW4gUsXrIC + nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b1010 + 0o47), 8), :]
dtDjwmLMtwJN = nDF4gVNx0u9Q.zQBGwUT7UU8L(a_25nCkImxKI[nzTpIcepk0o8('\060' + chr(2332 - 2221) + '\062', 56589 - 56581)] - pDhUq4x6UMmH[nzTpIcepk0o8('\060' + chr(6945 - 6834) + chr(1742 - 1692), 8)])
rgOxZsM1zdzX = nDF4gVNx0u9Q.zQBGwUT7UU8L(a_25nCkImxKI[nzTpIcepk0o8('\060' + chr(0b1011000 + 0o27) + '\x32', 8)] - uFA9Lk4IxvMH[nzTpIcepk0o8(chr(0b11100 + 0o24) + chr(11355 - 11244) + '\062', 8)])
WG_YxTrtxsT0 = nDF4gVNx0u9Q.zQBGwUT7UU8L(a_25nCkImxKI[nzTpIcepk0o8('\060' + '\x6f' + chr(0b11110 + 0o24), 8)] - oOkFbqn7XtpY[nzTpIcepk0o8(chr(0b1010 + 0o46) + chr(0b110010 + 0o75) + '\062', 8)])
M3SOQpsdDCzW = nDF4gVNx0u9Q.zQBGwUT7UU8L(pDhUq4x6UMmH[nzTpIcepk0o8('\x30' + '\157' + chr(140 - 90), 8)] - oOkFbqn7XtpY[nzTpIcepk0o8(chr(0b10011 + 0o35) + chr(0b101101 + 0o102) + '\062', 8)])
jdLmzTlzEqMg = nDF4gVNx0u9Q.zQBGwUT7UU8L(uFA9Lk4IxvMH[nzTpIcepk0o8(chr(1538 - 1490) + chr(0b1000101 + 0o52) + '\062', 8)] - oOkFbqn7XtpY[nzTpIcepk0o8(chr(0b111 + 0o51) + chr(111) + '\x32', 8)])
if KV9ckIhroIia(dtDjwmLMtwJN, WG_YxTrtxsT0, M3SOQpsdDCzW) < La6JG2ZCQoGQ:
if KDrTBsSS6rsI[ZlbFMSG8gCoF, sChW4gUsXrIC] == -nzTpIcepk0o8(chr(0b100100 + 0o14) + chr(0b110001 + 0o76) + '\061', 8):
roI3spqORKae(cB3g5EOJjEJS, roI3spqORKae(ES5oEprVxulp(b'\xcdm\x90I\x84-\x83\x93Y\xf5\x0e<'), '\144' + '\x65' + chr(99) + chr(0b1101111) + chr(9860 - 9760) + '\145')(chr(0b1110101) + chr(116) + '\x66' + chr(0b101101) + '\070'))(a_25nCkImxKI)
KDrTBsSS6rsI[ZlbFMSG8gCoF, sChW4gUsXrIC] = ftfygxgFas5X(cB3g5EOJjEJS) - nzTpIcepk0o8(chr(48) + chr(11083 - 10972) + chr(0b110001), 8)
if KDrTBsSS6rsI[ZlbFMSG8gCoF, sChW4gUsXrIC + nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110001), 8)] == -nzTpIcepk0o8(chr(0b100001 + 0o17) + '\157' + chr(0b101101 + 0o4), 8):
roI3spqORKae(cB3g5EOJjEJS, roI3spqORKae(ES5oEprVxulp(b'\xcdm\x90I\x84-\x83\x93Y\xf5\x0e<'), chr(100) + chr(7864 - 7763) + chr(0b11110 + 0o105) + '\157' + chr(0b1100100) + chr(101))(chr(0b100001 + 0o124) + chr(2388 - 2272) + chr(1728 - 1626) + chr(0b101101) + '\070'))(pDhUq4x6UMmH)
KDrTBsSS6rsI[ZlbFMSG8gCoF, sChW4gUsXrIC + nzTpIcepk0o8(chr(48) + chr(0b1010000 + 0o37) + chr(0b100110 + 0o13), 8)] = ftfygxgFas5X(cB3g5EOJjEJS) - nzTpIcepk0o8('\x30' + chr(8517 - 8406) + chr(0b100111 + 0o12), 8)
if KDrTBsSS6rsI[ZlbFMSG8gCoF + nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110001), 8), sChW4gUsXrIC + nzTpIcepk0o8('\060' + chr(111) + chr(49), 8)] == -nzTpIcepk0o8('\060' + chr(0b101111 + 0o100) + chr(2204 - 2155), 8):
roI3spqORKae(cB3g5EOJjEJS, roI3spqORKae(ES5oEprVxulp(b'\xcdm\x90I\x84-\x83\x93Y\xf5\x0e<'), '\x64' + '\145' + chr(99) + chr(0b1101111) + '\144' + chr(0b1100101))(chr(117) + chr(116) + '\146' + chr(0b101101) + chr(0b111000)))(oOkFbqn7XtpY)
KDrTBsSS6rsI[ZlbFMSG8gCoF + nzTpIcepk0o8('\060' + chr(0b10101 + 0o132) + '\x31', 8), sChW4gUsXrIC + nzTpIcepk0o8(chr(372 - 324) + '\157' + chr(1822 - 1773), 8)] = ftfygxgFas5X(cB3g5EOJjEJS) - nzTpIcepk0o8(chr(48) + '\x6f' + '\x31', 8)
aeNM5Iprzfin = KDrTBsSS6rsI[ZlbFMSG8gCoF, sChW4gUsXrIC]
ZS5P6RZOh020 = KDrTBsSS6rsI[ZlbFMSG8gCoF, sChW4gUsXrIC + nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110001), 8)]
rbEqVSdCcMlr = KDrTBsSS6rsI[ZlbFMSG8gCoF + nzTpIcepk0o8('\060' + chr(7548 - 7437) + '\061', 8), sChW4gUsXrIC + nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x31', 8)]
roI3spqORKae(tl5AEgx1IIHw, roI3spqORKae(ES5oEprVxulp(b'\xcdm\x90I\x84-\x83\x93Y\xf5\x0e<'), chr(0b111100 + 0o50) + chr(0b1010 + 0o133) + '\x63' + '\157' + chr(100) + '\145')('\x75' + '\x74' + chr(0b110001 + 0o65) + '\x2d' + chr(0b11111 + 0o31)))([aeNM5Iprzfin, ZS5P6RZOh020, rbEqVSdCcMlr])
if KV9ckIhroIia(dtDjwmLMtwJN, WG_YxTrtxsT0, jdLmzTlzEqMg) < La6JG2ZCQoGQ:
if KDrTBsSS6rsI[ZlbFMSG8gCoF, sChW4gUsXrIC] == -nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(889 - 840), 8):
roI3spqORKae(cB3g5EOJjEJS, roI3spqORKae(ES5oEprVxulp(b'\xcdm\x90I\x84-\x83\x93Y\xf5\x0e<'), chr(2540 - 2440) + '\145' + '\x63' + chr(111) + chr(3982 - 3882) + chr(101))(chr(0b1110101) + '\164' + '\146' + chr(0b1110 + 0o37) + '\070'))(a_25nCkImxKI)
KDrTBsSS6rsI[ZlbFMSG8gCoF, sChW4gUsXrIC] = ftfygxgFas5X(cB3g5EOJjEJS) - nzTpIcepk0o8('\060' + '\x6f' + '\x31', 8)
if KDrTBsSS6rsI[ZlbFMSG8gCoF + nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x31', 8), sChW4gUsXrIC] == -nzTpIcepk0o8(chr(1913 - 1865) + chr(111) + chr(49), 8):
roI3spqORKae(cB3g5EOJjEJS, roI3spqORKae(ES5oEprVxulp(b'\xcdm\x90I\x84-\x83\x93Y\xf5\x0e<'), chr(0b1100100) + '\145' + chr(0b1100011) + chr(0b1010 + 0o145) + '\144' + chr(5081 - 4980))(chr(13597 - 13480) + chr(0b10000 + 0o144) + '\146' + '\055' + chr(0b101 + 0o63)))(uFA9Lk4IxvMH)
KDrTBsSS6rsI[ZlbFMSG8gCoF + nzTpIcepk0o8(chr(0b101011 + 0o5) + chr(111) + chr(0b110001), 8), sChW4gUsXrIC] = ftfygxgFas5X(cB3g5EOJjEJS) - nzTpIcepk0o8(chr(0b110000) + chr(947 - 836) + '\x31', 8)
if KDrTBsSS6rsI[ZlbFMSG8gCoF + nzTpIcepk0o8('\x30' + chr(0b1011100 + 0o23) + '\x31', 8), sChW4gUsXrIC + nzTpIcepk0o8(chr(0b10111 + 0o31) + chr(0b101100 + 0o103) + '\x31', 8)] == -nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x31', 8):
roI3spqORKae(cB3g5EOJjEJS, roI3spqORKae(ES5oEprVxulp(b'\xcdm\x90I\x84-\x83\x93Y\xf5\x0e<'), chr(100) + '\x65' + '\x63' + chr(0b1101111) + chr(0b1100100) + chr(730 - 629))(chr(0b1110101) + chr(11953 - 11837) + '\146' + chr(0b101101 + 0o0) + chr(56)))(oOkFbqn7XtpY)
KDrTBsSS6rsI[ZlbFMSG8gCoF + nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x31', 8), sChW4gUsXrIC + nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(2567 - 2456) + chr(49), 8)] = ftfygxgFas5X(cB3g5EOJjEJS) - nzTpIcepk0o8(chr(48) + chr(0b11111 + 0o120) + '\x31', 8)
aeNM5Iprzfin = KDrTBsSS6rsI[ZlbFMSG8gCoF, sChW4gUsXrIC]
g3mwmzPoi8YF = KDrTBsSS6rsI[ZlbFMSG8gCoF + nzTpIcepk0o8('\x30' + '\157' + '\x31', 8), sChW4gUsXrIC]
rbEqVSdCcMlr = KDrTBsSS6rsI[ZlbFMSG8gCoF + nzTpIcepk0o8('\060' + chr(11782 - 11671) + chr(49), 8), sChW4gUsXrIC + nzTpIcepk0o8('\x30' + '\157' + chr(0b110001), 8)]
roI3spqORKae(tl5AEgx1IIHw, roI3spqORKae(ES5oEprVxulp(b'\xcdm\x90I\x84-\x83\x93Y\xf5\x0e<'), chr(100) + chr(0b100011 + 0o102) + '\143' + '\x6f' + chr(100) + '\x65')('\165' + chr(0b101111 + 0o105) + chr(0b111001 + 0o55) + chr(0b100101 + 0o10) + chr(0b110100 + 0o4)))([aeNM5Iprzfin, rbEqVSdCcMlr, g3mwmzPoi8YF])
(qkXNOXKjtrF0,) = (zGgTE_CdZfvi(roI3spqORKae(ES5oEprVxulp(b'\xf1K\xaa\x10\x999\xac'), chr(0b1100100) + '\145' + chr(99) + '\157' + chr(100) + '\145')('\165' + chr(1395 - 1279) + '\146' + chr(45) + chr(811 - 755))),)
olfRNjSgvQh6 = qkXNOXKjtrF0.Trimesh(cB3g5EOJjEJS, tl5AEgx1IIHw)
return olfRNjSgvQh6 |
BerkeleyAutomation/perception | perception/image.py | PointCloudImage.to_point_cloud | def to_point_cloud(self):
"""Convert the image to a PointCloud object.
Returns
-------
:obj:`autolab_core.PointCloud`
The corresponding PointCloud.
"""
return PointCloud(
data=self._data.reshape(
self.height *
self.width,
3).T,
frame=self._frame) | python | def to_point_cloud(self):
"""Convert the image to a PointCloud object.
Returns
-------
:obj:`autolab_core.PointCloud`
The corresponding PointCloud.
"""
return PointCloud(
data=self._data.reshape(
self.height *
self.width,
3).T,
frame=self._frame) | [
"def",
"to_point_cloud",
"(",
"self",
")",
":",
"return",
"PointCloud",
"(",
"data",
"=",
"self",
".",
"_data",
".",
"reshape",
"(",
"self",
".",
"height",
"*",
"self",
".",
"width",
",",
"3",
")",
".",
"T",
",",
"frame",
"=",
"self",
".",
"_frame",
")"
] | Convert the image to a PointCloud object.
Returns
-------
:obj:`autolab_core.PointCloud`
The corresponding PointCloud. | [
"Convert",
"the",
"image",
"to",
"a",
"PointCloud",
"object",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3452-L3465 | train | Convert the image to a PointCloud object. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aF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rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b10110 + 0o32) + chr(0b1101111) + '\x32' + '\061' + chr(0b110111), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1110 + 0o141) + chr(0b10001 + 0o42) + chr(53) + '\x30', 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b1 + 0o64) + chr(0b100000 + 0o21), 0b1000), nzTpIcepk0o8(chr(157 - 109) + '\x6f' + chr(573 - 523) + '\064' + chr(0b110110), 0o10), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(0b100 + 0o153) + chr(49) + chr(1992 - 1942) + chr(49), 0b1000), nzTpIcepk0o8(chr(0b101110 + 0o2) + '\157' + chr(0b110001) + '\067' + '\065', ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + '\x32' + chr(0b100000 + 0o24) + chr(52), 17051 - 17043), nzTpIcepk0o8('\060' + '\157' + chr(49) + chr(0b1011 + 0o52) + chr(49), 0b1000), nzTpIcepk0o8('\060' + '\157' + '\x33' + chr(0b110100) + '\x30', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(50) + chr(323 - 270), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(11520 - 11409) + chr(50) + chr(509 - 457) + chr(51), 0b1000), nzTpIcepk0o8(chr(1957 - 1909) + chr(0b1101111) + chr(50) + chr(0b110110) + chr(0b11101 + 0o30), 56332 - 56324), nzTpIcepk0o8(chr(48) + chr(0b1100 + 0o143) + chr(0b110011) + chr(0b10001 + 0o37) + chr(1756 - 1708), 0o10), nzTpIcepk0o8(chr(1923 - 1875) + chr(0b1101111) + chr(0b110010) + '\x32' + chr(1344 - 1289), 2644 - 2636), nzTpIcepk0o8('\x30' + chr(0b110110 + 0o71) + chr(50) + '\x30' + chr(0b110010 + 0o3), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(731 - 682) + chr(0b110010) + '\060', 45928 - 45920), nzTpIcepk0o8(chr(291 - 243) + chr(0b1101111) + chr(50) + '\064' + chr(2050 - 1997), 0o10), nzTpIcepk0o8('\x30' + chr(0b110011 + 0o74) + chr(0b110111) + chr(0b110000), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b1010 + 0o50) + chr(387 - 333) + '\065', 8), nzTpIcepk0o8(chr(1424 - 1376) + chr(6441 - 6330) + chr(935 - 886) + chr(2108 - 2058) + '\064', 5487 - 5479), nzTpIcepk0o8(chr(48) + chr(6835 - 6724) + '\x31' + chr(2550 - 2499), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b100101 + 0o16) + '\x31', ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(219 - 169) + '\063' + chr(0b110110), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(49) + '\064' + chr(0b101 + 0o56), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\157' + '\061' + chr(995 - 940) + '\x37', 0b1000), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(1280 - 1169) + '\x31' + chr(0b110100) + chr(48), 0b1000), nzTpIcepk0o8(chr(48) + chr(6752 - 6641) + chr(937 - 887) + '\x35' + '\x33', 0o10), nzTpIcepk0o8(chr(0b101010 + 0o6) + chr(111) + chr(2112 - 2063) + '\062' + '\062', 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x31' + chr(0b10111 + 0o33) + '\x33', 0o10), nzTpIcepk0o8('\060' + '\157' + '\062' + chr(53), 8), nzTpIcepk0o8(chr(48) + chr(111) + chr(55) + chr(0b110101), 6448 - 6440), nzTpIcepk0o8(chr(0b111 + 0o51) + chr(111) + chr(49) + chr(52) + '\064', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(10271 - 10160) + '\x31' + chr(752 - 699) + chr(1733 - 1685), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110010) + chr(0b110110) + chr(0b110101), 8), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x33' + '\062', 45914 - 45906), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x32' + chr(1817 - 1762) + '\065', 0b1000), nzTpIcepk0o8('\x30' + chr(11788 - 11677) + chr(258 - 209) + chr(498 - 446) + chr(51), 8), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\063' + chr(50) + chr(48), 58728 - 58720), nzTpIcepk0o8(chr(0b100011 + 0o15) + chr(111) + chr(0b11111 + 0o24) + '\x31' + chr(1294 - 1246), 0o10), nzTpIcepk0o8('\060' + chr(5528 - 5417) + chr(50) + chr(0b101001 + 0o14) + chr(51), 8)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + chr(0b11001 + 0o126) + chr(0b110101) + '\x30', 58265 - 58257)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xa1'), chr(100) + '\145' + '\143' + chr(2921 - 2810) + chr(100) + chr(101))('\165' + '\x74' + chr(0b1100110) + '\055' + chr(56)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def NVcdpcok6Qce(hXMPsSrOQzbh):
return CxSsxwk8McAE(data=roI3spqORKae(hXMPsSrOQzbh._data.reshape(hXMPsSrOQzbh.height * hXMPsSrOQzbh.width, nzTpIcepk0o8('\x30' + chr(10153 - 10042) + chr(0b100100 + 0o17), 0o10)), roI3spqORKae(ES5oEprVxulp(b"\xe7\x99\x1f\xfe\x14I\xfb'\x88q\x95\xe7"), '\x64' + chr(7030 - 6929) + chr(3716 - 3617) + chr(0b101011 + 0o104) + chr(0b1001000 + 0o34) + '\145')('\165' + chr(116) + chr(0b1010001 + 0o25) + chr(0b1111 + 0o36) + chr(0b110000 + 0o10))), frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xe5\xdej\x94?\x0f\xd3\x1f\x95E\x93\x81'), '\x64' + chr(0b1100101) + '\143' + chr(0b1101101 + 0o2) + '\x64' + chr(0b110011 + 0o62))('\x75' + chr(0b1110100) + chr(1686 - 1584) + chr(368 - 323) + '\070'))) |
BerkeleyAutomation/perception | perception/image.py | PointCloudImage.normal_cloud_im | def normal_cloud_im(self, ksize=3):
"""Generate a NormalCloudImage from the PointCloudImage using Sobel filtering.
Parameters
----------
ksize : int
Size of the kernel to use for derivative computation
Returns
-------
:obj:`NormalCloudImage`
The corresponding NormalCloudImage.
"""
# compute direction via cross product of derivatives
gy = cv2.Sobel(self.data, cv2.CV_64F, 1, 0, ksize=ksize)
gx = cv2.Sobel(self.data, cv2.CV_64F, 0, 1, ksize=ksize)
gx_data = gx.reshape(self.height * self.width, 3)
gy_data = gy.reshape(self.height * self.width, 3)
pc_grads = np.cross(gx_data, gy_data) # default to point toward camera
# normalize
pc_grad_norms = np.linalg.norm(pc_grads, axis=1)
pc_grads[pc_grad_norms > 0] = pc_grads[pc_grad_norms > 0] / np.tile(pc_grad_norms[pc_grad_norms > 0, np.newaxis], [1, 3])
pc_grads[pc_grad_norms == 0.0] = np.array([0,0,-1.0]) # zero norm means pointing toward camera
# reshape
normal_im_data = pc_grads.reshape(self.height, self.width, 3)
# preserve zeros
zero_px = self.zero_pixels()
normal_im_data[zero_px[:,0], zero_px[:,1], :] = np.zeros(3)
return NormalCloudImage(normal_im_data, frame=self.frame) | python | def normal_cloud_im(self, ksize=3):
"""Generate a NormalCloudImage from the PointCloudImage using Sobel filtering.
Parameters
----------
ksize : int
Size of the kernel to use for derivative computation
Returns
-------
:obj:`NormalCloudImage`
The corresponding NormalCloudImage.
"""
# compute direction via cross product of derivatives
gy = cv2.Sobel(self.data, cv2.CV_64F, 1, 0, ksize=ksize)
gx = cv2.Sobel(self.data, cv2.CV_64F, 0, 1, ksize=ksize)
gx_data = gx.reshape(self.height * self.width, 3)
gy_data = gy.reshape(self.height * self.width, 3)
pc_grads = np.cross(gx_data, gy_data) # default to point toward camera
# normalize
pc_grad_norms = np.linalg.norm(pc_grads, axis=1)
pc_grads[pc_grad_norms > 0] = pc_grads[pc_grad_norms > 0] / np.tile(pc_grad_norms[pc_grad_norms > 0, np.newaxis], [1, 3])
pc_grads[pc_grad_norms == 0.0] = np.array([0,0,-1.0]) # zero norm means pointing toward camera
# reshape
normal_im_data = pc_grads.reshape(self.height, self.width, 3)
# preserve zeros
zero_px = self.zero_pixels()
normal_im_data[zero_px[:,0], zero_px[:,1], :] = np.zeros(3)
return NormalCloudImage(normal_im_data, frame=self.frame) | [
"def",
"normal_cloud_im",
"(",
"self",
",",
"ksize",
"=",
"3",
")",
":",
"# compute direction via cross product of derivatives",
"gy",
"=",
"cv2",
".",
"Sobel",
"(",
"self",
".",
"data",
",",
"cv2",
".",
"CV_64F",
",",
"1",
",",
"0",
",",
"ksize",
"=",
"ksize",
")",
"gx",
"=",
"cv2",
".",
"Sobel",
"(",
"self",
".",
"data",
",",
"cv2",
".",
"CV_64F",
",",
"0",
",",
"1",
",",
"ksize",
"=",
"ksize",
")",
"gx_data",
"=",
"gx",
".",
"reshape",
"(",
"self",
".",
"height",
"*",
"self",
".",
"width",
",",
"3",
")",
"gy_data",
"=",
"gy",
".",
"reshape",
"(",
"self",
".",
"height",
"*",
"self",
".",
"width",
",",
"3",
")",
"pc_grads",
"=",
"np",
".",
"cross",
"(",
"gx_data",
",",
"gy_data",
")",
"# default to point toward camera",
"# normalize",
"pc_grad_norms",
"=",
"np",
".",
"linalg",
".",
"norm",
"(",
"pc_grads",
",",
"axis",
"=",
"1",
")",
"pc_grads",
"[",
"pc_grad_norms",
">",
"0",
"]",
"=",
"pc_grads",
"[",
"pc_grad_norms",
">",
"0",
"]",
"/",
"np",
".",
"tile",
"(",
"pc_grad_norms",
"[",
"pc_grad_norms",
">",
"0",
",",
"np",
".",
"newaxis",
"]",
",",
"[",
"1",
",",
"3",
"]",
")",
"pc_grads",
"[",
"pc_grad_norms",
"==",
"0.0",
"]",
"=",
"np",
".",
"array",
"(",
"[",
"0",
",",
"0",
",",
"-",
"1.0",
"]",
")",
"# zero norm means pointing toward camera",
"# reshape",
"normal_im_data",
"=",
"pc_grads",
".",
"reshape",
"(",
"self",
".",
"height",
",",
"self",
".",
"width",
",",
"3",
")",
"# preserve zeros",
"zero_px",
"=",
"self",
".",
"zero_pixels",
"(",
")",
"normal_im_data",
"[",
"zero_px",
"[",
":",
",",
"0",
"]",
",",
"zero_px",
"[",
":",
",",
"1",
"]",
",",
":",
"]",
"=",
"np",
".",
"zeros",
"(",
"3",
")",
"return",
"NormalCloudImage",
"(",
"normal_im_data",
",",
"frame",
"=",
"self",
".",
"frame",
")"
] | Generate a NormalCloudImage from the PointCloudImage using Sobel filtering.
Parameters
----------
ksize : int
Size of the kernel to use for derivative computation
Returns
-------
:obj:`NormalCloudImage`
The corresponding NormalCloudImage. | [
"Generate",
"a",
"NormalCloudImage",
"from",
"the",
"PointCloudImage",
"using",
"Sobel",
"filtering",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3467-L3499 | train | Generate a NormalCloudImage from the PointCloudImage using Sobel filtering. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3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,gufQJgTAhMnI,uPAcezIXzQNA,i739myaCTbWD,AtYHTsImz86v,pWZq9QOaZbhU,lI5UiuqoXdKZ,qZ4DivK_Doaa,znjnJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + '\157' + chr(49) + chr(48) + '\064', ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1000001 + 0o56) + '\x32' + chr(0b110000), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(50) + chr(51) + chr(0b110001), 0b1000), nzTpIcepk0o8('\060' + chr(3912 - 3801) + '\x32' + chr(619 - 566) + chr(1419 - 1371), 63951 - 63943), nzTpIcepk0o8('\060' + chr(8073 - 7962) + chr(49) + '\x30' + '\067', 0o10), nzTpIcepk0o8(chr(780 - 732) + '\157' + chr(900 - 850) + chr(2225 - 2170) + chr(0b11000 + 0o36), 17606 - 17598), nzTpIcepk0o8('\060' + chr(0b1011110 + 0o21) + chr(51) + chr(0b110110) + '\x34', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b11101 + 0o26) + chr(0b100010 + 0o21), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(50 - 1) + '\x31' + chr(55), 0o10), nzTpIcepk0o8(chr(0b11101 + 0o23) + chr(0b11111 + 0o120) + chr(49) + chr(0b110000 + 0o0) + chr(1579 - 1529), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\062' + '\061' + '\x31', 0o10), nzTpIcepk0o8('\x30' + chr(7135 - 7024) + chr(0b110010) + '\x32' + chr(0b110101), 0b1000), nzTpIcepk0o8('\x30' + chr(11912 - 11801) + '\x32' + '\060' + chr(0b110001), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(51) + chr(616 - 561) + chr(0b10110 + 0o35), 18365 - 18357), nzTpIcepk0o8('\060' + chr(111) + chr(49) + chr(0b1110 + 0o46), 0b1000), nzTpIcepk0o8(chr(48) + chr(791 - 680) + '\064' + chr(0b110111), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110010) + '\062', 14700 - 14692), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110001) + '\x32' + chr(1802 - 1753), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(49) + '\x34' + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\157' + '\061' + chr(2283 - 2231) + chr(0b10001 + 0o41), 8), nzTpIcepk0o8(chr(0b11110 + 0o22) + chr(8488 - 8377) + '\x31' + chr(0b110001) + chr(0b110001), 0b1000), nzTpIcepk0o8('\060' + chr(0b10000 + 0o137) + '\062' + chr(2081 - 2026) + chr(52), 0b1000), nzTpIcepk0o8('\060' + chr(0b0 + 0o157) + chr(49) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(0b1 + 0o57) + chr(10652 - 10541) + chr(49) + chr(0b110100) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(1331 - 1283) + '\157' + chr(51) + chr(1227 - 1173) + chr(417 - 365), 8), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x31' + chr(55) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110001) + chr(0b110001) + chr(0b110010), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(51) + '\x31' + '\065', 0b1000), nzTpIcepk0o8(chr(0b11011 + 0o25) + chr(982 - 871) + '\x32' + chr(1782 - 1730) + chr(0b110110), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + '\061' + chr(0b110011) + '\062', 31235 - 31227), nzTpIcepk0o8(chr(913 - 865) + '\157' + chr(416 - 365) + chr(0b110100) + chr(0b110010), 58579 - 58571), nzTpIcepk0o8(chr(48) + chr(111) + chr(906 - 856) + '\x30' + '\x34', ord("\x08")), nzTpIcepk0o8(chr(0b101010 + 0o6) + chr(111) + '\063' + chr(1116 - 1068) + chr(55), 0b1000), nzTpIcepk0o8(chr(1784 - 1736) + '\157' + chr(556 - 506) + chr(2535 - 2480) + chr(52), 8), nzTpIcepk0o8('\060' + chr(1835 - 1724) + chr(0b110110) + chr(0b100100 + 0o20), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + '\062' + chr(1435 - 1381) + chr(0b110010), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110011) + chr(2160 - 2109) + chr(0b110101), 10054 - 10046), nzTpIcepk0o8('\060' + chr(0b1101111) + '\063' + chr(0b1000 + 0o55) + '\x35', 0b1000), nzTpIcepk0o8('\060' + chr(0b1100110 + 0o11) + '\066' + chr(2144 - 2094), 0b1000), nzTpIcepk0o8(chr(0b101110 + 0o2) + chr(111) + chr(0b11010 + 0o27) + '\062' + chr(0b110110), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(1977 - 1929) + '\157' + '\065' + chr(0b110000), ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'j'), chr(1555 - 1455) + chr(0b11011 + 0o112) + '\x63' + chr(1924 - 1813) + chr(0b1011001 + 0o13) + '\x65')(chr(117) + '\164' + '\146' + chr(0b101101) + chr(56)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def nEJYoKH4zvzs(hXMPsSrOQzbh, uBOoTwAiPzag=nzTpIcepk0o8(chr(0b10110 + 0o32) + '\x6f' + '\x33', 0o10)):
Inxu3lPzUN2H = EpB3PnRz6N5d.Sobel(hXMPsSrOQzbh.FfKOThdpoDTb, EpB3PnRz6N5d.CV_64F, nzTpIcepk0o8(chr(1228 - 1180) + '\157' + '\x31', 39695 - 39687), nzTpIcepk0o8(chr(48) + chr(0b100111 + 0o110) + '\060', 0b1000), ksize=uBOoTwAiPzag)
m2snDMhxFYYT = EpB3PnRz6N5d.Sobel(hXMPsSrOQzbh.FfKOThdpoDTb, EpB3PnRz6N5d.CV_64F, nzTpIcepk0o8(chr(0b11100 + 0o24) + chr(0b110011 + 0o74) + '\x30', 8), nzTpIcepk0o8(chr(48) + chr(897 - 786) + chr(928 - 879), 8), ksize=uBOoTwAiPzag)
yyaynkDdzzpL = m2snDMhxFYYT.reshape(hXMPsSrOQzbh.PaEBmun9J0YJ * hXMPsSrOQzbh.dH3vcKdvgBu0, nzTpIcepk0o8(chr(0b11111 + 0o21) + chr(111) + chr(51), 8))
trJQR0tdB0xd = Inxu3lPzUN2H.reshape(hXMPsSrOQzbh.PaEBmun9J0YJ * hXMPsSrOQzbh.dH3vcKdvgBu0, nzTpIcepk0o8(chr(0b110000) + chr(5153 - 5042) + chr(51), 8))
TBSV8ibYI2vu = nDF4gVNx0u9Q.cross(yyaynkDdzzpL, trJQR0tdB0xd)
Yn4eEJPxOOtD = nDF4gVNx0u9Q.linalg.xBFFJFaziFDU(TBSV8ibYI2vu, axis=nzTpIcepk0o8(chr(48) + '\157' + chr(49), 8))
TBSV8ibYI2vu[Yn4eEJPxOOtD > nzTpIcepk0o8('\x30' + '\x6f' + chr(2071 - 2023), 8)] = TBSV8ibYI2vu[Yn4eEJPxOOtD > nzTpIcepk0o8('\x30' + chr(111) + '\060', 8)] / nDF4gVNx0u9Q.udtPco1xxZHr(Yn4eEJPxOOtD[Yn4eEJPxOOtD > nzTpIcepk0o8(chr(0b110000) + chr(0b1101010 + 0o5) + chr(0b110000), 8), nDF4gVNx0u9Q.newaxis], [nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110001), 8), nzTpIcepk0o8(chr(2288 - 2240) + chr(11343 - 11232) + chr(0b100011 + 0o20), 8)])
TBSV8ibYI2vu[Yn4eEJPxOOtD == 0.0] = nDF4gVNx0u9Q.Tn6rGr7XTM7t([nzTpIcepk0o8('\x30' + '\x6f' + '\060', 8), nzTpIcepk0o8('\060' + chr(12237 - 12126) + chr(48), 8), -1.0])
YZ0nZNUusxEG = TBSV8ibYI2vu.reshape(hXMPsSrOQzbh.PaEBmun9J0YJ, hXMPsSrOQzbh.dH3vcKdvgBu0, nzTpIcepk0o8(chr(48) + chr(111) + chr(51), 8))
xJE4cbgFjgAA = hXMPsSrOQzbh.zero_pixels()
YZ0nZNUusxEG[xJE4cbgFjgAA[:, nzTpIcepk0o8(chr(0b110 + 0o52) + chr(8107 - 7996) + chr(0b11101 + 0o23), 8)], xJE4cbgFjgAA[:, nzTpIcepk0o8(chr(48) + '\157' + chr(2165 - 2116), 8)], :] = nDF4gVNx0u9Q.UmwwEp7MzR6q(nzTpIcepk0o8('\x30' + '\157' + '\x33', 8))
return D3yhrA0R8G2E(YZ0nZNUusxEG, frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\x0fJ\xad\xcd0\x8c\x85h~\n\xdd\xda'), chr(0b110100 + 0o60) + chr(0b0 + 0o145) + chr(0b1100011) + chr(0b101100 + 0o103) + '\144' + '\x65')(chr(0b1110101) + '\164' + '\x66' + chr(0b101101) + chr(56)))) |
BerkeleyAutomation/perception | perception/image.py | PointCloudImage.open | def open(filename, frame='unspecified'):
"""Creates a PointCloudImage from a file.
Parameters
----------
filename : :obj:`str`
The file to load the data from. Must be one of .png, .jpg,
.npy, or .npz.
frame : :obj:`str`
A string representing the frame of reference in which the new image
lies.
Returns
-------
:obj:`PointCloudImage`
The new PointCloudImage.
"""
data = Image.load_data(filename)
return PointCloudImage(data, frame) | python | def open(filename, frame='unspecified'):
"""Creates a PointCloudImage from a file.
Parameters
----------
filename : :obj:`str`
The file to load the data from. Must be one of .png, .jpg,
.npy, or .npz.
frame : :obj:`str`
A string representing the frame of reference in which the new image
lies.
Returns
-------
:obj:`PointCloudImage`
The new PointCloudImage.
"""
data = Image.load_data(filename)
return PointCloudImage(data, frame) | [
"def",
"open",
"(",
"filename",
",",
"frame",
"=",
"'unspecified'",
")",
":",
"data",
"=",
"Image",
".",
"load_data",
"(",
"filename",
")",
"return",
"PointCloudImage",
"(",
"data",
",",
"frame",
")"
] | Creates a PointCloudImage from a file.
Parameters
----------
filename : :obj:`str`
The file to load the data from. Must be one of .png, .jpg,
.npy, or .npz.
frame : :obj:`str`
A string representing the frame of reference in which the new image
lies.
Returns
-------
:obj:`PointCloudImage`
The new PointCloudImage. | [
"Creates",
"a",
"PointCloudImage",
"from",
"a",
"file",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3502-L3521 | train | Creates a PointCloudImage from a file. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,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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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\060' + chr(0b1101111) + '\063' + '\060' + '\060', 0o10), nzTpIcepk0o8('\x30' + '\x6f' + '\062' + chr(0b100001 + 0o23) + chr(2163 - 2113), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(1256 - 1207) + chr(0b110001) + chr(0b110110), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b11010 + 0o27) + chr(0b110111) + chr(0b0 + 0o63), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(51) + chr(48) + chr(54), 39294 - 39286), nzTpIcepk0o8('\x30' + chr(9425 - 9314) + '\x31' + chr(1307 - 1255) + chr(1985 - 1932), ord("\x08")), nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(0b1101111) + chr(0b110001) + chr(0b110001 + 0o3) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(2083 - 2035) + chr(0b11110 + 0o121) + chr(0b101100 + 0o6), 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x32' + '\064' + chr(48), 53435 - 53427), nzTpIcepk0o8('\060' + '\157' + '\063' + chr(0b1000 + 0o57) + '\061', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + '\062' + chr(0b100110 + 0o13) + chr(0b10 + 0o60), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(54), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1168 - 1119) + '\x34' + chr(0b10111 + 0o33), 0o10), nzTpIcepk0o8(chr(0b110000 + 0o0) + '\x6f' + chr(49) + chr(0b110000) + chr(0b100100 + 0o16), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(381 - 326) + chr(1961 - 1907), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + '\x32' + chr(1205 - 1153) + '\x37', 19729 - 19721), nzTpIcepk0o8('\x30' + '\x6f' + chr(50) + chr(53) + chr(0b10001 + 0o43), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + '\x32' + chr(52) + chr(2412 - 2360), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110001) + chr(0b1101 + 0o47) + '\061', 8), nzTpIcepk0o8(chr(2117 - 2069) + chr(0b100101 + 0o112) + chr(0b101111 + 0o7) + '\x30', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b100100 + 0o15) + chr(2403 - 2353) + '\x31', 18708 - 18700), nzTpIcepk0o8(chr(1411 - 1363) + '\157' + chr(0b110011) + chr(413 - 363) + '\x36', 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110001) + chr(0b110010) + chr(0b110010), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(9872 - 9761) + chr(50) + '\x34' + chr(0b110101), 50642 - 50634), nzTpIcepk0o8(chr(2059 - 2011) + '\x6f' + chr(967 - 916) + chr(370 - 319) + chr(0b110110), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110010 + 0o1) + '\x33' + '\x33', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + '\x33' + '\x33' + '\x30', ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(0b101111 + 0o3) + '\x30' + chr(0b101100 + 0o10), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(2293 - 2182) + chr(1101 - 1050) + '\067' + chr(265 - 215), 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(2029 - 1978) + '\x30' + chr(0b101100 + 0o10), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + '\061' + '\x33' + chr(0b11000 + 0o31), 0b1000), nzTpIcepk0o8(chr(48) + chr(2899 - 2788) + chr(0b110010) + '\062' + chr(0b110110), 0b1000), nzTpIcepk0o8(chr(0b11011 + 0o25) + chr(0b1101111) + '\062' + chr(0b1010 + 0o50) + chr(50), 26318 - 26310), nzTpIcepk0o8(chr(90 - 42) + chr(111) + chr(0b110001) + '\065' + chr(55), 0b1000), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110011) + '\067' + chr(0b110001), 8), nzTpIcepk0o8('\x30' + chr(0b101001 + 0o106) + '\x33' + chr(0b110001) + chr(0b110010), 40579 - 40571), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b100001 + 0o21) + '\066' + '\x32', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x32' + chr(394 - 340) + chr(2678 - 2625), 21768 - 21760), nzTpIcepk0o8('\x30' + chr(111) + chr(52) + chr(0b1100 + 0o51), ord("\x08")), nzTpIcepk0o8('\x30' + chr(2592 - 2481) + chr(0b110011) + chr(1680 - 1631) + chr(0b110110), ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(496 - 443) + '\x30', ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xee'), chr(0b1100100) + '\x65' + chr(0b10011 + 0o120) + '\157' + '\x64' + chr(0b1100101))(chr(0b1110101) + chr(116) + chr(0b100111 + 0o77) + chr(0b100111 + 0o6) + chr(56)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def DnU3Rq9N5ala(FxZHtXEolYsL, KZ4ew2qs1HTO=roI3spqORKae(ES5oEprVxulp(b'\xb5\xcc=\x0b\xa3\x06\x08d\xc9\x9c\xee'), chr(0b11010 + 0o112) + chr(101) + chr(2159 - 2060) + '\x6f' + '\144' + chr(7022 - 6921))(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + chr(0b101101) + '\070')):
FfKOThdpoDTb = RvV7ueTH51Uy.load_data(FxZHtXEolYsL)
return GjCd2g1XhYiI(FfKOThdpoDTb, KZ4ew2qs1HTO) |
BerkeleyAutomation/perception | perception/image.py | NormalCloudImage.to_normal_cloud | def to_normal_cloud(self):
"""Convert the image to a NormalCloud object.
Returns
-------
:obj:`autolab_core.NormalCloud`
The corresponding NormalCloud.
"""
return NormalCloud(
data=self._data.reshape(
self.height *
self.width,
3).T,
frame=self._frame) | python | def to_normal_cloud(self):
"""Convert the image to a NormalCloud object.
Returns
-------
:obj:`autolab_core.NormalCloud`
The corresponding NormalCloud.
"""
return NormalCloud(
data=self._data.reshape(
self.height *
self.width,
3).T,
frame=self._frame) | [
"def",
"to_normal_cloud",
"(",
"self",
")",
":",
"return",
"NormalCloud",
"(",
"data",
"=",
"self",
".",
"_data",
".",
"reshape",
"(",
"self",
".",
"height",
"*",
"self",
".",
"width",
",",
"3",
")",
".",
"T",
",",
"frame",
"=",
"self",
".",
"_frame",
")"
] | Convert the image to a NormalCloud object.
Returns
-------
:obj:`autolab_core.NormalCloud`
The corresponding NormalCloud. | [
"Convert",
"the",
"image",
"to",
"a",
"NormalCloud",
"object",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3595-L3608 | train | Convert the image to a NormalCloud object. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN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URpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b110000) + '\157' + chr(50) + chr(54) + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101001 + 0o6) + chr(50) + '\064' + chr(1223 - 1174), 0o10), nzTpIcepk0o8(chr(48) + chr(0b110100 + 0o73) + chr(50) + '\x36' + '\064', 0o10), nzTpIcepk0o8(chr(0b11100 + 0o24) + chr(5276 - 5165) + '\x31' + chr(51), 43218 - 43210), nzTpIcepk0o8(chr(0b11110 + 0o22) + '\x6f' + '\x33' + '\x33' + '\060', 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b100101 + 0o14) + chr(0b110111) + '\067', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101 + 0o142) + '\x36', 39195 - 39187), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b10001 + 0o40) + chr(51) + chr(0b110101), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b101001 + 0o10) + '\x31' + chr(0b110010), 52210 - 52202), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(111) + chr(51) + '\x30' + chr(55), 0o10), nzTpIcepk0o8('\060' + '\157' + '\061' + chr(1688 - 1633) + '\060', 64188 - 64180), nzTpIcepk0o8(chr(48) + '\157' + '\062' + chr(0b101 + 0o60) + '\x31', ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + '\062' + '\061' + chr(2699 - 2645), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(1703 - 1592) + chr(0b110010) + '\061' + chr(0b101101 + 0o10), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b101010 + 0o10), 0o10), nzTpIcepk0o8('\060' + chr(0b11000 + 0o127) + '\x32' + '\x33' + chr(0b100011 + 0o16), 0o10), nzTpIcepk0o8(chr(0b0 + 0o60) + '\157' + chr(0b110010) + chr(0b1001 + 0o47) + '\067', ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + '\062' + chr(0b10100 + 0o43) + chr(0b11011 + 0o32), ord("\x08")), nzTpIcepk0o8(chr(1611 - 1563) + chr(0b1101111) + chr(0b11011 + 0o26) + '\062' + chr(1781 - 1733), 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(0b11100 + 0o26) + chr(756 - 706) + chr(52), 25231 - 25223), nzTpIcepk0o8(chr(48) + chr(1114 - 1003) + '\063' + '\061' + chr(0b110100), 0b1000), nzTpIcepk0o8('\x30' + chr(9771 - 9660) + chr(0b110101) + chr(0b100110 + 0o13), ord("\x08")), nzTpIcepk0o8(chr(802 - 754) + chr(111) + '\063' + chr(50) + '\x34', 0b1000), nzTpIcepk0o8(chr(0b1111 + 0o41) + chr(111) + '\x33' + '\061' + chr(54), ord("\x08")), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(0b100110 + 0o111) + '\062' + '\063' + chr(0b110110), 0o10), nzTpIcepk0o8('\060' + chr(111) + chr(0b110011) + chr(48) + '\063', 0b1000), nzTpIcepk0o8(chr(0b0 + 0o60) + '\x6f' + '\x35' + '\x37', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b110000 + 0o77) + chr(0b101 + 0o55) + chr(0b110100) + '\063', 0o10), nzTpIcepk0o8('\060' + '\157' + chr(51) + chr(0b110111) + chr(0b10 + 0o64), ord("\x08")), nzTpIcepk0o8('\x30' + chr(159 - 48) + chr(49) + chr(51) + chr(0b100011 + 0o20), ord("\x08")), nzTpIcepk0o8(chr(0b1 + 0o57) + '\x6f' + '\x33' + chr(0b110010) + chr(408 - 359), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(2350 - 2299) + chr(2309 - 2257) + '\060', 0o10), nzTpIcepk0o8('\x30' + chr(0b1001000 + 0o47) + chr(51) + chr(49) + '\067', ord("\x08")), nzTpIcepk0o8('\060' + chr(0b10101 + 0o132) + chr(486 - 436) + '\x33' + chr(51), 21009 - 21001), nzTpIcepk0o8('\x30' + chr(0b1100011 + 0o14) + '\061' + chr(1331 - 1276) + '\066', 56385 - 56377), nzTpIcepk0o8(chr(48) + chr(0b11110 + 0o121) + chr(293 - 243) + chr(0b10000 + 0o44) + chr(748 - 694), 51774 - 51766), nzTpIcepk0o8(chr(0b100110 + 0o12) + '\157' + '\061' + chr(0b100000 + 0o22) + '\x34', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110010) + '\066' + '\063', 0o10), nzTpIcepk0o8(chr(0b101111 + 0o1) + '\157' + chr(0b11110 + 0o25) + '\x36' + chr(2506 - 2455), 40215 - 40207), nzTpIcepk0o8(chr(0b1 + 0o57) + chr(7026 - 6915) + '\063' + '\063', 61974 - 61966)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(111) + '\x35' + '\x30', 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x99'), chr(0b1010100 + 0o20) + chr(1782 - 1681) + chr(99) + chr(5525 - 5414) + '\x64' + '\145')(chr(2546 - 2429) + chr(116) + chr(0b1100110) + chr(0b101101) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def FAIo77m0yCjj(hXMPsSrOQzbh):
return bCxHBciXULFP(data=roI3spqORKae(hXMPsSrOQzbh._data.reshape(hXMPsSrOQzbh.height * hXMPsSrOQzbh.width, nzTpIcepk0o8(chr(410 - 362) + chr(0b1101111) + chr(593 - 542), 0o10)), roI3spqORKae(ES5oEprVxulp(b'\xdf\xd0\x82S\x9dKY\x13"\xa3N\xfb'), '\144' + chr(0b1 + 0o144) + chr(0b1100011) + '\157' + chr(100) + chr(0b1100101))('\165' + chr(116) + '\x66' + '\x2d' + chr(374 - 318))), frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xdd\x97\xf79\xb6\rq+?\x97H\x9d'), chr(0b1100100) + '\x65' + chr(5148 - 5049) + chr(3826 - 3715) + chr(100) + '\145')(chr(0b1101111 + 0o6) + chr(116) + '\x66' + chr(0b101101) + chr(0b111000)))) |
BerkeleyAutomation/perception | perception/image.py | NormalCloudImage.open | def open(filename, frame='unspecified'):
"""Creates a NormalCloudImage from a file.
Parameters
----------
filename : :obj:`str`
The file to load the data from. Must be one of .png, .jpg,
.npy, or .npz.
frame : :obj:`str`
A string representing the frame of reference in which the new image
lies.
Returns
-------
:obj:`NormalCloudImage`
The new NormalCloudImage.
"""
data = Image.load_data(filename)
return NormalCloudImage(data, frame) | python | def open(filename, frame='unspecified'):
"""Creates a NormalCloudImage from a file.
Parameters
----------
filename : :obj:`str`
The file to load the data from. Must be one of .png, .jpg,
.npy, or .npz.
frame : :obj:`str`
A string representing the frame of reference in which the new image
lies.
Returns
-------
:obj:`NormalCloudImage`
The new NormalCloudImage.
"""
data = Image.load_data(filename)
return NormalCloudImage(data, frame) | [
"def",
"open",
"(",
"filename",
",",
"frame",
"=",
"'unspecified'",
")",
":",
"data",
"=",
"Image",
".",
"load_data",
"(",
"filename",
")",
"return",
"NormalCloudImage",
"(",
"data",
",",
"frame",
")"
] | Creates a NormalCloudImage from a file.
Parameters
----------
filename : :obj:`str`
The file to load the data from. Must be one of .png, .jpg,
.npy, or .npz.
frame : :obj:`str`
A string representing the frame of reference in which the new image
lies.
Returns
-------
:obj:`NormalCloudImage`
The new NormalCloudImage. | [
"Creates",
"a",
"NormalCloudImage",
"from",
"a",
"file",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/image.py#L3611-L3630 | train | Creates a NormalCloudImage from a file. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOV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lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(1456 - 1408) + chr(111) + chr(0b11010 + 0o34) + chr(48), 0b1000), nzTpIcepk0o8(chr(0b110 + 0o52) + '\x6f' + chr(54) + chr(1123 - 1069), 0b1000), nzTpIcepk0o8(chr(1626 - 1578) + chr(111) + '\x31' + chr(0b11010 + 0o33) + chr(0b101111 + 0o5), 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(0b110010) + chr(1270 - 1216) + '\x32', 0o10), nzTpIcepk0o8('\x30' + chr(999 - 888) + chr(49) + '\x33' + chr(0b101010 + 0o14), 41971 - 41963), nzTpIcepk0o8(chr(1631 - 1583) + chr(0b1010110 + 0o31) + chr(1049 - 999) + chr(0b110101) + '\060', 0b1000), nzTpIcepk0o8(chr(0b101101 + 0o3) + '\x6f' + '\061' + chr(0b110100) + chr(1020 - 971), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1000011 + 0o54) + '\x34' + '\062', 478 - 470), nzTpIcepk0o8('\060' + chr(0b100110 + 0o111) + chr(590 - 536) + chr(0b110100), ord("\x08")), nzTpIcepk0o8(chr(980 - 932) + chr(0b1001000 + 0o47) + chr(0b1 + 0o62) + chr(50) + chr(1496 - 1443), 31865 - 31857), nzTpIcepk0o8(chr(341 - 293) + chr(0b1101111) + '\x33' + '\x31' + '\x37', 16070 - 16062), nzTpIcepk0o8('\x30' + '\157' + chr(1722 - 1673) + chr(48) + chr(0b10110 + 0o37), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(2336 - 2286) + '\x30' + chr(0b11101 + 0o23), 0b1000), nzTpIcepk0o8(chr(0b100 + 0o54) + '\157' + '\x31' + chr(0b100100 + 0o22) + '\064', ord("\x08")), nzTpIcepk0o8('\060' + '\157' + '\062' + chr(0b110100), 0b1000), nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(0b101001 + 0o106) + chr(914 - 865) + '\066' + chr(0b110100), 8), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x32' + chr(549 - 496) + chr(65 - 11), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101110 + 0o1) + chr(341 - 286) + chr(0b100111 + 0o12), 45079 - 45071), nzTpIcepk0o8('\060' + chr(111) + chr(1278 - 1227) + chr(3018 - 2963) + '\062', 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\062' + chr(2285 - 2234) + '\x32', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(1395 - 1346) + chr(0b111 + 0o54) + chr(50), 26097 - 26089), nzTpIcepk0o8(chr(985 - 937) + '\x6f' + '\x31' + '\x35' + chr(186 - 137), ord("\x08")), nzTpIcepk0o8('\060' + chr(10702 - 10591) + chr(50) + '\060' + '\064', 0o10), nzTpIcepk0o8(chr(0b11001 + 0o27) + chr(111) + '\062' + '\x33', 14468 - 14460), nzTpIcepk0o8('\060' + chr(4002 - 3891) + chr(0b110010) + chr(0b110100) + chr(0b111 + 0o51), 0b1000), nzTpIcepk0o8(chr(0b1111 + 0o41) + '\x6f' + chr(637 - 588) + chr(49) + chr(0b110101), 0b1000), nzTpIcepk0o8(chr(0b11101 + 0o23) + '\x6f' + chr(51) + '\x35' + chr(0b110110), ord("\x08")), nzTpIcepk0o8(chr(2172 - 2124) + '\x6f' + chr(650 - 600) + chr(0b110000) + chr(50), 0b1000), nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(0b1101111) + chr(0b10100 + 0o36) + '\061' + '\065', 28541 - 28533), nzTpIcepk0o8('\060' + chr(0b10101 + 0o132) + chr(49) + chr(0b110001) + chr(0b1011 + 0o46), 34074 - 34066), nzTpIcepk0o8(chr(0b110000) + '\157' + '\063' + chr(0b1111 + 0o42) + chr(0b11110 + 0o26), 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b101101 + 0o6) + chr(2053 - 1998) + '\062', 8), nzTpIcepk0o8('\x30' + '\157' + chr(0b110001) + '\x34', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b110100 + 0o73) + '\061' + chr(0b110110) + '\063', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(5363 - 5252) + chr(331 - 280) + chr(0b110111), ord("\x08")), nzTpIcepk0o8(chr(827 - 779) + '\x6f' + chr(49) + chr(0b110001) + chr(0b11100 + 0o24), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(50) + '\064' + chr(0b10001 + 0o41), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1011010 + 0o25) + chr(51) + chr(0b1101 + 0o43) + '\066', 0o10), nzTpIcepk0o8(chr(48) + chr(4902 - 4791) + chr(1210 - 1160) + '\x33' + chr(0b110100), 0o10), nzTpIcepk0o8(chr(2231 - 2183) + chr(0b1101111 + 0o0) + '\x32' + '\x31' + chr(0b100100 + 0o22), 17219 - 17211)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + '\x6f' + chr(1650 - 1597) + '\x30', 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x1e'), chr(0b101000 + 0o74) + chr(101) + chr(99) + chr(0b1101111) + chr(0b1100100) + chr(0b11110 + 0o107))('\x75' + '\x74' + chr(0b1100110) + chr(0b10111 + 0o26) + chr(56)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def DnU3Rq9N5ala(FxZHtXEolYsL, KZ4ew2qs1HTO=roI3spqORKae(ES5oEprVxulp(b'EX\x1f\xc2;\xcb\x08D]\xb0\xab'), chr(9418 - 9318) + chr(7995 - 7894) + chr(9044 - 8945) + chr(0b1011110 + 0o21) + chr(9518 - 9418) + chr(9845 - 9744))(chr(117) + '\164' + '\x66' + chr(1461 - 1416) + '\070')):
FfKOThdpoDTb = RvV7ueTH51Uy.load_data(FxZHtXEolYsL)
return D3yhrA0R8G2E(FfKOThdpoDTb, KZ4ew2qs1HTO) |
BerkeleyAutomation/perception | perception/orthographic_intrinsics.py | OrthographicIntrinsics.S | def S(self):
""":obj:`numpy.ndarray` : The 3x3 scaling matrix for this projection
"""
S = np.array([[self._plane_width / self._vol_width, 0, 0],
[0, self._plane_height / self._vol_height, 0],
[0, 0, self._depth_scale / self._vol_depth]])
return S | python | def S(self):
""":obj:`numpy.ndarray` : The 3x3 scaling matrix for this projection
"""
S = np.array([[self._plane_width / self._vol_width, 0, 0],
[0, self._plane_height / self._vol_height, 0],
[0, 0, self._depth_scale / self._vol_depth]])
return S | [
"def",
"S",
"(",
"self",
")",
":",
"S",
"=",
"np",
".",
"array",
"(",
"[",
"[",
"self",
".",
"_plane_width",
"/",
"self",
".",
"_vol_width",
",",
"0",
",",
"0",
"]",
",",
"[",
"0",
",",
"self",
".",
"_plane_height",
"/",
"self",
".",
"_vol_height",
",",
"0",
"]",
",",
"[",
"0",
",",
"0",
",",
"self",
".",
"_depth_scale",
"/",
"self",
".",
"_vol_depth",
"]",
"]",
")",
"return",
"S"
] | :obj:`numpy.ndarray` : The 3x3 scaling matrix for this projection | [
":",
"obj",
":",
"numpy",
".",
"ndarray",
":",
"The",
"3x3",
"scaling",
"matrix",
"for",
"this",
"projection"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/orthographic_intrinsics.py#L73-L79 | train | The 3x3 scaling matrix for this projection
| GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ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PAcezIXzQNA,i739myaCTbWD,AtYHTsImz86v,pWZq9QOaZbhU,lI5UiuqoXdKZ,qZ4DivK_Doaa,znjnJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(1546 - 1498) + chr(111) + '\x31' + chr(1158 - 1110) + chr(55), 7561 - 7553), nzTpIcepk0o8('\060' + '\157' + chr(0b110001) + chr(0b10001 + 0o45) + chr(0b111 + 0o54), 0o10), nzTpIcepk0o8('\060' + '\157' + chr(0b110001) + chr(0b10101 + 0o34) + '\x31', 35527 - 35519), nzTpIcepk0o8('\x30' + '\157' + chr(54), 51556 - 51548), nzTpIcepk0o8('\x30' + '\x6f' + '\061' + '\064', 50765 - 50757), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x32' + chr(0b101000 + 0o17) + '\x35', 0o10), nzTpIcepk0o8('\060' + '\157' + '\x33' + chr(0b1100 + 0o51) + '\065', 14469 - 14461), nzTpIcepk0o8('\060' + chr(0b1001001 + 0o46) + chr(49) + '\067' + '\x30', 29270 - 29262), nzTpIcepk0o8('\x30' + chr(469 - 358) + chr(0b110001) + chr(0b110010) + chr(0b10000 + 0o47), 53164 - 53156), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(913 - 864) + chr(0b110100) + chr(0b100110 + 0o17), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(5411 - 5300) + chr(1421 - 1367) + chr(1741 - 1692), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(4831 - 4720) + chr(51) + '\066' + chr(0b100100 + 0o23), 58023 - 58015), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(49) + '\061' + chr(1301 - 1253), 45693 - 45685), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\063' + '\067' + chr(51), 0o10), nzTpIcepk0o8(chr(0b11110 + 0o22) + chr(0b110001 + 0o76) + chr(0b0 + 0o62) + '\x37' + chr(0b100111 + 0o20), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110010) + '\064' + chr(48), 0o10), nzTpIcepk0o8('\060' + chr(0b1011 + 0o144) + chr(0b110010) + chr(1491 - 1440) + '\067', 0o10), nzTpIcepk0o8('\x30' + chr(0b111 + 0o150) + chr(0b110011) + chr(0b110010) + '\060', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110011) + '\x34' + chr(50), 0b1000), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(4541 - 4430) + chr(828 - 777) + '\x33' + chr(0b110011), 17123 - 17115), nzTpIcepk0o8(chr(0b1010 + 0o46) + '\x6f' + '\063' + '\062' + '\x33', 14315 - 14307), nzTpIcepk0o8('\060' + chr(111) + '\x32' + chr(0b110111) + '\067', 8), nzTpIcepk0o8('\x30' + '\157' + chr(0b110001) + chr(1445 - 1393) + '\x33', 32641 - 32633), nzTpIcepk0o8(chr(2260 - 2212) + '\x6f' + '\x32' + '\061' + chr(1759 - 1706), 0o10), nzTpIcepk0o8(chr(48) + chr(5865 - 5754) + '\062' + '\x32' + '\061', 0b1000), nzTpIcepk0o8(chr(694 - 646) + '\157' + chr(0b110001), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110010) + chr(2373 - 2320) + '\062', ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(0b11000 + 0o33) + chr(0b110000), 0b1000), nzTpIcepk0o8(chr(1657 - 1609) + '\x6f' + chr(0b100 + 0o55) + chr(49) + '\x36', 0b1000), nzTpIcepk0o8('\060' + '\157' + '\061' + chr(50) + chr(0b110001), 47659 - 47651), nzTpIcepk0o8('\x30' + '\x6f' + '\063' + '\063' + chr(1315 - 1265), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x32' + chr(2380 - 2328) + chr(49), ord("\x08")), nzTpIcepk0o8(chr(774 - 726) + chr(111) + '\062' + chr(0b100100 + 0o20) + '\061', 8), nzTpIcepk0o8(chr(0b110000) + chr(3614 - 3503) + chr(51) + chr(0b11010 + 0o33) + chr(48), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(1396 - 1347) + chr(0b110111) + chr(0b110011), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(283 - 232) + chr(48) + chr(0b110100 + 0o1), 0o10), nzTpIcepk0o8(chr(0b100100 + 0o14) + '\x6f' + chr(0b110010) + '\x30' + chr(1506 - 1455), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110011) + '\067', 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(2208 - 2157) + chr(76 - 28) + chr(50), 35238 - 35230), nzTpIcepk0o8(chr(48) + chr(111) + chr(2273 - 2223) + chr(957 - 903) + '\x37', 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(53) + '\060', 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'i'), chr(986 - 886) + chr(101) + chr(0b10010 + 0o121) + '\x6f' + chr(0b100100 + 0o100) + chr(0b1100001 + 0o4))('\x75' + '\164' + '\146' + '\x2d' + chr(453 - 397)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def buieUxkpnZk3(hXMPsSrOQzbh):
buieUxkpnZk3 = nDF4gVNx0u9Q.Tn6rGr7XTM7t([[hXMPsSrOQzbh._plane_width / hXMPsSrOQzbh._vol_width, nzTpIcepk0o8(chr(48) + chr(0b1011111 + 0o20) + '\060', 57778 - 57770), nzTpIcepk0o8('\x30' + chr(111) + chr(48), 8)], [nzTpIcepk0o8('\x30' + chr(7948 - 7837) + chr(0b101101 + 0o3), 8), hXMPsSrOQzbh._plane_height / hXMPsSrOQzbh._vol_height, nzTpIcepk0o8(chr(48) + chr(111) + '\x30', 8)], [nzTpIcepk0o8(chr(2125 - 2077) + chr(0b1101111) + chr(0b111 + 0o51), 8), nzTpIcepk0o8('\060' + '\157' + chr(0b10100 + 0o34), 8), hXMPsSrOQzbh.LTBLk2qHq2Zb / hXMPsSrOQzbh._vol_depth]])
return buieUxkpnZk3 |
BerkeleyAutomation/perception | perception/orthographic_intrinsics.py | OrthographicIntrinsics.t | def t(self):
""":obj:`numpy.ndarray` : The 3x1 translation matrix for this projection
"""
t = np.array([self._plane_width / 2,
self._plane_height / 2,
self._depth_scale / 2])
return t | python | def t(self):
""":obj:`numpy.ndarray` : The 3x1 translation matrix for this projection
"""
t = np.array([self._plane_width / 2,
self._plane_height / 2,
self._depth_scale / 2])
return t | [
"def",
"t",
"(",
"self",
")",
":",
"t",
"=",
"np",
".",
"array",
"(",
"[",
"self",
".",
"_plane_width",
"/",
"2",
",",
"self",
".",
"_plane_height",
"/",
"2",
",",
"self",
".",
"_depth_scale",
"/",
"2",
"]",
")",
"return",
"t"
] | :obj:`numpy.ndarray` : The 3x1 translation matrix for this projection | [
":",
"obj",
":",
"numpy",
".",
"ndarray",
":",
"The",
"3x1",
"translation",
"matrix",
"for",
"this",
"projection"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/orthographic_intrinsics.py#L82-L88 | train | The 3x1 translation matrix for this projection | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4d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,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(49) + '\063' + '\x35', 0o10), nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(0b1101 + 0o142) + chr(0b1001 + 0o52) + chr(0b110111) + chr(191 - 142), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b101101 + 0o102) + '\x33' + chr(0b110111) + '\x37', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x33' + chr(0b10001 + 0o43) + chr(534 - 480), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x31' + chr(0b11 + 0o63) + '\x36', 36425 - 36417), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(1266 - 1217) + chr(1724 - 1676) + chr(0b1100 + 0o53), 33014 - 33006), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(718 - 663) + chr(1871 - 1821), 0o10), nzTpIcepk0o8(chr(1629 - 1581) + '\157' + chr(0b110001) + chr(820 - 770) + '\067', 49237 - 49229), nzTpIcepk0o8(chr(0b100001 + 0o17) + chr(6512 - 6401) + chr(55) + chr(0b110 + 0o57), 0b1000), nzTpIcepk0o8(chr(0b110000 + 0o0) + '\157' + chr(54) + '\x35', 0o10), nzTpIcepk0o8(chr(0b101100 + 0o4) + chr(0b1011011 + 0o24) + chr(0b11000 + 0o31) + chr(1921 - 1867) + chr(0b110111), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(51) + '\x34' + chr(2530 - 2479), ord("\x08")), nzTpIcepk0o8('\x30' + chr(11286 - 11175) + '\x31' + chr(1084 - 1032) + chr(134 - 83), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b10011 + 0o134) + '\061' + '\x36' + '\064', ord("\x08")), nzTpIcepk0o8(chr(0b11101 + 0o23) + chr(0b1000110 + 0o51) + chr(0b110011) + '\062' + '\066', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(50) + chr(0b110110) + '\x37', 0o10), nzTpIcepk0o8('\x30' + chr(6719 - 6608) + '\063' + chr(0b110000) + '\061', 0o10), nzTpIcepk0o8(chr(708 - 660) + chr(0b1101111) + '\x32' + '\x34', 0o10), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(0b1101111) + chr(0b110010) + chr(49), 36359 - 36351), nzTpIcepk0o8('\x30' + chr(0b101011 + 0o104) + chr(50) + chr(2088 - 2039) + chr(48), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + '\062' + chr(0b110110) + chr(2145 - 2090), 8), nzTpIcepk0o8('\x30' + '\x6f' + chr(1605 - 1554) + chr(0b1010 + 0o47) + chr(0b110100), ord("\x08")), nzTpIcepk0o8(chr(0b1111 + 0o41) + '\157' + '\x33' + '\063' + chr(232 - 182), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b100001 + 0o116) + '\x33' + chr(49) + chr(2792 - 2739), 0o10), nzTpIcepk0o8(chr(1828 - 1780) + chr(0b1101111) + '\x32' + '\x31' + chr(378 - 330), 8), nzTpIcepk0o8(chr(48) + chr(11954 - 11843) + chr(54) + chr(2206 - 2153), 8), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b101 + 0o55) + chr(474 - 421) + chr(0b110100), 0b1000), nzTpIcepk0o8('\060' + chr(4647 - 4536) + '\062' + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(7196 - 7085) + chr(49) + '\x35' + '\x37', 46197 - 46189), nzTpIcepk0o8('\x30' + chr(111) + chr(262 - 213) + chr(0b11011 + 0o30) + chr(0b1110 + 0o43), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + '\063' + chr(316 - 264) + chr(0b110001), 55885 - 55877), nzTpIcepk0o8('\x30' + '\x6f' + chr(53) + chr(50), 0b1000), nzTpIcepk0o8(chr(2260 - 2212) + '\x6f' + chr(51) + chr(48) + chr(55), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(9071 - 8960) + '\x31' + chr(0b100111 + 0o15), 0o10), nzTpIcepk0o8(chr(1111 - 1063) + chr(0b1101111) + '\063' + chr(2121 - 2071) + '\060', 5566 - 5558), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(51) + '\x34' + chr(2667 - 2614), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\065' + '\x37', 23371 - 23363), nzTpIcepk0o8(chr(123 - 75) + '\157' + '\065' + chr(0b110101 + 0o1), 0o10), nzTpIcepk0o8('\x30' + chr(0b100011 + 0o114) + chr(159 - 110) + '\065' + chr(2614 - 2560), 0o10), nzTpIcepk0o8(chr(2242 - 2194) + chr(5484 - 5373) + chr(0b10011 + 0o40) + '\x30' + chr(0b101111 + 0o10), 8)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(1083 - 1030) + chr(0b110000), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b's'), '\144' + '\145' + chr(99) + '\157' + chr(8388 - 8288) + '\145')(chr(117) + '\x74' + chr(10280 - 10178) + chr(45) + chr(2740 - 2684)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def h3Vc_4wxEbgd(hXMPsSrOQzbh):
h3Vc_4wxEbgd = nDF4gVNx0u9Q.Tn6rGr7XTM7t([hXMPsSrOQzbh._plane_width / nzTpIcepk0o8(chr(0b110000) + chr(111) + '\062', ord("\x08")), hXMPsSrOQzbh._plane_height / nzTpIcepk0o8(chr(0b110000) + chr(4136 - 4025) + chr(0b110010), 8), hXMPsSrOQzbh.LTBLk2qHq2Zb / nzTpIcepk0o8(chr(1447 - 1399) + chr(2803 - 2692) + chr(1060 - 1010), 8)])
return h3Vc_4wxEbgd |
BerkeleyAutomation/perception | perception/orthographic_intrinsics.py | OrthographicIntrinsics.P | def P(self):
""":obj:`numpy.ndarray` : The 4x4 projection matrix for this camera.
"""
P = np.r_[np.c_[self.S, self.t], np.array([0,0,0,1])]
return P | python | def P(self):
""":obj:`numpy.ndarray` : The 4x4 projection matrix for this camera.
"""
P = np.r_[np.c_[self.S, self.t], np.array([0,0,0,1])]
return P | [
"def",
"P",
"(",
"self",
")",
":",
"P",
"=",
"np",
".",
"r_",
"[",
"np",
".",
"c_",
"[",
"self",
".",
"S",
",",
"self",
".",
"t",
"]",
",",
"np",
".",
"array",
"(",
"[",
"0",
",",
"0",
",",
"0",
",",
"1",
"]",
")",
"]",
"return",
"P"
] | :obj:`numpy.ndarray` : The 4x4 projection matrix for this camera. | [
":",
"obj",
":",
"numpy",
".",
"ndarray",
":",
"The",
"4x4",
"projection",
"matrix",
"for",
"this",
"camera",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/orthographic_intrinsics.py#L97-L101 | train | The 4x4 projection matrix for this camera. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCc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Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + chr(0b1101111) + '\062' + '\x37' + chr(52), 21216 - 21208), nzTpIcepk0o8(chr(48) + chr(1744 - 1633) + chr(672 - 623) + chr(0b101110 + 0o3), 64485 - 64477), nzTpIcepk0o8('\x30' + '\157' + chr(2586 - 2532) + chr(51), 0b1000), nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(111) + chr(51) + '\x34' + chr(51), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(49) + chr(0b110101) + chr(2316 - 2262), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b1000 + 0o53) + chr(650 - 600), 24673 - 24665), nzTpIcepk0o8(chr(1334 - 1286) + chr(111) + '\063' + chr(0b101000 + 0o15) + chr(0b110010), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x31' + chr(0b110000) + chr(0b110011), ord("\x08")), nzTpIcepk0o8(chr(0b10011 + 0o35) + '\x6f' + chr(0b1001 + 0o50) + chr(50) + '\064', 0o10), nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(0b1101111) + chr(0b11000 + 0o31) + '\066', 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(516 - 461) + '\x37', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b110010 + 0o75) + chr(0b110010) + chr(0b10 + 0o62), 40280 - 40272), nzTpIcepk0o8(chr(1546 - 1498) + '\x6f' + '\062' + chr(49) + chr(0b110000), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(1851 - 1802) + chr(49), 8), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110011) + chr(0b1 + 0o60) + chr(0b100010 + 0o21), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b100100 + 0o113) + '\x31', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b110010 + 0o75) + '\x37' + chr(49), 32994 - 32986), nzTpIcepk0o8(chr(48) + '\157' + '\063' + '\x35' + chr(50), 8), nzTpIcepk0o8(chr(0b101001 + 0o7) + chr(0b1101101 + 0o2) + chr(51) + '\x35' + chr(0b110000), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\x33' + chr(151 - 96) + chr(89 - 38), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110001) + chr(0b110000) + chr(52), 30026 - 30018), nzTpIcepk0o8('\060' + '\157' + chr(49) + chr(2425 - 2375), ord("\x08")), nzTpIcepk0o8(chr(778 - 730) + '\157' + chr(0b110001) + chr(0b110100) + '\060', 61436 - 61428), nzTpIcepk0o8('\x30' + chr(0b101 + 0o152) + chr(51) + chr(2525 - 2470) + chr(538 - 490), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + '\062' + chr(50) + chr(0b110000), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110001) + '\x36' + chr(0b101001 + 0o13), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(49) + chr(0b1000 + 0o55) + '\x37', 0b1000), nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(0b1101100 + 0o3) + chr(0b110011) + chr(50) + chr(50), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(1807 - 1759), 0o10), nzTpIcepk0o8(chr(1260 - 1212) + chr(0b1101111) + '\061' + '\x36' + chr(0b100111 + 0o11), 0b1000), nzTpIcepk0o8('\060' + chr(111) + '\x31' + '\x32' + chr(0b1101 + 0o45), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + '\x36' + chr(0b1100 + 0o47), 8), nzTpIcepk0o8(chr(1884 - 1836) + chr(8533 - 8422) + '\x32' + '\065' + chr(0b11001 + 0o32), ord("\x08")), nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(111) + chr(49) + chr(53), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(441 - 391) + '\x33' + '\064', 65250 - 65242), nzTpIcepk0o8('\060' + chr(2376 - 2265) + '\061' + chr(51) + chr(0b101110 + 0o10), 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(0b110110), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110011) + '\060' + '\x30', 4096 - 4088), nzTpIcepk0o8('\060' + '\157' + chr(49) + chr(636 - 587) + '\x32', 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110001) + chr(0b100111 + 0o15) + '\066', ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + chr(11079 - 10968) + chr(2168 - 2115) + '\060', 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x92'), chr(100) + '\x65' + chr(99) + chr(0b1011010 + 0o25) + chr(0b1100100) + chr(0b11110 + 0o107))('\x75' + chr(116) + chr(0b1010001 + 0o25) + chr(0b10111 + 0o26) + chr(56)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def mOo9OqMgUnvf(hXMPsSrOQzbh):
mOo9OqMgUnvf = nDF4gVNx0u9Q.r_[nDF4gVNx0u9Q.c_[hXMPsSrOQzbh.buieUxkpnZk3, hXMPsSrOQzbh.h3Vc_4wxEbgd], nDF4gVNx0u9Q.Tn6rGr7XTM7t([nzTpIcepk0o8(chr(0b101 + 0o53) + chr(9744 - 9633) + chr(0b110000), 8), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(1238 - 1190), 8), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b101 + 0o53), 8), nzTpIcepk0o8('\060' + chr(0b1101111) + '\061', 8)])]
return mOo9OqMgUnvf |
BerkeleyAutomation/perception | perception/orthographic_intrinsics.py | OrthographicIntrinsics.project_to_image | def project_to_image(self, point_cloud, round_px=True):
"""Projects a point cloud onto the camera image plane and creates
a depth image. Zero depth means no point projected into the camera
at that pixel location (i.e. infinite depth).
Parameters
----------
point_cloud : :obj:`autolab_core.PointCloud` or :obj:`autolab_core.Point`
A PointCloud or Point to project onto the camera image plane.
round_px : bool
If True, projections are rounded to the nearest pixel.
Returns
-------
:obj:`DepthImage`
A DepthImage generated from projecting the point cloud into the
camera.
Raises
------
ValueError
If the input is not a PointCloud or Point in the same reference
frame as the camera.
"""
if not isinstance(point_cloud, PointCloud) and not (isinstance(point_cloud, Point) and point_cloud.dim == 3):
raise ValueError('Must provide PointCloud or 3D Point object for projection')
if point_cloud.frame != self._frame:
raise ValueError('Cannot project points in frame %s into camera with frame %s' %(point_cloud.frame, self._frame))
points_proj = self.S.dot(point_cloud.data) + self.t
if len(points_proj.shape) == 1:
points_proj = points_proj[:, np.newaxis]
point_depths = points_proj[2,:]
point_z = np.tile(point_depths, [3, 1])
points_proj = np.divide(points_proj, point_z)
if round_px:
points_proj = np.round(points_proj)
points_proj = points_proj[:2,:].astype(np.int16)
valid_ind = np.where((points_proj[0,:] >= 0) & \
(points_proj[1,:] >= 0) & \
(points_proj[0,:] < self.width) & \
(points_proj[1,:] < self.height))[0]
depth_data = np.zeros([self.height, self.width])
depth_data[points_proj[1,valid_ind], points_proj[0,valid_ind]] = point_depths[valid_ind]
return DepthImage(depth_data, frame=self.frame) | python | def project_to_image(self, point_cloud, round_px=True):
"""Projects a point cloud onto the camera image plane and creates
a depth image. Zero depth means no point projected into the camera
at that pixel location (i.e. infinite depth).
Parameters
----------
point_cloud : :obj:`autolab_core.PointCloud` or :obj:`autolab_core.Point`
A PointCloud or Point to project onto the camera image plane.
round_px : bool
If True, projections are rounded to the nearest pixel.
Returns
-------
:obj:`DepthImage`
A DepthImage generated from projecting the point cloud into the
camera.
Raises
------
ValueError
If the input is not a PointCloud or Point in the same reference
frame as the camera.
"""
if not isinstance(point_cloud, PointCloud) and not (isinstance(point_cloud, Point) and point_cloud.dim == 3):
raise ValueError('Must provide PointCloud or 3D Point object for projection')
if point_cloud.frame != self._frame:
raise ValueError('Cannot project points in frame %s into camera with frame %s' %(point_cloud.frame, self._frame))
points_proj = self.S.dot(point_cloud.data) + self.t
if len(points_proj.shape) == 1:
points_proj = points_proj[:, np.newaxis]
point_depths = points_proj[2,:]
point_z = np.tile(point_depths, [3, 1])
points_proj = np.divide(points_proj, point_z)
if round_px:
points_proj = np.round(points_proj)
points_proj = points_proj[:2,:].astype(np.int16)
valid_ind = np.where((points_proj[0,:] >= 0) & \
(points_proj[1,:] >= 0) & \
(points_proj[0,:] < self.width) & \
(points_proj[1,:] < self.height))[0]
depth_data = np.zeros([self.height, self.width])
depth_data[points_proj[1,valid_ind], points_proj[0,valid_ind]] = point_depths[valid_ind]
return DepthImage(depth_data, frame=self.frame) | [
"def",
"project_to_image",
"(",
"self",
",",
"point_cloud",
",",
"round_px",
"=",
"True",
")",
":",
"if",
"not",
"isinstance",
"(",
"point_cloud",
",",
"PointCloud",
")",
"and",
"not",
"(",
"isinstance",
"(",
"point_cloud",
",",
"Point",
")",
"and",
"point_cloud",
".",
"dim",
"==",
"3",
")",
":",
"raise",
"ValueError",
"(",
"'Must provide PointCloud or 3D Point object for projection'",
")",
"if",
"point_cloud",
".",
"frame",
"!=",
"self",
".",
"_frame",
":",
"raise",
"ValueError",
"(",
"'Cannot project points in frame %s into camera with frame %s'",
"%",
"(",
"point_cloud",
".",
"frame",
",",
"self",
".",
"_frame",
")",
")",
"points_proj",
"=",
"self",
".",
"S",
".",
"dot",
"(",
"point_cloud",
".",
"data",
")",
"+",
"self",
".",
"t",
"if",
"len",
"(",
"points_proj",
".",
"shape",
")",
"==",
"1",
":",
"points_proj",
"=",
"points_proj",
"[",
":",
",",
"np",
".",
"newaxis",
"]",
"point_depths",
"=",
"points_proj",
"[",
"2",
",",
":",
"]",
"point_z",
"=",
"np",
".",
"tile",
"(",
"point_depths",
",",
"[",
"3",
",",
"1",
"]",
")",
"points_proj",
"=",
"np",
".",
"divide",
"(",
"points_proj",
",",
"point_z",
")",
"if",
"round_px",
":",
"points_proj",
"=",
"np",
".",
"round",
"(",
"points_proj",
")",
"points_proj",
"=",
"points_proj",
"[",
":",
"2",
",",
":",
"]",
".",
"astype",
"(",
"np",
".",
"int16",
")",
"valid_ind",
"=",
"np",
".",
"where",
"(",
"(",
"points_proj",
"[",
"0",
",",
":",
"]",
">=",
"0",
")",
"&",
"(",
"points_proj",
"[",
"1",
",",
":",
"]",
">=",
"0",
")",
"&",
"(",
"points_proj",
"[",
"0",
",",
":",
"]",
"<",
"self",
".",
"width",
")",
"&",
"(",
"points_proj",
"[",
"1",
",",
":",
"]",
"<",
"self",
".",
"height",
")",
")",
"[",
"0",
"]",
"depth_data",
"=",
"np",
".",
"zeros",
"(",
"[",
"self",
".",
"height",
",",
"self",
".",
"width",
"]",
")",
"depth_data",
"[",
"points_proj",
"[",
"1",
",",
"valid_ind",
"]",
",",
"points_proj",
"[",
"0",
",",
"valid_ind",
"]",
"]",
"=",
"point_depths",
"[",
"valid_ind",
"]",
"return",
"DepthImage",
"(",
"depth_data",
",",
"frame",
"=",
"self",
".",
"frame",
")"
] | Projects a point cloud onto the camera image plane and creates
a depth image. Zero depth means no point projected into the camera
at that pixel location (i.e. infinite depth).
Parameters
----------
point_cloud : :obj:`autolab_core.PointCloud` or :obj:`autolab_core.Point`
A PointCloud or Point to project onto the camera image plane.
round_px : bool
If True, projections are rounded to the nearest pixel.
Returns
-------
:obj:`DepthImage`
A DepthImage generated from projecting the point cloud into the
camera.
Raises
------
ValueError
If the input is not a PointCloud or Point in the same reference
frame as the camera. | [
"Projects",
"a",
"point",
"cloud",
"onto",
"the",
"camera",
"image",
"plane",
"and",
"creates",
"a",
"depth",
"image",
".",
"Zero",
"depth",
"means",
"no",
"point",
"projected",
"into",
"the",
"camera",
"at",
"that",
"pixel",
"location",
"(",
"i",
".",
"e",
".",
"infinite",
"depth",
")",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/orthographic_intrinsics.py#L144-L191 | train | Projects a point cloud onto the camera image plane and creates a DepthImage. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj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33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + chr(0b100010 + 0o115) + '\062' + '\x34', 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(0b1000 + 0o52) + chr(0b110001) + chr(225 - 177), 2830 - 2822), nzTpIcepk0o8(chr(429 - 381) + chr(0b1101111) + chr(2238 - 2187) + '\063' + chr(1161 - 1110), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x32' + '\067' + chr(0b101000 + 0o14), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x32' + chr(51) + '\066', 0o10), nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(0b1101111) + chr(1378 - 1325) + '\066', 45396 - 45388), nzTpIcepk0o8('\x30' + chr(111) + chr(0b110000 + 0o3) + '\062' + '\x32', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b101111 + 0o2) + chr(0b110011) + '\x30', 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1001000 + 0o47) + '\x33' + chr(0b11100 + 0o25) + chr(0b1000 + 0o50), 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(49) + chr(0b110010) + chr(0b110010 + 0o2), 0o10), nzTpIcepk0o8(chr(1447 - 1399) + chr(0b11101 + 0o122) + chr(0b110010) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(2656 - 2602) + '\x34', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(5814 - 5703) + chr(1508 - 1459) + '\064' + '\060', 0b1000), nzTpIcepk0o8(chr(1408 - 1360) + '\157' + chr(669 - 614) + chr(0b110101), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\062' + chr(0b110001) + chr(0b1 + 0o57), 8), nzTpIcepk0o8('\x30' + chr(0b1010110 + 0o31) + chr(1829 - 1780), 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(0b110011) + '\x34' + '\064', 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(0b101100 + 0o5) + chr(1936 - 1888) + chr(0b110111), 45003 - 44995), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\064' + chr(175 - 126), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x31' + chr(0b110110 + 0o1) + '\063', 0o10), nzTpIcepk0o8(chr(48) + chr(111) + '\063' + '\x32' + chr(1327 - 1277), 8), nzTpIcepk0o8(chr(88 - 40) + '\157' + chr(1896 - 1846) + chr(0b100001 + 0o21) + '\063', 0o10), nzTpIcepk0o8(chr(751 - 703) + chr(111) + chr(49) + chr(0b110111) + '\063', 8), nzTpIcepk0o8(chr(48) + '\157' + chr(0b11 + 0o60) + chr(0b110100), 0o10), nzTpIcepk0o8(chr(986 - 938) + chr(9908 - 9797) + chr(0b110010) + chr(1450 - 1400) + chr(258 - 203), 0o10), nzTpIcepk0o8(chr(1314 - 1266) + '\x6f' + chr(2043 - 1991) + '\060', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1000100 + 0o53) + chr(0b101111 + 0o3) + '\063' + chr(0b100011 + 0o15), 0o10), nzTpIcepk0o8(chr(0b10110 + 0o32) + chr(111) + chr(1728 - 1677) + chr(0b110010) + '\064', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101100 + 0o3) + '\x33' + chr(48) + chr(0b110010), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110001) + chr(53), 0b1000), nzTpIcepk0o8(chr(1390 - 1342) + chr(0b1011000 + 0o27) + '\063' + chr(52) + chr(53), 34559 - 34551), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(50) + '\x37' + chr(2061 - 2007), ord("\x08")), nzTpIcepk0o8(chr(0b11001 + 0o27) + chr(0b1101111) + chr(1340 - 1289) + chr(0b110111) + chr(52), 1401 - 1393), nzTpIcepk0o8(chr(0b110000) + '\157' + '\063' + chr(0b110000) + '\x34', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b101110 + 0o101) + chr(52), 57254 - 57246), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x31' + chr(0b110000) + '\060', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(49) + chr(49) + '\x31', 57024 - 57016), nzTpIcepk0o8('\060' + '\157' + '\062' + chr(48) + chr(0b10011 + 0o35), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(50) + chr(0b101001 + 0o16) + chr(0b110010), 0o10), nzTpIcepk0o8(chr(651 - 603) + chr(0b100011 + 0o114) + '\x32' + '\060' + chr(0b110110), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + chr(0b110000 + 0o77) + chr(0b100100 + 0o21) + chr(0b110000), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b':'), chr(0b1100100) + chr(101) + chr(0b1000101 + 0o36) + '\x6f' + chr(100) + chr(0b1100101))(chr(1622 - 1505) + chr(0b1110100) + '\146' + '\055' + chr(0b110011 + 0o5)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def fim1QnMMQdOm(hXMPsSrOQzbh, JmlSMDkxjBEZ, Q5mFx5QRDr9z=nzTpIcepk0o8(chr(1579 - 1531) + chr(12243 - 12132) + '\x31', 8)):
if not suIjIS24Zkqw(JmlSMDkxjBEZ, CxSsxwk8McAE) and (not (suIjIS24Zkqw(JmlSMDkxjBEZ, wO40m0aHUhAf) and roI3spqORKae(JmlSMDkxjBEZ, roI3spqORKae(ES5oEprVxulp(b'X\xbd\x98\xf4\xaam\x849\x9c1r\x02'), '\144' + chr(0b1010000 + 0o25) + chr(0b1001010 + 0o31) + '\157' + chr(0b10101 + 0o117) + chr(10045 - 9944))('\165' + chr(0b1110100) + chr(0b1010110 + 0o20) + '\x2d' + '\070')) == nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(1791 - 1740), 0o10))):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'Y\xfd\xa8\xc8\xbe^\xa07\xbe=uQ@m\xe7h\x8a3b\x17\xbd\xe6\x1f<\xf8R\xb8\xe7\x86-\xb5\xd1\x95\xaap`&\xe2\xd0\xe3w\xfc\xfb\xda\xf1\\\xf2(\xba;{Q\x03I\xe1n\x8a'), chr(0b1100100) + chr(101) + chr(99) + chr(0b1001001 + 0o46) + chr(0b1011 + 0o131) + chr(0b1011 + 0o132))(chr(0b1110101 + 0o0) + chr(0b1000000 + 0o64) + chr(2906 - 2804) + '\x2d' + '\x38'))
if roI3spqORKae(JmlSMDkxjBEZ, roI3spqORKae(ES5oEprVxulp(b'_\xd2\xef\xd9\xe9\x1c\xa3+\xf9\x1cE{'), '\144' + '\x65' + '\x63' + chr(2030 - 1919) + chr(0b1100100) + chr(0b1 + 0o144))(chr(117) + chr(11376 - 11260) + '\146' + '\x2d' + '\070')) != roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'~\xbe\x98\x8e\xf0\\\xa5.\xbd\x04!\x00'), chr(100) + chr(0b1100101) + '\143' + '\x6f' + '\144' + '\145')(chr(13274 - 13157) + '\x74' + chr(0b1100110) + '\055' + '\x38')):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'W\xe9\xb5\xd2\xf1Z\xf2(\xba;{Q\x03I\xa8q\x8b.O\x0f\xa1\xb3\x12r\xb7F\xea\xb5\xafh\xc5\x9b\x8f\xe4m.=\xef\x9a\xe5u\xe5\xbe\xce\xff\x0e\xa51\xbc<1R\x12\\\xe5d\xc4bR'), chr(1603 - 1503) + chr(0b1100101) + chr(0b1100011) + chr(0b1101111) + chr(100) + '\x65')(chr(2431 - 2314) + chr(116) + chr(0b1100110) + chr(1817 - 1772) + '\x38') % (roI3spqORKae(JmlSMDkxjBEZ, roI3spqORKae(ES5oEprVxulp(b'_\xd2\xef\xd9\xe9\x1c\xa3+\xf9\x1cE{'), '\144' + chr(0b11 + 0o142) + '\x63' + chr(111) + chr(100) + chr(0b10110 + 0o117))(chr(0b110101 + 0o100) + '\x74' + '\x66' + chr(0b101000 + 0o5) + '\070')), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'~\xbe\x98\x8e\xf0\\\xa5.\xbd\x04!\x00'), '\x64' + chr(1546 - 1445) + chr(6858 - 6759) + '\x6f' + chr(6627 - 6527) + '\145')('\165' + '\x74' + chr(0b1000100 + 0o42) + chr(0b11000 + 0o25) + chr(0b10011 + 0o45)))))
QKdRLikedrHS = hXMPsSrOQzbh.S.dot(JmlSMDkxjBEZ.FfKOThdpoDTb) + hXMPsSrOQzbh.h3Vc_4wxEbgd
if ftfygxgFas5X(roI3spqORKae(QKdRLikedrHS, roI3spqORKae(ES5oEprVxulp(b'x\xe0\xb9\xf1\xae\x17\xe0\x19\x8e\x03)R'), chr(100) + chr(0b110110 + 0o57) + chr(99) + '\157' + chr(0b1000111 + 0o35) + '\145')(chr(0b1110101) + chr(13002 - 12886) + chr(0b1100110) + chr(0b11011 + 0o22) + '\070'))) == nzTpIcepk0o8(chr(1846 - 1798) + chr(111) + chr(0b11111 + 0o22), 8):
QKdRLikedrHS = QKdRLikedrHS[:, nDF4gVNx0u9Q.newaxis]
m0sb4Awff0yc = QKdRLikedrHS[nzTpIcepk0o8(chr(48) + '\157' + chr(0b110010), 64841 - 64833), :]
t7gRgV07Id2x = nDF4gVNx0u9Q.udtPco1xxZHr(m0sb4Awff0yc, [nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b11100 + 0o27), 8), nzTpIcepk0o8('\x30' + '\x6f' + chr(1620 - 1571), 8)])
QKdRLikedrHS = nDF4gVNx0u9Q.divide(QKdRLikedrHS, t7gRgV07Id2x)
if Q5mFx5QRDr9z:
QKdRLikedrHS = nDF4gVNx0u9Q.round(QKdRLikedrHS)
QKdRLikedrHS = QKdRLikedrHS[:nzTpIcepk0o8('\060' + chr(111) + '\062', 8), :].xqAChpcBkssb(nDF4gVNx0u9Q.int16)
kQBP9ZSunfMF = nDF4gVNx0u9Q.xWH4M7K6Qbd3((QKdRLikedrHS[nzTpIcepk0o8('\060' + chr(0b1101111) + chr(48), 0b1000), :] >= nzTpIcepk0o8(chr(935 - 887) + chr(111) + chr(475 - 427), 8)) & (QKdRLikedrHS[nzTpIcepk0o8(chr(0b1010 + 0o46) + chr(0b1101111) + chr(49), 8), :] >= nzTpIcepk0o8(chr(640 - 592) + chr(0b1101111) + chr(48), 8)) & (QKdRLikedrHS[nzTpIcepk0o8('\060' + chr(0b1101111) + chr(48), 8), :] < hXMPsSrOQzbh.dH3vcKdvgBu0) & (QKdRLikedrHS[nzTpIcepk0o8(chr(0b110000) + chr(9835 - 9724) + chr(1652 - 1603), 8), :] < hXMPsSrOQzbh.PaEBmun9J0YJ))[nzTpIcepk0o8(chr(48) + chr(111) + '\x30', 8)]
gTJczuG2gUhu = nDF4gVNx0u9Q.UmwwEp7MzR6q([hXMPsSrOQzbh.PaEBmun9J0YJ, hXMPsSrOQzbh.dH3vcKdvgBu0])
gTJczuG2gUhu[QKdRLikedrHS[nzTpIcepk0o8(chr(0b110 + 0o52) + chr(111) + '\061', 8), kQBP9ZSunfMF], QKdRLikedrHS[nzTpIcepk0o8('\x30' + chr(0b1101111) + '\060', 8), kQBP9ZSunfMF]] = m0sb4Awff0yc[kQBP9ZSunfMF]
return Ctd7ihpXT1E5(gTJczuG2gUhu, frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'_\xd2\xef\xd9\xe9\x1c\xa3+\xf9\x1cE{'), chr(100) + chr(0b1000 + 0o135) + chr(0b1100011) + '\x6f' + chr(3058 - 2958) + chr(0b100010 + 0o103))(chr(117) + '\x74' + chr(0b1100110) + chr(45) + '\x38'))) |
BerkeleyAutomation/perception | perception/orthographic_intrinsics.py | OrthographicIntrinsics.deproject | def deproject(self, depth_image):
"""Deprojects a DepthImage into a PointCloud.
Parameters
----------
depth_image : :obj:`DepthImage`
The 2D depth image to projet into a point cloud.
Returns
-------
:obj:`autolab_core.PointCloud`
A 3D point cloud created from the depth image.
Raises
------
ValueError
If depth_image is not a valid DepthImage in the same reference frame
as the camera.
"""
# check valid input
if not isinstance(depth_image, DepthImage):
raise ValueError('Must provide DepthImage object for projection')
if depth_image.frame != self._frame:
raise ValueError('Cannot deproject points in frame %s from camera with frame %s' %(depth_image.frame, self._frame))
# create homogeneous pixels
row_indices = np.arange(depth_image.height)
col_indices = np.arange(depth_image.width)
pixel_grid = np.meshgrid(col_indices, row_indices)
pixels = np.c_[pixel_grid[0].flatten(), pixel_grid[1].flatten()].T
depth_data = depth_image.data.flatten()
pixels_homog = np.r_[pixels, depth_data.reshape(1, depth_data.shape[0])]
# deproject
points_3d = np.linalg.inv(self.S).dot(pixels_homog - np.tile(self.t.reshape(3,1), [1, pixels_homog.shape[1]]))
return PointCloud(data=points_3d, frame=self._frame) | python | def deproject(self, depth_image):
"""Deprojects a DepthImage into a PointCloud.
Parameters
----------
depth_image : :obj:`DepthImage`
The 2D depth image to projet into a point cloud.
Returns
-------
:obj:`autolab_core.PointCloud`
A 3D point cloud created from the depth image.
Raises
------
ValueError
If depth_image is not a valid DepthImage in the same reference frame
as the camera.
"""
# check valid input
if not isinstance(depth_image, DepthImage):
raise ValueError('Must provide DepthImage object for projection')
if depth_image.frame != self._frame:
raise ValueError('Cannot deproject points in frame %s from camera with frame %s' %(depth_image.frame, self._frame))
# create homogeneous pixels
row_indices = np.arange(depth_image.height)
col_indices = np.arange(depth_image.width)
pixel_grid = np.meshgrid(col_indices, row_indices)
pixels = np.c_[pixel_grid[0].flatten(), pixel_grid[1].flatten()].T
depth_data = depth_image.data.flatten()
pixels_homog = np.r_[pixels, depth_data.reshape(1, depth_data.shape[0])]
# deproject
points_3d = np.linalg.inv(self.S).dot(pixels_homog - np.tile(self.t.reshape(3,1), [1, pixels_homog.shape[1]]))
return PointCloud(data=points_3d, frame=self._frame) | [
"def",
"deproject",
"(",
"self",
",",
"depth_image",
")",
":",
"# check valid input",
"if",
"not",
"isinstance",
"(",
"depth_image",
",",
"DepthImage",
")",
":",
"raise",
"ValueError",
"(",
"'Must provide DepthImage object for projection'",
")",
"if",
"depth_image",
".",
"frame",
"!=",
"self",
".",
"_frame",
":",
"raise",
"ValueError",
"(",
"'Cannot deproject points in frame %s from camera with frame %s'",
"%",
"(",
"depth_image",
".",
"frame",
",",
"self",
".",
"_frame",
")",
")",
"# create homogeneous pixels",
"row_indices",
"=",
"np",
".",
"arange",
"(",
"depth_image",
".",
"height",
")",
"col_indices",
"=",
"np",
".",
"arange",
"(",
"depth_image",
".",
"width",
")",
"pixel_grid",
"=",
"np",
".",
"meshgrid",
"(",
"col_indices",
",",
"row_indices",
")",
"pixels",
"=",
"np",
".",
"c_",
"[",
"pixel_grid",
"[",
"0",
"]",
".",
"flatten",
"(",
")",
",",
"pixel_grid",
"[",
"1",
"]",
".",
"flatten",
"(",
")",
"]",
".",
"T",
"depth_data",
"=",
"depth_image",
".",
"data",
".",
"flatten",
"(",
")",
"pixels_homog",
"=",
"np",
".",
"r_",
"[",
"pixels",
",",
"depth_data",
".",
"reshape",
"(",
"1",
",",
"depth_data",
".",
"shape",
"[",
"0",
"]",
")",
"]",
"# deproject",
"points_3d",
"=",
"np",
".",
"linalg",
".",
"inv",
"(",
"self",
".",
"S",
")",
".",
"dot",
"(",
"pixels_homog",
"-",
"np",
".",
"tile",
"(",
"self",
".",
"t",
".",
"reshape",
"(",
"3",
",",
"1",
")",
",",
"[",
"1",
",",
"pixels_homog",
".",
"shape",
"[",
"1",
"]",
"]",
")",
")",
"return",
"PointCloud",
"(",
"data",
"=",
"points_3d",
",",
"frame",
"=",
"self",
".",
"_frame",
")"
] | Deprojects a DepthImage into a PointCloud.
Parameters
----------
depth_image : :obj:`DepthImage`
The 2D depth image to projet into a point cloud.
Returns
-------
:obj:`autolab_core.PointCloud`
A 3D point cloud created from the depth image.
Raises
------
ValueError
If depth_image is not a valid DepthImage in the same reference frame
as the camera. | [
"Deprojects",
"a",
"DepthImage",
"into",
"a",
"PointCloud",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/orthographic_intrinsics.py#L193-L228 | train | Deprojects a DepthImage into a PointCloud. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJH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NQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\060' + chr(111) + chr(0b100001 + 0o21) + chr(0b111 + 0o60) + chr(0b100010 + 0o23), 50209 - 50201), nzTpIcepk0o8('\060' + '\157' + chr(51) + '\066' + chr(564 - 515), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x32' + chr(1899 - 1849) + '\060', ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(1082 - 1032) + chr(0b110000) + chr(0b100010 + 0o21), 49192 - 49184), nzTpIcepk0o8('\060' + chr(0b1100101 + 0o12) + '\x31' + chr(50) + chr(1721 - 1669), 0o10), nzTpIcepk0o8('\x30' + '\157' + '\066' + chr(0b110 + 0o52), 2810 - 2802), nzTpIcepk0o8(chr(0b110000) + chr(0b101001 + 0o106) + '\x37' + chr(436 - 384), 0b1000), nzTpIcepk0o8(chr(0b11110 + 0o22) + chr(0b11010 + 0o125) + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b10 + 0o155) + chr(1986 - 1935) + '\x31' + chr(0b100011 + 0o17), 63328 - 63320), nzTpIcepk0o8(chr(0b100000 + 0o20) + '\157' + '\x31' + '\067' + '\064', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b111011 + 0o64) + '\063' + '\x35' + chr(1452 - 1401), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + '\x33' + '\x30' + chr(0b110100), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(49) + chr(0b110111) + chr(49), 38866 - 38858), nzTpIcepk0o8('\060' + chr(0b111 + 0o150) + '\062' + '\x31', 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(50) + chr(0b110111) + chr(0b11000 + 0o32), ord("\x08")), nzTpIcepk0o8(chr(0b101010 + 0o6) + '\157' + chr(168 - 118) + '\x35' + '\x37', 0b1000), nzTpIcepk0o8('\060' + chr(0b110111 + 0o70) + chr(50) + '\x32' + chr(0b11101 + 0o24), 34990 - 34982), nzTpIcepk0o8(chr(936 - 888) + '\x6f' + '\061' + chr(51) + chr(605 - 555), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + '\062' + chr(0b110001) + chr(0b110110), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b11010 + 0o30) + chr(1576 - 1523) + '\x31', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(49) + '\060' + chr(0b10010 + 0o42), 62467 - 62459), nzTpIcepk0o8(chr(0b100001 + 0o17) + chr(0b110010 + 0o75) + chr(2455 - 2404) + chr(48) + chr(525 - 472), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x33' + chr(0b110000 + 0o7) + chr(0b101011 + 0o6), 19105 - 19097), nzTpIcepk0o8(chr(0b100001 + 0o17) + chr(111) + chr(1550 - 1500) + chr(0b110110) + chr(52), 0o10), nzTpIcepk0o8(chr(0b11011 + 0o25) + '\x6f' + '\062' + chr(2227 - 2175), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110101) + chr(2119 - 2068), 0o10), nzTpIcepk0o8(chr(0b10 + 0o56) + chr(0b0 + 0o157) + '\062' + '\x36' + chr(0b110110), 5469 - 5461), nzTpIcepk0o8('\060' + chr(11703 - 11592) + '\x31' + '\x35', 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1546 - 1495) + chr(54) + chr(49), 8), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x33' + '\x35' + chr(48), ord("\x08")), nzTpIcepk0o8(chr(270 - 222) + '\157' + chr(0b110101) + chr(0b110100), 24653 - 24645), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(1836 - 1787) + '\x32' + '\x36', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(5434 - 5323) + '\063' + chr(0b1101 + 0o43) + '\067', ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b10101 + 0o34) + chr(0b11101 + 0o32) + chr(53), 32126 - 32118), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(111) + '\061' + '\061' + chr(360 - 310), ord("\x08")), nzTpIcepk0o8(chr(0b11011 + 0o25) + chr(7047 - 6936) + '\062' + '\x30' + chr(0b110110 + 0o0), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b1011 + 0o47) + '\x35' + chr(49), 8), nzTpIcepk0o8(chr(627 - 579) + chr(111) + chr(0b110001) + chr(0b110001 + 0o6) + chr(55), 0o10), nzTpIcepk0o8(chr(958 - 910) + chr(0b111110 + 0o61) + chr(0b110101) + '\x33', 8), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(2486 - 2435) + chr(54) + chr(77 - 24), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(5149 - 5038) + chr(158 - 105) + chr(0b10101 + 0o33), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x93'), chr(0b11111 + 0o105) + chr(101) + chr(0b100 + 0o137) + chr(5175 - 5064) + chr(0b1100100) + chr(8033 - 7932))(chr(117) + '\164' + chr(0b1100110) + chr(0b0 + 0o55) + chr(56)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def J_jiksZJgi2H(hXMPsSrOQzbh, eUW2JKqvx8Cg):
if not suIjIS24Zkqw(eUW2JKqvx8Cg, Ctd7ihpXT1E5):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xf0\x84\xe3\xf7t@Nn\xbc\x15\x8f\xa1YU\xdf\xdf\xe52\xc7\xc4%\xa2\x9c\x94{I\xdch\x92\x9c\x0c0\xa8\x0fj\xf6\xdb\x10A\x90\xde\x85\xf9\xec:'), chr(100) + '\x65' + '\x63' + chr(1828 - 1717) + chr(100) + '\x65')('\x75' + chr(116) + '\x66' + chr(45) + chr(0b110111 + 0o1)))
if roI3spqORKae(eUW2JKqvx8Cg, roI3spqORKae(ES5oEprVxulp(b'\xf6\xab\xa4\xe6#\x02Mr\xfb4\xbf\x8b'), chr(0b1011001 + 0o13) + chr(7467 - 7366) + chr(99) + chr(5484 - 5373) + chr(6486 - 6386) + chr(0b1100101))('\x75' + chr(0b1110100) + chr(0b1100110) + chr(45) + chr(0b101101 + 0o13))) != roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xd7\xc7\xd3\xb1:BKw\xbf,\xdb\xf0'), chr(0b101110 + 0o66) + chr(0b10100 + 0o121) + chr(0b1100011) + chr(6412 - 6301) + chr(0b1100001 + 0o3) + chr(0b1011101 + 0o10))(chr(0b100010 + 0o123) + chr(0b1 + 0o163) + chr(0b101111 + 0o67) + '\x2d' + '\070')):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xfe\x90\xfe\xed;D\x1ce\xaf\x0c\x99\xab\x13t\xd9\xdb\xb1*\xe1\xc0*\xb1\x8a\x94}E\x96k\x83\x89A3\xe7X9\xa6\xcf\rD\x98\x9d\x92\xf1\xee1B]!\xbd\x15\x9f\xacYw\xc8\xce\xfc?\xae\x8c7'), chr(0b1100100) + chr(101) + chr(782 - 683) + chr(0b1101111) + chr(3707 - 3607) + chr(101))('\x75' + chr(0b1110100) + chr(102) + chr(0b101101) + chr(402 - 346)) % (roI3spqORKae(eUW2JKqvx8Cg, roI3spqORKae(ES5oEprVxulp(b'\xf6\xab\xa4\xe6#\x02Mr\xfb4\xbf\x8b'), chr(100) + '\145' + chr(5356 - 5257) + chr(0b1101111) + chr(0b1100100) + chr(101))(chr(117) + '\x74' + '\x66' + '\x2d' + chr(1991 - 1935))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xd7\xc7\xd3\xb1:BKw\xbf,\xdb\xf0'), chr(0b1100100) + '\145' + chr(0b111110 + 0o45) + chr(0b101 + 0o152) + '\x64' + '\x65')('\165' + chr(0b1110100) + chr(0b1100110) + '\x2d' + chr(56)))))
XFXnPDHgOrd6 = nDF4gVNx0u9Q.chmI_GMU_sEi(eUW2JKqvx8Cg.PaEBmun9J0YJ)
v4p9H1yjJ0Df = nDF4gVNx0u9Q.chmI_GMU_sEi(eUW2JKqvx8Cg.dH3vcKdvgBu0)
WihSr_mQ61Ah = nDF4gVNx0u9Q.meshgrid(v4p9H1yjJ0Df, XFXnPDHgOrd6)
FLkBAUyMM7qS = nDF4gVNx0u9Q.c_[WihSr_mQ61Ah[nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110000), 57803 - 57795)].flatten(), WihSr_mQ61Ah[nzTpIcepk0o8(chr(270 - 222) + chr(111) + chr(0b1111 + 0o42), 8)].flatten()].hq6XE4_Nhd6R
gTJczuG2gUhu = eUW2JKqvx8Cg.data.wozqDwllRa_T()
ta1xAewfAaP0 = nDF4gVNx0u9Q.r_[FLkBAUyMM7qS, gTJczuG2gUhu.reshape(nzTpIcepk0o8(chr(0b110000) + chr(0b1010000 + 0o37) + chr(1933 - 1884), 8), gTJczuG2gUhu.lhbM092AFW8f[nzTpIcepk0o8(chr(0b101011 + 0o5) + chr(111) + '\x30', 8)])]
fa7fk2hi9eEl = nDF4gVNx0u9Q.linalg.inv(hXMPsSrOQzbh.S).dot(ta1xAewfAaP0 - nDF4gVNx0u9Q.udtPco1xxZHr(hXMPsSrOQzbh.t.reshape(nzTpIcepk0o8(chr(0b110 + 0o52) + chr(0b1101111) + chr(0b100100 + 0o17), 0o10), nzTpIcepk0o8(chr(0b101011 + 0o5) + '\x6f' + '\x31', 8)), [nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\061', 8), ta1xAewfAaP0.lhbM092AFW8f[nzTpIcepk0o8('\x30' + chr(111) + '\061', 8)]]))
return CxSsxwk8McAE(data=fa7fk2hi9eEl, frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xd7\xc7\xd3\xb1:BKw\xbf,\xdb\xf0'), chr(9595 - 9495) + chr(2398 - 2297) + chr(99) + chr(111) + '\144' + '\145')('\x75' + '\164' + chr(6121 - 6019) + '\055' + chr(1469 - 1413)))) |
BerkeleyAutomation/perception | perception/orthographic_intrinsics.py | OrthographicIntrinsics.deproject_pixel | def deproject_pixel(self, depth, pixel):
"""Deprojects a single pixel with a given depth into a 3D point.
Parameters
----------
depth : float
The depth value at the given pixel location.
pixel : :obj:`autolab_core.Point`
A 2D point representing the pixel's location in the camera image.
Returns
-------
:obj:`autolab_core.Point`
The projected 3D point.
Raises
------
ValueError
If pixel is not a valid 2D Point in the same reference frame
as the camera.
"""
if not isinstance(pixel, Point) and not pixel.dim == 2:
raise ValueError('Must provide 2D Point object for pixel projection')
if pixel.frame != self._frame:
raise ValueError('Cannot deproject pixel in frame %s from camera with frame %s' %(pixel.frame, self._frame))
point = np.r_[pixel.data, depth]
point_3d = np.linalg.inv(self.S).dot(point - self.t)
return Point(data=point_3d, frame=self._frame) | python | def deproject_pixel(self, depth, pixel):
"""Deprojects a single pixel with a given depth into a 3D point.
Parameters
----------
depth : float
The depth value at the given pixel location.
pixel : :obj:`autolab_core.Point`
A 2D point representing the pixel's location in the camera image.
Returns
-------
:obj:`autolab_core.Point`
The projected 3D point.
Raises
------
ValueError
If pixel is not a valid 2D Point in the same reference frame
as the camera.
"""
if not isinstance(pixel, Point) and not pixel.dim == 2:
raise ValueError('Must provide 2D Point object for pixel projection')
if pixel.frame != self._frame:
raise ValueError('Cannot deproject pixel in frame %s from camera with frame %s' %(pixel.frame, self._frame))
point = np.r_[pixel.data, depth]
point_3d = np.linalg.inv(self.S).dot(point - self.t)
return Point(data=point_3d, frame=self._frame) | [
"def",
"deproject_pixel",
"(",
"self",
",",
"depth",
",",
"pixel",
")",
":",
"if",
"not",
"isinstance",
"(",
"pixel",
",",
"Point",
")",
"and",
"not",
"pixel",
".",
"dim",
"==",
"2",
":",
"raise",
"ValueError",
"(",
"'Must provide 2D Point object for pixel projection'",
")",
"if",
"pixel",
".",
"frame",
"!=",
"self",
".",
"_frame",
":",
"raise",
"ValueError",
"(",
"'Cannot deproject pixel in frame %s from camera with frame %s'",
"%",
"(",
"pixel",
".",
"frame",
",",
"self",
".",
"_frame",
")",
")",
"point",
"=",
"np",
".",
"r_",
"[",
"pixel",
".",
"data",
",",
"depth",
"]",
"point_3d",
"=",
"np",
".",
"linalg",
".",
"inv",
"(",
"self",
".",
"S",
")",
".",
"dot",
"(",
"point",
"-",
"self",
".",
"t",
")",
"return",
"Point",
"(",
"data",
"=",
"point_3d",
",",
"frame",
"=",
"self",
".",
"_frame",
")"
] | Deprojects a single pixel with a given depth into a 3D point.
Parameters
----------
depth : float
The depth value at the given pixel location.
pixel : :obj:`autolab_core.Point`
A 2D point representing the pixel's location in the camera image.
Returns
-------
:obj:`autolab_core.Point`
The projected 3D point.
Raises
------
ValueError
If pixel is not a valid 2D Point in the same reference frame
as the camera. | [
"Deprojects",
"a",
"single",
"pixel",
"with",
"a",
"given",
"depth",
"into",
"a",
"3D",
"point",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/orthographic_intrinsics.py#L254-L283 | train | Deprojects a single pixel with a given depth into a 3D point. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3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t,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(1417 - 1306) + chr(50) + chr(0b110101) + chr(589 - 541), ord("\x08")), nzTpIcepk0o8(chr(0b100110 + 0o12) + chr(5421 - 5310) + chr(51) + chr(0b110011) + chr(50), 13998 - 13990), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(0b1101001 + 0o6) + '\x32' + '\x37' + chr(0b110101), 0o10), nzTpIcepk0o8('\060' + chr(111) + chr(0b11100 + 0o26) + chr(55) + '\x35', 8), nzTpIcepk0o8('\x30' + chr(111) + '\062' + chr(2261 - 2211) + '\x32', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110011) + chr(0b110011) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(0b1100 + 0o44) + chr(111) + '\062' + chr(2160 - 2105) + chr(0b10110 + 0o32), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(50) + '\067' + chr(0b110010), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + '\061' + '\061' + '\x37', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(12138 - 12027) + chr(2260 - 2207) + chr(0b110011), 20198 - 20190), nzTpIcepk0o8(chr(48) + chr(8226 - 8115) + chr(1439 - 1388) + chr(0b110011) + chr(2497 - 2447), 8), nzTpIcepk0o8(chr(382 - 334) + chr(0b1101111) + chr(0b1111 + 0o44) + '\065' + '\x35', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(245 - 190), ord("\x08")), nzTpIcepk0o8(chr(270 - 222) + chr(111) + chr(2280 - 2230) + chr(49) + chr(54), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110010) + chr(55) + chr(0b1010 + 0o55), 41856 - 41848), nzTpIcepk0o8(chr(0b11110 + 0o22) + chr(8162 - 8051) + '\x31' + '\x35' + '\063', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(55) + chr(2127 - 2077), 63713 - 63705), nzTpIcepk0o8('\060' + '\157' + '\x32' + chr(897 - 845) + chr(51), 0o10), nzTpIcepk0o8('\x30' + chr(0b1 + 0o156) + chr(0b100001 + 0o20) + '\x30' + '\x33', ord("\x08")), nzTpIcepk0o8('\060' + chr(0b101000 + 0o107) + '\063' + chr(0b110010 + 0o2), 0o10), nzTpIcepk0o8('\060' + chr(7587 - 7476) + '\x35', 0o10), nzTpIcepk0o8(chr(0b110 + 0o52) + chr(0b1101111) + chr(50) + '\061' + chr(0b110110), 8), nzTpIcepk0o8('\060' + chr(11448 - 11337) + '\x32' + chr(2159 - 2109) + chr(0b100101 + 0o16), 0o10), nzTpIcepk0o8(chr(2256 - 2208) + '\157' + '\062' + chr(1129 - 1075), 0o10), nzTpIcepk0o8(chr(0b10001 + 0o37) + '\157' + chr(0b110010) + chr(0b110111) + chr(51), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + '\063' + '\067' + chr(0b110101), 15637 - 15629), nzTpIcepk0o8(chr(48) + '\157' + '\062' + chr(1813 - 1758), 0o10), nzTpIcepk0o8('\060' + '\157' + '\066' + chr(0b110011), ord("\x08")), nzTpIcepk0o8(chr(0b100100 + 0o14) + chr(111) + chr(0b1011 + 0o47) + '\060' + chr(0b10000 + 0o42), 5678 - 5670), nzTpIcepk0o8(chr(48) + chr(111) + '\063' + chr(0b110011) + '\x32', 8), nzTpIcepk0o8('\060' + '\157' + chr(1658 - 1608) + chr(0b110001) + chr(0b110100), 0o10), nzTpIcepk0o8('\060' + chr(0b1100110 + 0o11) + chr(0b10110 + 0o33) + '\x37', ord("\x08")), nzTpIcepk0o8(chr(1440 - 1392) + chr(111) + '\x32' + chr(52) + '\x35', ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1100010 + 0o15) + chr(1574 - 1525) + chr(0b110101) + chr(51), 8), nzTpIcepk0o8('\060' + chr(0b10110 + 0o131) + chr(0b110011) + '\x35', 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110101) + chr(2220 - 2165), ord("\x08")), nzTpIcepk0o8(chr(0b110 + 0o52) + '\157' + '\061' + chr(2117 - 2069) + chr(0b10111 + 0o31), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(5486 - 5375) + chr(0b11110 + 0o23) + chr(53) + chr(54), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110101) + '\x31', 28923 - 28915), nzTpIcepk0o8(chr(0b10111 + 0o31) + chr(111) + chr(1069 - 1018) + chr(0b100100 + 0o22) + '\x34', 51679 - 51671)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + '\157' + chr(2323 - 2270) + chr(0b100001 + 0o17), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x86'), chr(0b1100100) + chr(0b1100101) + '\143' + chr(111) + '\x64' + chr(101))('\165' + '\164' + '\146' + '\055' + chr(1421 - 1365)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def l8LbT7NiHFNm(hXMPsSrOQzbh, UH0YjwuI_XzX, UhW_548DGa2e):
if not suIjIS24Zkqw(UhW_548DGa2e, wO40m0aHUhAf) and (not roI3spqORKae(UhW_548DGa2e, roI3spqORKae(ES5oEprVxulp(b'\xe4\xef\xfe\xf5\xa6\x9a\xee\xdb\x1bN\xb9\xdb'), '\144' + chr(101) + chr(6743 - 6644) + '\157' + chr(4868 - 4768) + chr(154 - 53))(chr(0b1110101) + '\164' + '\146' + chr(45) + chr(0b110010 + 0o6))) == nzTpIcepk0o8('\060' + '\x6f' + '\x32', 2983 - 2975)):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b"\xe5\xaf\xce\xc9\xb2\xa9\xca\xd59B\xbe\x88'\xbc\xfbKj\xcc*rq\xae\xfct\xd1\x98tG\xa2\xbc\xe3}\x85\x1btW%\x02\t\x84\xda\xb5\xd7\xd8\xf1\xad\xd1\xd5!"), chr(0b100110 + 0o76) + chr(0b1100101) + chr(0b1011000 + 0o13) + '\x6f' + chr(0b1100100) + chr(101))(chr(117) + chr(0b1110100) + chr(102) + '\055' + chr(0b100011 + 0o25)))
if roI3spqORKae(UhW_548DGa2e, roI3spqORKae(ES5oEprVxulp(b'\xe3\x80\x89\xd8\xe5\xeb\xc9\xc9~c\x8e\xa2'), chr(0b1100100) + chr(0b1010100 + 0o21) + '\143' + chr(111) + '\144' + '\145')(chr(0b1010110 + 0o37) + chr(0b1110100) + chr(0b101011 + 0o73) + chr(74 - 29) + chr(0b11000 + 0o40))) != roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xc2\xec\xfe\x8f\xfc\xab\xcf\xcc:{\xea\xd9'), chr(3508 - 3408) + chr(0b1100001 + 0o4) + '\x63' + '\x6f' + chr(0b1100100) + chr(101))(chr(0b1000000 + 0o65) + chr(116) + chr(0b1001101 + 0o31) + '\x2d' + chr(0b111000))):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xeb\xbb\xd3\xd3\xfd\xad\x98\xde*[\xa8\x82m\xeb\xdc\x1f\x1a\xd3*d`\xe2\xb3\x7f\xd5\xddqA\xe3\xb7\xe9/\x80\x18=I2\x01D\xd4\xcb\xbb\xd0\xd8\xe0\xb8\x98\xcd&_\xb2\xcda\xfc\xde\x06_\x83fo'), chr(0b1100100) + chr(9366 - 9265) + chr(0b1100011) + chr(2378 - 2267) + '\x64' + chr(773 - 672))('\x75' + chr(0b1110100) + chr(0b1100110) + chr(45) + chr(0b110100 + 0o4)) % (roI3spqORKae(UhW_548DGa2e, roI3spqORKae(ES5oEprVxulp(b'\xe3\x80\x89\xd8\xe5\xeb\xc9\xc9~c\x8e\xa2'), chr(5077 - 4977) + chr(0b1010010 + 0o23) + chr(0b1100011) + '\x6f' + chr(0b1100100 + 0o0) + chr(101))('\165' + chr(116) + '\x66' + '\x2d' + '\x38')), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xc2\xec\xfe\x8f\xfc\xab\xcf\xcc:{\xea\xd9'), '\x64' + '\145' + '\143' + chr(0b110010 + 0o75) + '\144' + '\145')(chr(13043 - 12926) + chr(0b0 + 0o164) + chr(3618 - 3516) + chr(45) + chr(0b10100 + 0o44)))))
l1u4whQWoPEl = nDF4gVNx0u9Q.r_[UhW_548DGa2e.FfKOThdpoDTb, UH0YjwuI_XzX]
ARzRUBo8Ghnb = nDF4gVNx0u9Q.linalg.inv(hXMPsSrOQzbh.S).dot(l1u4whQWoPEl - hXMPsSrOQzbh.h3Vc_4wxEbgd)
return wO40m0aHUhAf(data=ARzRUBo8Ghnb, frame=roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xc2\xec\xfe\x8f\xfc\xab\xcf\xcc:{\xea\xd9'), chr(100) + chr(0b1100101) + chr(0b1100000 + 0o3) + '\157' + chr(0b0 + 0o144) + chr(0b1100101))(chr(0b1110101) + '\x74' + '\x66' + '\x2d' + chr(94 - 38)))) |
BerkeleyAutomation/perception | perception/orthographic_intrinsics.py | OrthographicIntrinsics.save | def save(self, filename):
"""Save the CameraIntrinsics object to a .intr file.
Parameters
----------
filename : :obj:`str`
The .intr file to save the object to.
Raises
------
ValueError
If filename does not have the .intr extension.
"""
file_root, file_ext = os.path.splitext(filename)
if file_ext.lower() != INTR_EXTENSION:
raise ValueError('Extension %s not supported for OrhtographicIntrinsics. Must be stored with extension %s' %(file_ext, INTR_EXTENSION))
camera_intr_dict = copy.deepcopy(self.__dict__)
f = open(filename, 'w')
json.dump(camera_intr_dict, f)
f.close() | python | def save(self, filename):
"""Save the CameraIntrinsics object to a .intr file.
Parameters
----------
filename : :obj:`str`
The .intr file to save the object to.
Raises
------
ValueError
If filename does not have the .intr extension.
"""
file_root, file_ext = os.path.splitext(filename)
if file_ext.lower() != INTR_EXTENSION:
raise ValueError('Extension %s not supported for OrhtographicIntrinsics. Must be stored with extension %s' %(file_ext, INTR_EXTENSION))
camera_intr_dict = copy.deepcopy(self.__dict__)
f = open(filename, 'w')
json.dump(camera_intr_dict, f)
f.close() | [
"def",
"save",
"(",
"self",
",",
"filename",
")",
":",
"file_root",
",",
"file_ext",
"=",
"os",
".",
"path",
".",
"splitext",
"(",
"filename",
")",
"if",
"file_ext",
".",
"lower",
"(",
")",
"!=",
"INTR_EXTENSION",
":",
"raise",
"ValueError",
"(",
"'Extension %s not supported for OrhtographicIntrinsics. Must be stored with extension %s'",
"%",
"(",
"file_ext",
",",
"INTR_EXTENSION",
")",
")",
"camera_intr_dict",
"=",
"copy",
".",
"deepcopy",
"(",
"self",
".",
"__dict__",
")",
"f",
"=",
"open",
"(",
"filename",
",",
"'w'",
")",
"json",
".",
"dump",
"(",
"camera_intr_dict",
",",
"f",
")",
"f",
".",
"close",
"(",
")"
] | Save the CameraIntrinsics object to a .intr file.
Parameters
----------
filename : :obj:`str`
The .intr file to save the object to.
Raises
------
ValueError
If filename does not have the .intr extension. | [
"Save",
"the",
"CameraIntrinsics",
"object",
"to",
"a",
".",
"intr",
"file",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/orthographic_intrinsics.py#L285-L305 | train | Save the camera intrinsics object to a. intr file. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZ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dkIpFeYozM,MdkNqd1bagO6,QNQS9e6tJqMV,typojWN5Phrq,gufQJgTAhMnI,uPAcezIXzQNA,i739myaCTbWD,AtYHTsImz86v,pWZq9QOaZbhU,lI5UiuqoXdKZ,qZ4DivK_Doaa,znjnJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(6314 - 6203) + chr(50) + chr(0b110000), 0o10), nzTpIcepk0o8(chr(48) + '\157' + chr(53) + '\x37', ord("\x08")), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(0b1101111) + chr(0b110011) + '\x36' + '\x34', 0o10), nzTpIcepk0o8('\060' + '\157' + '\x33' + '\061' + chr(2158 - 2110), 43895 - 43887), nzTpIcepk0o8(chr(48) + '\x6f' + '\x32' + chr(49) + '\x33', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x33' + chr(0b101110 + 0o5) + chr(0b110011), 57159 - 57151), nzTpIcepk0o8('\060' + '\157' + '\x32' + chr(0b11110 + 0o31) + '\x35', 7134 - 7126), nzTpIcepk0o8(chr(377 - 329) + chr(0b101001 + 0o106) + '\063' + chr(0b110111) + '\067', ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(0b110011) + '\060' + chr(0b11 + 0o61), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110010) + '\065' + chr(0b110100), 51439 - 51431), nzTpIcepk0o8('\x30' + '\x6f' + chr(51) + chr(0b110000), ord("\x08")), nzTpIcepk0o8(chr(1436 - 1388) + chr(111) + chr(50) + chr(1812 - 1760) + chr(413 - 364), 35254 - 35246), nzTpIcepk0o8(chr(0b110000) + chr(0b111110 + 0o61) + chr(0b10100 + 0o36) + '\x34' + '\060', 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(49) + '\065' + chr(0b110001), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + '\x33' + '\x33' + chr(0b110010), 21082 - 21074), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(55) + '\x36', 27441 - 27433), nzTpIcepk0o8(chr(0b11100 + 0o24) + chr(0b1101111) + chr(0b1110 + 0o43) + '\064' + chr(0b110110), 0o10), nzTpIcepk0o8('\060' + chr(111) + chr(0b110111) + '\063', 28554 - 28546), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(1205 - 1156) + chr(774 - 723) + chr(0b110010), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x31' + chr(2587 - 2535) + '\067', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b110110 + 0o71) + chr(51) + chr(0b100101 + 0o20), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110011) + chr(0b110001) + chr(0b110000), 8), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x31' + chr(0b110100) + '\x35', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x31' + '\x34' + '\060', 0b1000), nzTpIcepk0o8('\060' + chr(111) + chr(2133 - 2082) + '\066', 37012 - 37004), nzTpIcepk0o8('\060' + chr(10470 - 10359) + '\x36' + chr(0b1010 + 0o47), 0b1000), nzTpIcepk0o8(chr(48) + chr(1838 - 1727) + chr(1167 - 1116) + chr(0b110101) + chr(745 - 692), 23727 - 23719), nzTpIcepk0o8('\060' + chr(984 - 873) + chr(0b101 + 0o55) + '\063' + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(7550 - 7439) + chr(315 - 265) + chr(0b101101 + 0o4) + chr(55), ord("\x08")), nzTpIcepk0o8(chr(0b101110 + 0o2) + '\157' + '\x35', 0o10), nzTpIcepk0o8('\x30' + '\x6f' + '\061' + chr(169 - 121) + chr(1769 - 1714), 0b1000), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(0b1011010 + 0o25) + '\062' + '\x34' + chr(49), 8), nzTpIcepk0o8(chr(0b11100 + 0o24) + chr(1767 - 1656) + chr(0b10 + 0o60) + chr(55) + '\064', 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(1562 - 1512) + chr(2671 - 2616) + '\065', 8), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1010 - 961) + chr(344 - 295) + chr(0b110011), 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(51) + chr(1689 - 1635) + '\064', 8), nzTpIcepk0o8('\x30' + '\x6f' + chr(1801 - 1752) + chr(2371 - 2320) + chr(0b110011), 0o10), nzTpIcepk0o8(chr(994 - 946) + chr(0b1101111) + chr(0b1111 + 0o43) + chr(1932 - 1877) + '\062', 0b1000), nzTpIcepk0o8('\x30' + chr(6542 - 6431) + '\x31' + chr(51) + chr(0b10100 + 0o37), 8), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\067' + '\x35', 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(77 - 29) + chr(0b1101111) + '\065' + '\060', ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'>'), chr(0b1100100) + chr(3296 - 3195) + chr(0b1100011) + chr(111) + chr(100) + '\145')(chr(0b1010010 + 0o43) + chr(0b1011 + 0o151) + '\146' + '\055' + chr(618 - 562)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def mwgZMvWSpAHg(hXMPsSrOQzbh, FxZHtXEolYsL):
(cI016RJtE0ok, PGps9Hfk1I5F) = aHUqKstZLeS6.path.nKnjsA3UsXpY(FxZHtXEolYsL)
if roI3spqORKae(PGps9Hfk1I5F, roI3spqORKae(ES5oEprVxulp(b'HA\xcc\x8d\xc5\x8c\xf0\xa5\xa0\xe5J\xd5'), chr(6928 - 6828) + chr(6564 - 6463) + chr(0b110000 + 0o63) + '\x6f' + '\144' + '\145')(chr(117) + chr(116) + chr(102) + chr(0b10010 + 0o33) + chr(56)))() != afMU6s1_k7vy:
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'UW\x80\xad\xe5\xa8\xd4\x90\xaa\x8c=\xd2\x80\x07\xb5JFH/\x17m\xa7\x17\x14{U\xcd\xf9\xe0wg\xee\xce\xd5?\x9b<\xc8:MxF\x97\x81\xe5\xaf\xcf\x96\xaa\xdfq\xc2\xd3G\xfas\x13H.G\x7f\xadE\x13j^\x9f\xfa\xeb%0\xc8\xc8\xd5k\x91#\xce>ScF\x9b\xa6\xab\xfe\xce'), chr(0b1100100) + chr(0b100 + 0o141) + chr(2714 - 2615) + chr(0b1101111) + chr(0b1010101 + 0o17) + chr(0b1100100 + 0o1))(chr(10389 - 10272) + chr(12809 - 12693) + chr(102) + chr(0b100011 + 0o12) + chr(0b10111 + 0o41)) % (PGps9Hfk1I5F, afMU6s1_k7vy))
iVOYvYr6UBaP = aZTCj4v5QdfO.deepcopy(hXMPsSrOQzbh.vN7a1CEarTrT)
_R8IKF5IwAfX = DnU3Rq9N5ala(FxZHtXEolYsL, roI3spqORKae(ES5oEprVxulp(b'g'), chr(0b1100100) + chr(101) + chr(0b1100011) + chr(4320 - 4209) + '\x64' + chr(0b1100101))(chr(0b1110101) + chr(0b1110100) + '\146' + chr(0b101101) + chr(56)))
roI3spqORKae(LNUKEwZDIbyb, roI3spqORKae(ES5oEprVxulp(b'tZ\x99\xb8'), '\x64' + chr(0b110110 + 0o57) + '\143' + '\157' + chr(0b1100100) + chr(101))(chr(117) + chr(12090 - 11974) + chr(102) + chr(213 - 168) + '\x38'))(iVOYvYr6UBaP, _R8IKF5IwAfX)
roI3spqORKae(_R8IKF5IwAfX, roI3spqORKae(ES5oEprVxulp(b'JJ\x85\xff\xc8\xb8\xdb\xc6\x91\xc8 \xcb'), '\x64' + chr(0b1011010 + 0o13) + chr(5346 - 5247) + '\157' + chr(1071 - 971) + '\145')('\x75' + chr(116) + chr(7800 - 7698) + chr(0b101000 + 0o5) + '\x38'))() |
BerkeleyAutomation/perception | perception/orthographic_intrinsics.py | OrthographicIntrinsics.load | def load(filename):
"""Load a CameraIntrinsics object from a file.
Parameters
----------
filename : :obj:`str`
The .intr file to load the object from.
Returns
-------
:obj:`CameraIntrinsics`
The CameraIntrinsics object loaded from the file.
Raises
------
ValueError
If filename does not have the .intr extension.
"""
file_root, file_ext = os.path.splitext(filename)
if file_ext.lower() != INTR_EXTENSION:
raise ValueError('Extension %s not supported for CameraIntrinsics. Must be stored with extension %s' %(file_ext, INTR_EXTENSION))
f = open(filename, 'r')
ci = json.load(f)
f.close()
return OrthographicIntrinsics(frame=ci['_frame'],
vol_height=ci['_vol_height'],
vol_width=ci['_vol_width'],
vol_depth=ci['_vol_depth'],
plane_height=ci['_plane_height'],
plane_width=ci['_plane_width'],
depth_scale=ci['_depth_scale']) | python | def load(filename):
"""Load a CameraIntrinsics object from a file.
Parameters
----------
filename : :obj:`str`
The .intr file to load the object from.
Returns
-------
:obj:`CameraIntrinsics`
The CameraIntrinsics object loaded from the file.
Raises
------
ValueError
If filename does not have the .intr extension.
"""
file_root, file_ext = os.path.splitext(filename)
if file_ext.lower() != INTR_EXTENSION:
raise ValueError('Extension %s not supported for CameraIntrinsics. Must be stored with extension %s' %(file_ext, INTR_EXTENSION))
f = open(filename, 'r')
ci = json.load(f)
f.close()
return OrthographicIntrinsics(frame=ci['_frame'],
vol_height=ci['_vol_height'],
vol_width=ci['_vol_width'],
vol_depth=ci['_vol_depth'],
plane_height=ci['_plane_height'],
plane_width=ci['_plane_width'],
depth_scale=ci['_depth_scale']) | [
"def",
"load",
"(",
"filename",
")",
":",
"file_root",
",",
"file_ext",
"=",
"os",
".",
"path",
".",
"splitext",
"(",
"filename",
")",
"if",
"file_ext",
".",
"lower",
"(",
")",
"!=",
"INTR_EXTENSION",
":",
"raise",
"ValueError",
"(",
"'Extension %s not supported for CameraIntrinsics. Must be stored with extension %s'",
"%",
"(",
"file_ext",
",",
"INTR_EXTENSION",
")",
")",
"f",
"=",
"open",
"(",
"filename",
",",
"'r'",
")",
"ci",
"=",
"json",
".",
"load",
"(",
"f",
")",
"f",
".",
"close",
"(",
")",
"return",
"OrthographicIntrinsics",
"(",
"frame",
"=",
"ci",
"[",
"'_frame'",
"]",
",",
"vol_height",
"=",
"ci",
"[",
"'_vol_height'",
"]",
",",
"vol_width",
"=",
"ci",
"[",
"'_vol_width'",
"]",
",",
"vol_depth",
"=",
"ci",
"[",
"'_vol_depth'",
"]",
",",
"plane_height",
"=",
"ci",
"[",
"'_plane_height'",
"]",
",",
"plane_width",
"=",
"ci",
"[",
"'_plane_width'",
"]",
",",
"depth_scale",
"=",
"ci",
"[",
"'_depth_scale'",
"]",
")"
] | Load a CameraIntrinsics object from a file.
Parameters
----------
filename : :obj:`str`
The .intr file to load the object from.
Returns
-------
:obj:`CameraIntrinsics`
The CameraIntrinsics object loaded from the file.
Raises
------
ValueError
If filename does not have the .intr extension. | [
"Load",
"a",
"CameraIntrinsics",
"object",
"from",
"a",
"file",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/orthographic_intrinsics.py#L308-L339 | train | Loads a CameraIntrinsics object from a file. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU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glV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b100111 + 0o11) + '\x6f' + '\x33' + chr(1169 - 1117) + '\064', 45605 - 45597), nzTpIcepk0o8(chr(0b11001 + 0o27) + '\x6f' + chr(49) + chr(251 - 203) + chr(53), 0o10), nzTpIcepk0o8('\x30' + chr(4234 - 4123) + chr(0b10011 + 0o36) + chr(0b110110), 0o10), nzTpIcepk0o8(chr(1526 - 1478) + chr(2873 - 2762) + chr(0b110001) + chr(859 - 811) + chr(55), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(103 - 48) + chr(1010 - 960), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(1652 - 1603) + chr(1031 - 981) + chr(55), 0b1000), nzTpIcepk0o8('\x30' + '\157' + '\x33' + chr(55) + '\x32', 0b1000), nzTpIcepk0o8('\x30' + chr(11024 - 10913) + '\061' + chr(885 - 831) + '\060', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(6985 - 6874) + '\x33' + chr(0b110010) + '\062', 7506 - 7498), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x33' + chr(2024 - 1976) + chr(1840 - 1792), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b101011 + 0o6) + '\066' + '\066', ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(49) + chr(55) + chr(0b11 + 0o56), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b101 + 0o54) + chr(2400 - 2347) + chr(0b100110 + 0o12), 0o10), nzTpIcepk0o8('\060' + chr(11498 - 11387) + chr(1091 - 1040) + chr(0b110100) + chr(0b100111 + 0o11), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110010 + 0o0) + '\063' + chr(1408 - 1358), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + '\061' + chr(0b101 + 0o60) + '\x35', 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + '\061' + chr(0b101110 + 0o4) + '\063', 0b1000), nzTpIcepk0o8(chr(0b1011 + 0o45) + '\157' + chr(970 - 921) + '\x34' + chr(1702 - 1647), 0o10), nzTpIcepk0o8(chr(970 - 922) + '\157' + '\x33' + '\x30' + chr(0b100011 + 0o24), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + '\x33' + '\x34' + '\x37', 0o10), nzTpIcepk0o8(chr(700 - 652) + chr(0b1101111) + chr(0b1100 + 0o46) + chr(1315 - 1260) + '\x32', 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b10111 + 0o32) + chr(1848 - 1800) + chr(789 - 740), 0o10), nzTpIcepk0o8(chr(0b100 + 0o54) + '\157' + chr(0b110 + 0o55) + '\067' + '\063', 0o10), nzTpIcepk0o8(chr(255 - 207) + chr(5189 - 5078) + chr(1749 - 1698) + chr(50) + chr(0b100110 + 0o14), 8), nzTpIcepk0o8(chr(48) + chr(0b1011101 + 0o22) + '\066' + '\067', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(729 - 680) + chr(0b110111) + '\065', ord("\x08")), nzTpIcepk0o8('\x30' + chr(4562 - 4451) + chr(0b110001) + chr(0b110100), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(50) + chr(0b110001) + chr(0b110101), 46191 - 46183), nzTpIcepk0o8('\x30' + '\157' + chr(51) + '\066' + '\x35', ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110001) + '\060', 0b1000), nzTpIcepk0o8(chr(0b110 + 0o52) + chr(111) + chr(0b11011 + 0o27) + chr(0b110010) + '\066', 0b1000), nzTpIcepk0o8('\060' + chr(2875 - 2764) + chr(0b110011) + chr(1153 - 1105), 0o10), nzTpIcepk0o8(chr(0b110 + 0o52) + chr(111) + '\x35' + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\062' + '\x35' + '\x35', 13811 - 13803), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x31' + chr(0b110010 + 0o5) + '\063', ord("\x08")), nzTpIcepk0o8('\060' + chr(5083 - 4972) + chr(49) + chr(2360 - 2307) + chr(0b110101), 8), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b11110 + 0o23) + chr(0b101010 + 0o10) + '\x34', 0b1000), nzTpIcepk0o8('\060' + chr(160 - 49) + chr(0b1001 + 0o51) + '\x30' + '\065', ord("\x08")), nzTpIcepk0o8(chr(0b11011 + 0o25) + '\157' + chr(1220 - 1170) + '\x30' + chr(0b110000), 16911 - 16903), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(1727 - 1678) + chr(55) + chr(0b11001 + 0o30), 8)][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + chr(0b10010 + 0o135) + '\065' + chr(48), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xca'), chr(0b10001 + 0o123) + '\145' + '\x63' + chr(0b1011101 + 0o22) + chr(100) + chr(101))('\165' + chr(10794 - 10678) + chr(1866 - 1764) + chr(0b100011 + 0o12) + chr(1631 - 1575)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def ZERsdc7c1d8E(FxZHtXEolYsL):
(cI016RJtE0ok, PGps9Hfk1I5F) = aHUqKstZLeS6.path.nKnjsA3UsXpY(FxZHtXEolYsL)
if roI3spqORKae(PGps9Hfk1I5F, roI3spqORKae(ES5oEprVxulp(b'\xbc+6\x02t\x00\xb7*\xb6\x89$\r'), '\x64' + chr(0b1100101 + 0o0) + '\143' + chr(111) + '\x64' + '\145')(chr(11653 - 11536) + chr(0b1110100) + chr(0b1100110) + chr(299 - 254) + chr(0b10101 + 0o43)))() != afMU6s1_k7vy:
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xa1=z"T$\x93\x1f\xbc\xe0S\nH\x8e\xf5\x19s\x14\xb2\x97\xca.\x89\xa6R\x19,\xeb\x9az\xb6[K\xc0\x1e\x1f5\xcc\xee\r\x96,`4S4\x89^\xf2\x8d\x03\n\x1c\xc0\xf8\x08s\x14\xb3\x88\xc8$\x9f\xf2@\x14x\xe5\xd5m\xeelO\xc3\x08\x04;\xeb\xa0\\\x97'), chr(0b1100100) + '\145' + '\x63' + '\x6f' + chr(0b1100100) + chr(2439 - 2338))(chr(0b1110101) + '\x74' + chr(102) + chr(0b101101) + chr(56)) % (PGps9Hfk1I5F, afMU6s1_k7vy))
_R8IKF5IwAfX = DnU3Rq9N5ala(FxZHtXEolYsL, roI3spqORKae(ES5oEprVxulp(b'\x96'), chr(0b1100011 + 0o1) + chr(0b1100101) + '\143' + '\x6f' + chr(0b1100100) + chr(0b1000101 + 0o40))('\x75' + chr(116) + chr(9483 - 9381) + '\x2d' + chr(471 - 415)))
cjIqqAi052T8 = LNUKEwZDIbyb.ZERsdc7c1d8E(_R8IKF5IwAfX)
roI3spqORKae(_R8IKF5IwAfX, roI3spqORKae(ES5oEprVxulp(b'\xbe \x7fpy4\x9cI\x87\xa4N\x13'), chr(2869 - 2769) + chr(101) + chr(99) + chr(111) + '\x64' + chr(101))('\165' + chr(0b1110011 + 0o1) + chr(102) + chr(0b101101) + chr(0b10001 + 0o47)))()
return Fs9XmmVLCfag(frame=cjIqqAi052T8[roI3spqORKae(ES5oEprVxulp(b'\xbb#|&W2'), chr(100) + chr(0b1100101) + chr(0b10111 + 0o114) + chr(0b101 + 0o152) + chr(0b110011 + 0o61) + chr(0b1100011 + 0o2))(chr(0b1110101) + '\164' + chr(0b1100110) + '\055' + '\x38')], vol_height=cjIqqAi052T8[roI3spqORKae(ES5oEprVxulp(b'\xbb3a+e?\x9f\x19\xb5\xa8\x02'), chr(0b1100100) + chr(0b1001101 + 0o30) + chr(99) + '\157' + chr(100) + chr(0b110100 + 0o61))(chr(117) + chr(0b1110100) + chr(191 - 89) + '\x2d' + '\070')], vol_width=cjIqqAi052T8[roI3spqORKae(ES5oEprVxulp(b'\xbb3a+e \x93\x14\xa6\xa8'), '\144' + '\145' + chr(0b1100011) + chr(0b1101111) + '\144' + '\145')(chr(11594 - 11477) + chr(116) + chr(102) + '\055' + '\070')], vol_depth=cjIqqAi052T8[roI3spqORKae(ES5oEprVxulp(b'\xbb3a+e3\x9f\x00\xa6\xa8'), chr(1492 - 1392) + '\145' + chr(8782 - 8683) + chr(0b1101111) + chr(925 - 825) + '\145')(chr(9490 - 9373) + chr(116) + chr(5629 - 5527) + chr(45) + chr(56))], plane_height=cjIqqAi052T8[roI3spqORKae(ES5oEprVxulp(b'\xbb5b&T2\xa5\x18\xb7\xa9\x11\x11\x1c'), chr(0b1100100) + chr(0b1100001 + 0o4) + chr(0b111110 + 0o45) + '\x6f' + '\144' + chr(0b1100101))(chr(0b1000010 + 0o63) + chr(116) + chr(0b1100110) + chr(0b101101) + chr(0b111000))], plane_width=cjIqqAi052T8[roI3spqORKae(ES5oEprVxulp(b'\xbb5b&T2\xa5\x07\xbb\xa4\x02\x11'), chr(0b1100100) + chr(0b1011001 + 0o14) + chr(369 - 270) + chr(0b1101111) + chr(5872 - 5772) + '\x65')(chr(117) + chr(3032 - 2916) + '\146' + chr(0b10011 + 0o32) + chr(0b111000))], depth_scale=cjIqqAi052T8[roI3spqORKae(ES5oEprVxulp(b'\xbb!k7N?\xa5\x03\xb1\xa1\x1a\x1c'), '\144' + '\x65' + chr(99) + chr(9863 - 9752) + '\x64' + chr(1261 - 1160))(chr(0b1011 + 0o152) + chr(0b1110100) + chr(0b1100110 + 0o0) + '\055' + chr(56))]) |
BerkeleyAutomation/perception | perception/phoxi_sensor.py | PhoXiSensor.start | def start(self):
"""Start the sensor.
"""
if rospy.get_name() == '/unnamed':
raise ValueError('PhoXi sensor must be run inside a ros node!')
# Connect to the cameras
if not self._connect_to_sensor():
self._running = False
return False
# Set up subscribers for camera data
self._color_im_sub = rospy.Subscriber('/phoxi_camera/texture', ImageMessage, self._color_im_callback)
self._depth_im_sub = rospy.Subscriber('/phoxi_camera/depth_map', ImageMessage, self._depth_im_callback)
self._normal_map_sub = rospy.Subscriber('/phoxi_camera/normal_map', ImageMessage, self._normal_map_callback)
self._running = True
return True | python | def start(self):
"""Start the sensor.
"""
if rospy.get_name() == '/unnamed':
raise ValueError('PhoXi sensor must be run inside a ros node!')
# Connect to the cameras
if not self._connect_to_sensor():
self._running = False
return False
# Set up subscribers for camera data
self._color_im_sub = rospy.Subscriber('/phoxi_camera/texture', ImageMessage, self._color_im_callback)
self._depth_im_sub = rospy.Subscriber('/phoxi_camera/depth_map', ImageMessage, self._depth_im_callback)
self._normal_map_sub = rospy.Subscriber('/phoxi_camera/normal_map', ImageMessage, self._normal_map_callback)
self._running = True
return True | [
"def",
"start",
"(",
"self",
")",
":",
"if",
"rospy",
".",
"get_name",
"(",
")",
"==",
"'/unnamed'",
":",
"raise",
"ValueError",
"(",
"'PhoXi sensor must be run inside a ros node!'",
")",
"# Connect to the cameras",
"if",
"not",
"self",
".",
"_connect_to_sensor",
"(",
")",
":",
"self",
".",
"_running",
"=",
"False",
"return",
"False",
"# Set up subscribers for camera data",
"self",
".",
"_color_im_sub",
"=",
"rospy",
".",
"Subscriber",
"(",
"'/phoxi_camera/texture'",
",",
"ImageMessage",
",",
"self",
".",
"_color_im_callback",
")",
"self",
".",
"_depth_im_sub",
"=",
"rospy",
".",
"Subscriber",
"(",
"'/phoxi_camera/depth_map'",
",",
"ImageMessage",
",",
"self",
".",
"_depth_im_callback",
")",
"self",
".",
"_normal_map_sub",
"=",
"rospy",
".",
"Subscriber",
"(",
"'/phoxi_camera/normal_map'",
",",
"ImageMessage",
",",
"self",
".",
"_normal_map_callback",
")",
"self",
".",
"_running",
"=",
"True",
"return",
"True"
] | Start the sensor. | [
"Start",
"the",
"sensor",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/phoxi_sensor.py#L108-L126 | train | Start the sensor. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOVzf,YikXQdxs3VoO,UBvEeZympYSz,m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e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b110 + 0o52) + chr(0b0 + 0o157) + chr(1777 - 1727) + '\065' + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(173 - 118) + chr(0b101101 + 0o6), 63440 - 63432), nzTpIcepk0o8(chr(1813 - 1765) + '\x6f' + chr(0b110010) + chr(621 - 570), 48908 - 48900), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b101 + 0o54), 0o10), nzTpIcepk0o8(chr(0b10000 + 0o40) + '\157' + '\063' + '\063' + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(9086 - 8975) + chr(49) + chr(0b110011) + chr(51), 0b1000), nzTpIcepk0o8(chr(821 - 773) + chr(0b1100 + 0o143) + '\x34' + chr(477 - 427), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(51) + '\x35' + '\x33', 0b1000), nzTpIcepk0o8('\060' + '\x6f' + '\x33' + chr(0b1100 + 0o52), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110011) + chr(2438 - 2387) + chr(0b110011), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\062' + '\x31' + '\x37', 47744 - 47736), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\063' + '\066' + chr(51), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + '\067' + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(0b101111 + 0o1) + chr(7252 - 7141) + chr(49) + '\x30', 50074 - 50066), nzTpIcepk0o8('\x30' + '\x6f' + chr(51) + chr(991 - 937) + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110011) + '\063' + '\x33', 8), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110010 + 0o0) + chr(51) + chr(1530 - 1476), ord("\x08")), nzTpIcepk0o8(chr(0b100111 + 0o11) + '\x6f' + '\064' + chr(1339 - 1289), 8), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(54) + chr(50), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110010) + chr(54) + '\x37', 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101 + 0o142) + chr(0b1110 + 0o45) + chr(0b100010 + 0o23), 0o10), nzTpIcepk0o8(chr(0b100001 + 0o17) + chr(0b1101111) + chr(53), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b101111 + 0o100) + '\063' + chr(1521 - 1467) + chr(0b1 + 0o66), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\067' + chr(54), 45022 - 45014), nzTpIcepk0o8(chr(0b100011 + 0o15) + chr(0b1101111) + '\x33' + chr(0b101000 + 0o14) + '\x35', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(50) + '\061' + '\x37', 8), nzTpIcepk0o8(chr(0b1010 + 0o46) + '\x6f' + chr(51) + chr(0b101000 + 0o17) + '\x37', 0b1000), nzTpIcepk0o8('\060' + '\157' + '\x33' + '\x37', 21205 - 21197), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(927 - 877) + chr(0b11001 + 0o33) + '\061', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(50) + '\x36' + chr(53), 57423 - 57415), nzTpIcepk0o8('\x30' + '\x6f' + chr(52), ord("\x08")), nzTpIcepk0o8(chr(0b100001 + 0o17) + chr(0b101001 + 0o106) + '\065' + chr(53), ord("\x08")), nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(5000 - 4889) + '\063' + chr(0b110001) + chr(0b11011 + 0o25), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b10111 + 0o32) + chr(0b100 + 0o63) + chr(0b11000 + 0o33), 0o10), nzTpIcepk0o8('\x30' + chr(11180 - 11069) + chr(646 - 591) + chr(0b100111 + 0o12), 8), nzTpIcepk0o8('\060' + chr(0b1001100 + 0o43) + chr(885 - 831) + chr(0b100111 + 0o15), 0o10), nzTpIcepk0o8(chr(0b101 + 0o53) + '\157' + chr(0b110001) + '\x30' + chr(1926 - 1876), 0b1000), nzTpIcepk0o8(chr(878 - 830) + chr(0b1000110 + 0o51) + chr(52) + chr(1708 - 1658), 8), nzTpIcepk0o8(chr(1767 - 1719) + chr(0b1101111) + '\x33' + chr(2151 - 2100) + '\x37', 8), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(54) + '\061', 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + chr(7070 - 6959) + '\065' + chr(48), ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x84'), '\144' + '\x65' + '\143' + chr(9106 - 8995) + chr(0b1101 + 0o127) + chr(0b1100101))(chr(12154 - 12037) + chr(0b1110100) + chr(0b1100110) + '\055' + chr(0b111000)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def KQbHFTcl_LKy(hXMPsSrOQzbh):
if roI3spqORKae(yFQYWmsCnVBN, roI3spqORKae(ES5oEprVxulp(b'\xe8q|K\x8e*f\xdaj\x84\xf8\x8b'), '\144' + chr(3106 - 3005) + chr(4461 - 4362) + chr(0b1101111) + chr(0b100010 + 0o102) + chr(0b1100101))('\165' + chr(116) + '\x66' + chr(0b10 + 0o53) + '\070'))() == roI3spqORKae(ES5oEprVxulp(b'\x85N}o\xbe6G\x8f'), chr(0b1100100) + '\x65' + '\x63' + '\x6f' + '\144' + chr(8239 - 8138))(chr(0b1110101) + chr(0b101100 + 0o110) + chr(0b1100110) + '\055' + chr(0b111000)):
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xfaS|Y\xb6{Q\x8ep\xa8\xe0\x81\x19e\x84\xa8\xea\x02P\xd2=w\x82P\xc5\xe6\x91l\xc8\xd1a\r\xa9[K[1\x02\xb1^\xce^2'), '\144' + chr(101) + chr(5545 - 5446) + chr(7240 - 7129) + '\x64' + '\145')(chr(2536 - 2419) + chr(10765 - 10649) + chr(0b1000011 + 0o43) + chr(662 - 617) + '\070'))
if not roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xf5X|o\xb1>A\x9fA\xaf\xe0\xacJm\x9f\xa8\xf1P'), chr(114 - 14) + chr(5559 - 5458) + '\x63' + chr(0b1101111) + '\x64' + '\145')(chr(117) + chr(4263 - 4147) + '\x66' + chr(0b10001 + 0o34) + chr(1070 - 1014)))():
hXMPsSrOQzbh.IF4G0B37piRc = nzTpIcepk0o8(chr(618 - 570) + chr(7209 - 7098) + chr(0b110000), 0b1000)
return nzTpIcepk0o8(chr(1981 - 1933) + chr(111) + chr(1396 - 1348), 8)
hXMPsSrOQzbh.p5fxTCjagE9L = yFQYWmsCnVBN.Subscriber(roI3spqORKae(ES5oEprVxulp(b"\x85K{n\xa72}\x88\x7f\xb6\xea\x81X'\x85\xbe\xe6VG\xc5x"), '\x64' + '\145' + '\143' + chr(1141 - 1030) + '\144' + '\145')(chr(10454 - 10337) + chr(116) + chr(0b1000 + 0o136) + chr(0b101101) + chr(1227 - 1171)), Kat9sF13qtH9, hXMPsSrOQzbh._color_im_callback)
hXMPsSrOQzbh.DxK1LQUgnE5n = yFQYWmsCnVBN.Subscriber(roI3spqORKae(ES5oEprVxulp(b"\x85K{n\xa72}\x88\x7f\xb6\xea\x81X'\x95\xbe\xeeVZ\xe8pd\x87"), chr(100) + '\x65' + '\x63' + chr(0b1101111) + '\144' + chr(0b1010 + 0o133))(chr(117) + chr(1025 - 909) + '\x66' + chr(2021 - 1976) + chr(933 - 877)), Kat9sF13qtH9, hXMPsSrOQzbh._depth_im_callback)
hXMPsSrOQzbh.QWmpsMCIGBCD = yFQYWmsCnVBN.Subscriber(roI3spqORKae(ES5oEprVxulp(b"\x85K{n\xa72}\x88\x7f\xb6\xea\x81X'\x9f\xb4\xecOS\xdbBh\x96N"), '\x64' + chr(101) + chr(99) + '\x6f' + '\x64' + '\145')(chr(0b1110101) + chr(116) + chr(6054 - 5952) + chr(660 - 615) + '\070'), Kat9sF13qtH9, hXMPsSrOQzbh._normal_map_callback)
hXMPsSrOQzbh.IF4G0B37piRc = nzTpIcepk0o8('\x30' + chr(0b1101111) + '\061', 8)
return nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(1779 - 1730), 8) |
BerkeleyAutomation/perception | perception/phoxi_sensor.py | PhoXiSensor.stop | def stop(self):
"""Stop the sensor.
"""
# Check that everything is running
if not self._running:
logging.warning('PhoXi not running. Aborting stop')
return False
# Stop the subscribers
self._color_im_sub.unregister()
self._depth_im_sub.unregister()
self._normal_map_sub.unregister()
# Disconnect from the camera
rospy.ServiceProxy('phoxi_camera/disconnect_camera', Empty)()
self._running = False
return True | python | def stop(self):
"""Stop the sensor.
"""
# Check that everything is running
if not self._running:
logging.warning('PhoXi not running. Aborting stop')
return False
# Stop the subscribers
self._color_im_sub.unregister()
self._depth_im_sub.unregister()
self._normal_map_sub.unregister()
# Disconnect from the camera
rospy.ServiceProxy('phoxi_camera/disconnect_camera', Empty)()
self._running = False
return True | [
"def",
"stop",
"(",
"self",
")",
":",
"# Check that everything is running",
"if",
"not",
"self",
".",
"_running",
":",
"logging",
".",
"warning",
"(",
"'PhoXi not running. Aborting stop'",
")",
"return",
"False",
"# Stop the subscribers",
"self",
".",
"_color_im_sub",
".",
"unregister",
"(",
")",
"self",
".",
"_depth_im_sub",
".",
"unregister",
"(",
")",
"self",
".",
"_normal_map_sub",
".",
"unregister",
"(",
")",
"# Disconnect from the camera",
"rospy",
".",
"ServiceProxy",
"(",
"'phoxi_camera/disconnect_camera'",
",",
"Empty",
")",
"(",
")",
"self",
".",
"_running",
"=",
"False",
"return",
"True"
] | Stop the sensor. | [
"Stop",
"the",
"sensor",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/phoxi_sensor.py#L128-L146 | train | Stop the sensor. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOVzf,YikXQdxs3VoO,UBvEeZympYSz,mRTjFWUmjlQA,QhZRiM1qvaW7,WbNHlDKpyPtQ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JY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\060' + '\157' + chr(0b1011 + 0o46) + chr(0b1 + 0o61) + '\x32', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\061' + '\062' + '\x32', 8), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(370 - 321) + '\x35' + '\x37', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(3481 - 3370) + chr(605 - 554) + chr(55) + chr(0b110110), 0o10), nzTpIcepk0o8('\060' + '\157' + chr(1126 - 1076) + chr(0b11011 + 0o32) + chr(49), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(49) + chr(50) + chr(0b11 + 0o60), 39477 - 39469), nzTpIcepk0o8(chr(48) + '\x6f' + chr(539 - 488) + chr(53) + '\x35', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1001010 + 0o45) + chr(2316 - 2267) + '\x32' + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(48) + '\157' + chr(2041 - 1992) + chr(52) + chr(53), 33346 - 33338), nzTpIcepk0o8(chr(0b1000 + 0o50) + '\157' + '\061' + chr(0b110001) + chr(50), 0o10), nzTpIcepk0o8(chr(0b11 + 0o55) + chr(111) + '\062' + chr(53) + chr(0b101001 + 0o12), 27288 - 27280), nzTpIcepk0o8(chr(0b110000) + chr(0b100011 + 0o114) + chr(0b110001) + chr(159 - 106) + chr(641 - 591), 0o10), nzTpIcepk0o8('\060' + chr(0b101100 + 0o103) + '\063' + chr(0b11100 + 0o24) + chr(139 - 88), 25742 - 25734), nzTpIcepk0o8('\x30' + chr(111) + chr(54) + chr(51), 0o10), nzTpIcepk0o8('\x30' + chr(9894 - 9783) + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(51) + '\062' + chr(48), 11778 - 11770), nzTpIcepk0o8('\060' + chr(111) + '\063' + chr(0b111 + 0o57) + '\065', 0b1000), nzTpIcepk0o8(chr(1091 - 1043) + chr(0b1101111) + '\x37' + '\x35', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b100 + 0o153) + '\x33' + chr(691 - 642) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(50) + chr(0b110011) + '\063', 0o10), nzTpIcepk0o8(chr(48) + chr(9686 - 9575) + chr(0b110001) + chr(53) + chr(0b110010), 8), nzTpIcepk0o8(chr(0b10001 + 0o37) + chr(0b1101111) + chr(0b100000 + 0o25), 0o10), nzTpIcepk0o8(chr(48) + '\157' + '\x33' + chr(143 - 91), 0o10), nzTpIcepk0o8('\060' + '\x6f' + '\063' + chr(0b100100 + 0o21), 0b1000), nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(0b1101111) + chr(2251 - 2202) + chr(50), 0o10), nzTpIcepk0o8(chr(1003 - 955) + '\x6f' + chr(52) + chr(1549 - 1497), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110111) + chr(2292 - 2240), 0o10), nzTpIcepk0o8(chr(0b101000 + 0o10) + '\x6f' + chr(49) + '\x31' + chr(2855 - 2801), 0b1000), nzTpIcepk0o8(chr(1322 - 1274) + chr(111) + '\x35' + chr(0b1111 + 0o50), 16301 - 16293), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b1011 + 0o50) + chr(0b110110) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(658 - 610) + '\x6f' + '\067' + chr(0b11110 + 0o27), 8), nzTpIcepk0o8(chr(2191 - 2143) + chr(111) + '\067' + chr(54), 0o10), nzTpIcepk0o8('\060' + chr(111) + chr(0b11101 + 0o25) + chr(53) + chr(0b1111 + 0o43), 0b1000), nzTpIcepk0o8('\x30' + chr(4146 - 4035) + chr(0b110010) + chr(0b110001 + 0o6) + chr(745 - 696), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\065' + chr(0b110011), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1001111 + 0o40) + chr(2335 - 2284) + chr(0b11001 + 0o36) + chr(52), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b110011) + chr(0b110110) + chr(0b110100), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + '\062' + '\063' + '\x37', 0b1000), nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(551 - 440) + chr(0b10111 + 0o40) + chr(53), 8), nzTpIcepk0o8(chr(48) + '\157' + chr(0b101110 + 0o4) + chr(1401 - 1351) + chr(0b110001), 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b1100 + 0o44) + chr(0b1000001 + 0o56) + chr(1840 - 1787) + '\060', 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'|'), chr(0b1011000 + 0o14) + chr(8393 - 8292) + '\x63' + chr(0b111011 + 0o64) + chr(7823 - 7723) + chr(0b111111 + 0o46))('\165' + chr(116) + chr(0b1100110) + '\x2d' + chr(1150 - 1094)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def dYJbBiYO_nGE(hXMPsSrOQzbh):
if not roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\x1b\x14[\xb9\x99\x11\xdef\x15#\xf9\t'), chr(0b1010110 + 0o16) + chr(0b110110 + 0o57) + '\x63' + chr(0b1101111) + '\144' + '\145')(chr(117) + chr(0b1110100) + chr(0b10 + 0o144) + chr(0b1 + 0o54) + chr(0b0 + 0o70))):
roI3spqORKae(Lj4gcNafqrcl, roI3spqORKae(ES5oEprVxulp(b'%3\x1d\x90\xc0=\x8a'), '\144' + '\145' + chr(99) + chr(0b1101111) + chr(0b1010 + 0o132) + chr(0b1100101))(chr(0b1000010 + 0o63) + '\164' + '\x66' + chr(45) + chr(2032 - 1976)))(roI3spqORKae(ES5oEprVxulp(b'\x02:\x00\xa6\xc0s\x83>\x11j\xd9\x1f\xad]n\xbe\x92\x13\xe9\xda\x08jnicJ[n\\\x86RN'), chr(0b100001 + 0o103) + chr(575 - 474) + chr(6647 - 6548) + chr(0b1101111) + '\x64' + '\x65')(chr(0b1110101) + chr(0b1110100) + chr(4517 - 4415) + '\055' + chr(0b111000)))
return nzTpIcepk0o8('\x30' + chr(0b1010000 + 0o37) + chr(1166 - 1118), 0o10)
roI3spqORKae(hXMPsSrOQzbh._color_im_sub, roI3spqORKae(ES5oEprVxulp(b"'<\x1d\x9b\xce:\x9e%\x008"), chr(100) + chr(0b1100101) + '\x63' + '\157' + chr(0b101001 + 0o73) + '\145')(chr(0b1110101) + chr(0b1110100) + chr(4258 - 4156) + chr(0b101010 + 0o3) + chr(2434 - 2378)))()
roI3spqORKae(hXMPsSrOQzbh._depth_im_sub, roI3spqORKae(ES5oEprVxulp(b"'<\x1d\x9b\xce:\x9e%\x008"), '\x64' + '\145' + '\143' + chr(0b1001000 + 0o47) + '\144' + chr(6229 - 6128))('\x75' + '\x74' + '\x66' + chr(0b11100 + 0o21) + chr(0b111000)))()
roI3spqORKae(hXMPsSrOQzbh._normal_map_sub, roI3spqORKae(ES5oEprVxulp(b"'<\x1d\x9b\xce:\x9e%\x008"), chr(2255 - 2155) + chr(3212 - 3111) + chr(0b1100011) + chr(0b1010000 + 0o37) + chr(100) + '\145')(chr(0b1110101) + '\164' + '\146' + chr(0b101100 + 0o1) + '\070'))()
roI3spqORKae(yFQYWmsCnVBN, roI3spqORKae(ES5oEprVxulp(b'\x017\x1d\x88\xc00\x88\x01\x17%\xd3\x13'), chr(0b1000111 + 0o35) + chr(0b1100101) + chr(99) + chr(0b1101111) + '\144' + chr(10170 - 10069))(chr(2875 - 2758) + '\164' + '\x66' + chr(45) + chr(2538 - 2482)))(roI3spqORKae(ES5oEprVxulp(b'":\x00\x86\xc0\x0c\x8e0\x08/\xd9\x0b\xecWn\xa3\x96R\xa7\xf5\x0ffhBiEQ+]\x93'), chr(100) + '\145' + chr(5420 - 5321) + '\x6f' + chr(0b1000110 + 0o36) + '\x65')('\165' + chr(0b1110100) + chr(0b11011 + 0o113) + chr(45) + '\x38'), qT_VrE0oUQQb)()
hXMPsSrOQzbh.IF4G0B37piRc = nzTpIcepk0o8(chr(0b110000) + chr(11172 - 11061) + '\x30', 8)
return nzTpIcepk0o8(chr(0b110000) + chr(8957 - 8846) + chr(49), 52904 - 52896) |
BerkeleyAutomation/perception | perception/phoxi_sensor.py | PhoXiSensor.frames | def frames(self):
"""Retrieve a new frame from the PhoXi and convert it to a ColorImage,
a DepthImage, and an IrImage.
Returns
-------
:obj:`tuple` of :obj:`ColorImage`, :obj:`DepthImage`, :obj:`IrImage`, :obj:`numpy.ndarray`
The ColorImage, DepthImage, and IrImage of the current frame.
"""
# Run a software trigger
times = []
rospy.ServiceProxy('phoxi_camera/start_acquisition', Empty)()
rospy.ServiceProxy('phoxi_camera/trigger_image', TriggerImage)()
self._cur_color_im = None
self._cur_depth_im = None
self._cur_normal_map = None
rospy.ServiceProxy('phoxi_camera/get_frame', GetFrame)(-1)
max_time = 5.0
time_waiting = 0.0
while self._cur_color_im is None or self._cur_depth_im is None or self._cur_normal_map is None:
time.sleep(0.05)
time_waiting += 0.05
if time_waiting > max_time:
raise SensorUnresponsiveException('PhoXi sensor seems to be non-responsive')
return self._cur_color_im, self._cur_depth_im, None | python | def frames(self):
"""Retrieve a new frame from the PhoXi and convert it to a ColorImage,
a DepthImage, and an IrImage.
Returns
-------
:obj:`tuple` of :obj:`ColorImage`, :obj:`DepthImage`, :obj:`IrImage`, :obj:`numpy.ndarray`
The ColorImage, DepthImage, and IrImage of the current frame.
"""
# Run a software trigger
times = []
rospy.ServiceProxy('phoxi_camera/start_acquisition', Empty)()
rospy.ServiceProxy('phoxi_camera/trigger_image', TriggerImage)()
self._cur_color_im = None
self._cur_depth_im = None
self._cur_normal_map = None
rospy.ServiceProxy('phoxi_camera/get_frame', GetFrame)(-1)
max_time = 5.0
time_waiting = 0.0
while self._cur_color_im is None or self._cur_depth_im is None or self._cur_normal_map is None:
time.sleep(0.05)
time_waiting += 0.05
if time_waiting > max_time:
raise SensorUnresponsiveException('PhoXi sensor seems to be non-responsive')
return self._cur_color_im, self._cur_depth_im, None | [
"def",
"frames",
"(",
"self",
")",
":",
"# Run a software trigger",
"times",
"=",
"[",
"]",
"rospy",
".",
"ServiceProxy",
"(",
"'phoxi_camera/start_acquisition'",
",",
"Empty",
")",
"(",
")",
"rospy",
".",
"ServiceProxy",
"(",
"'phoxi_camera/trigger_image'",
",",
"TriggerImage",
")",
"(",
")",
"self",
".",
"_cur_color_im",
"=",
"None",
"self",
".",
"_cur_depth_im",
"=",
"None",
"self",
".",
"_cur_normal_map",
"=",
"None",
"rospy",
".",
"ServiceProxy",
"(",
"'phoxi_camera/get_frame'",
",",
"GetFrame",
")",
"(",
"-",
"1",
")",
"max_time",
"=",
"5.0",
"time_waiting",
"=",
"0.0",
"while",
"self",
".",
"_cur_color_im",
"is",
"None",
"or",
"self",
".",
"_cur_depth_im",
"is",
"None",
"or",
"self",
".",
"_cur_normal_map",
"is",
"None",
":",
"time",
".",
"sleep",
"(",
"0.05",
")",
"time_waiting",
"+=",
"0.05",
"if",
"time_waiting",
">",
"max_time",
":",
"raise",
"SensorUnresponsiveException",
"(",
"'PhoXi sensor seems to be non-responsive'",
")",
"return",
"self",
".",
"_cur_color_im",
",",
"self",
".",
"_cur_depth_im",
",",
"None"
] | Retrieve a new frame from the PhoXi and convert it to a ColorImage,
a DepthImage, and an IrImage.
Returns
-------
:obj:`tuple` of :obj:`ColorImage`, :obj:`DepthImage`, :obj:`IrImage`, :obj:`numpy.ndarray`
The ColorImage, DepthImage, and IrImage of the current frame. | [
"Retrieve",
"a",
"new",
"frame",
"from",
"the",
"PhoXi",
"and",
"convert",
"it",
"to",
"a",
"ColorImage",
"a",
"DepthImage",
"and",
"an",
"IrImage",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/phoxi_sensor.py#L148-L176 | train | Retrieve a new frame from the PhoXi and convert it to a ColorImage DepthImage and IrImage. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOVzf,YikXQdxs3VoO,UBvEeZympYSz,mRTjFWUmjlQA,QhZRiM1qvaW7,WbNHlDKpyPtQ,z18h6aCn31dg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aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b110000) + '\157' + '\x31' + '\066', ord("\x08")), nzTpIcepk0o8(chr(1234 - 1186) + '\157' + chr(0b1 + 0o62) + chr(0b110010) + chr(976 - 922), ord("\x08")), nzTpIcepk0o8(chr(0b101001 + 0o7) + chr(0b1101111) + chr(0b100110 + 0o15) + chr(55) + chr(0b10 + 0o61), 0o10), nzTpIcepk0o8(chr(48) + chr(10494 - 10383) + chr(0b110001) + chr(0b111 + 0o60), 23641 - 23633), nzTpIcepk0o8(chr(2288 - 2240) + '\x6f' + '\x33' + chr(0b110110) + '\067', 0b1000), nzTpIcepk0o8('\060' + chr(6036 - 5925) + chr(1576 - 1523) + chr(52), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(2241 - 2191) + chr(51) + '\x32', 0b1000), nzTpIcepk0o8(chr(1880 - 1832) + chr(0b1101111) + chr(50) + chr(0b1101 + 0o44) + chr(2659 - 2606), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x31' + chr(50) + chr(0b11110 + 0o25), 0o10), nzTpIcepk0o8(chr(942 - 894) + '\x6f' + '\x33' + chr(2025 - 1977) + chr(49), 28990 - 28982), nzTpIcepk0o8(chr(48) + '\x6f' + chr(51) + chr(0b110111) + '\x30', ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b10011 + 0o37) + chr(0b110111) + '\x31', 43420 - 43412), nzTpIcepk0o8('\x30' + '\x6f' + chr(1765 - 1713) + chr(0b11100 + 0o27), 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x31' + chr(54), 8), nzTpIcepk0o8('\060' + '\157' + '\x31' + '\x36' + chr(0b11000 + 0o34), ord("\x08")), nzTpIcepk0o8(chr(1804 - 1756) + chr(0b1101111) + '\x31' + '\x34' + chr(716 - 663), 0o10), nzTpIcepk0o8(chr(0b110 + 0o52) + chr(0b1101110 + 0o1) + chr(50) + chr(1112 - 1062) + chr(1766 - 1716), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b101101 + 0o5) + '\062' + '\x36', 59072 - 59064), nzTpIcepk0o8(chr(0b11011 + 0o25) + '\x6f' + chr(0b1110 + 0o44) + '\x34' + '\x36', 0b1000), nzTpIcepk0o8('\060' + chr(111) + '\063' + chr(50) + chr(0b11111 + 0o26), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b1011 + 0o50) + chr(838 - 790) + chr(0b1010 + 0o46), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110010) + chr(0b110000) + chr(0b1100 + 0o45), 0b1000), nzTpIcepk0o8('\060' + chr(0b100100 + 0o113) + chr(0b101 + 0o55) + '\065' + '\x33', ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + '\x32' + '\064' + '\067', 33999 - 33991), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110011) + chr(0b101 + 0o57) + '\062', ord("\x08")), nzTpIcepk0o8(chr(1018 - 970) + chr(0b10111 + 0o130) + chr(49) + chr(0b110001) + '\061', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1000101 + 0o52) + '\063' + chr(51) + '\x33', 41080 - 41072), nzTpIcepk0o8(chr(2035 - 1987) + chr(7605 - 7494) + '\x31' + '\x33', 47439 - 47431), nzTpIcepk0o8('\x30' + chr(111) + '\x32' + chr(2604 - 2549), 0o10), nzTpIcepk0o8(chr(0b101 + 0o53) + chr(0b1101100 + 0o3) + chr(522 - 473) + chr(0b110000), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(393 - 342) + chr(0b110011) + '\x33', 8), nzTpIcepk0o8(chr(48) + chr(111) + '\063' + chr(49), 51883 - 51875), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(996 - 947), 41065 - 41057), nzTpIcepk0o8(chr(0b1110 + 0o42) + '\x6f' + chr(0b110100) + chr(55), ord("\x08")), nzTpIcepk0o8('\x30' + chr(1348 - 1237) + chr(2272 - 2219) + chr(1415 - 1364), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\157' + '\061' + chr(2853 - 2798) + chr(51), 16493 - 16485), nzTpIcepk0o8(chr(0b110000) + chr(9258 - 9147) + '\061' + chr(2422 - 2370) + chr(0b110001), 0b1000), nzTpIcepk0o8('\060' + chr(111) + chr(0b101010 + 0o11) + chr(0b10011 + 0o36), 8), nzTpIcepk0o8('\060' + chr(5181 - 5070) + chr(901 - 851) + chr(0b110000) + chr(0b1 + 0o65), 0o10), nzTpIcepk0o8('\x30' + chr(1295 - 1184) + chr(1690 - 1639) + chr(182 - 132), 1257 - 1249)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(0b111010 + 0o65) + chr(0b110101) + chr(0b111 + 0o51), 51870 - 51862)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b' '), chr(0b110111 + 0o55) + '\x65' + chr(99) + chr(0b1011 + 0o144) + '\144' + '\x65')(chr(6477 - 6360) + '\164' + chr(0b1100110) + chr(0b101 + 0o50) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def G4Lisexwxqjs(hXMPsSrOQzbh):
wV5dGZrosDy4 = []
roI3spqORKae(yFQYWmsCnVBN, roI3spqORKae(ES5oEprVxulp(b']\xb3\x89y\x9eO\xff\xdd!\xae\x80\xc0'), chr(0b1100100) + '\x65' + chr(0b1100011) + chr(5698 - 5587) + chr(0b1100100) + '\145')('\165' + chr(116) + chr(8815 - 8713) + chr(0b10111 + 0o26) + chr(56)))(roI3spqORKae(ES5oEprVxulp(b'~\xbe\x94w\x9es\xf9\xec>\xa4\x8a\xd8\x0c}\x00\x04\xe0\xe2\xf9\xb4\xa3\xf0\xde\xce\x91 \xafbxf'), chr(100) + '\x65' + chr(0b101000 + 0o73) + '\157' + chr(0b1100100) + chr(0b1100101))(chr(0b111100 + 0o71) + '\x74' + '\x66' + chr(45) + '\070'), qT_VrE0oUQQb)()
roI3spqORKae(yFQYWmsCnVBN, roI3spqORKae(ES5oEprVxulp(b']\xb3\x89y\x9eO\xff\xdd!\xae\x80\xc0'), chr(2173 - 2073) + chr(101) + chr(1965 - 1866) + '\157' + '\x64' + chr(0b1100101))(chr(0b101101 + 0o110) + chr(116) + '\146' + chr(0b101101) + chr(56)))(roI3spqORKae(ES5oEprVxulp(b'~\xbe\x94w\x9es\xf9\xec>\xa4\x8a\xd8\x0cz\x06\x0c\xf5\xf1\xc3\xa7\x9f\xe8\xc6\xc6\x85,'), '\144' + chr(6477 - 6376) + '\143' + chr(111) + chr(0b1001111 + 0o25) + '\x65')(chr(4496 - 4379) + '\164' + chr(9254 - 9152) + chr(0b10001 + 0o34) + chr(56)), y6IhNn7r_4oM)()
hXMPsSrOQzbh.QTpeDyuazoVC = None
hXMPsSrOQzbh.svGVTE2PWnC2 = None
hXMPsSrOQzbh.uwlT5TAhvlzq = None
roI3spqORKae(yFQYWmsCnVBN, roI3spqORKae(ES5oEprVxulp(b']\xb3\x89y\x9eO\xff\xdd!\xae\x80\xc0'), chr(0b1001100 + 0o30) + chr(4403 - 4302) + chr(0b1000001 + 0o42) + chr(0b101100 + 0o103) + '\144' + '\145')('\165' + '\164' + '\x66' + chr(1325 - 1280) + chr(56)))(roI3spqORKae(ES5oEprVxulp(b'~\xbe\x94w\x9es\xf9\xec>\xa4\x8a\xd8\x0ci\x11\x11\xcd\xf0\xd4\xb4\xad\xe4'), chr(7730 - 7630) + '\145' + chr(99) + chr(0b1101111) + chr(0b1001 + 0o133) + chr(101))(chr(117) + chr(0b1110100) + chr(258 - 156) + '\055' + '\070'), FFfmYRQtm2td)(-nzTpIcepk0o8(chr(0b10011 + 0o35) + chr(111) + chr(0b110001), 8))
Dic1I4bNKi9O = 5.0
t9cqM2tjMfA2 = 0.0
while roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'_\x82\x8bj\xb3U\xef\xec)\xae\xae\xfa'), chr(0b1100100) + '\x65' + chr(0b1100011) + chr(0b1101111) + '\x64' + chr(0b110 + 0o137))(chr(0b1010110 + 0o37) + chr(0b1010110 + 0o36) + '\146' + '\x2d' + chr(0b101000 + 0o20))) is None or roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'}\xa0\xbcY\xa3i\xa8\xdd\x04\xaf\xbb\x8b'), '\x64' + chr(2433 - 2332) + '\x63' + chr(0b1101111) + chr(9250 - 9150) + chr(0b1100101))(chr(117) + '\x74' + chr(0b1011 + 0o133) + chr(695 - 650) + chr(1055 - 999))) is None or roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'{\xa1\x97[\xc2x\xdb\xe5%\xad\x82\xc8'), chr(100) + chr(101) + chr(99) + chr(0b1101000 + 0o7) + '\x64' + chr(0b1100101))(chr(0b1110011 + 0o2) + chr(0b1110100) + chr(0b1001011 + 0o33) + chr(0b100110 + 0o7) + chr(0b11 + 0o65))) is None:
roI3spqORKae(oprIvDIRQyCb, roI3spqORKae(ES5oEprVxulp(b'}\xba\x9ej\x87'), chr(3630 - 3530) + chr(0b1100101) + chr(6443 - 6344) + '\157' + chr(0b1100000 + 0o4) + '\x65')(chr(0b111011 + 0o72) + chr(12186 - 12070) + '\146' + chr(45) + chr(0b111000)))(0.05)
t9cqM2tjMfA2 += 0.05
if t9cqM2tjMfA2 > Dic1I4bNKi9O:
raise RUU_QCDjNd23(roI3spqORKae(ES5oEprVxulp(b"^\xbe\x94W\x9e\x0c\xe9\xe8=\xb2\x97\xcb\x03}\x11\x00\xff\xe5\x86\xa1\xaf\xa1\xc9\xc2\xc2'\xb4e:z\xbejqHE\x08\x08o\xe3"), chr(100) + chr(6001 - 5900) + '\143' + '\x6f' + chr(4989 - 4889) + chr(3204 - 3103))(chr(0b1110101) + chr(0b1110100) + '\146' + chr(45) + chr(1380 - 1324)))
return (roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'_\x82\x8bj\xb3U\xef\xec)\xae\xae\xfa'), '\x64' + chr(4480 - 4379) + chr(861 - 762) + chr(111) + '\x64' + chr(9351 - 9250))(chr(0b10001 + 0o144) + chr(0b1110100) + chr(102) + '\x2d' + chr(0b100000 + 0o30))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'}\xa0\xbcY\xa3i\xa8\xdd\x04\xaf\xbb\x8b'), chr(100) + chr(101) + chr(0b1001 + 0o132) + '\157' + '\x64' + '\x65')(chr(117) + chr(0b110101 + 0o77) + chr(0b1100110) + '\055' + '\070')), None) |
BerkeleyAutomation/perception | perception/phoxi_sensor.py | PhoXiSensor._connect_to_sensor | def _connect_to_sensor(self):
"""Connect to the sensor.
"""
name = self._device_name
try:
# Check if device is actively in list
rospy.wait_for_service('phoxi_camera/get_device_list')
device_list = rospy.ServiceProxy('phoxi_camera/get_device_list', GetDeviceList)().out
if not str(name) in device_list:
logging.error('PhoXi sensor {} not in list of active devices'.format(name))
return False
success = rospy.ServiceProxy('phoxi_camera/connect_camera', ConnectCamera)(name).success
if not success:
logging.error('Could not connect to PhoXi sensor {}'.format(name))
return False
logging.debug('Connected to PhoXi Sensor {}'.format(name))
return True
except rospy.ServiceException as e:
logging.error('Service call failed: {}'.format(e))
return False | python | def _connect_to_sensor(self):
"""Connect to the sensor.
"""
name = self._device_name
try:
# Check if device is actively in list
rospy.wait_for_service('phoxi_camera/get_device_list')
device_list = rospy.ServiceProxy('phoxi_camera/get_device_list', GetDeviceList)().out
if not str(name) in device_list:
logging.error('PhoXi sensor {} not in list of active devices'.format(name))
return False
success = rospy.ServiceProxy('phoxi_camera/connect_camera', ConnectCamera)(name).success
if not success:
logging.error('Could not connect to PhoXi sensor {}'.format(name))
return False
logging.debug('Connected to PhoXi Sensor {}'.format(name))
return True
except rospy.ServiceException as e:
logging.error('Service call failed: {}'.format(e))
return False | [
"def",
"_connect_to_sensor",
"(",
"self",
")",
":",
"name",
"=",
"self",
".",
"_device_name",
"try",
":",
"# Check if device is actively in list",
"rospy",
".",
"wait_for_service",
"(",
"'phoxi_camera/get_device_list'",
")",
"device_list",
"=",
"rospy",
".",
"ServiceProxy",
"(",
"'phoxi_camera/get_device_list'",
",",
"GetDeviceList",
")",
"(",
")",
".",
"out",
"if",
"not",
"str",
"(",
"name",
")",
"in",
"device_list",
":",
"logging",
".",
"error",
"(",
"'PhoXi sensor {} not in list of active devices'",
".",
"format",
"(",
"name",
")",
")",
"return",
"False",
"success",
"=",
"rospy",
".",
"ServiceProxy",
"(",
"'phoxi_camera/connect_camera'",
",",
"ConnectCamera",
")",
"(",
"name",
")",
".",
"success",
"if",
"not",
"success",
":",
"logging",
".",
"error",
"(",
"'Could not connect to PhoXi sensor {}'",
".",
"format",
"(",
"name",
")",
")",
"return",
"False",
"logging",
".",
"debug",
"(",
"'Connected to PhoXi Sensor {}'",
".",
"format",
"(",
"name",
")",
")",
"return",
"True",
"except",
"rospy",
".",
"ServiceException",
"as",
"e",
":",
"logging",
".",
"error",
"(",
"'Service call failed: {}'",
".",
"format",
"(",
"e",
")",
")",
"return",
"False"
] | Connect to the sensor. | [
"Connect",
"to",
"the",
"sensor",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/phoxi_sensor.py#L201-L223 | train | Connect to the sensor. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64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KZ,qZ4DivK_Doaa,znjnJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(111) + chr(52), 35432 - 35424), nzTpIcepk0o8('\060' + chr(0b1000010 + 0o55) + chr(0b110001) + chr(0b110101) + chr(0b110010), 0o10), nzTpIcepk0o8('\060' + chr(111) + chr(0b110101 + 0o0) + chr(0b101 + 0o62), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(132 - 83) + chr(1062 - 1014) + '\064', 0o10), nzTpIcepk0o8('\x30' + chr(2958 - 2847) + '\x31' + chr(51) + chr(1707 - 1656), 33174 - 33166), nzTpIcepk0o8('\060' + '\157' + chr(0b10 + 0o61) + chr(0b111 + 0o55) + chr(0b110011), 40032 - 40024), nzTpIcepk0o8(chr(48) + chr(111) + '\x37' + '\066', 0b1000), nzTpIcepk0o8(chr(1828 - 1780) + '\x6f' + chr(0b10001 + 0o42) + chr(0b110100) + '\x32', 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\064' + chr(0b0 + 0o62), 0o10), nzTpIcepk0o8(chr(0b110000 + 0o0) + chr(111) + chr(52) + chr(1113 - 1065), 0o10), nzTpIcepk0o8(chr(689 - 641) + chr(0b1101111) + chr(0b110011) + '\x37' + chr(0b110011), 0o10), nzTpIcepk0o8(chr(0b101 + 0o53) + chr(0b1100111 + 0o10) + chr(50) + chr(0b1011 + 0o53), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1000001 + 0o56) + chr(2240 - 2190) + chr(1391 - 1338) + '\x30', 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + '\062' + chr(52) + '\065', 0b1000), nzTpIcepk0o8(chr(48) + chr(0b111001 + 0o66) + chr(50) + chr(0b110001), 7637 - 7629), nzTpIcepk0o8(chr(48) + chr(111) + '\x33' + chr(0b110100) + chr(0b110011), 8), nzTpIcepk0o8('\060' + chr(7732 - 7621) + chr(49) + '\x30' + '\x31', 0b1000), nzTpIcepk0o8('\060' + chr(111) + '\x31' + '\x36' + '\x37', ord("\x08")), nzTpIcepk0o8(chr(0b11100 + 0o24) + chr(0b1011010 + 0o25) + '\x33' + '\x32' + '\062', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110001) + chr(0b110101) + chr(0b110100), 0b1000), nzTpIcepk0o8(chr(589 - 541) + chr(111) + '\061' + chr(0b11101 + 0o31) + chr(0b110101), 5265 - 5257), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(53) + '\061', 0o10), nzTpIcepk0o8(chr(946 - 898) + chr(0b1101111) + chr(0b11100 + 0o27) + chr(0b1011 + 0o45) + chr(362 - 308), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(0b1100 + 0o46) + '\064' + chr(480 - 425), 42380 - 42372), nzTpIcepk0o8('\x30' + chr(0b101001 + 0o106) + '\x31' + chr(0b110001) + chr(277 - 224), 0b1000), nzTpIcepk0o8(chr(1802 - 1754) + chr(11093 - 10982) + chr(1319 - 1269) + '\066' + chr(0b10111 + 0o35), ord("\x08")), nzTpIcepk0o8(chr(744 - 696) + chr(0b1101111) + chr(52) + '\x35', ord("\x08")), nzTpIcepk0o8(chr(0b0 + 0o60) + chr(4489 - 4378) + '\x32' + chr(2756 - 2702) + '\x37', 5122 - 5114), nzTpIcepk0o8(chr(0b110000) + chr(0b1010111 + 0o30) + '\063' + '\x30' + chr(2553 - 2498), 0o10), nzTpIcepk0o8(chr(48) + chr(0b1100100 + 0o13) + chr(0b1 + 0o64) + chr(0b10001 + 0o45), 60903 - 60895), nzTpIcepk0o8(chr(846 - 798) + chr(0b11010 + 0o125) + chr(0b110011) + chr(1379 - 1324) + chr(0b110010), 0o10), nzTpIcepk0o8(chr(1820 - 1772) + chr(0b1101111) + '\x35' + '\x34', 1935 - 1927), nzTpIcepk0o8('\x30' + chr(0b100110 + 0o111) + '\x33' + '\067' + chr(0b10110 + 0o32), 63029 - 63021), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(1407 - 1358) + chr(0b110110), 0o10), nzTpIcepk0o8('\x30' + chr(0b1100 + 0o143) + '\062' + '\x32' + chr(0b11101 + 0o30), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(265 - 215) + chr(0b10011 + 0o36) + chr(0b110111), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(150 - 100) + chr(0b11110 + 0o27) + chr(0b1101 + 0o50), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(51) + chr(54) + '\x34', ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(585 - 536) + '\x32', ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(9015 - 8904) + chr(164 - 111) + chr(0b110000), 7708 - 7700)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'*'), chr(100) + chr(4765 - 4664) + chr(0b1100011) + '\x6f' + chr(0b1011101 + 0o7) + '\145')(chr(0b1110101) + chr(0b100010 + 0o122) + chr(102) + chr(1407 - 1362) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def xgy1ius6CuvO(hXMPsSrOQzbh):
SLVB2BPA_mIe = hXMPsSrOQzbh._device_name
try:
roI3spqORKae(yFQYWmsCnVBN, roI3spqORKae(ES5oEprVxulp(b's\x0bF0\x04\x85Q\x90^QE\x89`\xc1\xc6t'), '\x64' + '\x65' + chr(99) + '\157' + chr(168 - 68) + '\x65')('\165' + chr(0b1010011 + 0o41) + '\146' + chr(45) + chr(0b111000)))(roI3spqORKae(ES5oEprVxulp(b't\x02@<2\xbc]\x83lGR\x9a9\xcf\xc0e\xbc%\x12\xa4\x05\x16L\x99\xcb$\xc7Q'), chr(100) + chr(9640 - 9539) + '\143' + chr(4542 - 4431) + chr(0b1100100) + chr(101))('\x75' + '\164' + chr(102) + chr(0b11100 + 0o21) + '\x38'))
FpXyu0rt0mr9 = yFQYWmsCnVBN.ServiceProxy(roI3spqORKae(ES5oEprVxulp(b't\x02@<2\xbc]\x83lGR\x9a9\xcf\xc0e\xbc%\x12\xa4\x05\x16L\x99\xcb$\xc7Q'), chr(6842 - 6742) + '\x65' + chr(1316 - 1217) + chr(0b1101010 + 0o5) + chr(100) + '\145')('\165' + chr(0b1110100) + chr(0b1100110) + '\055' + '\070'), BQyKjxh8SUOd)().VwOu8WkJ9cpc
if not N9zlRy29S1SS(SLVB2BPA_mIe) in FpXyu0rt0mr9:
roI3spqORKae(Lj4gcNafqrcl, roI3spqORKae(ES5oEprVxulp(b'u\x03\x1e32\x93n\xb4wgk\x9f'), chr(100) + chr(101) + chr(0b1100011) + chr(0b1101111) + '\x64' + chr(101))('\165' + chr(0b11111 + 0o125) + chr(102) + chr(45) + '\x38'))(roI3spqORKae(roI3spqORKae(ES5oEprVxulp(b'T\x02@\x1c2\xc3M\x87oQO\x896\xd3\xd81\x8d.\x03\xf2\x05\x1b\t\xaa\xce>\xc0\x05\xd8\xa1\x0e\x9bO\x8cg\xe3\xea\x8d\x90or\x03L!('), chr(0b1001 + 0o133) + chr(0b111111 + 0o46) + '\x63' + chr(0b110011 + 0o74) + '\x64' + '\145')(chr(117) + '\164' + chr(102) + chr(1490 - 1445) + chr(0b111000)), roI3spqORKae(ES5oEprVxulp(b'uY\x1c\x0f\x1c\xd0X\x8dP}c\xb1'), chr(100) + '\x65' + chr(99) + chr(0b1101111) + '\x64' + chr(101))(chr(117) + chr(116) + chr(0b1000101 + 0o41) + '\x2d' + '\070'))(SLVB2BPA_mIe))
return nzTpIcepk0o8(chr(516 - 468) + chr(0b1101111) + chr(0b100100 + 0o14), 0b1000)
Eve7WKj3GZpi = yFQYWmsCnVBN.ServiceProxy(roI3spqORKae(ES5oEprVxulp(b't\x02@<2\xbc]\x83lGR\x9a9\xcb\xca\x7f\x8d$\x14\xa63\x16H\xab\xc2?\xd5'), chr(0b1100100) + chr(0b1100101) + '\x63' + chr(637 - 526) + chr(6810 - 6710) + chr(101))('\165' + '\164' + chr(8561 - 8459) + chr(45) + chr(0b110010 + 0o6)), ubUcUfscP08b)(SLVB2BPA_mIe).Eve7WKj3GZpi
if not Eve7WKj3GZpi:
roI3spqORKae(Lj4gcNafqrcl, roI3spqORKae(ES5oEprVxulp(b'u\x03\x1e32\x93n\xb4wgk\x9f'), chr(0b110001 + 0o63) + '\x65' + '\x63' + chr(0b1101111) + chr(100) + chr(0b10011 + 0o122))(chr(0b110001 + 0o104) + '\164' + chr(5601 - 5499) + chr(1249 - 1204) + '\070'))(roI3spqORKae(roI3spqORKae(ES5oEprVxulp(b'G\x05Z(?\xc3P\x8du\x02C\x94x\xc6\xc0r\x97a\x03\xbdL%A\xa9\xff$\x94V\xd2\xa9]\x95^\xd8u\xe8'), '\144' + '\x65' + chr(7897 - 7798) + '\x6f' + chr(100) + chr(0b1100101))(chr(0b111100 + 0o71) + chr(116) + chr(0b101110 + 0o70) + chr(0b11110 + 0o17) + chr(0b111000)), roI3spqORKae(ES5oEprVxulp(b'uY\x1c\x0f\x1c\xd0X\x8dP}c\xb1'), chr(5925 - 5825) + '\145' + chr(0b1100011) + chr(0b1101111 + 0o0) + chr(100) + chr(0b1010001 + 0o24))('\x75' + chr(13453 - 13337) + chr(102) + '\055' + '\070'))(SLVB2BPA_mIe))
return nzTpIcepk0o8('\060' + chr(111) + chr(0b101 + 0o53), 8)
roI3spqORKae(Lj4gcNafqrcl, roI3spqORKae(ES5oEprVxulp(b'c+\x16\x1eb\x87Q\xd4TOe\xa1'), chr(7586 - 7486) + chr(101) + chr(2793 - 2694) + '\157' + chr(6880 - 6780) + '\x65')(chr(0b1110101) + '\164' + '\x66' + '\x2d' + chr(0b100110 + 0o22)))(roI3spqORKae(roI3spqORKae(ES5oEprVxulp(b'G\x05A*>\x80J\x87e\x02T\x946\xf8\xcd~\xbb(W\x81\t\x1bZ\xa9\xd5m\xcfX'), chr(100) + chr(101) + chr(99) + '\157' + chr(0b1100100) + chr(4171 - 4070))(chr(10753 - 10636) + '\164' + '\146' + '\055' + chr(0b111000)), roI3spqORKae(ES5oEprVxulp(b'uY\x1c\x0f\x1c\xd0X\x8dP}c\xb1'), '\x64' + '\x65' + chr(4101 - 4002) + chr(0b1001000 + 0o47) + chr(100) + chr(3017 - 2916))('\165' + chr(116) + '\146' + chr(0b11101 + 0o20) + '\070'))(SLVB2BPA_mIe))
return nzTpIcepk0o8(chr(0b110000) + chr(10268 - 10157) + '\061', 8)
except roI3spqORKae(yFQYWmsCnVBN, roI3spqORKae(ES5oEprVxulp(b'W\x0f]22\x80[\xa7yAE\x8bb\xc1\xca\x7f'), '\x64' + chr(101) + '\143' + '\x6f' + chr(100) + chr(4376 - 4275))(chr(117) + chr(0b1110100) + chr(0b110010 + 0o64) + chr(107 - 62) + '\070')) as wgf0sgcu_xPL:
roI3spqORKae(Lj4gcNafqrcl, roI3spqORKae(ES5oEprVxulp(b'u\x03\x1e32\x93n\xb4wgk\x9f'), chr(100) + '\145' + chr(0b1100011) + '\157' + chr(100) + chr(101))(chr(5259 - 5142) + '\x74' + '\146' + '\055' + chr(0b111 + 0o61)))(roI3spqORKae(roI3spqORKae(ES5oEprVxulp(b'W\x0f]22\x80[\xc2bCL\x976\xce\xc4x\x8f$\x13\xe8L\x0eT'), chr(0b1100100) + '\x65' + chr(5592 - 5493) + '\157' + chr(100) + chr(0b1100101))(chr(5426 - 5309) + chr(116) + '\146' + chr(0b11000 + 0o25) + '\070'), roI3spqORKae(ES5oEprVxulp(b'uY\x1c\x0f\x1c\xd0X\x8dP}c\xb1'), chr(0b1100100) + chr(0b10011 + 0o122) + chr(0b110100 + 0o57) + chr(111) + chr(0b1100100) + chr(101))(chr(13668 - 13551) + chr(0b110100 + 0o100) + chr(2914 - 2812) + '\055' + '\x38'))(wgf0sgcu_xPL))
return nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(0b101010 + 0o105) + chr(48), 8) |
BerkeleyAutomation/perception | perception/phoxi_sensor.py | PhoXiSensor._color_im_callback | def _color_im_callback(self, msg):
"""Callback for handling textures (greyscale images).
"""
try:
data = self._bridge.imgmsg_to_cv2(msg)
if np.max(data) > 255.0:
data = 255.0 * data / 1200.0 # Experimentally set value for white
data = np.clip(data, 0., 255.0).astype(np.uint8)
gsimage = GrayscaleImage(data, frame=self._frame)
self._cur_color_im = gsimage.to_color()
except:
self._cur_color_im = None | python | def _color_im_callback(self, msg):
"""Callback for handling textures (greyscale images).
"""
try:
data = self._bridge.imgmsg_to_cv2(msg)
if np.max(data) > 255.0:
data = 255.0 * data / 1200.0 # Experimentally set value for white
data = np.clip(data, 0., 255.0).astype(np.uint8)
gsimage = GrayscaleImage(data, frame=self._frame)
self._cur_color_im = gsimage.to_color()
except:
self._cur_color_im = None | [
"def",
"_color_im_callback",
"(",
"self",
",",
"msg",
")",
":",
"try",
":",
"data",
"=",
"self",
".",
"_bridge",
".",
"imgmsg_to_cv2",
"(",
"msg",
")",
"if",
"np",
".",
"max",
"(",
"data",
")",
">",
"255.0",
":",
"data",
"=",
"255.0",
"*",
"data",
"/",
"1200.0",
"# Experimentally set value for white",
"data",
"=",
"np",
".",
"clip",
"(",
"data",
",",
"0.",
",",
"255.0",
")",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
"gsimage",
"=",
"GrayscaleImage",
"(",
"data",
",",
"frame",
"=",
"self",
".",
"_frame",
")",
"self",
".",
"_cur_color_im",
"=",
"gsimage",
".",
"to_color",
"(",
")",
"except",
":",
"self",
".",
"_cur_color_im",
"=",
"None"
] | Callback for handling textures (greyscale images). | [
"Callback",
"for",
"handling",
"textures",
"(",
"greyscale",
"images",
")",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/phoxi_sensor.py#L225-L236 | train | Callback for handling textures. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3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Rk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(2152 - 2104) + '\x6f' + chr(0b110001) + '\067' + chr(0b110101), 0o10), nzTpIcepk0o8(chr(0b0 + 0o60) + '\157' + chr(1503 - 1448) + chr(2445 - 2395), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b1011 + 0o47) + '\062', 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(51) + '\x33' + '\067', 14593 - 14585), nzTpIcepk0o8(chr(0b110000) + chr(0b11 + 0o154) + '\x33' + chr(0b100100 + 0o22), 35780 - 35772), nzTpIcepk0o8(chr(0b110000) + chr(10421 - 10310) + chr(1148 - 1098) + '\x31' + chr(54), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110011) + chr(55) + chr(55), 0o10), nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(0b1101111) + chr(49) + chr(51) + chr(53), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(49) + chr(1264 - 1211) + '\x34', 0o10), nzTpIcepk0o8(chr(0b101001 + 0o7) + chr(0b1001001 + 0o46) + '\x31' + chr(51) + chr(0b100 + 0o60), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1011111 + 0o20) + chr(0b110011 + 0o0) + '\060' + '\062', 16229 - 16221), nzTpIcepk0o8(chr(0b11100 + 0o24) + '\157' + '\062' + '\x30' + '\x32', 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110011) + '\x31' + chr(0b1010 + 0o50), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(692 - 637) + '\067', ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + '\061' + '\060' + chr(0b110000), 50072 - 50064), nzTpIcepk0o8(chr(0b1111 + 0o41) + '\157' + chr(500 - 449) + chr(0b110001) + chr(0b110100), 0o10), nzTpIcepk0o8('\x30' + chr(6192 - 6081) + chr(0b110010) + '\061' + chr(0b1101 + 0o52), 6600 - 6592), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110001) + '\060' + chr(2018 - 1967), 0b1000), nzTpIcepk0o8(chr(725 - 677) + chr(0b0 + 0o157) + '\x31', ord("\x08")), nzTpIcepk0o8('\x30' + chr(8597 - 8486) + chr(51) + '\x34' + '\064', 20135 - 20127), nzTpIcepk0o8('\060' + chr(0b1000101 + 0o52) + chr(1228 - 1173) + '\062', 8), nzTpIcepk0o8(chr(973 - 925) + chr(0b1101111) + chr(0b0 + 0o61) + '\061' + chr(1507 - 1458), 0o10), nzTpIcepk0o8(chr(264 - 216) + '\x6f' + chr(0b110011) + chr(562 - 509) + '\x36', 0o10), nzTpIcepk0o8(chr(0b101010 + 0o6) + chr(512 - 401) + '\061' + chr(0b110111) + chr(54), 0b1000), nzTpIcepk0o8('\060' + chr(6123 - 6012) + chr(51) + '\x30' + chr(54), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\063' + chr(0b101011 + 0o12) + chr(0b110010 + 0o0), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b110101 + 0o72) + '\061' + chr(415 - 361) + chr(49), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(50) + chr(0b100100 + 0o17) + '\x35', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b1010 + 0o51) + chr(2145 - 2097) + chr(0b110110 + 0o1), 32046 - 32038), nzTpIcepk0o8(chr(1547 - 1499) + chr(111) + '\065' + '\063', 51827 - 51819), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b101 + 0o55) + chr(0b110100) + chr(0b11101 + 0o25), 0o10), nzTpIcepk0o8(chr(48) + chr(5019 - 4908) + chr(50) + chr(50), 8), nzTpIcepk0o8(chr(502 - 454) + chr(0b1101111) + chr(54) + '\x37', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(126 - 76) + '\x30', 0o10), nzTpIcepk0o8('\060' + '\157' + chr(51) + chr(54) + chr(0b110100), ord("\x08")), nzTpIcepk0o8(chr(1616 - 1568) + chr(0b1101111) + chr(0b110010 + 0o0) + chr(49) + '\065', 0o10), nzTpIcepk0o8(chr(633 - 585) + '\157' + '\x35' + chr(0b110011 + 0o3), 9357 - 9349), nzTpIcepk0o8(chr(48) + chr(111) + '\x33' + '\067' + chr(0b110000 + 0o1), 18875 - 18867), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110010), 0b1000), nzTpIcepk0o8(chr(48) + '\157' + chr(754 - 705) + chr(53) + chr(54), ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(2159 - 2111) + '\157' + chr(0b110101) + '\060', 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'S'), chr(0b1100100) + chr(0b1100101) + '\143' + '\x6f' + chr(0b1100100) + '\145')(chr(0b1110101) + chr(2128 - 2012) + chr(2056 - 1954) + chr(422 - 377) + chr(1086 - 1030)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def xn_gDjYsgJLM(hXMPsSrOQzbh, sldzbHve8G1S):
try:
FfKOThdpoDTb = hXMPsSrOQzbh._bridge.imgmsg_to_cv2(sldzbHve8G1S)
if roI3spqORKae(nDF4gVNx0u9Q, roI3spqORKae(ES5oEprVxulp(b'6l+\xbcu\xc7\x97/\x03\x15\xab\xe3'), chr(0b1100100) + chr(3965 - 3864) + chr(99) + chr(0b1000110 + 0o51) + chr(0b110101 + 0o57) + chr(101))('\165' + chr(116) + '\x66' + '\055' + chr(383 - 327)))(FfKOThdpoDTb) > 255.0:
FfKOThdpoDTb = 255.0 * FfKOThdpoDTb / 1200.0
FfKOThdpoDTb = nDF4gVNx0u9Q.clip(FfKOThdpoDTb, 0.0, 255.0).xqAChpcBkssb(nDF4gVNx0u9Q.aZB1vwmdWU_M)
q8FQTuHBWXFI = Z1uLnGoVp7O0(FfKOThdpoDTb, frame=hXMPsSrOQzbh.j6C2nrwvuP04)
hXMPsSrOQzbh.QTpeDyuazoVC = q8FQTuHBWXFI.to_color()
except UtiWT6f6p9yZ:
hXMPsSrOQzbh.QTpeDyuazoVC = None |
BerkeleyAutomation/perception | perception/phoxi_sensor.py | PhoXiSensor._depth_im_callback | def _depth_im_callback(self, msg):
"""Callback for handling depth images.
"""
try:
self._cur_depth_im = DepthImage(self._bridge.imgmsg_to_cv2(msg) / 1000.0, frame=self._frame)
except:
self._cur_depth_im = None | python | def _depth_im_callback(self, msg):
"""Callback for handling depth images.
"""
try:
self._cur_depth_im = DepthImage(self._bridge.imgmsg_to_cv2(msg) / 1000.0, frame=self._frame)
except:
self._cur_depth_im = None | [
"def",
"_depth_im_callback",
"(",
"self",
",",
"msg",
")",
":",
"try",
":",
"self",
".",
"_cur_depth_im",
"=",
"DepthImage",
"(",
"self",
".",
"_bridge",
".",
"imgmsg_to_cv2",
"(",
"msg",
")",
"/",
"1000.0",
",",
"frame",
"=",
"self",
".",
"_frame",
")",
"except",
":",
"self",
".",
"_cur_depth_im",
"=",
"None"
] | Callback for handling depth images. | [
"Callback",
"for",
"handling",
"depth",
"images",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/phoxi_sensor.py#L238-L244 | train | Callback for handling depth images. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5u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bT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b1001 + 0o47) + chr(111) + chr(0b110011) + chr(314 - 262) + chr(0b1111 + 0o41), 0b1000), nzTpIcepk0o8(chr(48) + chr(10627 - 10516) + chr(0b11110 + 0o25) + chr(0b100101 + 0o22) + '\x31', 0o10), nzTpIcepk0o8('\060' + '\157' + chr(0b100000 + 0o22) + chr(0b101101 + 0o5) + chr(0b110000), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b100011 + 0o20) + '\066' + '\x33', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b101101 + 0o102) + '\x31' + chr(53) + '\060', 0b1000), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(0b111011 + 0o64) + chr(0b110010) + '\x33' + chr(0b110100), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(552 - 503) + chr(0b110111) + '\065', 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(0b10010 + 0o41) + chr(636 - 586) + '\x37', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b111100 + 0o63) + chr(51) + chr(0b110000) + chr(0b101111 + 0o4), 26205 - 26197), nzTpIcepk0o8(chr(48) + '\x6f' + chr(603 - 554) + '\063' + chr(50), 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(2209 - 2160) + '\x35' + chr(2082 - 2027), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\x33' + chr(2481 - 2427) + chr(48), ord("\x08")), nzTpIcepk0o8(chr(1928 - 1880) + '\x6f' + '\063' + '\x31' + chr(0b110010 + 0o4), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b11000 + 0o36) + chr(986 - 933), 49480 - 49472), nzTpIcepk0o8(chr(733 - 685) + chr(3768 - 3657) + '\063' + chr(0b10011 + 0o40) + '\x34', 0b1000), nzTpIcepk0o8(chr(1941 - 1893) + chr(111) + chr(1717 - 1667) + '\067' + chr(2412 - 2357), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + chr(0b10000 + 0o42) + chr(0b100111 + 0o13) + chr(55), 0o10), nzTpIcepk0o8(chr(48) + chr(7883 - 7772) + chr(0b10001 + 0o42) + chr(1420 - 1367) + chr(1206 - 1152), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1010011 + 0o34) + chr(0b100101 + 0o15) + chr(51) + chr(0b110000), 30380 - 30372), nzTpIcepk0o8('\060' + chr(111) + chr(0b110011) + chr(52) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x31' + '\065' + chr(0b110110 + 0o1), 8), nzTpIcepk0o8('\060' + chr(7282 - 7171) + chr(0b110011) + chr(0b110101) + '\x35', ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110011 + 0o0) + '\x33' + chr(0b11000 + 0o31), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\062' + chr(49) + chr(0b101011 + 0o11), 0b1000), nzTpIcepk0o8('\x30' + '\157' + '\062' + chr(0b110100) + chr(0b110001), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b100010 + 0o115) + '\061' + '\060' + chr(0b110100), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x33' + '\x31', 44353 - 44345), nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(0b1101111) + '\x32' + chr(0b100110 + 0o15) + chr(0b1011 + 0o45), 8), nzTpIcepk0o8('\060' + chr(1484 - 1373) + chr(207 - 156) + '\x36' + '\067', 3464 - 3456), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110010) + chr(2290 - 2241) + chr(55), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1010101 + 0o32) + '\x31' + chr(52) + chr(1838 - 1789), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(0b100101 + 0o14) + chr(48) + '\062', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(272 - 222) + chr(0b110000), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(0b100000 + 0o21) + chr(49) + '\061', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(9914 - 9803) + '\062' + chr(53) + '\x30', 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b1000 + 0o53) + chr(55) + chr(51), 53074 - 53066), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b1010 + 0o54), 0b1000), nzTpIcepk0o8(chr(0b1000 + 0o50) + chr(0b1101111) + '\x33' + chr(0b110011) + chr(54), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(6321 - 6210) + chr(0b11101 + 0o26) + chr(369 - 319) + chr(539 - 486), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(556 - 505) + chr(1605 - 1556) + chr(50), 32111 - 32103)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(1201 - 1153) + chr(111) + '\x35' + chr(0b101100 + 0o4), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xce'), chr(0b1001000 + 0o34) + '\x65' + '\x63' + chr(111) + '\144' + '\145')(chr(0b1011111 + 0o26) + chr(0b1010001 + 0o43) + chr(0b1100110) + chr(45) + chr(2884 - 2828)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def QHqrrY0o7rBx(hXMPsSrOQzbh, sldzbHve8G1S):
try:
hXMPsSrOQzbh.svGVTE2PWnC2 = Ctd7ihpXT1E5(hXMPsSrOQzbh._bridge.imgmsg_to_cv2(sldzbHve8G1S) / 1000.0, frame=hXMPsSrOQzbh.j6C2nrwvuP04)
except UtiWT6f6p9yZ:
hXMPsSrOQzbh.svGVTE2PWnC2 = None |
BerkeleyAutomation/perception | perception/phoxi_sensor.py | PhoXiSensor._normal_map_callback | def _normal_map_callback(self, msg):
"""Callback for handling normal maps.
"""
try:
self._cur_normal_map = self._bridge.imgmsg_to_cv2(msg)
except:
self._cur_normal_map = None | python | def _normal_map_callback(self, msg):
"""Callback for handling normal maps.
"""
try:
self._cur_normal_map = self._bridge.imgmsg_to_cv2(msg)
except:
self._cur_normal_map = None | [
"def",
"_normal_map_callback",
"(",
"self",
",",
"msg",
")",
":",
"try",
":",
"self",
".",
"_cur_normal_map",
"=",
"self",
".",
"_bridge",
".",
"imgmsg_to_cv2",
"(",
"msg",
")",
"except",
":",
"self",
".",
"_cur_normal_map",
"=",
"None"
] | Callback for handling normal maps. | [
"Callback",
"for",
"handling",
"normal",
"maps",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/phoxi_sensor.py#L246-L252 | train | Callback for handling normal maps. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT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7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(1006 - 958) + '\x6f' + chr(0b11011 + 0o32) + chr(0b110111 + 0o0), 0o10), nzTpIcepk0o8(chr(0b10001 + 0o37) + chr(111) + '\x32' + chr(0b110 + 0o52) + chr(54), ord("\x08")), nzTpIcepk0o8(chr(251 - 203) + '\157' + '\x33' + chr(0b110110) + chr(0b1 + 0o64), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1010011 + 0o34) + chr(0b110010) + '\x31' + chr(1203 - 1155), 14419 - 14411), nzTpIcepk0o8(chr(1560 - 1512) + chr(0b1101111) + chr(1053 - 1002) + '\x35' + chr(0b110001), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b1000 + 0o53) + '\065' + chr(367 - 317), 0o10), nzTpIcepk0o8(chr(2045 - 1997) + '\x6f' + chr(1923 - 1874) + '\x37' + chr(538 - 490), 0o10), nzTpIcepk0o8(chr(0b100110 + 0o12) + chr(0b1101111) + '\x36' + chr(762 - 709), 0b1000), nzTpIcepk0o8(chr(0b1101 + 0o43) + '\x6f' + chr(0b0 + 0o61) + '\060' + chr(0b1011 + 0o51), 0b1000), nzTpIcepk0o8('\x30' + chr(0b110110 + 0o71) + chr(1782 - 1732) + chr(0b10110 + 0o33) + chr(0b0 + 0o62), 0o10), nzTpIcepk0o8(chr(0b101001 + 0o7) + '\x6f' + '\x33' + chr(0b110111) + '\x34', 7102 - 7094), nzTpIcepk0o8(chr(1876 - 1828) + '\157' + '\061' + chr(53) + chr(2596 - 2541), 0o10), nzTpIcepk0o8(chr(264 - 216) + chr(111) + '\x32' + chr(49) + chr(0b110000 + 0o0), 8), nzTpIcepk0o8(chr(1826 - 1778) + '\157' + chr(2091 - 2040) + chr(55) + chr(0b110011), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x33' + chr(0b110000) + '\x35', 0b1000), nzTpIcepk0o8(chr(206 - 158) + chr(0b100 + 0o153) + chr(223 - 173) + '\062' + '\x33', 23342 - 23334), nzTpIcepk0o8(chr(474 - 426) + chr(8332 - 8221) + chr(0b11101 + 0o26) + chr(0b110011) + chr(0b100010 + 0o24), 15398 - 15390), nzTpIcepk0o8('\x30' + chr(111) + chr(0b10100 + 0o37) + '\x32' + '\x30', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1000 + 0o147) + chr(53) + chr(619 - 571), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(2854 - 2799) + chr(0b110101), 0o10), nzTpIcepk0o8(chr(0b11010 + 0o26) + '\x6f' + chr(0b101111 + 0o3) + chr(52), 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(1852 - 1797) + '\062', 0b1000), nzTpIcepk0o8(chr(0b1001 + 0o47) + '\157' + chr(0b110011) + '\x37' + '\x35', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(2279 - 2230) + chr(0b10001 + 0o42) + chr(0b110101), 0b1000), nzTpIcepk0o8(chr(48) + chr(9277 - 9166) + chr(53) + chr(1019 - 970), 0b1000), nzTpIcepk0o8(chr(0b10111 + 0o31) + '\157' + '\x32' + '\x37' + '\x34', 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x32' + '\x30' + chr(0b10001 + 0o40), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b101000 + 0o107) + '\065' + '\060', 8), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b101011 + 0o6) + chr(1851 - 1803) + chr(0b1101 + 0o45), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\063' + chr(49) + chr(0b110110), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110010) + chr(0b0 + 0o65) + chr(0b110110), 0o10), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(0b1101111) + '\062' + '\x32' + chr(0b110101), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + '\061' + chr(48) + chr(53), 0o10), nzTpIcepk0o8(chr(855 - 807) + chr(0b1101111) + chr(0b110001) + chr(780 - 732) + '\061', 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110011) + chr(0b1110 + 0o42) + '\061', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(49) + chr(0b110 + 0o55) + chr(0b1111 + 0o43), ord("\x08")), nzTpIcepk0o8(chr(0b1010 + 0o46) + chr(111) + chr(0b110101) + chr(48), 8), nzTpIcepk0o8(chr(0b110000) + chr(10409 - 10298) + chr(2856 - 2801) + '\061', 0b1000), nzTpIcepk0o8(chr(48) + chr(6062 - 5951) + '\066' + chr(50), 14399 - 14391), nzTpIcepk0o8(chr(0b110000) + chr(7024 - 6913) + chr(796 - 746) + '\063' + chr(1921 - 1873), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(947 - 899) + '\x6f' + chr(0b110101) + chr(0b10101 + 0o33), 8)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x01'), chr(0b101101 + 0o67) + '\145' + '\143' + '\x6f' + '\144' + chr(0b1 + 0o144))(chr(11027 - 10910) + chr(0b11101 + 0o127) + chr(0b11000 + 0o116) + chr(45) + chr(2494 - 2438)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def hTCYCTfQjLaS(hXMPsSrOQzbh, sldzbHve8G1S):
try:
hXMPsSrOQzbh.uwlT5TAhvlzq = hXMPsSrOQzbh._bridge.imgmsg_to_cv2(sldzbHve8G1S)
except UtiWT6f6p9yZ:
hXMPsSrOQzbh.uwlT5TAhvlzq = None |
BerkeleyAutomation/perception | perception/opencv_camera_sensor.py | OpenCVCameraSensor.start | def start(self):
""" Starts the OpenCVCameraSensor Stream
Raises:
Exception if unable to open stream
"""
self._sensor = cv2.VideoCapture(self._device_id)
if not self._sensor.isOpened():
raise Exception("Unable to open OpenCVCameraSensor for id {0}".format(self._device_id))
self.flush() | python | def start(self):
""" Starts the OpenCVCameraSensor Stream
Raises:
Exception if unable to open stream
"""
self._sensor = cv2.VideoCapture(self._device_id)
if not self._sensor.isOpened():
raise Exception("Unable to open OpenCVCameraSensor for id {0}".format(self._device_id))
self.flush() | [
"def",
"start",
"(",
"self",
")",
":",
"self",
".",
"_sensor",
"=",
"cv2",
".",
"VideoCapture",
"(",
"self",
".",
"_device_id",
")",
"if",
"not",
"self",
".",
"_sensor",
".",
"isOpened",
"(",
")",
":",
"raise",
"Exception",
"(",
"\"Unable to open OpenCVCameraSensor for id {0}\"",
".",
"format",
"(",
"self",
".",
"_device_id",
")",
")",
"self",
".",
"flush",
"(",
")"
] | Starts the OpenCVCameraSensor Stream
Raises:
Exception if unable to open stream | [
"Starts",
"the",
"OpenCVCameraSensor",
"Stream",
"Raises",
":",
"Exception",
"if",
"unable",
"to",
"open",
"stream"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/opencv_camera_sensor.py#L18-L26 | train | Starts the OpenCVCameraSensor Stream
| GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOVzf,YikXQdxs3VoO,UBvEeZympYSz,mRTjFWUmjlQA,QhZRiM1qvaW7,WbNHlDKpyPtQ,z18h6aCn31dg,oxjHmqoBrCHG,GA4ANb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4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b101011 + 0o5) + chr(0b10000 + 0o137) + chr(53) + chr(50), 64999 - 64991), nzTpIcepk0o8(chr(386 - 338) + chr(111) + '\064' + chr(1250 - 1201), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b111100 + 0o63) + chr(682 - 630) + chr(0b1011 + 0o52), 5318 - 5310), nzTpIcepk0o8(chr(0b11101 + 0o23) + '\x6f' + chr(0b110001) + '\067' + chr(0b10110 + 0o37), 62217 - 62209), nzTpIcepk0o8(chr(48) + '\x6f' + '\062' + '\x34' + chr(51), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(51) + '\060' + chr(0b110001), 37967 - 37959), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(1253 - 1202) + '\x30' + '\x30', 0o10), nzTpIcepk0o8(chr(0b110000 + 0o0) + '\x6f' + '\062' + chr(0b1101 + 0o44) + chr(1118 - 1069), 64386 - 64378), nzTpIcepk0o8(chr(48) + chr(111) + chr(53) + '\063', 0b1000), nzTpIcepk0o8(chr(2167 - 2119) + chr(8990 - 8879) + chr(0b110001) + chr(0b1000 + 0o51) + chr(54), 0o10), nzTpIcepk0o8(chr(0b11101 + 0o23) + '\157' + chr(1087 - 1037) + chr(0b11111 + 0o21) + chr(1214 - 1166), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(49) + chr(1469 - 1419) + chr(1927 - 1873), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(6163 - 6052) + '\x31' + chr(0b1010 + 0o53) + chr(0b101010 + 0o13), 0b1000), nzTpIcepk0o8(chr(0b101101 + 0o3) + chr(0b101000 + 0o107) + chr(640 - 590) + chr(1907 - 1853) + chr(924 - 875), 21520 - 21512), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110110) + '\066', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(51) + chr(0b11111 + 0o22) + '\067', 43972 - 43964), nzTpIcepk0o8(chr(48) + chr(5800 - 5689) + '\063' + '\063' + chr(1795 - 1744), 40257 - 40249), nzTpIcepk0o8('\060' + chr(0b1100100 + 0o13) + chr(0b110100) + chr(51), 4678 - 4670), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110011 + 0o0), ord("\x08")), nzTpIcepk0o8(chr(1154 - 1106) + chr(111) + chr(726 - 675) + chr(0b101100 + 0o12) + '\x37', 0b1000), nzTpIcepk0o8(chr(48) + chr(967 - 856) + '\x35' + chr(0b100001 + 0o25), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\063' + chr(0b101011 + 0o14) + chr(0b110100), 0o10), nzTpIcepk0o8(chr(1355 - 1307) + chr(0b10000 + 0o137) + chr(207 - 157) + chr(49) + chr(1651 - 1596), 13171 - 13163), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b100110 + 0o14) + chr(0b100111 + 0o15) + chr(0b110000), 0b1000), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(0b1101111) + '\x32' + chr(0b110110) + '\067', 0b1000), nzTpIcepk0o8('\060' + chr(11866 - 11755) + chr(0b1100 + 0o46) + chr(1405 - 1354) + chr(0b11101 + 0o24), 0o10), nzTpIcepk0o8(chr(1985 - 1937) + chr(0b1101111) + chr(51) + '\066', 47212 - 47204), nzTpIcepk0o8(chr(1806 - 1758) + chr(0b1010110 + 0o31) + '\063' + chr(2362 - 2311) + chr(0b10 + 0o57), 38748 - 38740), nzTpIcepk0o8(chr(48) + '\x6f' + chr(2172 - 2121) + '\x34' + chr(0b110000 + 0o0), 0o10), nzTpIcepk0o8(chr(1053 - 1005) + chr(0b1001001 + 0o46) + chr(492 - 439) + chr(0b110100), 62525 - 62517), nzTpIcepk0o8('\060' + '\157' + chr(0b110010) + chr(0b110010 + 0o1) + chr(1286 - 1237), 8), nzTpIcepk0o8(chr(918 - 870) + chr(111) + chr(1345 - 1295) + chr(2147 - 2099) + '\061', 0o10), nzTpIcepk0o8(chr(48) + chr(6336 - 6225) + chr(0b101 + 0o54) + chr(1736 - 1688) + '\x33', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b100111 + 0o14) + '\067' + chr(0b100010 + 0o17), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(0b110011) + chr(0b1110 + 0o50) + chr(0b110110), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + '\061' + '\065' + chr(0b110101), 8), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1055 - 1001) + chr(53), 0b1000), nzTpIcepk0o8(chr(633 - 585) + '\157' + '\062' + chr(0b110101) + chr(55), 53119 - 53111), nzTpIcepk0o8(chr(497 - 449) + chr(0b11111 + 0o120) + chr(0b11 + 0o57) + chr(0b110001) + chr(1325 - 1275), 32135 - 32127), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(52) + '\x34', 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + '\x6f' + chr(53) + chr(48), 41037 - 41029)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x04'), '\144' + chr(101) + chr(3841 - 3742) + chr(0b1101111) + chr(7858 - 7758) + chr(0b1100101))(chr(117) + chr(0b1110100) + chr(102) + chr(1555 - 1510) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def KQbHFTcl_LKy(hXMPsSrOQzbh):
hXMPsSrOQzbh.KfyHOFJp4aOe = EpB3PnRz6N5d.VideoCapture(hXMPsSrOQzbh._device_id)
if not roI3spqORKae(hXMPsSrOQzbh._sensor, roI3spqORKae(ES5oEprVxulp(b'CRj\r\xc6\xaf\xa5\xed'), chr(4676 - 4576) + chr(101) + '\x63' + '\157' + chr(100) + '\145')('\x75' + '\x74' + chr(0b1100110) + chr(45) + chr(2372 - 2316)))():
raise zfo2Sgkz3IVJ(roI3spqORKae(roI3spqORKae(ES5oEprVxulp(b'\x7fOD\x1f\xcf\xa4\xe0\xfdDn\xef&\x08\xdf\x16\x80\xabFm\xb4x\xbf\xee\xcd\xd2\xeb\x7f\x8a\x85B\xea\xee1\xd9\x90\x02G\x8f\xe3@\nZ\x15\x00'), chr(0b1100100) + chr(9097 - 8996) + chr(0b1100011) + '\157' + '\144' + chr(0b101110 + 0o67))(chr(0b1110101) + chr(10743 - 10627) + '\x66' + chr(869 - 824) + chr(56)), roI3spqORKae(ES5oEprVxulp(b'[\x12\x166\xe4\xf2\xa6\xe6z\x11\xc3\x1c'), chr(0b1100100) + '\145' + chr(99) + chr(111) + chr(0b101100 + 0o70) + chr(0b1010 + 0o133))('\x75' + chr(0b1001110 + 0o46) + chr(0b1100110) + chr(0b101101) + '\070'))(roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'uE@\x0b\xca\xa2\xa5\xd6B*'), '\x64' + chr(0b1100101) + chr(2614 - 2515) + '\157' + '\x64' + chr(0b1001010 + 0o33))(chr(0b110100 + 0o101) + chr(11187 - 11071) + chr(0b1100110) + chr(639 - 594) + '\070'))))
roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'AvU\x04\xe1\xb3\x96\xdei>\xf3\x13'), '\x64' + '\145' + chr(3383 - 3284) + chr(0b1101101 + 0o2) + '\144' + '\145')('\165' + chr(0b10011 + 0o141) + chr(0b100011 + 0o103) + chr(45) + chr(56)))() |
BerkeleyAutomation/perception | perception/opencv_camera_sensor.py | OpenCVCameraSensor.frames | def frames(self, flush=True):
""" Returns the latest color image from the stream
Raises:
Exception if opencv sensor gives ret_val of 0
"""
self.flush()
ret_val, frame = self._sensor.read()
if not ret_val:
raise Exception("Unable to retrieve frame from OpenCVCameraSensor for id {0}".format(self._device_id))
frame = cv2.cvtColor(frame, cv2.COLOR_BGR2RGB)
if self._upside_down:
frame = np.flipud(frame).astype(np.uint8)
frame = np.fliplr(frame).astype(np.uint8)
return ColorImage(frame) | python | def frames(self, flush=True):
""" Returns the latest color image from the stream
Raises:
Exception if opencv sensor gives ret_val of 0
"""
self.flush()
ret_val, frame = self._sensor.read()
if not ret_val:
raise Exception("Unable to retrieve frame from OpenCVCameraSensor for id {0}".format(self._device_id))
frame = cv2.cvtColor(frame, cv2.COLOR_BGR2RGB)
if self._upside_down:
frame = np.flipud(frame).astype(np.uint8)
frame = np.fliplr(frame).astype(np.uint8)
return ColorImage(frame) | [
"def",
"frames",
"(",
"self",
",",
"flush",
"=",
"True",
")",
":",
"self",
".",
"flush",
"(",
")",
"ret_val",
",",
"frame",
"=",
"self",
".",
"_sensor",
".",
"read",
"(",
")",
"if",
"not",
"ret_val",
":",
"raise",
"Exception",
"(",
"\"Unable to retrieve frame from OpenCVCameraSensor for id {0}\"",
".",
"format",
"(",
"self",
".",
"_device_id",
")",
")",
"frame",
"=",
"cv2",
".",
"cvtColor",
"(",
"frame",
",",
"cv2",
".",
"COLOR_BGR2RGB",
")",
"if",
"self",
".",
"_upside_down",
":",
"frame",
"=",
"np",
".",
"flipud",
"(",
"frame",
")",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
"frame",
"=",
"np",
".",
"fliplr",
"(",
"frame",
")",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
"return",
"ColorImage",
"(",
"frame",
")"
] | Returns the latest color image from the stream
Raises:
Exception if opencv sensor gives ret_val of 0 | [
"Returns",
"the",
"latest",
"color",
"image",
"from",
"the",
"stream",
"Raises",
":",
"Exception",
"if",
"opencv",
"sensor",
"gives",
"ret_val",
"of",
"0"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/opencv_camera_sensor.py#L36-L49 | train | Returns the latest color image from the stream | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7e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Warning,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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\060' + '\x6f' + chr(792 - 738) + '\060', ord("\x08")), nzTpIcepk0o8(chr(1964 - 1916) + '\x6f' + '\x35' + chr(0b100010 + 0o23), 0b1000), nzTpIcepk0o8(chr(830 - 782) + '\x6f' + chr(51) + chr(0b10 + 0o60) + '\060', 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(1194 - 1141) + '\x34', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(1150 - 1099) + chr(0b0 + 0o64) + '\066', 0b1000), nzTpIcepk0o8(chr(0b100000 + 0o20) + chr(0b101101 + 0o102) + chr(49) + '\x35' + '\x33', 0b1000), nzTpIcepk0o8(chr(48) + chr(0b111011 + 0o64) + '\x33' + chr(53) + chr(2080 - 2031), 0o10), nzTpIcepk0o8(chr(1681 - 1633) + chr(0b1101111) + '\x33' + chr(50) + '\066', ord("\x08")), nzTpIcepk0o8(chr(353 - 305) + chr(0b1101101 + 0o2) + chr(0b11101 + 0o26) + '\063' + chr(0b11 + 0o62), 7423 - 7415), nzTpIcepk0o8('\060' + '\157' + '\x33' + '\x31' + '\x32', 47419 - 47411), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\062' + chr(0b110110) + chr(1198 - 1148), ord("\x08")), nzTpIcepk0o8(chr(0b1101 + 0o43) + chr(0b11001 + 0o126) + chr(55), 0o10), nzTpIcepk0o8(chr(48) + chr(237 - 126) + chr(0b110010) + chr(0b110101) + '\067', 58895 - 58887), nzTpIcepk0o8(chr(0b100000 + 0o20) + chr(111) + chr(89 - 40) + chr(0b10011 + 0o44) + '\066', 31303 - 31295), nzTpIcepk0o8('\060' + '\x6f' + chr(0b1010 + 0o51) + chr(0b1101 + 0o50) + '\x36', 0b1000), nzTpIcepk0o8(chr(0b100110 + 0o12) + '\x6f' + chr(0b100001 + 0o20) + chr(54) + '\064', 16971 - 16963), nzTpIcepk0o8('\060' + chr(9709 - 9598) + chr(0b110111) + chr(49), 60549 - 60541), nzTpIcepk0o8(chr(2291 - 2243) + '\157' + chr(247 - 197) + chr(55) + chr(0b100110 + 0o12), 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(1335 - 1284) + '\062' + chr(0b11111 + 0o25), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110001) + chr(393 - 344) + '\065', 0o10), nzTpIcepk0o8('\060' + chr(7008 - 6897) + chr(0b101100 + 0o6) + '\x35' + chr(0b110101 + 0o1), 0o10), nzTpIcepk0o8(chr(0b100 + 0o54) + '\x6f' + '\x36' + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(1976 - 1927) + '\x33' + chr(55), 0o10), nzTpIcepk0o8(chr(0b11110 + 0o22) + chr(111) + '\x32' + chr(343 - 289) + '\x30', 0b1000), nzTpIcepk0o8('\060' + '\157' + '\062' + '\062' + '\x36', 0b1000), nzTpIcepk0o8(chr(48) + chr(0b111100 + 0o63) + chr(0b110010) + chr(53) + chr(0b1011 + 0o45), 46050 - 46042), nzTpIcepk0o8(chr(0b11011 + 0o25) + '\157' + '\061' + '\062', 0b1000), nzTpIcepk0o8('\060' + '\157' + '\061' + chr(55) + chr(0b11000 + 0o34), 34518 - 34510), nzTpIcepk0o8(chr(0b11111 + 0o21) + chr(111) + chr(1677 - 1624) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(1913 - 1865) + chr(0b1101111) + chr(2409 - 2359) + chr(0b110101) + '\x35', 0o10), nzTpIcepk0o8(chr(48) + '\157' + '\x32' + chr(0b110001) + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b11111 + 0o26), ord("\x08")), nzTpIcepk0o8(chr(132 - 84) + chr(111) + chr(0b11111 + 0o22) + chr(49) + chr(53), 8), nzTpIcepk0o8('\060' + chr(111) + chr(50) + '\x30' + chr(0b110110), 0o10), nzTpIcepk0o8(chr(1937 - 1889) + chr(0b1101111) + chr(0b1010 + 0o50) + chr(49) + '\062', 62858 - 62850), nzTpIcepk0o8(chr(116 - 68) + chr(9037 - 8926) + chr(53), 8), nzTpIcepk0o8(chr(2116 - 2068) + '\157' + '\x32' + '\x35' + chr(49), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b100110 + 0o111) + '\x31' + '\x32' + chr(0b110111), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(50) + chr(48) + '\063', ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(2218 - 2169) + chr(0b110010) + chr(0b101000 + 0o13), 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + chr(4263 - 4152) + '\065' + chr(0b110000), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x1e'), chr(6613 - 6513) + chr(8157 - 8056) + '\x63' + chr(111) + chr(0b10011 + 0o121) + chr(7009 - 6908))(chr(0b1100001 + 0o24) + '\164' + '\x66' + '\x2d' + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def G4Lisexwxqjs(hXMPsSrOQzbh, kWpyBrVWBpsE=nzTpIcepk0o8(chr(48) + chr(0b111010 + 0o65) + chr(0b0 + 0o61), 0o10)):
roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'[z\xa0U\xa4\x19\xbf\x81\x9f\xba\xc1B'), chr(0b1100100) + '\x65' + chr(0b1100011) + chr(0b1101111) + '\x64' + chr(0b1011000 + 0o15))(chr(117) + '\x74' + chr(8055 - 7953) + chr(0b101101) + chr(0b111000)))()
(g1Ev6aC4OlWO, KZ4ew2qs1HTO) = hXMPsSrOQzbh._sensor.eoXknH7XUn7m()
if not g1Ev6aC4OlWO:
raise zfo2Sgkz3IVJ(roI3spqORKae(roI3spqORKae(ES5oEprVxulp(b'eC\xb1N\x8a\x0e\xc9\xa2\xb2\xea\xc0b\xdb\x0c\x87\x11O\xdd\xf4+\xdcP2\xd5\xb6\xcex\x13D\x8d\xc6u(\xe8\xc9S\xea6\xee6BL\x83I\x88\x18\x86\xa4\xfd\xac\xddu\x8f\x17\x8aTB\x88\xa9'), '\144' + chr(7038 - 6937) + chr(0b1100011) + chr(10740 - 10629) + chr(3425 - 3325) + chr(0b1011111 + 0o6))('\165' + chr(0b1101100 + 0o10) + '\x66' + chr(0b11100 + 0o21) + chr(0b100101 + 0o23)), roI3spqORKae(ES5oEprVxulp(b'A\x1e\xe3g\xa1X\x8f\xb9\x8c\x95\xf1M'), chr(0b1100100) + '\x65' + chr(99) + chr(111) + chr(2218 - 2118) + chr(0b110000 + 0o65))(chr(0b1010 + 0o153) + chr(8661 - 8545) + chr(6583 - 6481) + chr(0b10 + 0o53) + chr(2212 - 2156)))(roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'oI\xb5Z\x8f\x08\x8c\x89\xb4\xae'), chr(0b1100100) + '\x65' + chr(6683 - 6584) + chr(0b1101111) + chr(0b11011 + 0o111) + chr(0b111000 + 0o55))(chr(11214 - 11097) + chr(116) + chr(0b111011 + 0o53) + chr(1298 - 1253) + chr(0b111000)))))
KZ4ew2qs1HTO = EpB3PnRz6N5d.cvtColor(KZ4ew2qs1HTO, EpB3PnRz6N5d.COLOR_BGR2RGB)
if roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'oX\xa0_\x8f\x0f\x8c\x89\xb9\xa5\xc5i'), chr(0b1100100) + chr(101) + chr(8196 - 8097) + chr(0b111111 + 0o60) + chr(0b1100100) + chr(0b1100101))(chr(117) + '\x74' + chr(6901 - 6799) + chr(0b10011 + 0o32) + chr(56))):
KZ4ew2qs1HTO = nDF4gVNx0u9Q.flipud(KZ4ew2qs1HTO).xqAChpcBkssb(nDF4gVNx0u9Q.aZB1vwmdWU_M)
KZ4ew2qs1HTO = nDF4gVNx0u9Q.fliplr(KZ4ew2qs1HTO).xqAChpcBkssb(nDF4gVNx0u9Q.aZB1vwmdWU_M)
return lPn7XfHAFaXG(KZ4ew2qs1HTO) |
BerkeleyAutomation/perception | perception/detector.py | RgbdDetection.image | def image(self, render_mode):
""" Get the image associated with a particular render mode """
if render_mode == RenderMode.SEGMASK:
return self.query_im
elif render_mode == RenderMode.COLOR:
return self.color_im
elif render_mode == RenderMode.DEPTH:
return self.depth_im
else:
raise ValueError('Render mode %s not supported' %(render_mode)) | python | def image(self, render_mode):
""" Get the image associated with a particular render mode """
if render_mode == RenderMode.SEGMASK:
return self.query_im
elif render_mode == RenderMode.COLOR:
return self.color_im
elif render_mode == RenderMode.DEPTH:
return self.depth_im
else:
raise ValueError('Render mode %s not supported' %(render_mode)) | [
"def",
"image",
"(",
"self",
",",
"render_mode",
")",
":",
"if",
"render_mode",
"==",
"RenderMode",
".",
"SEGMASK",
":",
"return",
"self",
".",
"query_im",
"elif",
"render_mode",
"==",
"RenderMode",
".",
"COLOR",
":",
"return",
"self",
".",
"color_im",
"elif",
"render_mode",
"==",
"RenderMode",
".",
"DEPTH",
":",
"return",
"self",
".",
"depth_im",
"else",
":",
"raise",
"ValueError",
"(",
"'Render mode %s not supported'",
"%",
"(",
"render_mode",
")",
")"
] | Get the image associated with a particular render mode | [
"Get",
"the",
"image",
"associated",
"with",
"a",
"particular",
"render",
"mode"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/detector.py#L101-L110 | train | Returns the image associated with a particular render mode | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E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kv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + '\157' + chr(0b10001 + 0o41) + chr(1903 - 1854) + '\x35', 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1050 - 1000) + chr(2256 - 2205) + chr(53), ord("\x08")), nzTpIcepk0o8(chr(1387 - 1339) + chr(0b1010111 + 0o30) + chr(51) + '\064' + '\062', 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110011) + chr(0b110010) + '\x36', 19558 - 19550), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(1701 - 1650) + chr(52), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x32' + chr(49) + '\061', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(3991 - 3880) + chr(0b110010) + chr(0b110101) + chr(0b1 + 0o57), 0o10), nzTpIcepk0o8(chr(1096 - 1048) + '\157' + chr(761 - 712), 0o10), nzTpIcepk0o8(chr(68 - 20) + '\157' + '\062' + chr(0b11111 + 0o21) + '\066', 30731 - 30723), nzTpIcepk0o8('\x30' + '\157' + '\x31' + chr(0b101000 + 0o17) + '\064', 37859 - 37851), nzTpIcepk0o8('\x30' + chr(111) + '\061' + chr(500 - 446) + chr(0b110110), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\061' + chr(1717 - 1664) + chr(0b110000), ord("\x08")), nzTpIcepk0o8(chr(1123 - 1075) + '\x6f' + chr(1635 - 1587), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(389 - 339) + '\061' + chr(52), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(0b110011) + chr(2309 - 2256) + '\x31', 37077 - 37069), nzTpIcepk0o8('\x30' + chr(0b1010000 + 0o37) + chr(0b10010 + 0o44) + chr(1622 - 1568), 0o10), nzTpIcepk0o8(chr(48) + chr(5678 - 5567) + chr(0b110011) + chr(0b110110), 0b1000), nzTpIcepk0o8(chr(1475 - 1427) + chr(11527 - 11416) + '\062' + chr(0b110111 + 0o0) + chr(2841 - 2787), 39542 - 39534), nzTpIcepk0o8(chr(0b110000) + chr(2507 - 2396) + chr(0b110001) + chr(2371 - 2320) + chr(50), 0b1000), nzTpIcepk0o8(chr(0b1100 + 0o44) + chr(1411 - 1300) + chr(0b110001) + '\x35' + chr(0b110001), 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(0b110001) + chr(227 - 177) + '\060', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b111001 + 0o66) + '\x33' + chr(0b110100) + chr(49), 45431 - 45423), nzTpIcepk0o8('\x30' + '\x6f' + chr(51) + chr(0b1101 + 0o45) + chr(51), 0b1000), nzTpIcepk0o8(chr(1003 - 955) + chr(11608 - 11497) + chr(0b110100) + chr(50), 65428 - 65420), nzTpIcepk0o8(chr(1451 - 1403) + '\157' + chr(55) + '\062', 0o10), nzTpIcepk0o8(chr(1600 - 1552) + chr(7514 - 7403) + '\062' + chr(0b110010) + chr(55), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x33' + chr(0b100101 + 0o16) + chr(233 - 185), 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(0b11101 + 0o25) + chr(1198 - 1147) + '\x35', 8), nzTpIcepk0o8('\x30' + '\157' + chr(0b101110 + 0o5) + '\063', ord("\x08")), nzTpIcepk0o8(chr(0b1001 + 0o47) + '\157' + '\062' + chr(2121 - 2072) + '\x33', 0b1000), nzTpIcepk0o8('\x30' + chr(111) + '\x31' + chr(1971 - 1917) + chr(49), 0o10), nzTpIcepk0o8(chr(0b1100 + 0o44) + '\x6f' + chr(486 - 437) + chr(55) + chr(53), 38900 - 38892), nzTpIcepk0o8('\060' + '\x6f' + chr(50) + chr(291 - 236) + chr(0b101101 + 0o3), 690 - 682), nzTpIcepk0o8(chr(2218 - 2170) + chr(8606 - 8495) + chr(50) + chr(1534 - 1484) + chr(49), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(4526 - 4415) + '\x31' + chr(0b110001) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(762 - 712) + '\062' + chr(1305 - 1256), 8), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x32' + chr(2028 - 1975), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + '\067' + chr(0b100011 + 0o22), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(682 - 632) + chr(0b1111 + 0o42) + chr(1745 - 1690), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + chr(0b11110 + 0o24) + chr(0b110111) + chr(0b10001 + 0o37), 8)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b1 + 0o57) + '\157' + '\065' + '\060', 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xa3'), chr(100) + chr(101) + chr(0b1100011) + '\x6f' + chr(0b1010001 + 0o23) + '\145')('\165' + chr(0b1110100) + '\146' + chr(1458 - 1413) + chr(0b111000)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def qqETtneJqWI2(hXMPsSrOQzbh, IF6XPl_JIrPU):
if IF6XPl_JIrPU == roI3spqORKae(qcvjnKeI4Yc1, roI3spqORKae(ES5oEprVxulp(b'\xde\xd8\xa5\x9b]\xda\xe3'), chr(100) + '\145' + chr(2966 - 2867) + chr(111) + '\x64' + chr(4170 - 4069))(chr(117) + '\164' + '\146' + chr(0b101101) + chr(213 - 157))):
return roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xfc\xe8\x87\xa4e\xd6\xc1l'), chr(6034 - 5934) + chr(101) + chr(7814 - 7715) + chr(0b1101111) + chr(2528 - 2428) + chr(9142 - 9041))('\165' + '\164' + '\x66' + chr(0b101101) + chr(466 - 410)))
elif IF6XPl_JIrPU == roI3spqORKae(qcvjnKeI4Yc1, roI3spqORKae(ES5oEprVxulp(b'\xce\xd2\xae\x99N'), '\144' + chr(0b1100101) + chr(0b100011 + 0o100) + chr(111) + '\144' + '\x65')(chr(0b1000101 + 0o60) + chr(116) + chr(102) + '\055' + chr(0b10000 + 0o50))):
return roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xee\xf2\x8e\xb9n\xd6\xc1l'), chr(645 - 545) + '\145' + chr(0b1100011) + chr(111) + chr(0b110010 + 0o62) + '\x65')('\x75' + chr(116) + chr(0b1011000 + 0o16) + chr(45) + chr(56)))
elif IF6XPl_JIrPU == roI3spqORKae(qcvjnKeI4Yc1, roI3spqORKae(ES5oEprVxulp(b'\xc9\xd8\xb2\x82T'), '\x64' + chr(0b1100101) + '\143' + chr(111) + chr(0b1100100) + '\x65')(chr(117) + chr(13423 - 13307) + '\146' + chr(0b101101) + chr(2553 - 2497))):
return roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xe9\xf8\x92\xa2t\xd6\xc1l'), '\x64' + '\x65' + chr(0b1100011) + '\157' + chr(100) + chr(2852 - 2751))(chr(0b111111 + 0o66) + chr(7496 - 7380) + chr(8713 - 8611) + chr(45) + '\070'))
else:
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\xdf\xf8\x8c\xb2y\xfb\x88l\xe9\x18\x13H%\xff\xc9Xq\xcaz\x1a%\x91\xa3MH\xe3\xbd\xf9'), chr(0b110110 + 0o56) + chr(0b1100101) + '\x63' + chr(0b1101111) + chr(100) + '\x65')(chr(0b1110101) + '\164' + chr(995 - 893) + chr(1652 - 1607) + chr(0b111000)) % IF6XPl_JIrPU) |
BerkeleyAutomation/perception | perception/detector.py | RgbdForegroundMaskDetector.detect | def detect(self, color_im, depth_im, cfg, camera_intr=None,
T_camera_world=None, segmask=None):
"""
Detects all relevant objects in an rgbd image pair using foreground masking.
Parameters
----------
color_im : :obj:`ColorImage`
color image for detection
depth_im : :obj:`DepthImage`
depth image for detection (corresponds to color image)
cfg : :obj:`YamlConfig`
parameters of detection function
camera_intr : :obj:`CameraIntrinsics`
intrinsics of the camera
T_camera_world : :obj:`autolab_core.RigidTransform`
registration of the camera to world frame
segmask : :obj:`BinaryImage`
optional segmask of invalid pixels
Returns
------
:obj:`list` of :obj:`RgbdDetection`
all detections in the image
"""
# read params
foreground_mask_tolerance = cfg['foreground_mask_tolerance']
min_contour_area = cfg['min_contour_area']
max_contour_area = cfg['max_contour_area']
w = cfg['filter_dim']
# mask image using background detection
bgmodel = color_im.background_model()
binary_im = color_im.foreground_mask(foreground_mask_tolerance, bgmodel=bgmodel)
# filter the image
y, x = np.ogrid[-w/2+1:w/2+1, -w/2+1:w/2+1]
mask = x*x + y*y <= w/2*w/2
filter_struct = np.zeros([w,w]).astype(np.uint8)
filter_struct[mask] = 1
binary_im_filtered = binary_im.apply(snm.grey_closing, structure=filter_struct)
visualize = False
if visualize:
plt.figure()
plt.imshow(binary_im_filtered.data, cmap=plt.cm.gray)
plt.axis('off')
plt.show()
# find all contours
contours = binary_im_filtered.find_contours(min_area=min_contour_area, max_area=max_contour_area)
# convert contours to detections
detections = []
for contour in contours:
box = contour.bounding_box
color_thumbnail = color_im.crop(box.height, box.width, box.ci, box.cj)
depth_thumbnail = depth_im.crop(box.height, box.width, box.ci, box.cj)
binary_thumbnail = binary_im_filtered.crop(box.height, box.width, box.ci, box.cj)
thumbnail_intr = camera_intr
if camera_intr is not None:
thumbnail_intr = camera_intr.crop(box.height, box.width, box.ci, box.cj)
detections.append(RgbdDetection(color_thumbnail,
depth_thumbnail,
box,
binary_thumbnail=binary_thumbnail,
contour=contour,
camera_intr=thumbnail_intr))
return detections | python | def detect(self, color_im, depth_im, cfg, camera_intr=None,
T_camera_world=None, segmask=None):
"""
Detects all relevant objects in an rgbd image pair using foreground masking.
Parameters
----------
color_im : :obj:`ColorImage`
color image for detection
depth_im : :obj:`DepthImage`
depth image for detection (corresponds to color image)
cfg : :obj:`YamlConfig`
parameters of detection function
camera_intr : :obj:`CameraIntrinsics`
intrinsics of the camera
T_camera_world : :obj:`autolab_core.RigidTransform`
registration of the camera to world frame
segmask : :obj:`BinaryImage`
optional segmask of invalid pixels
Returns
------
:obj:`list` of :obj:`RgbdDetection`
all detections in the image
"""
# read params
foreground_mask_tolerance = cfg['foreground_mask_tolerance']
min_contour_area = cfg['min_contour_area']
max_contour_area = cfg['max_contour_area']
w = cfg['filter_dim']
# mask image using background detection
bgmodel = color_im.background_model()
binary_im = color_im.foreground_mask(foreground_mask_tolerance, bgmodel=bgmodel)
# filter the image
y, x = np.ogrid[-w/2+1:w/2+1, -w/2+1:w/2+1]
mask = x*x + y*y <= w/2*w/2
filter_struct = np.zeros([w,w]).astype(np.uint8)
filter_struct[mask] = 1
binary_im_filtered = binary_im.apply(snm.grey_closing, structure=filter_struct)
visualize = False
if visualize:
plt.figure()
plt.imshow(binary_im_filtered.data, cmap=plt.cm.gray)
plt.axis('off')
plt.show()
# find all contours
contours = binary_im_filtered.find_contours(min_area=min_contour_area, max_area=max_contour_area)
# convert contours to detections
detections = []
for contour in contours:
box = contour.bounding_box
color_thumbnail = color_im.crop(box.height, box.width, box.ci, box.cj)
depth_thumbnail = depth_im.crop(box.height, box.width, box.ci, box.cj)
binary_thumbnail = binary_im_filtered.crop(box.height, box.width, box.ci, box.cj)
thumbnail_intr = camera_intr
if camera_intr is not None:
thumbnail_intr = camera_intr.crop(box.height, box.width, box.ci, box.cj)
detections.append(RgbdDetection(color_thumbnail,
depth_thumbnail,
box,
binary_thumbnail=binary_thumbnail,
contour=contour,
camera_intr=thumbnail_intr))
return detections | [
"def",
"detect",
"(",
"self",
",",
"color_im",
",",
"depth_im",
",",
"cfg",
",",
"camera_intr",
"=",
"None",
",",
"T_camera_world",
"=",
"None",
",",
"segmask",
"=",
"None",
")",
":",
"# read params",
"foreground_mask_tolerance",
"=",
"cfg",
"[",
"'foreground_mask_tolerance'",
"]",
"min_contour_area",
"=",
"cfg",
"[",
"'min_contour_area'",
"]",
"max_contour_area",
"=",
"cfg",
"[",
"'max_contour_area'",
"]",
"w",
"=",
"cfg",
"[",
"'filter_dim'",
"]",
"# mask image using background detection",
"bgmodel",
"=",
"color_im",
".",
"background_model",
"(",
")",
"binary_im",
"=",
"color_im",
".",
"foreground_mask",
"(",
"foreground_mask_tolerance",
",",
"bgmodel",
"=",
"bgmodel",
")",
"# filter the image",
"y",
",",
"x",
"=",
"np",
".",
"ogrid",
"[",
"-",
"w",
"/",
"2",
"+",
"1",
":",
"w",
"/",
"2",
"+",
"1",
",",
"-",
"w",
"/",
"2",
"+",
"1",
":",
"w",
"/",
"2",
"+",
"1",
"]",
"mask",
"=",
"x",
"*",
"x",
"+",
"y",
"*",
"y",
"<=",
"w",
"/",
"2",
"*",
"w",
"/",
"2",
"filter_struct",
"=",
"np",
".",
"zeros",
"(",
"[",
"w",
",",
"w",
"]",
")",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
"filter_struct",
"[",
"mask",
"]",
"=",
"1",
"binary_im_filtered",
"=",
"binary_im",
".",
"apply",
"(",
"snm",
".",
"grey_closing",
",",
"structure",
"=",
"filter_struct",
")",
"visualize",
"=",
"False",
"if",
"visualize",
":",
"plt",
".",
"figure",
"(",
")",
"plt",
".",
"imshow",
"(",
"binary_im_filtered",
".",
"data",
",",
"cmap",
"=",
"plt",
".",
"cm",
".",
"gray",
")",
"plt",
".",
"axis",
"(",
"'off'",
")",
"plt",
".",
"show",
"(",
")",
"# find all contours",
"contours",
"=",
"binary_im_filtered",
".",
"find_contours",
"(",
"min_area",
"=",
"min_contour_area",
",",
"max_area",
"=",
"max_contour_area",
")",
"# convert contours to detections",
"detections",
"=",
"[",
"]",
"for",
"contour",
"in",
"contours",
":",
"box",
"=",
"contour",
".",
"bounding_box",
"color_thumbnail",
"=",
"color_im",
".",
"crop",
"(",
"box",
".",
"height",
",",
"box",
".",
"width",
",",
"box",
".",
"ci",
",",
"box",
".",
"cj",
")",
"depth_thumbnail",
"=",
"depth_im",
".",
"crop",
"(",
"box",
".",
"height",
",",
"box",
".",
"width",
",",
"box",
".",
"ci",
",",
"box",
".",
"cj",
")",
"binary_thumbnail",
"=",
"binary_im_filtered",
".",
"crop",
"(",
"box",
".",
"height",
",",
"box",
".",
"width",
",",
"box",
".",
"ci",
",",
"box",
".",
"cj",
")",
"thumbnail_intr",
"=",
"camera_intr",
"if",
"camera_intr",
"is",
"not",
"None",
":",
"thumbnail_intr",
"=",
"camera_intr",
".",
"crop",
"(",
"box",
".",
"height",
",",
"box",
".",
"width",
",",
"box",
".",
"ci",
",",
"box",
".",
"cj",
")",
"detections",
".",
"append",
"(",
"RgbdDetection",
"(",
"color_thumbnail",
",",
"depth_thumbnail",
",",
"box",
",",
"binary_thumbnail",
"=",
"binary_thumbnail",
",",
"contour",
"=",
"contour",
",",
"camera_intr",
"=",
"thumbnail_intr",
")",
")",
"return",
"detections"
] | Detects all relevant objects in an rgbd image pair using foreground masking.
Parameters
----------
color_im : :obj:`ColorImage`
color image for detection
depth_im : :obj:`DepthImage`
depth image for detection (corresponds to color image)
cfg : :obj:`YamlConfig`
parameters of detection function
camera_intr : :obj:`CameraIntrinsics`
intrinsics of the camera
T_camera_world : :obj:`autolab_core.RigidTransform`
registration of the camera to world frame
segmask : :obj:`BinaryImage`
optional segmask of invalid pixels
Returns
------
:obj:`list` of :obj:`RgbdDetection`
all detections in the image | [
"Detects",
"all",
"relevant",
"objects",
"in",
"an",
"rgbd",
"image",
"pair",
"using",
"foreground",
"masking",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/detector.py#L149-L217 | train | Detects all relevant objects in an rgbd image pair using foreground masking. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4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D,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(0b100101 + 0o112) + chr(1730 - 1680) + '\063', ord("\x08")), nzTpIcepk0o8('\x30' + chr(1941 - 1830) + '\x32' + chr(48) + '\064', 16299 - 16291), nzTpIcepk0o8('\x30' + chr(0b1000100 + 0o53) + chr(0b110011) + chr(0b110001) + chr(54), 0o10), nzTpIcepk0o8(chr(0b100000 + 0o20) + chr(0b1001100 + 0o43) + chr(0b110001) + chr(0b1001 + 0o54) + chr(0b110110), 12739 - 12731), nzTpIcepk0o8(chr(48) + chr(111) + '\061' + chr(0b110111) + chr(929 - 874), 0b1000), nzTpIcepk0o8(chr(48) + chr(6460 - 6349) + '\x31' + '\x32' + '\x31', 38919 - 38911), nzTpIcepk0o8('\x30' + chr(111) + '\x31' + chr(0b1101 + 0o44) + chr(0b11000 + 0o37), 0o10), nzTpIcepk0o8(chr(312 - 264) + '\x6f' + chr(0b110010) + '\x36' + chr(0b11011 + 0o32), 0b1000), nzTpIcepk0o8(chr(48) + chr(714 - 603) + chr(49) + chr(0b110110), 35853 - 35845), nzTpIcepk0o8('\x30' + chr(0b100100 + 0o113) + chr(49) + chr(0b100110 + 0o13) + '\x36', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1000 + 0o147) + chr(968 - 917) + chr(485 - 436) + '\060', 7360 - 7352), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\063' + chr(0b110001) + chr(1269 - 1221), 8), nzTpIcepk0o8(chr(0b101111 + 0o1) + chr(111) + chr(0b10100 + 0o36) + chr(1118 - 1065) + '\060', 0o10), nzTpIcepk0o8(chr(0b1 + 0o57) + chr(0b1010 + 0o145) + chr(51) + chr(0b100010 + 0o20) + chr(0b101101 + 0o6), ord("\x08")), nzTpIcepk0o8(chr(496 - 448) + '\157' + chr(51) + '\x36' + chr(0b110000), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110010) + '\x31' + chr(55), 14374 - 14366), nzTpIcepk0o8('\060' + chr(0b111 + 0o150) + chr(50) + '\067' + chr(48), 0o10), nzTpIcepk0o8(chr(0b1 + 0o57) + chr(0b1100000 + 0o17) + chr(1527 - 1473) + chr(110 - 56), 0o10), nzTpIcepk0o8('\060' + chr(1124 - 1013) + chr(51) + chr(51) + '\x31', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(2450 - 2339) + chr(0b10101 + 0o35) + chr(0b110010) + '\x34', 0b1000), nzTpIcepk0o8(chr(1209 - 1161) + '\x6f' + chr(0b10100 + 0o36) + chr(0b10100 + 0o34), ord("\x08")), nzTpIcepk0o8(chr(660 - 612) + chr(6965 - 6854) + chr(1232 - 1183) + chr(51) + '\x31', 2173 - 2165), nzTpIcepk0o8('\060' + chr(0b1101010 + 0o5) + '\062' + chr(0b110110) + chr(1455 - 1407), 0o10), nzTpIcepk0o8(chr(712 - 664) + '\157' + chr(0b1001 + 0o56) + chr(0b110000), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(483 - 433) + '\x35' + chr(0b10011 + 0o40), ord("\x08")), nzTpIcepk0o8(chr(0b100011 + 0o15) + chr(0b1101111) + chr(0b11011 + 0o27) + chr(1712 - 1660) + '\x34', 26047 - 26039), nzTpIcepk0o8(chr(1452 - 1404) + '\157' + chr(50) + chr(1556 - 1504) + chr(52), 8), nzTpIcepk0o8(chr(0b110000) + '\157' + '\062' + chr(0b110101) + '\x36', 0b1000), nzTpIcepk0o8('\060' + chr(9841 - 9730) + '\063' + chr(0b100111 + 0o15) + chr(1415 - 1362), 0o10), nzTpIcepk0o8(chr(165 - 117) + chr(583 - 472) + chr(0b110010) + chr(0b100101 + 0o17) + '\x36', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1010010 + 0o35) + chr(0b10111 + 0o32) + chr(658 - 608) + '\062', 0b1000), nzTpIcepk0o8('\x30' + chr(2740 - 2629) + chr(0b1000 + 0o51) + chr(0b10111 + 0o31) + chr(50), 0o10), nzTpIcepk0o8(chr(0b11001 + 0o27) + '\x6f' + chr(0b110010) + chr(817 - 766) + chr(0b1110 + 0o47), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110001) + chr(0b110100) + chr(48), 43168 - 43160), nzTpIcepk0o8(chr(0b110000) + chr(1747 - 1636) + '\x32', 0b1000), nzTpIcepk0o8(chr(1868 - 1820) + chr(7125 - 7014) + chr(0b101110 + 0o5) + chr(218 - 165) + '\061', 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x31' + chr(49) + '\066', 8), nzTpIcepk0o8(chr(1533 - 1485) + chr(0b100101 + 0o112) + '\062' + chr(0b0 + 0o61) + '\x37', 8), nzTpIcepk0o8(chr(0b11110 + 0o22) + chr(0b1100000 + 0o17) + chr(0b1011 + 0o47) + chr(53) + chr(1826 - 1771), ord("\x08")), nzTpIcepk0o8(chr(0b111 + 0o51) + chr(9159 - 9048) + chr(51) + chr(1610 - 1555) + chr(0b11001 + 0o36), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(0b1101011 + 0o4) + chr(53) + '\x30', 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'='), chr(0b10011 + 0o121) + chr(8321 - 8220) + '\143' + chr(111) + '\144' + chr(101))(chr(117) + chr(0b1010001 + 0o43) + chr(8148 - 8046) + chr(0b101101) + chr(0b10101 + 0o43)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def KCHfuNuJY4BH(hXMPsSrOQzbh, GFVgEmwvG0jZ, WZcCXRnThfxU, v3DD0K4I9igJ, wgYNRnQWtrEG=None, bml1vBwpIyzY=None, uGhmBzyWgv_A=None):
Cntm4eD2V2OT = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'u\xeb\xbc\x0b\x18# \xc0`*\x97\xa5\xc9\xa0\x9b\xd0\xccY\xb5\xf1b8\xde[\xce'), chr(0b111001 + 0o53) + chr(251 - 150) + chr(0b1100011) + chr(0b1010000 + 0o37) + chr(3690 - 3590) + chr(0b1100011 + 0o2))('\165' + '\x74' + chr(102) + chr(169 - 124) + chr(708 - 652))]
lfg28qa5j5ei = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'~\xed\xa01\x1c>!\xc1a;\xba\x97\xc9\xa1\x95\xee'), chr(0b111100 + 0o50) + chr(0b11100 + 0o111) + '\143' + chr(0b1011011 + 0o24) + chr(4919 - 4819) + '\145')(chr(0b1000110 + 0o57) + '\164' + chr(102) + chr(966 - 921) + '\070')]
_KS6tfhVhGj_ = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'~\xe5\xb61\x1c>!\xc1a;\xba\x97\xc9\xa1\x95\xee'), '\x64' + chr(0b1100101) + chr(99) + '\x6f' + '\x64' + chr(0b1100101))(chr(117) + chr(0b1110100) + chr(102) + '\055' + chr(0b101001 + 0o17))]
sm7_CLmeWGR7 = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'u\xed\xa2\x1a\x1a#\x10\xd1g#'), chr(100) + '\x65' + '\143' + chr(0b1011011 + 0o24) + '\144' + chr(0b1100101))(chr(117) + chr(0b1000111 + 0o55) + chr(0b10 + 0o144) + '\x2d' + chr(1701 - 1645))]
MLvji1aaS6HF = GFVgEmwvG0jZ.background_model()
yMN3wUHEhDLY = GFVgEmwvG0jZ.foreground_mask(Cntm4eD2V2OT, bgmodel=MLvji1aaS6HF)
(Fi3yzxctM1zW, bI5jsQ9OkQtj) = nDF4gVNx0u9Q.ogrid[-sm7_CLmeWGR7 / nzTpIcepk0o8(chr(0b10111 + 0o31) + chr(111) + chr(0b110010), 8) + nzTpIcepk0o8('\060' + chr(0b1001110 + 0o41) + '\x31', 0o10):sm7_CLmeWGR7 / nzTpIcepk0o8('\060' + '\157' + chr(0b110010), 8) + nzTpIcepk0o8('\x30' + '\157' + '\x31', 8), -sm7_CLmeWGR7 / nzTpIcepk0o8('\x30' + chr(10933 - 10822) + chr(50), 8) + nzTpIcepk0o8(chr(1527 - 1479) + '\x6f' + chr(0b11101 + 0o24), 8):sm7_CLmeWGR7 / nzTpIcepk0o8(chr(0b110000) + chr(0b1100101 + 0o12) + '\x32', 8) + nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b101000 + 0o11), 8)]
BBM8dxm7YWge = bI5jsQ9OkQtj * bI5jsQ9OkQtj + Fi3yzxctM1zW * Fi3yzxctM1zW <= sm7_CLmeWGR7 / nzTpIcepk0o8(chr(48) + chr(111) + chr(0b10000 + 0o42), 8) * sm7_CLmeWGR7 / nzTpIcepk0o8('\x30' + '\157' + '\062', 8)
QPppo3i50evp = nDF4gVNx0u9Q.zeros([sm7_CLmeWGR7, sm7_CLmeWGR7]).xqAChpcBkssb(nDF4gVNx0u9Q.aZB1vwmdWU_M)
QPppo3i50evp[BBM8dxm7YWge] = nzTpIcepk0o8('\060' + '\x6f' + '\x31', 8)
gwheshWPFHtV = yMN3wUHEhDLY.apply(NCLBGpFJImZ_.grey_closing, structure=QPppo3i50evp)
isQPFgqNd00m = nzTpIcepk0o8('\060' + chr(8865 - 8754) + '\060', 0o10)
if isQPFgqNd00m:
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'v\xf7\xfe4I55\xf6f\x1d\x84\xfd'), chr(0b1000101 + 0o37) + chr(0b1100101) + chr(0b1011100 + 0o7) + chr(111) + '\x64' + chr(5485 - 5384))('\165' + '\164' + '\x66' + '\055' + chr(1078 - 1022)))()
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'z\xe9\xbd\x06\x10&'), chr(0b11001 + 0o113) + chr(0b100001 + 0o104) + chr(0b100011 + 0o100) + chr(0b1101111) + chr(100) + chr(0b111010 + 0o53))('\x75' + chr(2881 - 2765) + chr(0b1001011 + 0o33) + '\x2d' + chr(56)))(roI3spqORKae(gwheshWPFHtV, roI3spqORKae(ES5oEprVxulp(b'U\xe2\x85!+9+\xc5a\n\x9c\xaa'), chr(0b1000011 + 0o41) + chr(101) + '\143' + chr(0b1101111) + chr(0b1000 + 0o134) + chr(101))('\x75' + '\x74' + chr(0b11001 + 0o115) + chr(279 - 234) + chr(56))), cmap=roI3spqORKae(Z7HGgmIyegqz.cm, roI3spqORKae(ES5oEprVxulp(b't\xf6\xaf\x17'), chr(9417 - 9317) + chr(0b10111 + 0o116) + '\143' + chr(0b1101111 + 0o0) + '\x64' + chr(101))(chr(3642 - 3525) + chr(10033 - 9917) + '\146' + chr(45) + chr(2060 - 2004))))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'Y\xc0\xf7^M!9\xccM\x02\x80\xf9'), '\144' + chr(2648 - 2547) + '\x63' + chr(9287 - 9176) + chr(0b101011 + 0o71) + '\x65')(chr(117) + chr(6432 - 6316) + chr(102) + '\x2d' + '\070'))(roI3spqORKae(ES5oEprVxulp(b'|\xe2\xa8'), chr(100) + '\145' + chr(0b1011100 + 0o7) + chr(0b1101111) + '\x64' + chr(101))(chr(0b1100010 + 0o23) + chr(116) + chr(102) + chr(45) + chr(1983 - 1927)))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'u\xd3\x8b\x03\x1a\x19\x18\xc1Q\x11\x84\xb2'), chr(8639 - 8539) + chr(101) + chr(9454 - 9355) + chr(111) + chr(0b1010110 + 0o16) + '\145')('\x75' + '\164' + chr(0b1100110) + '\055' + chr(0b111000)))()
aMtoOZWkl57Y = gwheshWPFHtV.find_contours(min_area=lfg28qa5j5ei, max_area=_KS6tfhVhGj_)
Ddqq_KJiUyMj = []
for AyBXIsYKwGw5 in aMtoOZWkl57Y:
zCpo5MKsMnlF = AyBXIsYKwGw5.bounding_box
WwizskcCQveS = GFVgEmwvG0jZ.crop(zCpo5MKsMnlF.PaEBmun9J0YJ, zCpo5MKsMnlF.dH3vcKdvgBu0, zCpo5MKsMnlF.ci, zCpo5MKsMnlF.cj)
emtSjD_A2mpW = WZcCXRnThfxU.crop(zCpo5MKsMnlF.PaEBmun9J0YJ, zCpo5MKsMnlF.dH3vcKdvgBu0, zCpo5MKsMnlF.ci, zCpo5MKsMnlF.cj)
flutRBqQMHUR = gwheshWPFHtV.crop(zCpo5MKsMnlF.PaEBmun9J0YJ, zCpo5MKsMnlF.dH3vcKdvgBu0, zCpo5MKsMnlF.ci, zCpo5MKsMnlF.cj)
VGfJf3mobI8j = wgYNRnQWtrEG
if wgYNRnQWtrEG is not None:
VGfJf3mobI8j = wgYNRnQWtrEG.crop(zCpo5MKsMnlF.PaEBmun9J0YJ, zCpo5MKsMnlF.dH3vcKdvgBu0, zCpo5MKsMnlF.ci, zCpo5MKsMnlF.cj)
roI3spqORKae(Ddqq_KJiUyMj, roI3spqORKae(ES5oEprVxulp(b'[\xd0\x9dZ\x076\x08\xdad!\x9d\xfd'), '\x64' + '\145' + '\143' + chr(0b111100 + 0o63) + chr(0b1000011 + 0o41) + '\x65')(chr(0b1110101) + '\164' + '\146' + '\x2d' + '\x38'))(c8ZY0Gppk1hk(WwizskcCQveS, emtSjD_A2mpW, zCpo5MKsMnlF, binary_thumbnail=flutRBqQMHUR, contour=AyBXIsYKwGw5, camera_intr=VGfJf3mobI8j))
return Ddqq_KJiUyMj |
BerkeleyAutomation/perception | perception/detector.py | RgbdForegroundMaskQueryImageDetector._segment_color | def _segment_color(self, color_im, bounding_box, bgmodel, cfg, vis_segmentation=False):
""" Re-segments a color image to isolate an object of interest using foreground masking and kmeans """
# read params
foreground_mask_tolerance = cfg['foreground_mask_tolerance']
color_seg_rgb_weight = cfg['color_seg_rgb_weight']
color_seg_num_clusters = cfg['color_seg_num_clusters']
color_seg_hsv_weight = cfg['color_seg_hsv_weight']
color_seg_dist_pctile = cfg['color_seg_dist_pctile']
color_seg_dist_thresh = cfg['color_seg_dist_thresh']
color_seg_min_bg_dist = cfg['color_seg_min_bg_dist']
min_contour_area= cfg['min_contour_area']
contour_dist_thresh = cfg['contour_dist_thresh']
# foreground masking
binary_im = color_im.foreground_mask(foreground_mask_tolerance, bgmodel=bgmodel)
binary_im = binary_im.prune_contours(area_thresh=min_contour_area, dist_thresh=contour_dist_thresh)
if binary_im is None:
return None, None, None
color_im = color_im.mask_binary(binary_im)
# kmeans segmentation
segment_im = color_im.segment_kmeans(color_seg_rgb_weight,
color_seg_num_clusters,
hue_weight=color_seg_hsv_weight)
# keep the segment that is farthest from the background
bg_dists = []
hsv_bgmodel = 255 * np.array(colorsys.rgb_to_hsv(float(bgmodel[0]) / 255,
float(bgmodel[1]) / 255,
float(bgmodel[2]) / 255))
hsv_bgmodel = np.r_[color_seg_rgb_weight * np.array(bgmodel), color_seg_hsv_weight * hsv_bgmodel[:1]]
for k in range(segment_im.num_segments-1):
seg_mask = segment_im.segment_mask(k)
color_im_segment = color_im.mask_binary(seg_mask)
color_im_segment_data = color_im_segment.nonzero_data()
color_im_segment_data = np.c_[color_seg_rgb_weight * color_im_segment_data, color_seg_hsv_weight * color_im_segment.nonzero_hsv_data()[:,:1]]
# take the median distance from the background
bg_dist = np.median(np.linalg.norm(color_im_segment_data - hsv_bgmodel, axis=1))
if vis_segmentation:
logging.info('BG Dist for segment %d: %.4f' %(k, bg_dist))
bg_dists.append(bg_dist)
# sort by distance
dists_and_indices = zip(np.arange(len(bg_dists)), bg_dists)
dists_and_indices.sort(key = lambda x: x[1], reverse=True)
# mask out the segment in the binary image
if color_seg_num_clusters > 1 and abs(dists_and_indices[0][1] - dists_and_indices[1][1]) > color_seg_dist_thresh and dists_and_indices[1][1] < color_seg_min_bg_dist:
obj_segment = dists_and_indices[0][0]
obj_seg_mask = segment_im.segment_mask(obj_segment)
binary_im = binary_im.mask_binary(obj_seg_mask)
binary_im, diff_px = binary_im.center_nonzero()
bounding_box = Box(bounding_box.min_pt.astype(np.float32) - diff_px,
bounding_box.max_pt.astype(np.float32) - diff_px,
bounding_box.frame)
if vis_segmentation:
plt.figure()
plt.subplot(1,3,1)
plt.imshow(color_im.data)
plt.axis('off')
plt.subplot(1,3,2)
plt.imshow(segment_im.data)
plt.colorbar()
plt.axis('off')
plt.subplot(1,3,3)
plt.imshow(binary_im.data, cmap=plt.cm.gray)
plt.axis('off')
plt.show()
return binary_im, segment_im, bounding_box | python | def _segment_color(self, color_im, bounding_box, bgmodel, cfg, vis_segmentation=False):
""" Re-segments a color image to isolate an object of interest using foreground masking and kmeans """
# read params
foreground_mask_tolerance = cfg['foreground_mask_tolerance']
color_seg_rgb_weight = cfg['color_seg_rgb_weight']
color_seg_num_clusters = cfg['color_seg_num_clusters']
color_seg_hsv_weight = cfg['color_seg_hsv_weight']
color_seg_dist_pctile = cfg['color_seg_dist_pctile']
color_seg_dist_thresh = cfg['color_seg_dist_thresh']
color_seg_min_bg_dist = cfg['color_seg_min_bg_dist']
min_contour_area= cfg['min_contour_area']
contour_dist_thresh = cfg['contour_dist_thresh']
# foreground masking
binary_im = color_im.foreground_mask(foreground_mask_tolerance, bgmodel=bgmodel)
binary_im = binary_im.prune_contours(area_thresh=min_contour_area, dist_thresh=contour_dist_thresh)
if binary_im is None:
return None, None, None
color_im = color_im.mask_binary(binary_im)
# kmeans segmentation
segment_im = color_im.segment_kmeans(color_seg_rgb_weight,
color_seg_num_clusters,
hue_weight=color_seg_hsv_weight)
# keep the segment that is farthest from the background
bg_dists = []
hsv_bgmodel = 255 * np.array(colorsys.rgb_to_hsv(float(bgmodel[0]) / 255,
float(bgmodel[1]) / 255,
float(bgmodel[2]) / 255))
hsv_bgmodel = np.r_[color_seg_rgb_weight * np.array(bgmodel), color_seg_hsv_weight * hsv_bgmodel[:1]]
for k in range(segment_im.num_segments-1):
seg_mask = segment_im.segment_mask(k)
color_im_segment = color_im.mask_binary(seg_mask)
color_im_segment_data = color_im_segment.nonzero_data()
color_im_segment_data = np.c_[color_seg_rgb_weight * color_im_segment_data, color_seg_hsv_weight * color_im_segment.nonzero_hsv_data()[:,:1]]
# take the median distance from the background
bg_dist = np.median(np.linalg.norm(color_im_segment_data - hsv_bgmodel, axis=1))
if vis_segmentation:
logging.info('BG Dist for segment %d: %.4f' %(k, bg_dist))
bg_dists.append(bg_dist)
# sort by distance
dists_and_indices = zip(np.arange(len(bg_dists)), bg_dists)
dists_and_indices.sort(key = lambda x: x[1], reverse=True)
# mask out the segment in the binary image
if color_seg_num_clusters > 1 and abs(dists_and_indices[0][1] - dists_and_indices[1][1]) > color_seg_dist_thresh and dists_and_indices[1][1] < color_seg_min_bg_dist:
obj_segment = dists_and_indices[0][0]
obj_seg_mask = segment_im.segment_mask(obj_segment)
binary_im = binary_im.mask_binary(obj_seg_mask)
binary_im, diff_px = binary_im.center_nonzero()
bounding_box = Box(bounding_box.min_pt.astype(np.float32) - diff_px,
bounding_box.max_pt.astype(np.float32) - diff_px,
bounding_box.frame)
if vis_segmentation:
plt.figure()
plt.subplot(1,3,1)
plt.imshow(color_im.data)
plt.axis('off')
plt.subplot(1,3,2)
plt.imshow(segment_im.data)
plt.colorbar()
plt.axis('off')
plt.subplot(1,3,3)
plt.imshow(binary_im.data, cmap=plt.cm.gray)
plt.axis('off')
plt.show()
return binary_im, segment_im, bounding_box | [
"def",
"_segment_color",
"(",
"self",
",",
"color_im",
",",
"bounding_box",
",",
"bgmodel",
",",
"cfg",
",",
"vis_segmentation",
"=",
"False",
")",
":",
"# read params",
"foreground_mask_tolerance",
"=",
"cfg",
"[",
"'foreground_mask_tolerance'",
"]",
"color_seg_rgb_weight",
"=",
"cfg",
"[",
"'color_seg_rgb_weight'",
"]",
"color_seg_num_clusters",
"=",
"cfg",
"[",
"'color_seg_num_clusters'",
"]",
"color_seg_hsv_weight",
"=",
"cfg",
"[",
"'color_seg_hsv_weight'",
"]",
"color_seg_dist_pctile",
"=",
"cfg",
"[",
"'color_seg_dist_pctile'",
"]",
"color_seg_dist_thresh",
"=",
"cfg",
"[",
"'color_seg_dist_thresh'",
"]",
"color_seg_min_bg_dist",
"=",
"cfg",
"[",
"'color_seg_min_bg_dist'",
"]",
"min_contour_area",
"=",
"cfg",
"[",
"'min_contour_area'",
"]",
"contour_dist_thresh",
"=",
"cfg",
"[",
"'contour_dist_thresh'",
"]",
"# foreground masking",
"binary_im",
"=",
"color_im",
".",
"foreground_mask",
"(",
"foreground_mask_tolerance",
",",
"bgmodel",
"=",
"bgmodel",
")",
"binary_im",
"=",
"binary_im",
".",
"prune_contours",
"(",
"area_thresh",
"=",
"min_contour_area",
",",
"dist_thresh",
"=",
"contour_dist_thresh",
")",
"if",
"binary_im",
"is",
"None",
":",
"return",
"None",
",",
"None",
",",
"None",
"color_im",
"=",
"color_im",
".",
"mask_binary",
"(",
"binary_im",
")",
"# kmeans segmentation",
"segment_im",
"=",
"color_im",
".",
"segment_kmeans",
"(",
"color_seg_rgb_weight",
",",
"color_seg_num_clusters",
",",
"hue_weight",
"=",
"color_seg_hsv_weight",
")",
"# keep the segment that is farthest from the background",
"bg_dists",
"=",
"[",
"]",
"hsv_bgmodel",
"=",
"255",
"*",
"np",
".",
"array",
"(",
"colorsys",
".",
"rgb_to_hsv",
"(",
"float",
"(",
"bgmodel",
"[",
"0",
"]",
")",
"/",
"255",
",",
"float",
"(",
"bgmodel",
"[",
"1",
"]",
")",
"/",
"255",
",",
"float",
"(",
"bgmodel",
"[",
"2",
"]",
")",
"/",
"255",
")",
")",
"hsv_bgmodel",
"=",
"np",
".",
"r_",
"[",
"color_seg_rgb_weight",
"*",
"np",
".",
"array",
"(",
"bgmodel",
")",
",",
"color_seg_hsv_weight",
"*",
"hsv_bgmodel",
"[",
":",
"1",
"]",
"]",
"for",
"k",
"in",
"range",
"(",
"segment_im",
".",
"num_segments",
"-",
"1",
")",
":",
"seg_mask",
"=",
"segment_im",
".",
"segment_mask",
"(",
"k",
")",
"color_im_segment",
"=",
"color_im",
".",
"mask_binary",
"(",
"seg_mask",
")",
"color_im_segment_data",
"=",
"color_im_segment",
".",
"nonzero_data",
"(",
")",
"color_im_segment_data",
"=",
"np",
".",
"c_",
"[",
"color_seg_rgb_weight",
"*",
"color_im_segment_data",
",",
"color_seg_hsv_weight",
"*",
"color_im_segment",
".",
"nonzero_hsv_data",
"(",
")",
"[",
":",
",",
":",
"1",
"]",
"]",
"# take the median distance from the background",
"bg_dist",
"=",
"np",
".",
"median",
"(",
"np",
".",
"linalg",
".",
"norm",
"(",
"color_im_segment_data",
"-",
"hsv_bgmodel",
",",
"axis",
"=",
"1",
")",
")",
"if",
"vis_segmentation",
":",
"logging",
".",
"info",
"(",
"'BG Dist for segment %d: %.4f'",
"%",
"(",
"k",
",",
"bg_dist",
")",
")",
"bg_dists",
".",
"append",
"(",
"bg_dist",
")",
"# sort by distance",
"dists_and_indices",
"=",
"zip",
"(",
"np",
".",
"arange",
"(",
"len",
"(",
"bg_dists",
")",
")",
",",
"bg_dists",
")",
"dists_and_indices",
".",
"sort",
"(",
"key",
"=",
"lambda",
"x",
":",
"x",
"[",
"1",
"]",
",",
"reverse",
"=",
"True",
")",
"# mask out the segment in the binary image",
"if",
"color_seg_num_clusters",
">",
"1",
"and",
"abs",
"(",
"dists_and_indices",
"[",
"0",
"]",
"[",
"1",
"]",
"-",
"dists_and_indices",
"[",
"1",
"]",
"[",
"1",
"]",
")",
">",
"color_seg_dist_thresh",
"and",
"dists_and_indices",
"[",
"1",
"]",
"[",
"1",
"]",
"<",
"color_seg_min_bg_dist",
":",
"obj_segment",
"=",
"dists_and_indices",
"[",
"0",
"]",
"[",
"0",
"]",
"obj_seg_mask",
"=",
"segment_im",
".",
"segment_mask",
"(",
"obj_segment",
")",
"binary_im",
"=",
"binary_im",
".",
"mask_binary",
"(",
"obj_seg_mask",
")",
"binary_im",
",",
"diff_px",
"=",
"binary_im",
".",
"center_nonzero",
"(",
")",
"bounding_box",
"=",
"Box",
"(",
"bounding_box",
".",
"min_pt",
".",
"astype",
"(",
"np",
".",
"float32",
")",
"-",
"diff_px",
",",
"bounding_box",
".",
"max_pt",
".",
"astype",
"(",
"np",
".",
"float32",
")",
"-",
"diff_px",
",",
"bounding_box",
".",
"frame",
")",
"if",
"vis_segmentation",
":",
"plt",
".",
"figure",
"(",
")",
"plt",
".",
"subplot",
"(",
"1",
",",
"3",
",",
"1",
")",
"plt",
".",
"imshow",
"(",
"color_im",
".",
"data",
")",
"plt",
".",
"axis",
"(",
"'off'",
")",
"plt",
".",
"subplot",
"(",
"1",
",",
"3",
",",
"2",
")",
"plt",
".",
"imshow",
"(",
"segment_im",
".",
"data",
")",
"plt",
".",
"colorbar",
"(",
")",
"plt",
".",
"axis",
"(",
"'off'",
")",
"plt",
".",
"subplot",
"(",
"1",
",",
"3",
",",
"3",
")",
"plt",
".",
"imshow",
"(",
"binary_im",
".",
"data",
",",
"cmap",
"=",
"plt",
".",
"cm",
".",
"gray",
")",
"plt",
".",
"axis",
"(",
"'off'",
")",
"plt",
".",
"show",
"(",
")",
"return",
"binary_im",
",",
"segment_im",
",",
"bounding_box"
] | Re-segments a color image to isolate an object of interest using foreground masking and kmeans | [
"Re",
"-",
"segments",
"a",
"color",
"image",
"to",
"isolate",
"an",
"object",
"of",
"interest",
"using",
"foreground",
"masking",
"and",
"kmeans"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/detector.py#L225-L298 | train | Re - segments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T2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + '\157' + '\061' + '\x32' + chr(54), 33111 - 33103), nzTpIcepk0o8('\060' + chr(1273 - 1162) + '\063' + '\066' + '\063', ord("\x08")), nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(3236 - 3125) + '\061' + chr(0b110110) + chr(0b110011), 0o10), nzTpIcepk0o8('\060' + chr(4408 - 4297) + '\063' + chr(1109 - 1061) + chr(0b110110), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(2086 - 2035) + '\064' + chr(1550 - 1501), 0o10), nzTpIcepk0o8(chr(1000 - 952) + chr(0b1101101 + 0o2) + chr(49) + '\x37' + chr(2558 - 2504), 0b1000), nzTpIcepk0o8(chr(1047 - 999) + chr(0b10101 + 0o132) + chr(0b101001 + 0o10) + chr(0b110010) + chr(0b0 + 0o60), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(1581 - 1531) + chr(1075 - 1023) + chr(1671 - 1619), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b1 + 0o63) + chr(0b11110 + 0o30), ord("\x08")), nzTpIcepk0o8(chr(0b10 + 0o56) + chr(0b1101111) + chr(1667 - 1616) + chr(52) + chr(2181 - 2132), 8), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110011) + chr(0b1000 + 0o53), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1100000 + 0o17) + chr(0b110011) + chr(52), ord("\x08")), nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(111) + chr(51) + chr(0b1100 + 0o53) + '\x36', 0o10), nzTpIcepk0o8('\x30' + chr(1497 - 1386) + chr(0b110001) + '\x36' + '\061', 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b10000 + 0o43) + chr(0b110101) + chr(647 - 594), 42101 - 42093), nzTpIcepk0o8(chr(759 - 711) + '\157' + chr(0b110010) + chr(1523 - 1468) + chr(50), 0o10), nzTpIcepk0o8(chr(1358 - 1310) + '\157' + '\x33' + '\x34' + chr(1017 - 968), 8), nzTpIcepk0o8('\x30' + chr(0b111010 + 0o65) + '\x31' + chr(911 - 863) + chr(48), ord("\x08")), nzTpIcepk0o8(chr(629 - 581) + '\157' + '\x31' + '\067' + '\x31', 0o10), nzTpIcepk0o8(chr(48) + '\157' + chr(1779 - 1729) + chr(0b110110) + '\x35', 0o10), nzTpIcepk0o8(chr(0b11000 + 0o30) + '\157' + '\x32' + '\062' + chr(226 - 172), 0o10), nzTpIcepk0o8(chr(785 - 737) + chr(111) + '\x31' + chr(0b110110) + chr(0b1110 + 0o51), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101110 + 0o1) + chr(0b11100 + 0o26) + chr(1610 - 1560) + chr(52), 0b1000), nzTpIcepk0o8(chr(48) + chr(9425 - 9314) + chr(55) + chr(1836 - 1787), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(0b0 + 0o63) + chr(48) + '\062', ord("\x08")), nzTpIcepk0o8(chr(0b1 + 0o57) + chr(111) + chr(51) + '\064' + chr(2029 - 1978), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(798 - 743) + chr(0b1101 + 0o47), 0o10), nzTpIcepk0o8('\060' + chr(0b1000 + 0o147) + chr(0b1101 + 0o46) + chr(0b10 + 0o62) + chr(0b110011), 8), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\061' + chr(0b110100) + '\x36', 56760 - 56752), nzTpIcepk0o8(chr(0b110000) + chr(0b100001 + 0o116) + chr(0b110001) + chr(2231 - 2180) + chr(2144 - 2096), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + '\x33' + '\063' + chr(1304 - 1254), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(701 - 652) + '\062' + chr(0b110010), 15137 - 15129), nzTpIcepk0o8('\060' + chr(111) + '\064' + chr(0b110101), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b111 + 0o54) + chr(0b110001) + '\x36', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b100101 + 0o112) + chr(1861 - 1811) + chr(0b1011 + 0o54), 0o10), nzTpIcepk0o8(chr(2159 - 2111) + chr(0b1101111) + chr(0b110011) + chr(51), 8), nzTpIcepk0o8('\060' + chr(1912 - 1801) + '\064' + chr(0b110000), 25404 - 25396), nzTpIcepk0o8(chr(0b10000 + 0o40) + '\157' + chr(49) + '\x34' + chr(55), 0o10), nzTpIcepk0o8(chr(0b100 + 0o54) + chr(0b1101111) + '\x32' + chr(0b10010 + 0o37) + '\x33', 31737 - 31729), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\061' + chr(1273 - 1221), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(0b1101111) + chr(53) + chr(2040 - 1992), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'x'), chr(5184 - 5084) + '\145' + '\143' + chr(111) + chr(8717 - 8617) + chr(0b1100101))('\x75' + chr(3668 - 3552) + chr(0b110101 + 0o61) + chr(0b101101) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def BKMz7HzlDOm0(hXMPsSrOQzbh, GFVgEmwvG0jZ, GwODkau2t25G, MLvji1aaS6HF, v3DD0K4I9igJ, K8HPRdH8m3eE=nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b0 + 0o60), 0o10)):
Cntm4eD2V2OT = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'0\x9c\x01\xa3\x86\x0c?\xd1H\x85Dq\x9f\x02\x86\xe5\x95/\x15\xd0\xe4\x16\xfaZ\xa7'), '\144' + '\x65' + chr(1454 - 1355) + chr(0b110011 + 0o74) + chr(0b11100 + 0o110) + '\x65')(chr(117) + chr(116) + '\x66' + chr(45) + '\070')]
jOwBM9qSFnpB = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b"5\x9c\x1f\xa9\x93!#\xc1A\xbei{\x9c.\x9a\xdf\x88'\x11\xc1"), chr(100) + chr(2197 - 2096) + chr(0b1100011) + chr(439 - 328) + chr(100) + chr(6336 - 6235))(chr(0b100111 + 0o116) + chr(116) + '\146' + '\x2d' + chr(0b110101 + 0o3))]
WWrhgFRrE1I8 = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'5\x9c\x1f\xa9\x93!#\xc1A\xbeui\x93.\x8e\xd6\x943\r\xd0\xe4\x04'), '\x64' + chr(101) + chr(1087 - 988) + chr(111) + '\x64' + chr(4559 - 4458))('\x75' + chr(0b1101100 + 0o10) + '\146' + '\055' + chr(0b111000))]
L_U0oGbUShyg = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b"5\x9c\x1f\xa9\x93!#\xc1A\xbeso\x88.\x9a\xdf\x88'\x11\xc1"), chr(2161 - 2061) + chr(0b1100101) + chr(1750 - 1651) + chr(5989 - 5878) + chr(0b1100100) + chr(0b1100011 + 0o2))(chr(117) + chr(116) + chr(2857 - 2755) + chr(437 - 392) + chr(0b111000))]
Tne_2y2IL4ZG = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'5\x9c\x1f\xa9\x93!#\xc1A\xbe\x7fu\x8d\x05\xb2\xca\x824\x10\xd9\xf3'), chr(653 - 553) + chr(0b1100101) + '\143' + chr(1563 - 1452) + chr(0b1100100) + chr(101))(chr(117) + chr(0b1101111 + 0o5) + chr(8522 - 8420) + chr(1076 - 1031) + chr(56))]
Tg2nzHp7WfTy = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'5\x9c\x1f\xa9\x93!#\xc1A\xbe\x7fu\x8d\x05\xb2\xce\x892\x1c\xc6\xfe'), chr(0b1001001 + 0o33) + chr(0b1100101) + chr(99) + chr(9550 - 9439) + chr(100) + chr(0b1000111 + 0o36))(chr(117) + chr(0b101011 + 0o111) + '\x66' + chr(45) + '\x38')]
ZhreRPkSCPIK = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'5\x9c\x1f\xa9\x93!#\xc1A\xbevu\x90.\x8f\xdd\xbe$\x10\xc6\xe2'), chr(0b1100100) + '\x65' + '\x63' + chr(0b1101111) + chr(100) + chr(0b1011 + 0o132))(chr(117) + chr(3467 - 3351) + '\x66' + chr(0b101101) + chr(0b111000))]
lfg28qa5j5ei = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b';\x9a\x1d\x99\x82\x11>\xd0I\x94iC\x9f\x03\x88\xdb'), chr(100) + chr(8160 - 8059) + chr(6389 - 6290) + chr(4024 - 3913) + '\144' + '\x65')(chr(0b1110101) + chr(3951 - 3835) + chr(102) + chr(45) + '\x38')]
H3boup3W92ki = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'5\x9c\x1d\xb2\x8e\x0b"\xfbB\x88hh\xa1\x05\x85\xc8\x843\x11'), '\x64' + chr(101) + '\143' + '\x6f' + '\x64' + chr(0b1100101))(chr(0b1110101) + '\164' + '\146' + chr(0b101 + 0o50) + '\x38')]
yMN3wUHEhDLY = GFVgEmwvG0jZ.foreground_mask(Cntm4eD2V2OT, bgmodel=MLvji1aaS6HF)
yMN3wUHEhDLY = yMN3wUHEhDLY.prune_contours(area_thresh=lfg28qa5j5ei, dist_thresh=H3boup3W92ki)
if yMN3wUHEhDLY is None:
return (None, None, None)
GFVgEmwvG0jZ = GFVgEmwvG0jZ.mask_binary(yMN3wUHEhDLY)
Oy5usdWhBvBH = GFVgEmwvG0jZ.segment_kmeans(jOwBM9qSFnpB, WWrhgFRrE1I8, hue_weight=L_U0oGbUShyg)
X04UpNkFFmGc = []
m0YoKEqUqMWT = nzTpIcepk0o8('\060' + '\x6f' + chr(51) + chr(1522 - 1467) + chr(0b10011 + 0o44), 0b1000) * nDF4gVNx0u9Q.Tn6rGr7XTM7t(u1jGtKnyqzqw.rgb_to_hsv(jLW6pRf2DSRk(MLvji1aaS6HF[nzTpIcepk0o8(chr(1343 - 1295) + chr(0b1011101 + 0o22) + '\x30', 8)]) / nzTpIcepk0o8('\x30' + chr(10978 - 10867) + chr(0b110011) + chr(1488 - 1433) + chr(55), 8), jLW6pRf2DSRk(MLvji1aaS6HF[nzTpIcepk0o8('\x30' + chr(111) + chr(49), 0o10)]) / nzTpIcepk0o8(chr(48) + chr(0b1101111 + 0o0) + '\x33' + chr(2077 - 2022) + chr(0b110111), 8), jLW6pRf2DSRk(MLvji1aaS6HF[nzTpIcepk0o8(chr(0b10011 + 0o35) + chr(0b1100001 + 0o16) + '\x32', 3883 - 3875)]) / nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(111) + chr(51) + chr(0b110111) + '\x37', 8)))
m0YoKEqUqMWT = nDF4gVNx0u9Q.r_[jOwBM9qSFnpB * nDF4gVNx0u9Q.Tn6rGr7XTM7t(MLvji1aaS6HF), L_U0oGbUShyg * m0YoKEqUqMWT[:nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110001), 8)]]
for B6UAF1zReOyJ in bbT2xIe5pzk7(roI3spqORKae(Oy5usdWhBvBH, roI3spqORKae(ES5oEprVxulp(b'8\x86\x1e\x99\x92\x1b7\xc9C\x8foo'), chr(0b1100100) + '\145' + chr(0b111 + 0o134) + '\x6f' + '\x64' + chr(5722 - 5621))(chr(0b1001010 + 0o53) + chr(0b1010 + 0o152) + chr(0b1010011 + 0o23) + chr(1715 - 1670) + '\x38')) - nzTpIcepk0o8('\x30' + chr(111) + '\061', 8)):
ylTayCtIFMh4 = Oy5usdWhBvBH.segment_mask(B6UAF1zReOyJ)
XerMc41Zmccr = GFVgEmwvG0jZ.mask_binary(ylTayCtIFMh4)
oD0cReGo_Ny3 = XerMc41Zmccr.nonzero_data()
oD0cReGo_Ny3 = nDF4gVNx0u9Q.c_[jOwBM9qSFnpB * oD0cReGo_Ny3, L_U0oGbUShyg * XerMc41Zmccr.nonzero_hsv_data()[:, :nzTpIcepk0o8(chr(1457 - 1409) + '\x6f' + chr(0b10011 + 0o36), 8)]]
gBIp4T7dq6Qw = nDF4gVNx0u9Q.FvpUlOwKdj9t(nDF4gVNx0u9Q.linalg.xBFFJFaziFDU(oD0cReGo_Ny3 - m0YoKEqUqMWT, axis=nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x31', 8)))
if K8HPRdH8m3eE:
roI3spqORKae(Lj4gcNafqrcl, roI3spqORKae(ES5oEprVxulp(b"?\x8b=\xbe\xd82'\xfb\x17\x86iS"), '\144' + '\x65' + '\x63' + chr(111) + chr(0b111100 + 0o50) + chr(0b111100 + 0o51))(chr(0b1110101) + '\164' + chr(4768 - 4666) + '\055' + '\x38'))(roI3spqORKae(ES5oEprVxulp(b'\x14\xb4S\x82\x88\r$\x84@\x8ei<\x8d\x14\x8a\xd7\x84.\r\x95\xb3\x13\xae\x19\xe7\xcd\x08\x85'), chr(0b1100100) + chr(0b1011110 + 0o7) + chr(0b1100001 + 0o2) + chr(0b1010011 + 0o34) + chr(0b1000001 + 0o43) + chr(0b1100000 + 0o5))(chr(117) + '\164' + '\146' + chr(749 - 704) + chr(0b11110 + 0o32)) % (B6UAF1zReOyJ, gBIp4T7dq6Qw))
roI3spqORKae(X04UpNkFFmGc, roI3spqORKae(ES5oEprVxulp(b'\x1e\xa7 \xf2\x99\x19\x17\xcbL\x8eN)'), '\144' + '\145' + chr(6588 - 6489) + chr(0b111001 + 0o66) + chr(0b1100100) + '\145')('\x75' + '\164' + chr(0b1001110 + 0o30) + '\x2d' + '\070'))(gBIp4T7dq6Qw)
sjja46katO6s = TxMFWa_Xzviv(nDF4gVNx0u9Q.chmI_GMU_sEi(ftfygxgFas5X(X04UpNkFFmGc)), X04UpNkFFmGc)
roI3spqORKae(sjja46katO6s, roI3spqORKae(ES5oEprVxulp(b'%\x9c\x01\xb2'), '\144' + '\x65' + '\x63' + chr(111) + '\144' + chr(0b1100101))('\165' + '\164' + chr(102) + chr(0b1000 + 0o45) + chr(56)))(key=lambda bI5jsQ9OkQtj: bI5jsQ9OkQtj[nzTpIcepk0o8(chr(232 - 184) + chr(0b1011111 + 0o20) + chr(0b101001 + 0o10), 8)], reverse=nzTpIcepk0o8(chr(2209 - 2161) + chr(111) + '\061', 8))
if WWrhgFRrE1I8 > nzTpIcepk0o8('\060' + chr(111) + chr(0b101101 + 0o4), 8) and zQBGwUT7UU8L(sjja46katO6s[nzTpIcepk0o8('\060' + '\x6f' + chr(48), 8)][nzTpIcepk0o8(chr(2065 - 2017) + chr(0b1101111) + chr(49), 8)] - sjja46katO6s[nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(1498 - 1449), 8)][nzTpIcepk0o8('\x30' + '\157' + chr(990 - 941), 8)]) > Tg2nzHp7WfTy and (sjja46katO6s[nzTpIcepk0o8('\x30' + chr(3899 - 3788) + chr(0b110001), 8)][nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b101101 + 0o4), 8)] < ZhreRPkSCPIK):
sWZbAD4kPjGu = sjja46katO6s[nzTpIcepk0o8(chr(0b110000) + chr(0b1010111 + 0o30) + chr(368 - 320), 8)][nzTpIcepk0o8('\x30' + chr(111) + chr(0b100 + 0o54), 8)]
jJxadXSqtFbL = Oy5usdWhBvBH.segment_mask(sWZbAD4kPjGu)
yMN3wUHEhDLY = yMN3wUHEhDLY.mask_binary(jJxadXSqtFbL)
(yMN3wUHEhDLY, YDkjg08z5lNS) = yMN3wUHEhDLY.center_nonzero()
GwODkau2t25G = HNLGzjvLh2Ac(GwODkau2t25G.min_pt.xqAChpcBkssb(nDF4gVNx0u9Q.float32) - YDkjg08z5lNS, GwODkau2t25G.max_pt.xqAChpcBkssb(nDF4gVNx0u9Q.float32) - YDkjg08z5lNS, GwODkau2t25G.KZ4ew2qs1HTO)
if K8HPRdH8m3eE:
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'3\x80C\x9c\xd7\x1a*\xe7N\xb2W)'), chr(100) + chr(0b1100101) + chr(0b1010011 + 0o20) + chr(111) + '\x64' + chr(101))('\165' + chr(0b111100 + 0o70) + '\x66' + '\055' + '\070'))()
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'%\x86\x11\xb6\x8d\x11$'), chr(100) + '\x65' + '\x63' + chr(0b1100011 + 0o14) + chr(7591 - 7491) + chr(101))(chr(0b1110101) + chr(0b1110100) + chr(102) + chr(45) + '\x38'))(nzTpIcepk0o8('\x30' + chr(1535 - 1424) + chr(0b110001), 8), nzTpIcepk0o8(chr(48) + '\157' + chr(51), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(8759 - 8648) + '\x31', 8))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'?\x9e\x00\xae\x8e\t'), chr(0b100001 + 0o103) + chr(0b1100101) + chr(5481 - 5382) + chr(111) + chr(0b101000 + 0o74) + '\145')(chr(117) + chr(0b11110 + 0o126) + chr(0b1000101 + 0o41) + chr(0b1100 + 0o41) + '\070'))(roI3spqORKae(GFVgEmwvG0jZ, roI3spqORKae(ES5oEprVxulp(b'\x10\x958\x89\xb5\x164\xd4I\xa5O~'), chr(0b1100100) + '\x65' + chr(99) + chr(0b1101111) + chr(0b1000011 + 0o41) + chr(5083 - 4982))('\165' + chr(0b1100010 + 0o22) + chr(3945 - 3843) + chr(0b11 + 0o52) + chr(0b10 + 0o66))))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\x1c\xb7J\xf6\xd3\x0e&\xdde\xadS-'), chr(100) + chr(101) + '\143' + chr(111) + chr(0b1100100) + chr(101))('\165' + chr(0b111111 + 0o65) + '\146' + '\x2d' + '\070'))(roI3spqORKae(ES5oEprVxulp(b'9\x95\x15'), '\x64' + chr(4541 - 4440) + '\x63' + chr(0b110010 + 0o75) + '\144' + chr(0b1100101))('\165' + '\164' + '\146' + chr(146 - 101) + chr(0b10000 + 0o50)))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'%\x86\x11\xb6\x8d\x11$'), chr(0b1011 + 0o131) + '\145' + chr(0b1100011) + chr(0b1101111) + chr(100) + chr(8496 - 8395))('\165' + '\x74' + chr(0b1001101 + 0o31) + chr(0b101101) + '\070'))(nzTpIcepk0o8('\x30' + chr(111) + chr(49), 8), nzTpIcepk0o8(chr(0b110000) + '\157' + '\063', 8), nzTpIcepk0o8(chr(0b1111 + 0o41) + chr(111) + chr(0b100010 + 0o20), 8))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'?\x9e\x00\xae\x8e\t'), chr(100) + chr(0b1100101) + chr(1517 - 1418) + '\157' + '\144' + '\145')(chr(117) + '\x74' + '\146' + chr(0b101101) + '\070'))(roI3spqORKae(Oy5usdWhBvBH, roI3spqORKae(ES5oEprVxulp(b'\x10\x958\x89\xb5\x164\xd4I\xa5O~'), '\144' + '\x65' + chr(0b110 + 0o135) + chr(0b111010 + 0o65) + '\x64' + chr(0b1100101))(chr(117) + chr(116) + chr(0b1 + 0o145) + chr(0b101010 + 0o3) + chr(0b111000))))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\x11\xc2\x1d\xaa\xb9\x1c\x14\xc5o\xbel}'), chr(0b1100100) + '\x65' + chr(0b101101 + 0o66) + chr(0b1101111) + chr(0b1011110 + 0o6) + '\x65')(chr(13409 - 13292) + chr(116) + chr(102) + '\055' + '\070'))()
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\x1c\xb7J\xf6\xd3\x0e&\xdde\xadS-'), '\144' + chr(0b1100101) + chr(4693 - 4594) + chr(0b111011 + 0o64) + chr(0b111001 + 0o53) + chr(101))(chr(117) + chr(118 - 2) + chr(0b1100110) + chr(0b101001 + 0o4) + '\x38'))(roI3spqORKae(ES5oEprVxulp(b'9\x95\x15'), chr(0b10010 + 0o122) + '\x65' + chr(99) + chr(0b1101111) + chr(100) + chr(101))('\165' + chr(0b1001111 + 0o45) + chr(5149 - 5047) + chr(0b11 + 0o52) + chr(0b111000)))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'%\x86\x11\xb6\x8d\x11$'), chr(7111 - 7011) + chr(0b1010000 + 0o25) + chr(7296 - 7197) + chr(111) + '\144' + chr(0b1100101))(chr(117) + '\164' + chr(102) + '\055' + '\070'))(nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b100111 + 0o12), 8), nzTpIcepk0o8(chr(48) + chr(111) + chr(1057 - 1006), 8), nzTpIcepk0o8(chr(48) + '\157' + '\063', 8))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'?\x9e\x00\xae\x8e\t'), chr(0b1100100) + chr(6542 - 6441) + chr(0b100010 + 0o101) + '\x6f' + chr(3024 - 2924) + chr(101))('\x75' + chr(0b1110100) + chr(102) + chr(45) + chr(0b111000)))(roI3spqORKae(yMN3wUHEhDLY, roI3spqORKae(ES5oEprVxulp(b'\x10\x958\x89\xb5\x164\xd4I\xa5O~'), chr(100) + '\x65' + '\143' + chr(6951 - 6840) + '\144' + '\145')('\x75' + chr(4744 - 4628) + '\146' + '\x2d' + chr(0b10001 + 0o47))), cmap=roI3spqORKae(Z7HGgmIyegqz.cm, roI3spqORKae(ES5oEprVxulp(b'1\x81\x12\xbf'), chr(0b1100100) + '\145' + chr(0b1010100 + 0o17) + chr(0b1101111) + chr(0b110010 + 0o62) + chr(6412 - 6311))(chr(0b1110101) + chr(0b101001 + 0o113) + chr(7764 - 7662) + chr(488 - 443) + chr(56))))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\x1c\xb7J\xf6\xd3\x0e&\xdde\xadS-'), '\144' + chr(101) + chr(0b10 + 0o141) + chr(2363 - 2252) + '\144' + chr(5182 - 5081))('\x75' + '\164' + '\146' + '\x2d' + chr(0b10101 + 0o43)))(roI3spqORKae(ES5oEprVxulp(b'9\x95\x15'), '\x64' + chr(101) + chr(99) + chr(111) + chr(0b1000100 + 0o40) + chr(8901 - 8800))(chr(0b100010 + 0o123) + chr(0b1110100) + chr(2376 - 2274) + '\x2d' + chr(56)))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'0\xa46\xab\x846\x07\xd0y\xbeWf'), chr(100) + chr(101) + chr(0b10001 + 0o122) + chr(0b101001 + 0o106) + '\x64' + '\x65')('\165' + chr(0b1110100) + chr(3066 - 2964) + chr(0b11111 + 0o16) + chr(0b111000)))()
return (yMN3wUHEhDLY, Oy5usdWhBvBH, GwODkau2t25G) |
BerkeleyAutomation/perception | perception/detector.py | RgbdForegroundMaskQueryImageDetector.detect | def detect(self, color_im, depth_im, cfg, camera_intr=None,
T_camera_world=None,
vis_foreground=False, vis_segmentation=False, segmask=None):
"""
Detects all relevant objects in an rgbd image pair using foreground masking.
Parameters
----------
color_im : :obj:`ColorImage`
color image for detection
depth_im : :obj:`DepthImage`
depth image for detection (corresponds to color image)
cfg : :obj:`YamlConfig`
parameters of detection function
camera_intr : :obj:`CameraIntrinsics`
intrinsics of the camera
T_camera_world : :obj:`autolab_core.RigidTransform`
registration of the camera to world frame
segmask : :obj:`BinaryImage`
optional segmask of invalid pixels
Returns
------
:obj:`list` of :obj:`RgbdDetection`
all detections in the image
"""
# read params
foreground_mask_tolerance = cfg['foreground_mask_tolerance']
min_contour_area = cfg['min_contour_area']
max_contour_area = cfg['max_contour_area']
min_box_area = cfg['min_box_area']
max_box_area = cfg['max_box_area']
box_padding_px = cfg['box_padding_px']
crop_height = cfg['image_height']
crop_width = cfg['image_width']
depth_grad_thresh = cfg['depth_grad_thresh']
w = cfg['filter_dim']
half_crop_height = float(crop_height) / 2
half_crop_width = float(crop_width) / 2
half_crop_dims = np.array([half_crop_height, half_crop_width])
fill_depth = np.max(depth_im.data[depth_im.data > 0])
kinect2_denoising = False
if 'kinect2_denoising' in cfg.keys() and cfg['kinect2_denoising']:
kinect2_denoising = True
depth_offset = cfg['kinect2_noise_offset']
max_depth = cfg['kinect2_noise_max_depth']
# mask image using background detection
bgmodel = color_im.background_model()
binary_im = color_im.foreground_mask(foreground_mask_tolerance, bgmodel=bgmodel)
# filter the image
y, x = np.ogrid[-w/2+1:w/2+1, -w/2+1:w/2+1]
mask = x*x + y*y <= w/2*w/2
filter_struct = np.zeros([w,w]).astype(np.uint8)
filter_struct[mask] = 1
binary_im_filtered = binary_im.apply(snm.grey_closing, structure=filter_struct)
# find all contours
contours = binary_im_filtered.find_contours(min_area=min_contour_area, max_area=max_contour_area)
if vis_foreground:
plt.figure()
plt.subplot(1,2,1)
plt.imshow(color_im.data)
plt.axis('off')
plt.subplot(1,2,2)
plt.imshow(binary_im_filtered.data, cmap=plt.cm.gray)
plt.axis('off')
plt.show()
# threshold gradients of depth
depth_im = depth_im.threshold_gradients(depth_grad_thresh)
# convert contours to detections
detections = []
for contour in contours:
orig_box = contour.bounding_box
if orig_box.area > min_box_area and orig_box.area < max_box_area:
# convert orig bounding box to query bounding box
min_pt = orig_box.center - half_crop_dims
max_pt = orig_box.center + half_crop_dims
query_box = Box(min_pt, max_pt, frame=orig_box.frame)
# segment color to get refined detection
color_thumbnail = color_im.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
binary_thumbnail, segment_thumbnail, query_box = self._segment_color(color_thumbnail, query_box, bgmodel, cfg, vis_segmentation=vis_segmentation)
if binary_thumbnail is None:
continue
else:
# otherwise take original bounding box
query_box = Box(contour.bounding_box.min_pt - box_padding_px,
contour.bounding_box.max_pt + box_padding_px,
frame = contour.bounding_box.frame)
binary_thumbnail = binary_im_filtered.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
# crop to get thumbnails
color_thumbnail = color_im.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
depth_thumbnail = depth_im.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
thumbnail_intr = camera_intr
if camera_intr is not None:
thumbnail_intr = camera_intr.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
# fix depth thumbnail
depth_thumbnail = depth_thumbnail.replace_zeros(fill_depth)
if kinect2_denoising:
depth_data = depth_thumbnail.data
min_depth = np.min(depth_data)
binary_mask_data = binary_thumbnail.data
depth_mask_data = depth_thumbnail.mask_binary(binary_thumbnail).data
depth_mask_data += depth_offset
depth_data[binary_mask_data > 0] = depth_mask_data[binary_mask_data > 0]
depth_thumbnail = DepthImage(depth_data, depth_thumbnail.frame)
# append to detections
detections.append(RgbdDetection(color_thumbnail,
depth_thumbnail,
query_box,
binary_thumbnail=binary_thumbnail,
contour=contour,
camera_intr=thumbnail_intr))
return detections | python | def detect(self, color_im, depth_im, cfg, camera_intr=None,
T_camera_world=None,
vis_foreground=False, vis_segmentation=False, segmask=None):
"""
Detects all relevant objects in an rgbd image pair using foreground masking.
Parameters
----------
color_im : :obj:`ColorImage`
color image for detection
depth_im : :obj:`DepthImage`
depth image for detection (corresponds to color image)
cfg : :obj:`YamlConfig`
parameters of detection function
camera_intr : :obj:`CameraIntrinsics`
intrinsics of the camera
T_camera_world : :obj:`autolab_core.RigidTransform`
registration of the camera to world frame
segmask : :obj:`BinaryImage`
optional segmask of invalid pixels
Returns
------
:obj:`list` of :obj:`RgbdDetection`
all detections in the image
"""
# read params
foreground_mask_tolerance = cfg['foreground_mask_tolerance']
min_contour_area = cfg['min_contour_area']
max_contour_area = cfg['max_contour_area']
min_box_area = cfg['min_box_area']
max_box_area = cfg['max_box_area']
box_padding_px = cfg['box_padding_px']
crop_height = cfg['image_height']
crop_width = cfg['image_width']
depth_grad_thresh = cfg['depth_grad_thresh']
w = cfg['filter_dim']
half_crop_height = float(crop_height) / 2
half_crop_width = float(crop_width) / 2
half_crop_dims = np.array([half_crop_height, half_crop_width])
fill_depth = np.max(depth_im.data[depth_im.data > 0])
kinect2_denoising = False
if 'kinect2_denoising' in cfg.keys() and cfg['kinect2_denoising']:
kinect2_denoising = True
depth_offset = cfg['kinect2_noise_offset']
max_depth = cfg['kinect2_noise_max_depth']
# mask image using background detection
bgmodel = color_im.background_model()
binary_im = color_im.foreground_mask(foreground_mask_tolerance, bgmodel=bgmodel)
# filter the image
y, x = np.ogrid[-w/2+1:w/2+1, -w/2+1:w/2+1]
mask = x*x + y*y <= w/2*w/2
filter_struct = np.zeros([w,w]).astype(np.uint8)
filter_struct[mask] = 1
binary_im_filtered = binary_im.apply(snm.grey_closing, structure=filter_struct)
# find all contours
contours = binary_im_filtered.find_contours(min_area=min_contour_area, max_area=max_contour_area)
if vis_foreground:
plt.figure()
plt.subplot(1,2,1)
plt.imshow(color_im.data)
plt.axis('off')
plt.subplot(1,2,2)
plt.imshow(binary_im_filtered.data, cmap=plt.cm.gray)
plt.axis('off')
plt.show()
# threshold gradients of depth
depth_im = depth_im.threshold_gradients(depth_grad_thresh)
# convert contours to detections
detections = []
for contour in contours:
orig_box = contour.bounding_box
if orig_box.area > min_box_area and orig_box.area < max_box_area:
# convert orig bounding box to query bounding box
min_pt = orig_box.center - half_crop_dims
max_pt = orig_box.center + half_crop_dims
query_box = Box(min_pt, max_pt, frame=orig_box.frame)
# segment color to get refined detection
color_thumbnail = color_im.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
binary_thumbnail, segment_thumbnail, query_box = self._segment_color(color_thumbnail, query_box, bgmodel, cfg, vis_segmentation=vis_segmentation)
if binary_thumbnail is None:
continue
else:
# otherwise take original bounding box
query_box = Box(contour.bounding_box.min_pt - box_padding_px,
contour.bounding_box.max_pt + box_padding_px,
frame = contour.bounding_box.frame)
binary_thumbnail = binary_im_filtered.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
# crop to get thumbnails
color_thumbnail = color_im.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
depth_thumbnail = depth_im.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
thumbnail_intr = camera_intr
if camera_intr is not None:
thumbnail_intr = camera_intr.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
# fix depth thumbnail
depth_thumbnail = depth_thumbnail.replace_zeros(fill_depth)
if kinect2_denoising:
depth_data = depth_thumbnail.data
min_depth = np.min(depth_data)
binary_mask_data = binary_thumbnail.data
depth_mask_data = depth_thumbnail.mask_binary(binary_thumbnail).data
depth_mask_data += depth_offset
depth_data[binary_mask_data > 0] = depth_mask_data[binary_mask_data > 0]
depth_thumbnail = DepthImage(depth_data, depth_thumbnail.frame)
# append to detections
detections.append(RgbdDetection(color_thumbnail,
depth_thumbnail,
query_box,
binary_thumbnail=binary_thumbnail,
contour=contour,
camera_intr=thumbnail_intr))
return detections | [
"def",
"detect",
"(",
"self",
",",
"color_im",
",",
"depth_im",
",",
"cfg",
",",
"camera_intr",
"=",
"None",
",",
"T_camera_world",
"=",
"None",
",",
"vis_foreground",
"=",
"False",
",",
"vis_segmentation",
"=",
"False",
",",
"segmask",
"=",
"None",
")",
":",
"# read params",
"foreground_mask_tolerance",
"=",
"cfg",
"[",
"'foreground_mask_tolerance'",
"]",
"min_contour_area",
"=",
"cfg",
"[",
"'min_contour_area'",
"]",
"max_contour_area",
"=",
"cfg",
"[",
"'max_contour_area'",
"]",
"min_box_area",
"=",
"cfg",
"[",
"'min_box_area'",
"]",
"max_box_area",
"=",
"cfg",
"[",
"'max_box_area'",
"]",
"box_padding_px",
"=",
"cfg",
"[",
"'box_padding_px'",
"]",
"crop_height",
"=",
"cfg",
"[",
"'image_height'",
"]",
"crop_width",
"=",
"cfg",
"[",
"'image_width'",
"]",
"depth_grad_thresh",
"=",
"cfg",
"[",
"'depth_grad_thresh'",
"]",
"w",
"=",
"cfg",
"[",
"'filter_dim'",
"]",
"half_crop_height",
"=",
"float",
"(",
"crop_height",
")",
"/",
"2",
"half_crop_width",
"=",
"float",
"(",
"crop_width",
")",
"/",
"2",
"half_crop_dims",
"=",
"np",
".",
"array",
"(",
"[",
"half_crop_height",
",",
"half_crop_width",
"]",
")",
"fill_depth",
"=",
"np",
".",
"max",
"(",
"depth_im",
".",
"data",
"[",
"depth_im",
".",
"data",
">",
"0",
"]",
")",
"kinect2_denoising",
"=",
"False",
"if",
"'kinect2_denoising'",
"in",
"cfg",
".",
"keys",
"(",
")",
"and",
"cfg",
"[",
"'kinect2_denoising'",
"]",
":",
"kinect2_denoising",
"=",
"True",
"depth_offset",
"=",
"cfg",
"[",
"'kinect2_noise_offset'",
"]",
"max_depth",
"=",
"cfg",
"[",
"'kinect2_noise_max_depth'",
"]",
"# mask image using background detection",
"bgmodel",
"=",
"color_im",
".",
"background_model",
"(",
")",
"binary_im",
"=",
"color_im",
".",
"foreground_mask",
"(",
"foreground_mask_tolerance",
",",
"bgmodel",
"=",
"bgmodel",
")",
"# filter the image",
"y",
",",
"x",
"=",
"np",
".",
"ogrid",
"[",
"-",
"w",
"/",
"2",
"+",
"1",
":",
"w",
"/",
"2",
"+",
"1",
",",
"-",
"w",
"/",
"2",
"+",
"1",
":",
"w",
"/",
"2",
"+",
"1",
"]",
"mask",
"=",
"x",
"*",
"x",
"+",
"y",
"*",
"y",
"<=",
"w",
"/",
"2",
"*",
"w",
"/",
"2",
"filter_struct",
"=",
"np",
".",
"zeros",
"(",
"[",
"w",
",",
"w",
"]",
")",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
"filter_struct",
"[",
"mask",
"]",
"=",
"1",
"binary_im_filtered",
"=",
"binary_im",
".",
"apply",
"(",
"snm",
".",
"grey_closing",
",",
"structure",
"=",
"filter_struct",
")",
"# find all contours",
"contours",
"=",
"binary_im_filtered",
".",
"find_contours",
"(",
"min_area",
"=",
"min_contour_area",
",",
"max_area",
"=",
"max_contour_area",
")",
"if",
"vis_foreground",
":",
"plt",
".",
"figure",
"(",
")",
"plt",
".",
"subplot",
"(",
"1",
",",
"2",
",",
"1",
")",
"plt",
".",
"imshow",
"(",
"color_im",
".",
"data",
")",
"plt",
".",
"axis",
"(",
"'off'",
")",
"plt",
".",
"subplot",
"(",
"1",
",",
"2",
",",
"2",
")",
"plt",
".",
"imshow",
"(",
"binary_im_filtered",
".",
"data",
",",
"cmap",
"=",
"plt",
".",
"cm",
".",
"gray",
")",
"plt",
".",
"axis",
"(",
"'off'",
")",
"plt",
".",
"show",
"(",
")",
"# threshold gradients of depth",
"depth_im",
"=",
"depth_im",
".",
"threshold_gradients",
"(",
"depth_grad_thresh",
")",
"# convert contours to detections",
"detections",
"=",
"[",
"]",
"for",
"contour",
"in",
"contours",
":",
"orig_box",
"=",
"contour",
".",
"bounding_box",
"if",
"orig_box",
".",
"area",
">",
"min_box_area",
"and",
"orig_box",
".",
"area",
"<",
"max_box_area",
":",
"# convert orig bounding box to query bounding box",
"min_pt",
"=",
"orig_box",
".",
"center",
"-",
"half_crop_dims",
"max_pt",
"=",
"orig_box",
".",
"center",
"+",
"half_crop_dims",
"query_box",
"=",
"Box",
"(",
"min_pt",
",",
"max_pt",
",",
"frame",
"=",
"orig_box",
".",
"frame",
")",
"# segment color to get refined detection",
"color_thumbnail",
"=",
"color_im",
".",
"crop",
"(",
"query_box",
".",
"height",
",",
"query_box",
".",
"width",
",",
"query_box",
".",
"ci",
",",
"query_box",
".",
"cj",
")",
"binary_thumbnail",
",",
"segment_thumbnail",
",",
"query_box",
"=",
"self",
".",
"_segment_color",
"(",
"color_thumbnail",
",",
"query_box",
",",
"bgmodel",
",",
"cfg",
",",
"vis_segmentation",
"=",
"vis_segmentation",
")",
"if",
"binary_thumbnail",
"is",
"None",
":",
"continue",
"else",
":",
"# otherwise take original bounding box",
"query_box",
"=",
"Box",
"(",
"contour",
".",
"bounding_box",
".",
"min_pt",
"-",
"box_padding_px",
",",
"contour",
".",
"bounding_box",
".",
"max_pt",
"+",
"box_padding_px",
",",
"frame",
"=",
"contour",
".",
"bounding_box",
".",
"frame",
")",
"binary_thumbnail",
"=",
"binary_im_filtered",
".",
"crop",
"(",
"query_box",
".",
"height",
",",
"query_box",
".",
"width",
",",
"query_box",
".",
"ci",
",",
"query_box",
".",
"cj",
")",
"# crop to get thumbnails",
"color_thumbnail",
"=",
"color_im",
".",
"crop",
"(",
"query_box",
".",
"height",
",",
"query_box",
".",
"width",
",",
"query_box",
".",
"ci",
",",
"query_box",
".",
"cj",
")",
"depth_thumbnail",
"=",
"depth_im",
".",
"crop",
"(",
"query_box",
".",
"height",
",",
"query_box",
".",
"width",
",",
"query_box",
".",
"ci",
",",
"query_box",
".",
"cj",
")",
"thumbnail_intr",
"=",
"camera_intr",
"if",
"camera_intr",
"is",
"not",
"None",
":",
"thumbnail_intr",
"=",
"camera_intr",
".",
"crop",
"(",
"query_box",
".",
"height",
",",
"query_box",
".",
"width",
",",
"query_box",
".",
"ci",
",",
"query_box",
".",
"cj",
")",
"# fix depth thumbnail",
"depth_thumbnail",
"=",
"depth_thumbnail",
".",
"replace_zeros",
"(",
"fill_depth",
")",
"if",
"kinect2_denoising",
":",
"depth_data",
"=",
"depth_thumbnail",
".",
"data",
"min_depth",
"=",
"np",
".",
"min",
"(",
"depth_data",
")",
"binary_mask_data",
"=",
"binary_thumbnail",
".",
"data",
"depth_mask_data",
"=",
"depth_thumbnail",
".",
"mask_binary",
"(",
"binary_thumbnail",
")",
".",
"data",
"depth_mask_data",
"+=",
"depth_offset",
"depth_data",
"[",
"binary_mask_data",
">",
"0",
"]",
"=",
"depth_mask_data",
"[",
"binary_mask_data",
">",
"0",
"]",
"depth_thumbnail",
"=",
"DepthImage",
"(",
"depth_data",
",",
"depth_thumbnail",
".",
"frame",
")",
"# append to detections",
"detections",
".",
"append",
"(",
"RgbdDetection",
"(",
"color_thumbnail",
",",
"depth_thumbnail",
",",
"query_box",
",",
"binary_thumbnail",
"=",
"binary_thumbnail",
",",
"contour",
"=",
"contour",
",",
"camera_intr",
"=",
"thumbnail_intr",
")",
")",
"return",
"detections"
] | Detects all relevant objects in an rgbd image pair using foreground masking.
Parameters
----------
color_im : :obj:`ColorImage`
color image for detection
depth_im : :obj:`DepthImage`
depth image for detection (corresponds to color image)
cfg : :obj:`YamlConfig`
parameters of detection function
camera_intr : :obj:`CameraIntrinsics`
intrinsics of the camera
T_camera_world : :obj:`autolab_core.RigidTransform`
registration of the camera to world frame
segmask : :obj:`BinaryImage`
optional segmask of invalid pixels
Returns
------
:obj:`list` of :obj:`RgbdDetection`
all detections in the image | [
"Detects",
"all",
"relevant",
"objects",
"in",
"an",
"rgbd",
"image",
"pair",
"using",
"foreground",
"masking",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/detector.py#L300-L427 | train | Detects all relevant objects in an rgbd image pair using foreground masking. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOV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lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + '\157' + '\063' + '\062' + chr(0b1101 + 0o51), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b101101 + 0o12) + '\065', 0o10), nzTpIcepk0o8(chr(1255 - 1207) + chr(0b1101111) + chr(50) + '\x30', 65254 - 65246), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110001) + chr(2189 - 2134), ord("\x08")), nzTpIcepk0o8(chr(0b1001 + 0o47) + chr(0b1101111) + '\x32' + '\x34' + chr(55), 0b1000), nzTpIcepk0o8(chr(0b100000 + 0o20) + chr(0b1101111) + chr(2562 - 2511) + '\066' + '\x34', 0o10), nzTpIcepk0o8(chr(2097 - 2049) + chr(0b1101111) + '\061' + '\066' + chr(50), ord("\x08")), nzTpIcepk0o8(chr(1855 - 1807) + chr(0b100001 + 0o116) + chr(50) + chr(52) + '\x34', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1010110 + 0o31) + '\x33' + chr(0b110000 + 0o3) + chr(0b110001), 10279 - 10271), nzTpIcepk0o8(chr(48) + '\157' + '\x32' + chr(842 - 791) + chr(2427 - 2372), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(50) + chr(0b110010) + '\x34', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(3954 - 3843) + chr(50) + '\063' + chr(50), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b11111 + 0o22) + '\064' + '\067', 0o10), nzTpIcepk0o8('\060' + chr(0b101100 + 0o103) + chr(0b110111) + chr(0b110100), 0b1000), nzTpIcepk0o8('\060' + '\157' + '\x33' + '\065' + '\065', ord("\x08")), nzTpIcepk0o8(chr(1333 - 1285) + chr(111) + chr(0b10 + 0o60) + '\x34' + '\062', 0o10), nzTpIcepk0o8('\060' + chr(0b1000100 + 0o53) + '\x33' + '\x32' + chr(50), 0o10), nzTpIcepk0o8(chr(0b11101 + 0o23) + '\157' + chr(50) + chr(1437 - 1383) + chr(52), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + '\x36' + chr(52), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(50) + chr(0b11101 + 0o31) + chr(1120 - 1072), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1110 + 0o141) + chr(570 - 519) + chr(0b11111 + 0o22) + chr(0b110110), 60993 - 60985), nzTpIcepk0o8(chr(89 - 41) + chr(0b1101111) + chr(51) + '\060', 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(0b11111 + 0o22) + chr(50) + chr(0b100001 + 0o24), 51958 - 51950), nzTpIcepk0o8('\060' + chr(1160 - 1049) + chr(1703 - 1654) + chr(53) + '\x31', 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b100000 + 0o21) + chr(1184 - 1134) + chr(0b101011 + 0o7), 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(51) + chr(146 - 92) + chr(51), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b11011 + 0o124) + chr(49) + '\x36' + chr(0b10010 + 0o43), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\062' + chr(1544 - 1496) + chr(1093 - 1043), 0o10), nzTpIcepk0o8('\060' + chr(0b1000101 + 0o52) + '\061' + chr(902 - 849) + chr(0b101100 + 0o11), 0b1000), nzTpIcepk0o8(chr(48) + chr(11841 - 11730) + chr(0b110011) + '\x37' + chr(399 - 345), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x37' + chr(55), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110001) + chr(0b110000) + chr(0b110010), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b11 + 0o154) + '\x33' + chr(0b11 + 0o61), 0b1000), nzTpIcepk0o8(chr(0b101 + 0o53) + chr(5193 - 5082) + chr(1652 - 1603) + chr(0b110011) + '\066', 46116 - 46108), nzTpIcepk0o8(chr(48) + chr(4532 - 4421) + chr(0b11111 + 0o23) + chr(53) + '\x34', 0b1000), nzTpIcepk0o8('\060' + chr(111) + '\x31' + '\x36' + '\x32', 8), nzTpIcepk0o8(chr(1527 - 1479) + '\157' + chr(0b110011) + '\x37', 0o10), nzTpIcepk0o8(chr(48) + chr(2305 - 2194) + '\x33' + chr(289 - 235) + chr(0b1000 + 0o51), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b100 + 0o57) + chr(0b101000 + 0o16), 44653 - 44645), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x34', 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b101010 + 0o13) + chr(930 - 882), ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xf8'), chr(0b1100100) + '\145' + chr(1028 - 929) + '\x6f' + chr(0b11101 + 0o107) + chr(8350 - 8249))(chr(117) + chr(0b110100 + 0o100) + chr(8041 - 7939) + chr(0b10111 + 0o26) + chr(0b111000)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def KCHfuNuJY4BH(hXMPsSrOQzbh, GFVgEmwvG0jZ, WZcCXRnThfxU, v3DD0K4I9igJ, wgYNRnQWtrEG=None, bml1vBwpIyzY=None, HMGTq0S42cQ6=nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110000), 0o10), K8HPRdH8m3eE=nzTpIcepk0o8(chr(0b110000) + chr(8132 - 8021) + chr(0b10101 + 0o33), 8), uGhmBzyWgv_A=None):
Cntm4eD2V2OT = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xb0Rbj\xc0\x86\x1d\xd1\xb7\xfb\xcb\xf7\x06O\x86\xfd\xa6\xdbX\xd5\xbcy;\n7'), '\x64' + chr(6902 - 6801) + chr(5804 - 5705) + chr(0b1000010 + 0o55) + chr(0b1100010 + 0o2) + '\x65')(chr(117) + '\164' + '\146' + chr(0b101101) + chr(56))]
lfg28qa5j5ei = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xbbT~P\xc4\x9b\x1c\xd0\xb6\xea\xe6\xc5\x06N\x88\xc3'), chr(0b11101 + 0o107) + chr(0b1100101) + chr(0b111001 + 0o52) + chr(7990 - 7879) + '\144' + chr(0b1100101))(chr(117) + chr(0b1110100) + '\146' + chr(0b1111 + 0o36) + chr(167 - 111))]
_KS6tfhVhGj_ = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xbb\\hP\xc4\x9b\x1c\xd0\xb6\xea\xe6\xc5\x06N\x88\xc3'), chr(6276 - 6176) + chr(101) + chr(0b1010010 + 0o21) + chr(2146 - 2035) + '\x64' + chr(101))('\165' + chr(0b1011110 + 0o26) + chr(0b1100110) + '\x2d' + chr(56))]
DfWZja9636Ja = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xbbT~P\xc5\x9b\n\xfb\xb8\xed\xf1\xfb'), '\x64' + chr(101) + chr(99) + '\x6f' + '\144' + '\x65')(chr(0b1000111 + 0o56) + '\x74' + chr(102) + chr(45) + chr(548 - 492))]
eEDlUBCIHhca = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xbb\\hP\xc5\x9b\n\xfb\xb8\xed\xf1\xfb'), '\144' + chr(7670 - 7569) + chr(4071 - 3972) + chr(11599 - 11488) + '\x64' + chr(4267 - 4166))('\x75' + chr(0b111001 + 0o73) + '\146' + chr(1178 - 1133) + '\x38')]
anDmN0aUxLk8 = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xb4RhP\xd7\x95\x16\xc0\xb0\xf1\xf3\xc5\x17D'), chr(100) + '\145' + chr(0b1000000 + 0o43) + chr(111) + '\x64' + chr(1434 - 1333))(chr(0b1110101) + chr(116) + chr(9798 - 9696) + chr(0b1101 + 0o40) + chr(56))]
YuPAjcYJvauC = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xbfPqh\xc2\xab\x1a\xc1\xb0\xf8\xfc\xee'), chr(5673 - 5573) + chr(0b1000110 + 0o37) + chr(99) + chr(5346 - 5235) + chr(0b1100100) + '\x65')(chr(0b1000101 + 0o60) + chr(0b1110100) + chr(0b111000 + 0o56) + '\055' + '\x38')]
Hs02AGBacRK5 = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xbfPqh\xc2\xab\x05\xcd\xbd\xeb\xfc'), '\x64' + '\145' + '\143' + '\x6f' + '\x64' + chr(101))(chr(0b1110101) + chr(116) + chr(0b1100110) + chr(0b101101) + chr(56))]
rMeLSt0C6JGk = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xb2X`{\xcf\xab\x15\xd6\xb8\xfb\xcb\xee\x0fN\x88\xd1\xba'), chr(5661 - 5561) + chr(6286 - 6185) + '\143' + chr(0b111011 + 0o64) + chr(1505 - 1405) + chr(5898 - 5797))(chr(9142 - 9025) + chr(0b1010 + 0o152) + chr(0b1100110) + chr(1439 - 1394) + chr(0b111000))]
sm7_CLmeWGR7 = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xb0T|{\xc2\x86-\xc0\xb0\xf2'), chr(6972 - 6872) + chr(0b1011000 + 0o15) + chr(3339 - 3240) + chr(0b1101111) + chr(0b1100100) + chr(4444 - 4343))('\165' + '\x74' + chr(9602 - 9500) + '\x2d' + chr(0b11110 + 0o32))]
_2_GMkhXzDGB = jLW6pRf2DSRk(YuPAjcYJvauC) / nzTpIcepk0o8(chr(48) + chr(278 - 167) + '\x32', 32388 - 32380)
AcEi8W7neS59 = jLW6pRf2DSRk(Hs02AGBacRK5) / nzTpIcepk0o8(chr(0b110000) + chr(9748 - 9637) + chr(0b111 + 0o53), 8)
PZDpO5KEjEvJ = nDF4gVNx0u9Q.Tn6rGr7XTM7t([_2_GMkhXzDGB, AcEi8W7neS59])
OtBA5JjCoiah = nDF4gVNx0u9Q.KV9ckIhroIia(WZcCXRnThfxU.FfKOThdpoDTb[WZcCXRnThfxU.FfKOThdpoDTb > nzTpIcepk0o8('\x30' + chr(0b1010011 + 0o34) + chr(48), 8)])
guL_bclejJPl = nzTpIcepk0o8(chr(0b110000) + chr(0b111010 + 0o65) + chr(0b110000), 8)
if roI3spqORKae(ES5oEprVxulp(b'\xbdT~j\xc4\x80@\xfb\xbd\xfa\xfa\xf5\x0eO\x84\xcc\xb5'), '\x64' + chr(101) + chr(99) + chr(10603 - 10492) + chr(0b1001100 + 0o30) + '\145')(chr(117) + '\x74' + chr(102) + chr(96 - 51) + chr(1335 - 1279)) in roI3spqORKae(v3DD0K4I9igJ, roI3spqORKae(ES5oEprVxulp(b'\xbdXi|'), chr(0b1000001 + 0o43) + '\145' + chr(99) + chr(8869 - 8758) + chr(679 - 579) + '\145')('\x75' + chr(116) + '\146' + chr(0b101101) + chr(226 - 170)))() and v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xbdT~j\xc4\x80@\xfb\xbd\xfa\xfa\xf5\x0eO\x84\xcc\xb5'), chr(100) + chr(0b1100101) + chr(7867 - 7768) + '\x6f' + chr(0b1100100) + '\145')(chr(0b1010111 + 0o36) + chr(116) + chr(0b1100110) + '\x2d' + chr(0b111000))]:
guL_bclejJPl = nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(444 - 395), ord("\x08"))
OFJwdIkSxBR5 = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xbdT~j\xc4\x80@\xfb\xb7\xf0\xfd\xe9\x02c\x82\xc4\xb4\xc7Q\xc4'), chr(0b1100100) + chr(0b1001110 + 0o27) + chr(0b100101 + 0o76) + '\x6f' + chr(100) + chr(0b1100101))(chr(909 - 792) + chr(116) + '\x66' + chr(0b101101) + chr(0b111000))]
dQNXocQ4z2HF = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'\xbdT~j\xc4\x80@\xfb\xb7\xf0\xfd\xe9\x02c\x80\xc3\xaa\xebP\xd5\xbel='), '\144' + chr(0b1010000 + 0o25) + chr(0b100000 + 0o103) + chr(1754 - 1643) + '\x64' + chr(101))(chr(0b1011010 + 0o33) + chr(0b100010 + 0o122) + chr(102) + chr(1953 - 1908) + chr(0b111000))]
MLvji1aaS6HF = GFVgEmwvG0jZ.background_model()
yMN3wUHEhDLY = GFVgEmwvG0jZ.foreground_mask(Cntm4eD2V2OT, bgmodel=MLvji1aaS6HF)
(Fi3yzxctM1zW, bI5jsQ9OkQtj) = nDF4gVNx0u9Q.ogrid[-sm7_CLmeWGR7 / nzTpIcepk0o8('\060' + '\157' + chr(0b110010), 8) + nzTpIcepk0o8('\x30' + chr(111) + chr(2048 - 1999), 8):sm7_CLmeWGR7 / nzTpIcepk0o8(chr(48) + '\x6f' + '\x32', 8) + nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\061', 8), -sm7_CLmeWGR7 / nzTpIcepk0o8('\060' + '\x6f' + chr(0b10 + 0o60), 8) + nzTpIcepk0o8('\060' + '\157' + '\x31', 8):sm7_CLmeWGR7 / nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110000 + 0o2), 8) + nzTpIcepk0o8(chr(857 - 809) + '\x6f' + chr(0b110001), 8)]
BBM8dxm7YWge = bI5jsQ9OkQtj * bI5jsQ9OkQtj + Fi3yzxctM1zW * Fi3yzxctM1zW <= sm7_CLmeWGR7 / nzTpIcepk0o8('\x30' + chr(0b1011100 + 0o23) + chr(1242 - 1192), 8) * sm7_CLmeWGR7 / nzTpIcepk0o8(chr(0b11011 + 0o25) + chr(0b1101111) + chr(0b10110 + 0o34), 8)
QPppo3i50evp = nDF4gVNx0u9Q.zeros([sm7_CLmeWGR7, sm7_CLmeWGR7]).xqAChpcBkssb(nDF4gVNx0u9Q.aZB1vwmdWU_M)
QPppo3i50evp[BBM8dxm7YWge] = nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b1111 + 0o42), 8)
gwheshWPFHtV = yMN3wUHEhDLY.apply(NCLBGpFJImZ_.grey_closing, structure=QPppo3i50evp)
aMtoOZWkl57Y = gwheshWPFHtV.find_contours(min_area=lfg28qa5j5ei, max_area=_KS6tfhVhGj_)
if HMGTq0S42cQ6:
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\xb3N U\x91\x90\x08\xe7\xb1\xcc\xd8\xaf'), chr(100) + chr(8381 - 8280) + '\x63' + '\157' + chr(2311 - 2211) + chr(0b1001001 + 0o34))(chr(0b10101 + 0o140) + chr(0b111001 + 0o73) + chr(102) + '\x2d' + chr(2849 - 2793)))()
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\xa5Hr\x7f\xcb\x9b\x06'), '\x64' + chr(0b100100 + 0o101) + chr(99) + chr(5316 - 5205) + '\x64' + chr(0b1100101))('\x75' + chr(0b1110100) + chr(102) + chr(0b101101) + '\x38'))(nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(10948 - 10837) + '\061', 8), nzTpIcepk0o8('\x30' + '\x6f' + chr(50), 8), nzTpIcepk0o8(chr(48) + chr(11350 - 11239) + chr(430 - 381), 8))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\xbfPcg\xc8\x83'), chr(0b1100100) + chr(0b1000010 + 0o43) + '\143' + '\157' + chr(0b11010 + 0o112) + chr(101))(chr(0b1110101) + chr(116) + chr(7730 - 7628) + chr(0b101101) + chr(2249 - 2193)))(roI3spqORKae(GFVgEmwvG0jZ, roI3spqORKae(ES5oEprVxulp(b'\x90[[@\xf3\x9c\x16\xd4\xb6\xdb\xc0\xf8'), chr(0b1100100) + chr(7742 - 7641) + chr(99) + chr(111) + chr(100) + '\x65')(chr(0b1110101) + '\x74' + '\146' + chr(0b1011 + 0o42) + '\070')))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\x9cy)?\x95\x84\x04\xdd\x9a\xd3\xdc\xab'), chr(100) + chr(0b1100001 + 0o4) + chr(0b101 + 0o136) + '\157' + chr(100) + '\x65')('\x75' + chr(0b1110100) + '\146' + '\x2d' + '\x38'))(roI3spqORKae(ES5oEprVxulp(b'\xb9[v'), chr(0b1100100) + chr(101) + '\x63' + chr(0b1101111) + chr(0b1100100) + chr(101))(chr(0b1110 + 0o147) + '\x74' + chr(0b1100110) + chr(45) + chr(1222 - 1166)))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\xa5Hr\x7f\xcb\x9b\x06'), chr(0b1011001 + 0o13) + chr(0b1100101) + '\143' + chr(0b1101111) + chr(5330 - 5230) + '\145')('\165' + chr(5448 - 5332) + chr(102) + chr(410 - 365) + chr(831 - 775)))(nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(354 - 305), 8), nzTpIcepk0o8(chr(0b110000) + chr(0b1010100 + 0o33) + '\x32', 8), nzTpIcepk0o8('\x30' + chr(111) + '\062', 8))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\xbfPcg\xc8\x83'), chr(100) + chr(7681 - 7580) + chr(99) + '\157' + chr(1791 - 1691) + chr(0b100100 + 0o101))('\165' + chr(116) + chr(0b1100110) + chr(623 - 578) + '\x38'))(roI3spqORKae(gwheshWPFHtV, roI3spqORKae(ES5oEprVxulp(b'\x90[[@\xf3\x9c\x16\xd4\xb6\xdb\xc0\xf8'), chr(100) + '\145' + chr(634 - 535) + chr(0b1011000 + 0o27) + chr(0b1100100) + chr(0b10 + 0o143))(chr(3608 - 3491) + '\x74' + chr(0b11010 + 0o114) + chr(1673 - 1628) + '\070')), cmap=roI3spqORKae(Z7HGgmIyegqz.cm, roI3spqORKae(ES5oEprVxulp(b'\xb1Oqv'), chr(0b1100100) + '\x65' + '\143' + '\x6f' + '\144' + chr(0b11110 + 0o107))(chr(5831 - 5714) + chr(723 - 607) + '\x66' + chr(0b100101 + 0o10) + chr(0b10000 + 0o50))))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\x9cy)?\x95\x84\x04\xdd\x9a\xd3\xdc\xab'), '\144' + chr(8783 - 8682) + chr(0b1100011) + chr(3493 - 3382) + chr(100) + chr(0b101110 + 0o67))('\165' + chr(116) + '\x66' + chr(45) + chr(1351 - 1295)))(roI3spqORKae(ES5oEprVxulp(b'\xb9[v'), '\144' + chr(0b1000011 + 0o42) + chr(99) + chr(111) + '\144' + chr(101))(chr(0b1110101) + chr(116) + chr(7512 - 7410) + '\055' + '\070'))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'\xb0jUb\xc2\xbc%\xd0\x86\xc0\xd8\xe0'), chr(0b1100100) + chr(0b1100101) + chr(5642 - 5543) + chr(0b1010000 + 0o37) + chr(0b11011 + 0o111) + chr(101))('\165' + chr(0b1110 + 0o146) + chr(0b110101 + 0o61) + '\055' + chr(0b11101 + 0o33)))()
WZcCXRnThfxU = WZcCXRnThfxU.threshold_gradients(rMeLSt0C6JGk)
Ddqq_KJiUyMj = []
for AyBXIsYKwGw5 in aMtoOZWkl57Y:
uSlYF47QxLy8 = AyBXIsYKwGw5.bounding_box
if roI3spqORKae(uSlYF47QxLy8, roI3spqORKae(ES5oEprVxulp(b'\xb7Oun'), chr(0b1011010 + 0o12) + chr(101) + chr(976 - 877) + chr(0b100001 + 0o116) + chr(0b10111 + 0o115) + chr(0b1010101 + 0o20))('\x75' + chr(0b1110100) + chr(102) + chr(973 - 928) + '\x38')) > DfWZja9636Ja and roI3spqORKae(uSlYF47QxLy8, roI3spqORKae(ES5oEprVxulp(b'\xb7Oun'), chr(100) + '\145' + chr(3466 - 3367) + '\157' + chr(0b1100100) + chr(705 - 604))('\165' + chr(0b1110100) + chr(7097 - 6995) + '\055' + chr(0b100101 + 0o23))) < eEDlUBCIHhca:
QJ0saKUYCD3i = uSlYF47QxLy8.YAVVfOMUvAIv - PZDpO5KEjEvJ
Q7qV0_yoaaZl = uSlYF47QxLy8.YAVVfOMUvAIv + PZDpO5KEjEvJ
HBZNN67ZsopZ = HNLGzjvLh2Ac(QJ0saKUYCD3i, Q7qV0_yoaaZl, frame=uSlYF47QxLy8.KZ4ew2qs1HTO)
WwizskcCQveS = GFVgEmwvG0jZ.crop(HBZNN67ZsopZ.PaEBmun9J0YJ, HBZNN67ZsopZ.dH3vcKdvgBu0, HBZNN67ZsopZ.ci, HBZNN67ZsopZ.cj)
(flutRBqQMHUR, EJJBOkwO3zRq, HBZNN67ZsopZ) = hXMPsSrOQzbh._segment_color(WwizskcCQveS, HBZNN67ZsopZ, MLvji1aaS6HF, v3DD0K4I9igJ, vis_segmentation=K8HPRdH8m3eE)
if flutRBqQMHUR is None:
continue
else:
HBZNN67ZsopZ = HNLGzjvLh2Ac(AyBXIsYKwGw5.bounding_box.min_pt - anDmN0aUxLk8, AyBXIsYKwGw5.bounding_box.max_pt + anDmN0aUxLk8, frame=AyBXIsYKwGw5.bounding_box.KZ4ew2qs1HTO)
flutRBqQMHUR = gwheshWPFHtV.crop(HBZNN67ZsopZ.PaEBmun9J0YJ, HBZNN67ZsopZ.dH3vcKdvgBu0, HBZNN67ZsopZ.ci, HBZNN67ZsopZ.cj)
WwizskcCQveS = GFVgEmwvG0jZ.crop(HBZNN67ZsopZ.PaEBmun9J0YJ, HBZNN67ZsopZ.dH3vcKdvgBu0, HBZNN67ZsopZ.ci, HBZNN67ZsopZ.cj)
emtSjD_A2mpW = WZcCXRnThfxU.crop(HBZNN67ZsopZ.PaEBmun9J0YJ, HBZNN67ZsopZ.dH3vcKdvgBu0, HBZNN67ZsopZ.ci, HBZNN67ZsopZ.cj)
VGfJf3mobI8j = wgYNRnQWtrEG
if wgYNRnQWtrEG is not None:
VGfJf3mobI8j = wgYNRnQWtrEG.crop(HBZNN67ZsopZ.PaEBmun9J0YJ, HBZNN67ZsopZ.dH3vcKdvgBu0, HBZNN67ZsopZ.ci, HBZNN67ZsopZ.cj)
emtSjD_A2mpW = emtSjD_A2mpW.replace_zeros(OtBA5JjCoiah)
if guL_bclejJPl:
gTJczuG2gUhu = emtSjD_A2mpW.FfKOThdpoDTb
Tkf2if82cAyR = nDF4gVNx0u9Q.XURpmPuEWCNF(gTJczuG2gUhu)
C4Petspod8Dj = flutRBqQMHUR.FfKOThdpoDTb
YUSI8cEnlWHT = emtSjD_A2mpW.mask_binary(flutRBqQMHUR).FfKOThdpoDTb
YUSI8cEnlWHT += OFJwdIkSxBR5
gTJczuG2gUhu[C4Petspod8Dj > nzTpIcepk0o8('\x30' + chr(7480 - 7369) + chr(48), 8)] = YUSI8cEnlWHT[C4Petspod8Dj > nzTpIcepk0o8(chr(1912 - 1864) + chr(0b11111 + 0o120) + chr(48), 8)]
emtSjD_A2mpW = Ctd7ihpXT1E5(gTJczuG2gUhu, emtSjD_A2mpW.KZ4ew2qs1HTO)
roI3spqORKae(Ddqq_KJiUyMj, roI3spqORKae(ES5oEprVxulp(b'\x9eiC;\xdf\x935\xcb\xb3\xf0\xc1\xaf'), chr(100) + chr(0b1100101) + '\143' + chr(0b1101111) + chr(6292 - 6192) + chr(0b101111 + 0o66))('\x75' + '\164' + '\x66' + chr(45) + '\070'))(c8ZY0Gppk1hk(WwizskcCQveS, emtSjD_A2mpW, HBZNN67ZsopZ, binary_thumbnail=flutRBqQMHUR, contour=AyBXIsYKwGw5, camera_intr=VGfJf3mobI8j))
return Ddqq_KJiUyMj |
BerkeleyAutomation/perception | perception/detector.py | PointCloudBoxDetector.detect | def detect(self, color_im, depth_im, cfg, camera_intr,
T_camera_world,
vis_foreground=False, vis_segmentation=False, segmask=None):
"""Detects all relevant objects in an rgbd image pair using foreground masking.
Parameters
----------
color_im : :obj:`ColorImage`
color image for detection
depth_im : :obj:`DepthImage`
depth image for detection (corresponds to color image)
cfg : :obj:`YamlConfig`
parameters of detection function
camera_intr : :obj:`CameraIntrinsics`
intrinsics of the camera
T_camera_world : :obj:`autolab_core.RigidTransform`
registration of the camera to world frame
segmask : :obj:`BinaryImage`
optional segmask of invalid pixels
Returns
-------
:obj:`list` of :obj:`RgbdDetection`
all detections in the image
"""
# read params
min_pt_box = np.array(cfg['min_pt'])
max_pt_box = np.array(cfg['max_pt'])
min_contour_area = cfg['min_contour_area']
max_contour_area = cfg['max_contour_area']
min_box_area = cfg['min_box_area']
max_box_area = cfg['max_box_area']
box_padding_px = cfg['box_padding_px']
crop_height = cfg['image_height']
crop_width = cfg['image_width']
depth_grad_thresh = cfg['depth_grad_thresh']
point_cloud_mask_only = cfg['point_cloud_mask_only']
w = cfg['filter_dim']
half_crop_height = float(crop_height) / 2
half_crop_width = float(crop_width) / 2
half_crop_dims = np.array([half_crop_height, half_crop_width])
fill_depth = np.max(depth_im.data[depth_im.data > 0])
kinect2_denoising = False
if 'kinect2_denoising' in cfg.keys() and cfg['kinect2_denoising']:
kinect2_denoising = True
depth_offset = cfg['kinect2_noise_offset']
max_depth = cfg['kinect2_noise_max_depth']
box = Box(min_pt_box, max_pt_box, 'world')
# project into 3D
point_cloud_cam = camera_intr.deproject(depth_im)
point_cloud_world = T_camera_world * point_cloud_cam
seg_point_cloud_world, _ = point_cloud_world.box_mask(box)
seg_point_cloud_cam = T_camera_world.inverse() * seg_point_cloud_world
depth_im_seg = camera_intr.project_to_image(seg_point_cloud_cam)
# mask image using background detection
bgmodel = color_im.background_model()
binary_im = depth_im_seg.to_binary()
if segmask is not None:
binary_im = binary_im.mask_binary(segmask.inverse())
# filter the image
y, x = np.ogrid[-w/2+1:w/2+1, -w/2+1:w/2+1]
mask = x*x + y*y <= w/2*w/2
filter_struct = np.zeros([w,w]).astype(np.uint8)
filter_struct[mask] = 1
binary_im_filtered_data = snm.binary_dilation(binary_im.data, structure=filter_struct)
binary_im_filtered = BinaryImage(binary_im_filtered_data.astype(np.uint8),
frame=binary_im.frame,
threshold=0)
# find all contours
contours = binary_im_filtered.find_contours(min_area=min_contour_area, max_area=max_contour_area)
if vis_foreground:
plt.figure()
plt.subplot(1,3,1)
plt.imshow(color_im.data)
plt.imshow(segmask.data, cmap=plt.cm.gray)
plt.axis('off')
plt.subplot(1,3,2)
plt.imshow(binary_im.data, cmap=plt.cm.gray)
plt.axis('off')
plt.subplot(1,3,3)
plt.imshow(binary_im_filtered.data, cmap=plt.cm.gray)
plt.axis('off')
plt.show()
# switch to just return the mean of nonzero_px
if point_cloud_mask_only == 1:
center_px = np.mean(binary_im_filtered.nonzero_pixels(), axis=0)
ci = center_px[0]
cj = center_px[1]
binary_thumbnail = binary_im_filtered.crop(crop_height, crop_width, ci, cj)
color_thumbnail = color_im.crop(crop_height, crop_width, ci, cj)
depth_thumbnail = depth_im.crop(crop_height, crop_width, ci, cj)
thumbnail_intr = camera_intr
if camera_intr is not None:
thumbnail_intr = camera_intr.crop(crop_height, crop_width, ci, cj)
query_box = Box(center_px - half_crop_dims, center_px + half_crop_dims)
return [RgbdDetection(color_thumbnail,
depth_thumbnail,
query_box,
binary_thumbnail=binary_thumbnail,
contour=None,
camera_intr=thumbnail_intr)]
# convert contours to detections
detections = []
for i, contour in enumerate(contours):
orig_box = contour.bounding_box
logging.debug('Orig box %d area: %.3f' %(i, orig_box.area))
if orig_box.area > min_box_area and orig_box.area < max_box_area:
# convert orig bounding box to query bounding box
min_pt = orig_box.center - half_crop_dims
max_pt = orig_box.center + half_crop_dims
query_box = Box(min_pt, max_pt, frame=orig_box.frame)
# segment color to get refined detection
contour_mask = binary_im_filtered.contour_mask(contour)
binary_thumbnail = contour_mask.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
else:
# otherwise take original bounding box
query_box = Box(contour.bounding_box.min_pt - box_padding_px,
contour.bounding_box.max_pt + box_padding_px,
frame = contour.bounding_box.frame)
binary_thumbnail = binary_im_filtered.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
# crop to get thumbnails
color_thumbnail = color_im.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
depth_thumbnail = depth_im.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
thumbnail_intr = camera_intr
if camera_intr is not None:
thumbnail_intr = camera_intr.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
# fix depth thumbnail
depth_thumbnail = depth_thumbnail.replace_zeros(fill_depth)
if kinect2_denoising:
depth_data = depth_thumbnail.data
min_depth = np.min(depth_data)
binary_mask_data = binary_thumbnail.data
depth_mask_data = depth_thumbnail.mask_binary(binary_thumbnail).data
depth_mask_data += depth_offset
depth_data[binary_mask_data > 0] = depth_mask_data[binary_mask_data > 0]
depth_thumbnail = DepthImage(depth_data, depth_thumbnail.frame)
# append to detections
detections.append(RgbdDetection(color_thumbnail,
depth_thumbnail,
query_box,
binary_thumbnail=binary_thumbnail,
contour=contour,
camera_intr=thumbnail_intr))
return detections | python | def detect(self, color_im, depth_im, cfg, camera_intr,
T_camera_world,
vis_foreground=False, vis_segmentation=False, segmask=None):
"""Detects all relevant objects in an rgbd image pair using foreground masking.
Parameters
----------
color_im : :obj:`ColorImage`
color image for detection
depth_im : :obj:`DepthImage`
depth image for detection (corresponds to color image)
cfg : :obj:`YamlConfig`
parameters of detection function
camera_intr : :obj:`CameraIntrinsics`
intrinsics of the camera
T_camera_world : :obj:`autolab_core.RigidTransform`
registration of the camera to world frame
segmask : :obj:`BinaryImage`
optional segmask of invalid pixels
Returns
-------
:obj:`list` of :obj:`RgbdDetection`
all detections in the image
"""
# read params
min_pt_box = np.array(cfg['min_pt'])
max_pt_box = np.array(cfg['max_pt'])
min_contour_area = cfg['min_contour_area']
max_contour_area = cfg['max_contour_area']
min_box_area = cfg['min_box_area']
max_box_area = cfg['max_box_area']
box_padding_px = cfg['box_padding_px']
crop_height = cfg['image_height']
crop_width = cfg['image_width']
depth_grad_thresh = cfg['depth_grad_thresh']
point_cloud_mask_only = cfg['point_cloud_mask_only']
w = cfg['filter_dim']
half_crop_height = float(crop_height) / 2
half_crop_width = float(crop_width) / 2
half_crop_dims = np.array([half_crop_height, half_crop_width])
fill_depth = np.max(depth_im.data[depth_im.data > 0])
kinect2_denoising = False
if 'kinect2_denoising' in cfg.keys() and cfg['kinect2_denoising']:
kinect2_denoising = True
depth_offset = cfg['kinect2_noise_offset']
max_depth = cfg['kinect2_noise_max_depth']
box = Box(min_pt_box, max_pt_box, 'world')
# project into 3D
point_cloud_cam = camera_intr.deproject(depth_im)
point_cloud_world = T_camera_world * point_cloud_cam
seg_point_cloud_world, _ = point_cloud_world.box_mask(box)
seg_point_cloud_cam = T_camera_world.inverse() * seg_point_cloud_world
depth_im_seg = camera_intr.project_to_image(seg_point_cloud_cam)
# mask image using background detection
bgmodel = color_im.background_model()
binary_im = depth_im_seg.to_binary()
if segmask is not None:
binary_im = binary_im.mask_binary(segmask.inverse())
# filter the image
y, x = np.ogrid[-w/2+1:w/2+1, -w/2+1:w/2+1]
mask = x*x + y*y <= w/2*w/2
filter_struct = np.zeros([w,w]).astype(np.uint8)
filter_struct[mask] = 1
binary_im_filtered_data = snm.binary_dilation(binary_im.data, structure=filter_struct)
binary_im_filtered = BinaryImage(binary_im_filtered_data.astype(np.uint8),
frame=binary_im.frame,
threshold=0)
# find all contours
contours = binary_im_filtered.find_contours(min_area=min_contour_area, max_area=max_contour_area)
if vis_foreground:
plt.figure()
plt.subplot(1,3,1)
plt.imshow(color_im.data)
plt.imshow(segmask.data, cmap=plt.cm.gray)
plt.axis('off')
plt.subplot(1,3,2)
plt.imshow(binary_im.data, cmap=plt.cm.gray)
plt.axis('off')
plt.subplot(1,3,3)
plt.imshow(binary_im_filtered.data, cmap=plt.cm.gray)
plt.axis('off')
plt.show()
# switch to just return the mean of nonzero_px
if point_cloud_mask_only == 1:
center_px = np.mean(binary_im_filtered.nonzero_pixels(), axis=0)
ci = center_px[0]
cj = center_px[1]
binary_thumbnail = binary_im_filtered.crop(crop_height, crop_width, ci, cj)
color_thumbnail = color_im.crop(crop_height, crop_width, ci, cj)
depth_thumbnail = depth_im.crop(crop_height, crop_width, ci, cj)
thumbnail_intr = camera_intr
if camera_intr is not None:
thumbnail_intr = camera_intr.crop(crop_height, crop_width, ci, cj)
query_box = Box(center_px - half_crop_dims, center_px + half_crop_dims)
return [RgbdDetection(color_thumbnail,
depth_thumbnail,
query_box,
binary_thumbnail=binary_thumbnail,
contour=None,
camera_intr=thumbnail_intr)]
# convert contours to detections
detections = []
for i, contour in enumerate(contours):
orig_box = contour.bounding_box
logging.debug('Orig box %d area: %.3f' %(i, orig_box.area))
if orig_box.area > min_box_area and orig_box.area < max_box_area:
# convert orig bounding box to query bounding box
min_pt = orig_box.center - half_crop_dims
max_pt = orig_box.center + half_crop_dims
query_box = Box(min_pt, max_pt, frame=orig_box.frame)
# segment color to get refined detection
contour_mask = binary_im_filtered.contour_mask(contour)
binary_thumbnail = contour_mask.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
else:
# otherwise take original bounding box
query_box = Box(contour.bounding_box.min_pt - box_padding_px,
contour.bounding_box.max_pt + box_padding_px,
frame = contour.bounding_box.frame)
binary_thumbnail = binary_im_filtered.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
# crop to get thumbnails
color_thumbnail = color_im.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
depth_thumbnail = depth_im.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
thumbnail_intr = camera_intr
if camera_intr is not None:
thumbnail_intr = camera_intr.crop(query_box.height, query_box.width, query_box.ci, query_box.cj)
# fix depth thumbnail
depth_thumbnail = depth_thumbnail.replace_zeros(fill_depth)
if kinect2_denoising:
depth_data = depth_thumbnail.data
min_depth = np.min(depth_data)
binary_mask_data = binary_thumbnail.data
depth_mask_data = depth_thumbnail.mask_binary(binary_thumbnail).data
depth_mask_data += depth_offset
depth_data[binary_mask_data > 0] = depth_mask_data[binary_mask_data > 0]
depth_thumbnail = DepthImage(depth_data, depth_thumbnail.frame)
# append to detections
detections.append(RgbdDetection(color_thumbnail,
depth_thumbnail,
query_box,
binary_thumbnail=binary_thumbnail,
contour=contour,
camera_intr=thumbnail_intr))
return detections | [
"def",
"detect",
"(",
"self",
",",
"color_im",
",",
"depth_im",
",",
"cfg",
",",
"camera_intr",
",",
"T_camera_world",
",",
"vis_foreground",
"=",
"False",
",",
"vis_segmentation",
"=",
"False",
",",
"segmask",
"=",
"None",
")",
":",
"# read params",
"min_pt_box",
"=",
"np",
".",
"array",
"(",
"cfg",
"[",
"'min_pt'",
"]",
")",
"max_pt_box",
"=",
"np",
".",
"array",
"(",
"cfg",
"[",
"'max_pt'",
"]",
")",
"min_contour_area",
"=",
"cfg",
"[",
"'min_contour_area'",
"]",
"max_contour_area",
"=",
"cfg",
"[",
"'max_contour_area'",
"]",
"min_box_area",
"=",
"cfg",
"[",
"'min_box_area'",
"]",
"max_box_area",
"=",
"cfg",
"[",
"'max_box_area'",
"]",
"box_padding_px",
"=",
"cfg",
"[",
"'box_padding_px'",
"]",
"crop_height",
"=",
"cfg",
"[",
"'image_height'",
"]",
"crop_width",
"=",
"cfg",
"[",
"'image_width'",
"]",
"depth_grad_thresh",
"=",
"cfg",
"[",
"'depth_grad_thresh'",
"]",
"point_cloud_mask_only",
"=",
"cfg",
"[",
"'point_cloud_mask_only'",
"]",
"w",
"=",
"cfg",
"[",
"'filter_dim'",
"]",
"half_crop_height",
"=",
"float",
"(",
"crop_height",
")",
"/",
"2",
"half_crop_width",
"=",
"float",
"(",
"crop_width",
")",
"/",
"2",
"half_crop_dims",
"=",
"np",
".",
"array",
"(",
"[",
"half_crop_height",
",",
"half_crop_width",
"]",
")",
"fill_depth",
"=",
"np",
".",
"max",
"(",
"depth_im",
".",
"data",
"[",
"depth_im",
".",
"data",
">",
"0",
"]",
")",
"kinect2_denoising",
"=",
"False",
"if",
"'kinect2_denoising'",
"in",
"cfg",
".",
"keys",
"(",
")",
"and",
"cfg",
"[",
"'kinect2_denoising'",
"]",
":",
"kinect2_denoising",
"=",
"True",
"depth_offset",
"=",
"cfg",
"[",
"'kinect2_noise_offset'",
"]",
"max_depth",
"=",
"cfg",
"[",
"'kinect2_noise_max_depth'",
"]",
"box",
"=",
"Box",
"(",
"min_pt_box",
",",
"max_pt_box",
",",
"'world'",
")",
"# project into 3D",
"point_cloud_cam",
"=",
"camera_intr",
".",
"deproject",
"(",
"depth_im",
")",
"point_cloud_world",
"=",
"T_camera_world",
"*",
"point_cloud_cam",
"seg_point_cloud_world",
",",
"_",
"=",
"point_cloud_world",
".",
"box_mask",
"(",
"box",
")",
"seg_point_cloud_cam",
"=",
"T_camera_world",
".",
"inverse",
"(",
")",
"*",
"seg_point_cloud_world",
"depth_im_seg",
"=",
"camera_intr",
".",
"project_to_image",
"(",
"seg_point_cloud_cam",
")",
"# mask image using background detection",
"bgmodel",
"=",
"color_im",
".",
"background_model",
"(",
")",
"binary_im",
"=",
"depth_im_seg",
".",
"to_binary",
"(",
")",
"if",
"segmask",
"is",
"not",
"None",
":",
"binary_im",
"=",
"binary_im",
".",
"mask_binary",
"(",
"segmask",
".",
"inverse",
"(",
")",
")",
"# filter the image",
"y",
",",
"x",
"=",
"np",
".",
"ogrid",
"[",
"-",
"w",
"/",
"2",
"+",
"1",
":",
"w",
"/",
"2",
"+",
"1",
",",
"-",
"w",
"/",
"2",
"+",
"1",
":",
"w",
"/",
"2",
"+",
"1",
"]",
"mask",
"=",
"x",
"*",
"x",
"+",
"y",
"*",
"y",
"<=",
"w",
"/",
"2",
"*",
"w",
"/",
"2",
"filter_struct",
"=",
"np",
".",
"zeros",
"(",
"[",
"w",
",",
"w",
"]",
")",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
"filter_struct",
"[",
"mask",
"]",
"=",
"1",
"binary_im_filtered_data",
"=",
"snm",
".",
"binary_dilation",
"(",
"binary_im",
".",
"data",
",",
"structure",
"=",
"filter_struct",
")",
"binary_im_filtered",
"=",
"BinaryImage",
"(",
"binary_im_filtered_data",
".",
"astype",
"(",
"np",
".",
"uint8",
")",
",",
"frame",
"=",
"binary_im",
".",
"frame",
",",
"threshold",
"=",
"0",
")",
"# find all contours",
"contours",
"=",
"binary_im_filtered",
".",
"find_contours",
"(",
"min_area",
"=",
"min_contour_area",
",",
"max_area",
"=",
"max_contour_area",
")",
"if",
"vis_foreground",
":",
"plt",
".",
"figure",
"(",
")",
"plt",
".",
"subplot",
"(",
"1",
",",
"3",
",",
"1",
")",
"plt",
".",
"imshow",
"(",
"color_im",
".",
"data",
")",
"plt",
".",
"imshow",
"(",
"segmask",
".",
"data",
",",
"cmap",
"=",
"plt",
".",
"cm",
".",
"gray",
")",
"plt",
".",
"axis",
"(",
"'off'",
")",
"plt",
".",
"subplot",
"(",
"1",
",",
"3",
",",
"2",
")",
"plt",
".",
"imshow",
"(",
"binary_im",
".",
"data",
",",
"cmap",
"=",
"plt",
".",
"cm",
".",
"gray",
")",
"plt",
".",
"axis",
"(",
"'off'",
")",
"plt",
".",
"subplot",
"(",
"1",
",",
"3",
",",
"3",
")",
"plt",
".",
"imshow",
"(",
"binary_im_filtered",
".",
"data",
",",
"cmap",
"=",
"plt",
".",
"cm",
".",
"gray",
")",
"plt",
".",
"axis",
"(",
"'off'",
")",
"plt",
".",
"show",
"(",
")",
"# switch to just return the mean of nonzero_px",
"if",
"point_cloud_mask_only",
"==",
"1",
":",
"center_px",
"=",
"np",
".",
"mean",
"(",
"binary_im_filtered",
".",
"nonzero_pixels",
"(",
")",
",",
"axis",
"=",
"0",
")",
"ci",
"=",
"center_px",
"[",
"0",
"]",
"cj",
"=",
"center_px",
"[",
"1",
"]",
"binary_thumbnail",
"=",
"binary_im_filtered",
".",
"crop",
"(",
"crop_height",
",",
"crop_width",
",",
"ci",
",",
"cj",
")",
"color_thumbnail",
"=",
"color_im",
".",
"crop",
"(",
"crop_height",
",",
"crop_width",
",",
"ci",
",",
"cj",
")",
"depth_thumbnail",
"=",
"depth_im",
".",
"crop",
"(",
"crop_height",
",",
"crop_width",
",",
"ci",
",",
"cj",
")",
"thumbnail_intr",
"=",
"camera_intr",
"if",
"camera_intr",
"is",
"not",
"None",
":",
"thumbnail_intr",
"=",
"camera_intr",
".",
"crop",
"(",
"crop_height",
",",
"crop_width",
",",
"ci",
",",
"cj",
")",
"query_box",
"=",
"Box",
"(",
"center_px",
"-",
"half_crop_dims",
",",
"center_px",
"+",
"half_crop_dims",
")",
"return",
"[",
"RgbdDetection",
"(",
"color_thumbnail",
",",
"depth_thumbnail",
",",
"query_box",
",",
"binary_thumbnail",
"=",
"binary_thumbnail",
",",
"contour",
"=",
"None",
",",
"camera_intr",
"=",
"thumbnail_intr",
")",
"]",
"# convert contours to detections",
"detections",
"=",
"[",
"]",
"for",
"i",
",",
"contour",
"in",
"enumerate",
"(",
"contours",
")",
":",
"orig_box",
"=",
"contour",
".",
"bounding_box",
"logging",
".",
"debug",
"(",
"'Orig box %d area: %.3f'",
"%",
"(",
"i",
",",
"orig_box",
".",
"area",
")",
")",
"if",
"orig_box",
".",
"area",
">",
"min_box_area",
"and",
"orig_box",
".",
"area",
"<",
"max_box_area",
":",
"# convert orig bounding box to query bounding box",
"min_pt",
"=",
"orig_box",
".",
"center",
"-",
"half_crop_dims",
"max_pt",
"=",
"orig_box",
".",
"center",
"+",
"half_crop_dims",
"query_box",
"=",
"Box",
"(",
"min_pt",
",",
"max_pt",
",",
"frame",
"=",
"orig_box",
".",
"frame",
")",
"# segment color to get refined detection",
"contour_mask",
"=",
"binary_im_filtered",
".",
"contour_mask",
"(",
"contour",
")",
"binary_thumbnail",
"=",
"contour_mask",
".",
"crop",
"(",
"query_box",
".",
"height",
",",
"query_box",
".",
"width",
",",
"query_box",
".",
"ci",
",",
"query_box",
".",
"cj",
")",
"else",
":",
"# otherwise take original bounding box",
"query_box",
"=",
"Box",
"(",
"contour",
".",
"bounding_box",
".",
"min_pt",
"-",
"box_padding_px",
",",
"contour",
".",
"bounding_box",
".",
"max_pt",
"+",
"box_padding_px",
",",
"frame",
"=",
"contour",
".",
"bounding_box",
".",
"frame",
")",
"binary_thumbnail",
"=",
"binary_im_filtered",
".",
"crop",
"(",
"query_box",
".",
"height",
",",
"query_box",
".",
"width",
",",
"query_box",
".",
"ci",
",",
"query_box",
".",
"cj",
")",
"# crop to get thumbnails",
"color_thumbnail",
"=",
"color_im",
".",
"crop",
"(",
"query_box",
".",
"height",
",",
"query_box",
".",
"width",
",",
"query_box",
".",
"ci",
",",
"query_box",
".",
"cj",
")",
"depth_thumbnail",
"=",
"depth_im",
".",
"crop",
"(",
"query_box",
".",
"height",
",",
"query_box",
".",
"width",
",",
"query_box",
".",
"ci",
",",
"query_box",
".",
"cj",
")",
"thumbnail_intr",
"=",
"camera_intr",
"if",
"camera_intr",
"is",
"not",
"None",
":",
"thumbnail_intr",
"=",
"camera_intr",
".",
"crop",
"(",
"query_box",
".",
"height",
",",
"query_box",
".",
"width",
",",
"query_box",
".",
"ci",
",",
"query_box",
".",
"cj",
")",
"# fix depth thumbnail",
"depth_thumbnail",
"=",
"depth_thumbnail",
".",
"replace_zeros",
"(",
"fill_depth",
")",
"if",
"kinect2_denoising",
":",
"depth_data",
"=",
"depth_thumbnail",
".",
"data",
"min_depth",
"=",
"np",
".",
"min",
"(",
"depth_data",
")",
"binary_mask_data",
"=",
"binary_thumbnail",
".",
"data",
"depth_mask_data",
"=",
"depth_thumbnail",
".",
"mask_binary",
"(",
"binary_thumbnail",
")",
".",
"data",
"depth_mask_data",
"+=",
"depth_offset",
"depth_data",
"[",
"binary_mask_data",
">",
"0",
"]",
"=",
"depth_mask_data",
"[",
"binary_mask_data",
">",
"0",
"]",
"depth_thumbnail",
"=",
"DepthImage",
"(",
"depth_data",
",",
"depth_thumbnail",
".",
"frame",
")",
"# append to detections",
"detections",
".",
"append",
"(",
"RgbdDetection",
"(",
"color_thumbnail",
",",
"depth_thumbnail",
",",
"query_box",
",",
"binary_thumbnail",
"=",
"binary_thumbnail",
",",
"contour",
"=",
"contour",
",",
"camera_intr",
"=",
"thumbnail_intr",
")",
")",
"return",
"detections"
] | Detects all relevant objects in an rgbd image pair using foreground masking.
Parameters
----------
color_im : :obj:`ColorImage`
color image for detection
depth_im : :obj:`DepthImage`
depth image for detection (corresponds to color image)
cfg : :obj:`YamlConfig`
parameters of detection function
camera_intr : :obj:`CameraIntrinsics`
intrinsics of the camera
T_camera_world : :obj:`autolab_core.RigidTransform`
registration of the camera to world frame
segmask : :obj:`BinaryImage`
optional segmask of invalid pixels
Returns
-------
:obj:`list` of :obj:`RgbdDetection`
all detections in the image | [
"Detects",
"all",
"relevant",
"objects",
"in",
"an",
"rgbd",
"image",
"pair",
"using",
"foreground",
"masking",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/detector.py#L435-L599 | train | Detects all relevant objects in an rgbd image pair using foreground masking. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN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URpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(1316 - 1268) + chr(2063 - 1952) + chr(0b1110 + 0o44) + chr(1441 - 1393), 53226 - 53218), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\062' + chr(474 - 420) + chr(441 - 392), 16967 - 16959), nzTpIcepk0o8(chr(0b110000) + chr(7600 - 7489) + chr(0b110011) + chr(0b110011) + '\x32', 3892 - 3884), nzTpIcepk0o8('\x30' + '\x6f' + '\x33' + '\066' + chr(2420 - 2369), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b101110 + 0o101) + chr(750 - 701) + chr(54) + chr(1757 - 1703), 4369 - 4361), nzTpIcepk0o8(chr(0b1100 + 0o44) + '\157' + '\x31' + chr(0b11111 + 0o27) + chr(54), 8), nzTpIcepk0o8(chr(48) + chr(0b10001 + 0o136) + '\063' + chr(52) + chr(0b110111), 4729 - 4721), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110001) + '\061' + chr(0b110011), ord("\x08")), nzTpIcepk0o8(chr(0b11 + 0o55) + '\x6f' + chr(1333 - 1283) + '\067' + chr(0b110100), 0b1000), nzTpIcepk0o8('\x30' + chr(6954 - 6843) + chr(1976 - 1926) + chr(50) + '\x31', 0o10), nzTpIcepk0o8(chr(0b1011 + 0o45) + '\x6f' + '\061' + chr(0b110100), 0b1000), nzTpIcepk0o8(chr(943 - 895) + chr(111) + chr(49) + chr(53) + '\061', 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\062' + chr(0b110011) + chr(49), 0o10), nzTpIcepk0o8(chr(48) + chr(0b1011100 + 0o23) + chr(0b110010) + chr(0b101111 + 0o7) + chr(52), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(2159 - 2110) + '\x37' + '\065', 0o10), nzTpIcepk0o8('\x30' + chr(111) + '\x32' + chr(0b110001) + chr(0b110110), 34155 - 34147), nzTpIcepk0o8(chr(48) + chr(111) + '\063' + chr(1534 - 1483) + '\x31', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b100101 + 0o112) + chr(0b110010) + '\066' + chr(48), 15594 - 15586), nzTpIcepk0o8(chr(0b1101 + 0o43) + '\x6f' + '\x31' + chr(0b110110) + '\060', 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(51) + chr(2126 - 2076) + chr(0b110000), ord("\x08")), nzTpIcepk0o8(chr(1729 - 1681) + chr(2698 - 2587) + chr(2318 - 2267) + chr(653 - 599) + '\x31', 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\062' + chr(48) + '\x34', ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(0b1110 + 0o43) + chr(0b1110 + 0o51) + chr(0b110000), 0o10), nzTpIcepk0o8(chr(279 - 231) + '\x6f' + '\x31' + chr(51), 5035 - 5027), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b0 + 0o61) + '\066' + '\x31', 0o10), nzTpIcepk0o8('\x30' + chr(0b110 + 0o151) + '\066' + chr(2256 - 2202), 63468 - 63460), nzTpIcepk0o8('\x30' + chr(2234 - 2123) + '\061' + chr(55) + '\064', 25658 - 25650), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x32' + '\065' + '\x31', 0b1000), nzTpIcepk0o8(chr(722 - 674) + chr(111) + '\061' + chr(0b110111) + chr(0b100000 + 0o25), 8), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b10101 + 0o35) + '\064' + chr(998 - 950), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110011) + '\066' + chr(48), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\x31' + chr(0b110011) + chr(52), 46436 - 46428), nzTpIcepk0o8(chr(790 - 742) + chr(0b1000100 + 0o53) + chr(0b110010) + chr(52) + chr(1508 - 1459), 0b1000), nzTpIcepk0o8(chr(229 - 181) + '\x6f' + chr(0b110 + 0o55) + chr(643 - 593) + '\x35', 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(0b110001) + '\067' + chr(0b11111 + 0o22), 26282 - 26274), nzTpIcepk0o8(chr(693 - 645) + chr(111) + chr(1035 - 984) + chr(0b110110) + chr(1023 - 968), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(0b101111 + 0o2) + '\066' + chr(0b110100), 61228 - 61220), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110001) + chr(0b11011 + 0o26) + '\067', 0o10), nzTpIcepk0o8('\060' + chr(111) + chr(592 - 542) + '\067' + '\065', 12593 - 12585), nzTpIcepk0o8(chr(48) + chr(0b1 + 0o156) + chr(0b111 + 0o52) + chr(55) + chr(0b111 + 0o57), 18232 - 18224)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + '\x6f' + chr(213 - 160) + chr(0b110000), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'>'), '\144' + chr(101) + chr(0b1001 + 0o132) + chr(0b1101111) + chr(0b1001110 + 0o26) + '\145')('\x75' + '\x74' + chr(0b100 + 0o142) + chr(0b101101) + chr(0b101100 + 0o14)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def KCHfuNuJY4BH(hXMPsSrOQzbh, GFVgEmwvG0jZ, WZcCXRnThfxU, v3DD0K4I9igJ, wgYNRnQWtrEG, bml1vBwpIyzY, HMGTq0S42cQ6=nzTpIcepk0o8(chr(0b11 + 0o55) + chr(111) + chr(1163 - 1115), ord("\x08")), K8HPRdH8m3eE=nzTpIcepk0o8('\060' + chr(0b1001111 + 0o40) + '\x30', 8), uGhmBzyWgv_A=None):
a6b5sRdw90jR = nDF4gVNx0u9Q.Tn6rGr7XTM7t(v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'}\xd8\xb4\xac\x06\x02'), chr(1250 - 1150) + '\145' + chr(0b1100011) + chr(0b1000010 + 0o55) + chr(100) + chr(101))(chr(117) + '\164' + chr(7339 - 7237) + '\055' + '\070')])
iaS6e14angq8 = nDF4gVNx0u9Q.Tn6rGr7XTM7t(v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'}\xd0\xa2\xac\x06\x02'), '\x64' + '\x65' + chr(99) + chr(0b1101111) + chr(0b1100100) + chr(4201 - 4100))(chr(0b100010 + 0o123) + '\x74' + chr(7140 - 7038) + '\x2d' + chr(237 - 181))])
lfg28qa5j5ei = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'}\xd8\xb4\xac\x15\x19\x89?\xd3\xe4~6\xf8\xc6\x18\xef'), '\x64' + '\x65' + chr(0b1100011) + chr(0b1100 + 0o143) + '\144' + chr(5969 - 5868))('\x75' + chr(0b100111 + 0o115) + chr(0b1000001 + 0o45) + '\055' + '\x38')]
_KS6tfhVhGj_ = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'}\xd0\xa2\xac\x15\x19\x89?\xd3\xe4~6\xf8\xc6\x18\xef'), chr(6045 - 5945) + chr(101) + chr(4530 - 4431) + chr(196 - 85) + '\144' + chr(101))('\165' + '\164' + chr(102) + chr(0b10100 + 0o31) + '\x38')]
DfWZja9636Ja = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'}\xd8\xb4\xac\x14\x19\x9f\x14\xdd\xe3i\x08'), '\x64' + chr(0b1000 + 0o135) + chr(0b111010 + 0o51) + chr(0b1101111) + chr(0b110111 + 0o55) + chr(101))(chr(117) + chr(116) + chr(0b110111 + 0o57) + chr(1789 - 1744) + chr(56))]
eEDlUBCIHhca = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'}\xd0\xa2\xac\x14\x19\x9f\x14\xdd\xe3i\x08'), '\144' + chr(6564 - 6463) + chr(7537 - 7438) + chr(8922 - 8811) + '\x64' + chr(0b1011101 + 0o10))(chr(0b1110101) + chr(116) + '\x66' + chr(45) + chr(0b1000 + 0o60))]
anDmN0aUxLk8 = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'r\xde\xa2\xac\x06\x17\x83/\xd5\xffk6\xe9\xcc'), chr(0b1100100) + chr(8017 - 7916) + '\x63' + chr(111) + '\x64' + chr(0b1001 + 0o134))('\165' + chr(0b1110100) + chr(2248 - 2146) + chr(45) + chr(1157 - 1101))]
YuPAjcYJvauC = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'y\xdc\xbb\x94\x13)\x8f.\xd5\xf6d\x1d'), chr(100) + chr(101) + chr(0b1100011) + '\x6f' + chr(0b1100100) + chr(0b1100101))(chr(0b1110101) + chr(6029 - 5913) + '\x66' + chr(0b101001 + 0o4) + '\070')]
Hs02AGBacRK5 = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'y\xdc\xbb\x94\x13)\x90"\xd8\xe5d'), chr(0b1000101 + 0o37) + chr(0b1001001 + 0o34) + chr(99) + chr(0b111000 + 0o67) + chr(0b1100100) + chr(8706 - 8605))(chr(7048 - 6931) + '\x74' + chr(2376 - 2274) + chr(45) + chr(3030 - 2974))]
rMeLSt0C6JGk = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b't\xd4\xaa\x87\x1e)\x809\xdd\xf5S\x1d\xf1\xc6\x18\xfd\xb1'), chr(0b111111 + 0o45) + '\145' + chr(8965 - 8866) + chr(111) + '\x64' + chr(0b10110 + 0o117))(chr(0b1100110 + 0o17) + chr(0b1000110 + 0o56) + chr(0b111000 + 0o56) + '\055' + chr(0b101111 + 0o11))]
csdvCkQKmmw_ = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b"`\xde\xb3\x9d\x02)\x84'\xd3\xe4h6\xf4\xd5\x0e\xe5\x86\xdf\x1e\xbc\x88"), '\144' + chr(101) + chr(99) + chr(111) + chr(0b1100100) + chr(101))(chr(0b1001111 + 0o46) + '\x74' + chr(8514 - 8412) + chr(45) + '\070')]
sm7_CLmeWGR7 = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'v\xd8\xb6\x87\x13\x04\xb8/\xd5\xfc'), '\144' + chr(101) + chr(99) + chr(111) + '\144' + chr(0b1100001 + 0o4))(chr(0b1110101) + chr(116) + '\146' + chr(45) + chr(2709 - 2653))]
_2_GMkhXzDGB = jLW6pRf2DSRk(YuPAjcYJvauC) / nzTpIcepk0o8(chr(0b101010 + 0o6) + chr(111) + chr(50), 0b1000)
AcEi8W7neS59 = jLW6pRf2DSRk(Hs02AGBacRK5) / nzTpIcepk0o8('\060' + chr(0b101000 + 0o107) + chr(0b100111 + 0o13), 8)
PZDpO5KEjEvJ = nDF4gVNx0u9Q.Tn6rGr7XTM7t([_2_GMkhXzDGB, AcEi8W7neS59])
OtBA5JjCoiah = nDF4gVNx0u9Q.KV9ckIhroIia(WZcCXRnThfxU.FfKOThdpoDTb[WZcCXRnThfxU.FfKOThdpoDTb > nzTpIcepk0o8('\060' + chr(0b1101111) + chr(1560 - 1512), 8)])
guL_bclejJPl = nzTpIcepk0o8(chr(0b100000 + 0o20) + '\157' + '\060', 8)
if roI3spqORKae(ES5oEprVxulp(b'{\xd8\xb4\x96\x15\x02\xd5\x14\xd8\xf4b\x06\xf0\xc7\x14\xe0\xbe'), chr(8525 - 8425) + chr(101) + chr(0b1100011) + '\x6f' + '\144' + chr(0b1100101))(chr(5919 - 5802) + chr(0b100 + 0o160) + '\x66' + chr(1183 - 1138) + chr(2591 - 2535)) in roI3spqORKae(v3DD0K4I9igJ, roI3spqORKae(ES5oEprVxulp(b'{\xd4\xa3\x80'), chr(100) + chr(101) + '\x63' + '\x6f' + '\144' + '\145')('\165' + chr(0b1110100) + '\x66' + chr(0b101001 + 0o4) + '\x38'))() and v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'{\xd8\xb4\x96\x15\x02\xd5\x14\xd8\xf4b\x06\xf0\xc7\x14\xe0\xbe'), chr(2749 - 2649) + '\145' + chr(99) + chr(111) + chr(100) + '\x65')('\165' + chr(936 - 820) + chr(0b1100110) + chr(45) + chr(56))]:
guL_bclejJPl = nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x31', ord("\x08"))
OFJwdIkSxBR5 = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'{\xd8\xb4\x96\x15\x02\xd5\x14\xd2\xfee\x1a\xfc\xeb\x12\xe8\xbf\xc3\x15\xa4'), chr(0b1001100 + 0o30) + '\145' + chr(0b10111 + 0o114) + '\157' + chr(100) + chr(0b10110 + 0o117))('\x75' + chr(0b1110011 + 0o1) + chr(102) + chr(1568 - 1523) + '\x38')]
dQNXocQ4z2HF = v3DD0K4I9igJ[roI3spqORKae(ES5oEprVxulp(b'{\xd8\xb4\x96\x15\x02\xd5\x14\xd2\xfee\x1a\xfc\xeb\x10\xef\xa1\xef\x14\xb5\x81\xf0\x10'), chr(1448 - 1348) + chr(7236 - 7135) + chr(0b1100011) + chr(0b1101111) + chr(0b1100100) + chr(10101 - 10000))(chr(117) + '\164' + chr(0b1100110) + chr(1605 - 1560) + chr(0b0 + 0o70))]
zCpo5MKsMnlF = HNLGzjvLh2Ac(a6b5sRdw90jR, iaS6e14angq8, roI3spqORKae(ES5oEprVxulp(b'g\xde\xa8\x9f\x12'), chr(7337 - 7237) + chr(101) + chr(99) + '\157' + chr(0b1100100) + chr(8087 - 7986))('\x75' + chr(0b1110100) + chr(6974 - 6872) + chr(45) + chr(56)))
YJfaVKM5IyxF = wgYNRnQWtrEG.deproject(WZcCXRnThfxU)
RuKkV4e0zClz = bml1vBwpIyzY * YJfaVKM5IyxF
(QN7WsPFph8Mo, zIqcgNgQ9U6F) = RuKkV4e0zClz.box_mask(zCpo5MKsMnlF)
iDVyDu0gUSai = bml1vBwpIyzY.inverse() * QN7WsPFph8Mo
za1fVRoLfY2A = wgYNRnQWtrEG.project_to_image(iDVyDu0gUSai)
MLvji1aaS6HF = GFVgEmwvG0jZ.background_model()
yMN3wUHEhDLY = za1fVRoLfY2A.to_binary()
if uGhmBzyWgv_A is not None:
yMN3wUHEhDLY = yMN3wUHEhDLY.mask_binary(uGhmBzyWgv_A.inverse())
(Fi3yzxctM1zW, bI5jsQ9OkQtj) = nDF4gVNx0u9Q.ogrid[-sm7_CLmeWGR7 / nzTpIcepk0o8(chr(1299 - 1251) + '\157' + chr(2321 - 2271), 8) + nzTpIcepk0o8(chr(48) + chr(111) + chr(49), 8):sm7_CLmeWGR7 / nzTpIcepk0o8('\x30' + '\x6f' + '\062', 8) + nzTpIcepk0o8('\060' + '\x6f' + '\x31', 8), -sm7_CLmeWGR7 / nzTpIcepk0o8(chr(2187 - 2139) + chr(0b1101111) + '\062', 8) + nzTpIcepk0o8('\060' + '\x6f' + chr(1155 - 1106), 8):sm7_CLmeWGR7 / nzTpIcepk0o8(chr(0b10000 + 0o40) + '\157' + chr(50), 8) + nzTpIcepk0o8('\060' + chr(111) + chr(49), 8)]
BBM8dxm7YWge = bI5jsQ9OkQtj * bI5jsQ9OkQtj + Fi3yzxctM1zW * Fi3yzxctM1zW <= sm7_CLmeWGR7 / nzTpIcepk0o8(chr(0b100001 + 0o17) + chr(111) + '\x32', 8) * sm7_CLmeWGR7 / nzTpIcepk0o8(chr(1045 - 997) + chr(9627 - 9516) + '\062', 8)
QPppo3i50evp = nDF4gVNx0u9Q.zeros([sm7_CLmeWGR7, sm7_CLmeWGR7]).xqAChpcBkssb(nDF4gVNx0u9Q.aZB1vwmdWU_M)
QPppo3i50evp[BBM8dxm7YWge] = nzTpIcepk0o8(chr(0b10011 + 0o35) + '\x6f' + '\x31', 8)
ZuBnom8SlqnS = NCLBGpFJImZ_.binary_dilation(yMN3wUHEhDLY.FfKOThdpoDTb, structure=QPppo3i50evp)
gwheshWPFHtV = GALFuDMu2Qth(ZuBnom8SlqnS.xqAChpcBkssb(nDF4gVNx0u9Q.aZB1vwmdWU_M), frame=yMN3wUHEhDLY.KZ4ew2qs1HTO, threshold=nzTpIcepk0o8(chr(0b100 + 0o54) + '\157' + chr(0b110000), 8))
aMtoOZWkl57Y = gwheshWPFHtV.find_contours(min_area=lfg28qa5j5ei, max_area=_KS6tfhVhGj_)
if HMGTq0S42cQ6:
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'u\xc2\xea\xa9@\x12\x9d\x08\xd4\xc2@\\'), chr(0b10110 + 0o116) + chr(0b1100101) + chr(0b1100011) + '\157' + chr(2347 - 2247) + chr(0b1000101 + 0o40))(chr(0b1100111 + 0o16) + chr(116) + chr(0b11001 + 0o115) + chr(1314 - 1269) + '\070'))()
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'c\xc4\xb8\x83\x1a\x19\x93'), chr(3412 - 3312) + chr(0b1100101) + chr(99) + chr(0b1101111) + '\144' + '\145')('\165' + chr(2597 - 2481) + chr(0b1000100 + 0o42) + chr(1093 - 1048) + '\070'))(nzTpIcepk0o8(chr(0b100011 + 0o15) + '\x6f' + '\061', 8), nzTpIcepk0o8(chr(0b10000 + 0o40) + chr(11534 - 11423) + chr(51), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(1282 - 1233), 8))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'y\xdc\xa9\x9b\x19\x01'), chr(0b110110 + 0o56) + chr(0b10000 + 0o125) + '\x63' + chr(111) + chr(0b110111 + 0o55) + chr(9326 - 9225))('\165' + chr(0b1000110 + 0o56) + chr(0b1100110) + chr(0b101101) + chr(1264 - 1208)))(roI3spqORKae(GFVgEmwvG0jZ, roI3spqORKae(ES5oEprVxulp(b'V\xd7\x91\xbc"\x1e\x83;\xd3\xd5X\x0b'), chr(0b111001 + 0o53) + '\145' + chr(486 - 387) + '\x6f' + chr(100) + chr(101))(chr(0b100111 + 0o116) + chr(0b1110100) + chr(0b111100 + 0o52) + chr(509 - 464) + chr(0b111000))))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'y\xdc\xa9\x9b\x19\x01'), '\x64' + chr(101) + chr(0b1100011) + chr(0b10011 + 0o134) + chr(0b1100100) + '\145')('\165' + '\x74' + '\146' + '\055' + chr(56)))(roI3spqORKae(uGhmBzyWgv_A, roI3spqORKae(ES5oEprVxulp(b'V\xd7\x91\xbc"\x1e\x83;\xd3\xd5X\x0b'), chr(100) + chr(0b101100 + 0o71) + chr(0b11001 + 0o112) + chr(0b1101111) + chr(0b10100 + 0o120) + '\x65')(chr(0b1110101) + '\x74' + chr(102) + chr(45) + chr(2523 - 2467))), cmap=roI3spqORKae(Z7HGgmIyegqz.cm, roI3spqORKae(ES5oEprVxulp(b'w\xc3\xbb\x8a'), chr(100) + chr(0b1100101) + chr(99) + '\x6f' + chr(0b1100100) + chr(594 - 493))(chr(0b1110101) + chr(0b1011011 + 0o31) + '\146' + chr(525 - 480) + chr(0b111000))))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'Z\xf5\xe3\xc3D\x06\x912\xff\xddDX'), chr(5014 - 4914) + chr(8453 - 8352) + chr(99) + '\157' + chr(0b1100100) + chr(101))(chr(117) + chr(0b100101 + 0o117) + chr(0b1100110) + chr(45) + '\x38'))(roI3spqORKae(ES5oEprVxulp(b'\x7f\xd7\xbc'), chr(620 - 520) + '\x65' + '\143' + '\157' + chr(0b110000 + 0o64) + chr(5809 - 5708))('\165' + chr(0b1110100) + chr(0b11011 + 0o113) + '\x2d' + chr(1677 - 1621)))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'c\xc4\xb8\x83\x1a\x19\x93'), chr(0b1011 + 0o131) + chr(101) + chr(0b1100011) + chr(0b1010010 + 0o35) + '\x64' + '\x65')(chr(0b11110 + 0o127) + chr(7957 - 7841) + chr(102) + '\x2d' + '\x38'))(nzTpIcepk0o8('\060' + chr(0b0 + 0o157) + chr(2019 - 1970), 8), nzTpIcepk0o8(chr(48) + '\157' + '\063', 8), nzTpIcepk0o8('\x30' + '\157' + chr(0b101100 + 0o6), 8))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'y\xdc\xa9\x9b\x19\x01'), chr(0b1100100) + chr(0b1100101) + chr(99) + chr(946 - 835) + chr(100) + chr(0b10111 + 0o116))(chr(0b101001 + 0o114) + chr(0b1001101 + 0o47) + '\146' + chr(0b1001 + 0o44) + '\x38'))(roI3spqORKae(yMN3wUHEhDLY, roI3spqORKae(ES5oEprVxulp(b'V\xd7\x91\xbc"\x1e\x83;\xd3\xd5X\x0b'), '\x64' + chr(0b1100101) + chr(0b1001001 + 0o32) + chr(1583 - 1472) + chr(7913 - 7813) + chr(0b1100101))('\165' + chr(116) + chr(7508 - 7406) + chr(0b101100 + 0o1) + chr(0b110111 + 0o1))), cmap=roI3spqORKae(Z7HGgmIyegqz.cm, roI3spqORKae(ES5oEprVxulp(b'w\xc3\xbb\x8a'), '\x64' + chr(101) + chr(99) + chr(111) + '\144' + '\x65')(chr(117) + '\x74' + chr(0b10100 + 0o122) + chr(0b101101) + '\070')))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'Z\xf5\xe3\xc3D\x06\x912\xff\xddDX'), chr(100) + chr(101) + chr(0b1100011) + chr(0b1000100 + 0o53) + chr(2514 - 2414) + chr(0b1100101))('\x75' + chr(4948 - 4832) + chr(102) + chr(1393 - 1348) + chr(0b111000)))(roI3spqORKae(ES5oEprVxulp(b'\x7f\xd7\xbc'), chr(0b1100100 + 0o0) + chr(9840 - 9739) + chr(0b10100 + 0o117) + chr(3344 - 3233) + chr(2585 - 2485) + chr(101))(chr(0b101010 + 0o113) + '\164' + chr(102) + chr(0b101101) + '\070'))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'c\xc4\xb8\x83\x1a\x19\x93'), '\144' + chr(0b1000 + 0o135) + '\143' + '\157' + chr(0b1100100) + chr(0b1100101))('\165' + '\x74' + '\x66' + '\055' + '\x38'))(nzTpIcepk0o8(chr(0b101101 + 0o3) + '\x6f' + chr(0b110001), 8), nzTpIcepk0o8(chr(48) + '\157' + '\x33', 8), nzTpIcepk0o8('\x30' + '\x6f' + '\063', 8))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'y\xdc\xa9\x9b\x19\x01'), chr(0b1100100) + chr(0b1100101) + '\143' + chr(1815 - 1704) + '\144' + chr(0b1100101))(chr(0b1110101) + '\x74' + chr(102) + '\x2d' + chr(1730 - 1674)))(roI3spqORKae(gwheshWPFHtV, roI3spqORKae(ES5oEprVxulp(b'V\xd7\x91\xbc"\x1e\x83;\xd3\xd5X\x0b'), chr(0b100010 + 0o102) + chr(0b1100101) + chr(0b1100011) + chr(0b1100110 + 0o11) + '\x64' + chr(0b1100101))('\x75' + '\164' + chr(0b1100110) + chr(45) + chr(0b1111 + 0o51))), cmap=roI3spqORKae(Z7HGgmIyegqz.cm, roI3spqORKae(ES5oEprVxulp(b'w\xc3\xbb\x8a'), '\144' + chr(101) + '\143' + chr(5975 - 5864) + chr(0b1010111 + 0o15) + '\x65')(chr(117) + '\164' + chr(0b101001 + 0o75) + chr(286 - 241) + chr(56))))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'Z\xf5\xe3\xc3D\x06\x912\xff\xddDX'), chr(1989 - 1889) + '\145' + chr(998 - 899) + '\x6f' + chr(0b1100100) + '\145')('\165' + chr(5494 - 5378) + '\146' + chr(0b101101) + '\x38'))(roI3spqORKae(ES5oEprVxulp(b'\x7f\xd7\xbc'), chr(0b1100100) + '\145' + chr(0b111001 + 0o52) + chr(0b10110 + 0o131) + chr(0b100111 + 0o75) + chr(0b1001110 + 0o27))(chr(0b100001 + 0o124) + '\164' + chr(102) + chr(45) + chr(0b111000)))
roI3spqORKae(Z7HGgmIyegqz, roI3spqORKae(ES5oEprVxulp(b'v\xe6\x9f\x9e\x13>\xb0?\xe3\xce@\x13'), chr(100) + '\145' + chr(0b1100011) + chr(0b1110 + 0o141) + '\x64' + '\x65')(chr(0b1001110 + 0o47) + '\164' + chr(8064 - 7962) + '\x2d' + chr(2146 - 2090)))()
if csdvCkQKmmw_ == nzTpIcepk0o8(chr(0b1110 + 0o42) + chr(0b11111 + 0o120) + chr(2159 - 2110), 8):
NXKO43o5_urM = nDF4gVNx0u9Q.JE1frtxECu3x(gwheshWPFHtV.nonzero_pixels(), axis=nzTpIcepk0o8(chr(48) + '\x6f' + '\x30', 8))
cjIqqAi052T8 = NXKO43o5_urM[nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(48), 8)]
FnDTpkEWgcm7 = NXKO43o5_urM[nzTpIcepk0o8(chr(0b1101 + 0o43) + chr(2204 - 2093) + chr(0b100100 + 0o15), 8)]
flutRBqQMHUR = gwheshWPFHtV.crop(YuPAjcYJvauC, Hs02AGBacRK5, cjIqqAi052T8, FnDTpkEWgcm7)
WwizskcCQveS = GFVgEmwvG0jZ.crop(YuPAjcYJvauC, Hs02AGBacRK5, cjIqqAi052T8, FnDTpkEWgcm7)
emtSjD_A2mpW = WZcCXRnThfxU.crop(YuPAjcYJvauC, Hs02AGBacRK5, cjIqqAi052T8, FnDTpkEWgcm7)
VGfJf3mobI8j = wgYNRnQWtrEG
if wgYNRnQWtrEG is not None:
VGfJf3mobI8j = wgYNRnQWtrEG.crop(YuPAjcYJvauC, Hs02AGBacRK5, cjIqqAi052T8, FnDTpkEWgcm7)
HBZNN67ZsopZ = HNLGzjvLh2Ac(NXKO43o5_urM - PZDpO5KEjEvJ, NXKO43o5_urM + PZDpO5KEjEvJ)
return [c8ZY0Gppk1hk(WwizskcCQveS, emtSjD_A2mpW, HBZNN67ZsopZ, binary_thumbnail=flutRBqQMHUR, contour=None, camera_intr=VGfJf3mobI8j)]
Ddqq_KJiUyMj = []
for (ZlbFMSG8gCoF, AyBXIsYKwGw5) in _kV_Bomx8PZ4(aMtoOZWkl57Y):
uSlYF47QxLy8 = AyBXIsYKwGw5.bounding_box
roI3spqORKae(Lj4gcNafqrcl, roI3spqORKae(ES5oEprVxulp(b'w\xf0\xe3\xa9O\x12\x88}\xe9\xfcI3'), '\x64' + chr(101) + chr(0b1100011) + chr(0b111010 + 0o65) + '\144' + chr(2394 - 2293))('\x75' + '\164' + chr(4885 - 4783) + '\055' + '\070'))(roI3spqORKae(ES5oEprVxulp(b'_\xc3\xb3\x94V\x14\x883\x9c\xb4hI\xf8\xc6\x18\xef\xe3\x90U\xfe\xc2\xe2'), '\144' + chr(8492 - 8391) + chr(2278 - 2179) + chr(111) + chr(0b1100100) + '\x65')('\x75' + chr(0b1100001 + 0o23) + chr(0b1100110) + chr(1849 - 1804) + chr(784 - 728)) % (ZlbFMSG8gCoF, roI3spqORKae(uSlYF47QxLy8, roI3spqORKae(ES5oEprVxulp(b'q\xc3\xbf\x92'), chr(0b1100100) + chr(101) + chr(0b1100011) + '\x6f' + chr(0b110011 + 0o61) + '\x65')(chr(8380 - 8263) + '\x74' + '\146' + '\055' + chr(0b111000)))))
if roI3spqORKae(uSlYF47QxLy8, roI3spqORKae(ES5oEprVxulp(b'q\xc3\xbf\x92'), '\x64' + chr(0b1100101) + chr(0b1100011) + chr(7570 - 7459) + chr(0b1010100 + 0o20) + chr(0b110 + 0o137))(chr(0b1110101) + chr(6220 - 6104) + chr(2674 - 2572) + '\x2d' + chr(0b111000))) > DfWZja9636Ja and roI3spqORKae(uSlYF47QxLy8, roI3spqORKae(ES5oEprVxulp(b'q\xc3\xbf\x92'), chr(220 - 120) + chr(101) + chr(0b111001 + 0o52) + chr(111) + '\144' + '\145')(chr(2630 - 2513) + chr(0b1110100) + chr(4170 - 4068) + chr(0b1110 + 0o37) + chr(0b110 + 0o62))) < eEDlUBCIHhca:
QJ0saKUYCD3i = uSlYF47QxLy8.YAVVfOMUvAIv - PZDpO5KEjEvJ
Q7qV0_yoaaZl = uSlYF47QxLy8.YAVVfOMUvAIv + PZDpO5KEjEvJ
HBZNN67ZsopZ = HNLGzjvLh2Ac(QJ0saKUYCD3i, Q7qV0_yoaaZl, frame=uSlYF47QxLy8.KZ4ew2qs1HTO)
kHmI44zTB5n3 = gwheshWPFHtV.contour_mask(AyBXIsYKwGw5)
flutRBqQMHUR = kHmI44zTB5n3.crop(HBZNN67ZsopZ.PaEBmun9J0YJ, HBZNN67ZsopZ.dH3vcKdvgBu0, HBZNN67ZsopZ.ci, HBZNN67ZsopZ.cj)
else:
HBZNN67ZsopZ = HNLGzjvLh2Ac(AyBXIsYKwGw5.bounding_box.min_pt - anDmN0aUxLk8, AyBXIsYKwGw5.bounding_box.max_pt + anDmN0aUxLk8, frame=AyBXIsYKwGw5.bounding_box.KZ4ew2qs1HTO)
flutRBqQMHUR = gwheshWPFHtV.crop(HBZNN67ZsopZ.PaEBmun9J0YJ, HBZNN67ZsopZ.dH3vcKdvgBu0, HBZNN67ZsopZ.ci, HBZNN67ZsopZ.cj)
WwizskcCQveS = GFVgEmwvG0jZ.crop(HBZNN67ZsopZ.PaEBmun9J0YJ, HBZNN67ZsopZ.dH3vcKdvgBu0, HBZNN67ZsopZ.ci, HBZNN67ZsopZ.cj)
emtSjD_A2mpW = WZcCXRnThfxU.crop(HBZNN67ZsopZ.PaEBmun9J0YJ, HBZNN67ZsopZ.dH3vcKdvgBu0, HBZNN67ZsopZ.ci, HBZNN67ZsopZ.cj)
VGfJf3mobI8j = wgYNRnQWtrEG
if wgYNRnQWtrEG is not None:
VGfJf3mobI8j = wgYNRnQWtrEG.crop(HBZNN67ZsopZ.PaEBmun9J0YJ, HBZNN67ZsopZ.dH3vcKdvgBu0, HBZNN67ZsopZ.ci, HBZNN67ZsopZ.cj)
emtSjD_A2mpW = emtSjD_A2mpW.replace_zeros(OtBA5JjCoiah)
if guL_bclejJPl:
gTJczuG2gUhu = emtSjD_A2mpW.FfKOThdpoDTb
Tkf2if82cAyR = nDF4gVNx0u9Q.XURpmPuEWCNF(gTJczuG2gUhu)
C4Petspod8Dj = flutRBqQMHUR.FfKOThdpoDTb
YUSI8cEnlWHT = emtSjD_A2mpW.mask_binary(flutRBqQMHUR).FfKOThdpoDTb
YUSI8cEnlWHT += OFJwdIkSxBR5
gTJczuG2gUhu[C4Petspod8Dj > nzTpIcepk0o8('\x30' + '\157' + chr(1013 - 965), 8)] = YUSI8cEnlWHT[C4Petspod8Dj > nzTpIcepk0o8('\060' + chr(0b1101111) + chr(48), 8)]
emtSjD_A2mpW = Ctd7ihpXT1E5(gTJczuG2gUhu, emtSjD_A2mpW.KZ4ew2qs1HTO)
roI3spqORKae(Ddqq_KJiUyMj, roI3spqORKae(ES5oEprVxulp(b'X\xe5\x89\xc7\x0e\x11\xa0$\xd6\xfeY\\'), '\144' + chr(0b1100101) + chr(0b111100 + 0o47) + chr(111) + '\x64' + chr(0b1100101))('\165' + '\164' + chr(0b1100110) + chr(45) + chr(211 - 155)))(c8ZY0Gppk1hk(WwizskcCQveS, emtSjD_A2mpW, HBZNN67ZsopZ, binary_thumbnail=flutRBqQMHUR, contour=AyBXIsYKwGw5, camera_intr=VGfJf3mobI8j))
return Ddqq_KJiUyMj |
BerkeleyAutomation/perception | perception/detector.py | RgbdDetectorFactory.detector | def detector(detector_type):
""" Returns a detector of the specified type. """
if detector_type == 'point_cloud_box':
return PointCloudBoxDetector()
elif detector_type == 'rgbd_foreground_mask_query':
return RgbdForegroundMaskQueryImageDetector()
elif detector_type == 'rgbd_foreground_mask':
return RgbdForegroundMaskDetector()
raise ValueError('Detector type %s not understood' %(detector_type)) | python | def detector(detector_type):
""" Returns a detector of the specified type. """
if detector_type == 'point_cloud_box':
return PointCloudBoxDetector()
elif detector_type == 'rgbd_foreground_mask_query':
return RgbdForegroundMaskQueryImageDetector()
elif detector_type == 'rgbd_foreground_mask':
return RgbdForegroundMaskDetector()
raise ValueError('Detector type %s not understood' %(detector_type)) | [
"def",
"detector",
"(",
"detector_type",
")",
":",
"if",
"detector_type",
"==",
"'point_cloud_box'",
":",
"return",
"PointCloudBoxDetector",
"(",
")",
"elif",
"detector_type",
"==",
"'rgbd_foreground_mask_query'",
":",
"return",
"RgbdForegroundMaskQueryImageDetector",
"(",
")",
"elif",
"detector_type",
"==",
"'rgbd_foreground_mask'",
":",
"return",
"RgbdForegroundMaskDetector",
"(",
")",
"raise",
"ValueError",
"(",
"'Detector type %s not understood'",
"%",
"(",
"detector_type",
")",
")"
] | Returns a detector of the specified type. | [
"Returns",
"a",
"detector",
"of",
"the",
"specified",
"type",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/detector.py#L604-L612 | train | Returns a detector of the specified type. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07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NtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(0b100101 + 0o112) + chr(1777 - 1726) + '\061' + '\x30', ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(49) + chr(52) + chr(51), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(49) + chr(0b110110) + chr(50), 55499 - 55491), nzTpIcepk0o8('\x30' + '\157' + '\x32' + chr(0b11010 + 0o32) + '\064', ord("\x08")), nzTpIcepk0o8('\060' + '\157' + '\x33' + '\060' + chr(1782 - 1728), 0o10), nzTpIcepk0o8(chr(587 - 539) + chr(948 - 837) + chr(0b110010) + chr(0b110011) + chr(55), 0b1000), nzTpIcepk0o8(chr(0b101111 + 0o1) + '\157' + '\x32' + chr(52), 0b1000), nzTpIcepk0o8(chr(0b10110 + 0o32) + '\x6f' + chr(0b11110 + 0o24) + chr(49) + chr(52), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + '\061' + chr(1822 - 1767) + chr(0b101010 + 0o6), 59229 - 59221), nzTpIcepk0o8('\060' + '\157' + '\064' + chr(1152 - 1103), 54970 - 54962), nzTpIcepk0o8('\x30' + chr(111) + chr(0b101111 + 0o3) + chr(49) + chr(0b110000), 0o10), nzTpIcepk0o8(chr(0b11 + 0o55) + chr(0b1101111) + chr(49) + '\x31' + '\066', 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(55) + chr(0b110100 + 0o2), 0o10), nzTpIcepk0o8('\060' + chr(111) + chr(1880 - 1829) + chr(54) + chr(250 - 196), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b110010) + chr(2122 - 2072) + chr(49), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b101110 + 0o101) + chr(0b1110 + 0o46) + '\x34', 61320 - 61312), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(2579 - 2526) + '\x32', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(1849 - 1738) + '\063' + '\x36' + '\x36', 8), nzTpIcepk0o8(chr(573 - 525) + '\x6f' + '\063' + chr(0b10 + 0o65), 0o10), nzTpIcepk0o8('\060' + chr(111) + chr(1392 - 1341) + '\x33' + '\x35', 60856 - 60848), nzTpIcepk0o8('\x30' + chr(8334 - 8223) + chr(49) + chr(54), 0b1000), nzTpIcepk0o8(chr(1901 - 1853) + chr(111) + chr(0b11011 + 0o27) + chr(0b110000) + '\062', 0b1000), nzTpIcepk0o8(chr(332 - 284) + '\157' + chr(699 - 649) + chr(0b110010) + '\065', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x32' + chr(381 - 331) + chr(51), 0b1000), nzTpIcepk0o8('\060' + chr(0b11 + 0o154) + chr(0b110011) + chr(0b100001 + 0o26) + chr(0b110011), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b110100 + 0o73) + '\x31' + chr(0b110001 + 0o5) + chr(0b10110 + 0o40), 63540 - 63532), nzTpIcepk0o8(chr(1773 - 1725) + '\x6f' + chr(49) + chr(0b110001) + chr(0b110001), 0b1000), nzTpIcepk0o8('\x30' + chr(2562 - 2451) + chr(54) + '\x35', 0o10), nzTpIcepk0o8(chr(2265 - 2217) + chr(0b101001 + 0o106) + '\x33' + chr(1151 - 1098) + chr(48), 49716 - 49708), nzTpIcepk0o8('\x30' + chr(0b100101 + 0o112) + '\x32' + '\x36' + chr(1882 - 1833), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x32' + chr(0b110111) + chr(0b100101 + 0o15), 0o10), nzTpIcepk0o8('\060' + chr(0b10111 + 0o130) + '\x31' + '\062', 0b1000), nzTpIcepk0o8('\060' + chr(628 - 517) + chr(51) + chr(54), 31837 - 31829), nzTpIcepk0o8('\x30' + chr(1367 - 1256) + '\061' + chr(1815 - 1763) + chr(295 - 242), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + '\062' + '\063' + chr(48), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\061' + chr(49) + chr(1211 - 1160), 0b1000), nzTpIcepk0o8(chr(216 - 168) + chr(0b1101111) + '\062' + '\060' + chr(0b10011 + 0o43), ord("\x08")), nzTpIcepk0o8(chr(577 - 529) + chr(2976 - 2865) + chr(50) + '\x36' + chr(0b110011), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110001) + chr(0b110111) + chr(0b110101), 0b1000), nzTpIcepk0o8(chr(48) + chr(10871 - 10760) + '\x33' + chr(52) + '\x31', 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + chr(1335 - 1224) + chr(0b10111 + 0o36) + chr(0b10110 + 0o32), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xe6'), chr(0b1011011 + 0o11) + chr(0b10101 + 0o120) + '\x63' + chr(11920 - 11809) + '\x64' + chr(101))(chr(0b101 + 0o160) + chr(1923 - 1807) + chr(102) + chr(0b101101) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def LfPiDcn9SJlW(FYQuioLMZfrB):
if FYQuioLMZfrB == roI3spqORKae(ES5oEprVxulp(b'\xb8\x0c\x1b\xca\xb2\xc0w\xe0\x17T\xec\x11\\\x99\xe9'), chr(6927 - 6827) + chr(0b1000011 + 0o42) + '\143' + chr(0b11001 + 0o126) + chr(100) + '\x65')(chr(9192 - 9075) + '\164' + chr(0b1000010 + 0o44) + '\055' + chr(873 - 817)):
return ZvWBisJg7xoA()
elif FYQuioLMZfrB == roI3spqORKae(ES5oEprVxulp(b'\xba\x04\x10\xc0\x99\xf9{\xfe\x1dF\xfa!K\x98\xf5{G\x97l\xb6Q\xf3\xe0\xf6\x89\x0f'), chr(5123 - 5023) + chr(0b1100101) + chr(0b10000 + 0o123) + chr(111) + chr(8104 - 8004) + chr(101))(chr(10703 - 10586) + '\x74' + chr(0b1100110) + chr(1137 - 1092) + chr(0b110111 + 0o1)):
return ZZh0OmImWG8R()
elif FYQuioLMZfrB == roI3spqORKae(ES5oEprVxulp(b'\xba\x04\x10\xc0\x99\xf9{\xfe\x1dF\xfa!K\x98\xf5{G\x97l\xb6'), chr(8407 - 8307) + '\x65' + chr(0b1100011) + chr(0b1101111) + chr(9482 - 9382) + chr(101))(chr(0b1110101) + chr(9614 - 9498) + chr(0b1000001 + 0o45) + chr(45) + chr(0b111000)):
return EZ6l6jIg7wNR()
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'\x8c\x06\x06\xc1\xa5\xeb{\xfeXU\xf1>[\xd6\xb4W\n\x98p\xa9.\xf7\xfb\xf7\x9e\x04:A\x87\xde\xde'), chr(5550 - 5450) + chr(7228 - 7127) + chr(0b1100011) + '\157' + '\144' + chr(9044 - 8943))(chr(1008 - 891) + chr(0b1001010 + 0o52) + chr(102) + chr(0b101101) + '\x38') % FYQuioLMZfrB) |
BerkeleyAutomation/perception | tools/capture_dataset.py | preprocess_images | def preprocess_images(raw_color_im,
raw_depth_im,
camera_intr,
T_camera_world,
workspace_box,
workspace_im,
image_proc_config):
""" Preprocess a set of color and depth images. """
# read params
inpaint_rescale_factor = image_proc_config['inpaint_rescale_factor']
cluster = image_proc_config['cluster']
cluster_tolerance = image_proc_config['cluster_tolerance']
min_cluster_size = image_proc_config['min_cluster_size']
max_cluster_size = image_proc_config['max_cluster_size']
# deproject into 3D world coordinates
point_cloud_cam = camera_intr.deproject(raw_depth_im)
point_cloud_cam.remove_zero_points()
point_cloud_world = T_camera_world * point_cloud_cam
# compute the segmask for points above the box
seg_point_cloud_world, _ = point_cloud_world.box_mask(workspace_box)
seg_point_cloud_cam = T_camera_world.inverse() * seg_point_cloud_world
depth_im_seg = camera_intr.project_to_image(seg_point_cloud_cam)
# mask out objects in the known workspace
env_pixels = depth_im_seg.pixels_farther_than(workspace_im)
depth_im_seg._data[env_pixels[:,0], env_pixels[:,1]] = 0
# REMOVE NOISE
# clip low points
low_indices = np.where(point_cloud_world.data[2,:] < workspace_box.min_pt[2])[0]
point_cloud_world.data[2,low_indices] = workspace_box.min_pt[2]
# clip high points
high_indices = np.where(point_cloud_world.data[2,:] > workspace_box.max_pt[2])[0]
point_cloud_world.data[2,high_indices] = workspace_box.max_pt[2]
# segment out the region in the workspace (including the table)
workspace_point_cloud_world, valid_indices = point_cloud_world.box_mask(workspace_box)
invalid_indices = np.setdiff1d(np.arange(point_cloud_world.num_points),
valid_indices)
if cluster:
# create new cloud
pcl_cloud = pcl.PointCloud(workspace_point_cloud_world.data.T.astype(np.float32))
tree = pcl_cloud.make_kdtree()
# find large clusters (likely to be real objects instead of noise)
ec = pcl_cloud.make_EuclideanClusterExtraction()
ec.set_ClusterTolerance(cluster_tolerance)
ec.set_MinClusterSize(min_cluster_size)
ec.set_MaxClusterSize(max_cluster_size)
ec.set_SearchMethod(tree)
cluster_indices = ec.Extract()
num_clusters = len(cluster_indices)
# read out all points in large clusters
filtered_points = np.zeros([3,workspace_point_cloud_world.num_points])
cur_i = 0
for j, indices in enumerate(cluster_indices):
num_points = len(indices)
points = np.zeros([3,num_points])
for i, index in enumerate(indices):
points[0,i] = pcl_cloud[index][0]
points[1,i] = pcl_cloud[index][1]
points[2,i] = pcl_cloud[index][2]
filtered_points[:,cur_i:cur_i+num_points] = points.copy()
cur_i = cur_i + num_points
# reconstruct the point cloud
all_points = np.c_[filtered_points[:,:cur_i], point_cloud_world.data[:,invalid_indices]]
else:
all_points = point_cloud_world.data
filtered_point_cloud_world = PointCloud(all_points,
frame='world')
# compute the filtered depth image
filtered_point_cloud_cam = T_camera_world.inverse() * filtered_point_cloud_world
depth_im = camera_intr.project_to_image(filtered_point_cloud_cam)
# form segmask
segmask = depth_im_seg.to_binary()
valid_px_segmask = depth_im.invalid_pixel_mask().inverse()
segmask = segmask.mask_binary(valid_px_segmask)
# inpaint
color_im = raw_color_im.inpaint(rescale_factor=inpaint_rescale_factor)
depth_im = depth_im.inpaint(rescale_factor=inpaint_rescale_factor)
return color_im, depth_im, segmask | python | def preprocess_images(raw_color_im,
raw_depth_im,
camera_intr,
T_camera_world,
workspace_box,
workspace_im,
image_proc_config):
""" Preprocess a set of color and depth images. """
# read params
inpaint_rescale_factor = image_proc_config['inpaint_rescale_factor']
cluster = image_proc_config['cluster']
cluster_tolerance = image_proc_config['cluster_tolerance']
min_cluster_size = image_proc_config['min_cluster_size']
max_cluster_size = image_proc_config['max_cluster_size']
# deproject into 3D world coordinates
point_cloud_cam = camera_intr.deproject(raw_depth_im)
point_cloud_cam.remove_zero_points()
point_cloud_world = T_camera_world * point_cloud_cam
# compute the segmask for points above the box
seg_point_cloud_world, _ = point_cloud_world.box_mask(workspace_box)
seg_point_cloud_cam = T_camera_world.inverse() * seg_point_cloud_world
depth_im_seg = camera_intr.project_to_image(seg_point_cloud_cam)
# mask out objects in the known workspace
env_pixels = depth_im_seg.pixels_farther_than(workspace_im)
depth_im_seg._data[env_pixels[:,0], env_pixels[:,1]] = 0
# REMOVE NOISE
# clip low points
low_indices = np.where(point_cloud_world.data[2,:] < workspace_box.min_pt[2])[0]
point_cloud_world.data[2,low_indices] = workspace_box.min_pt[2]
# clip high points
high_indices = np.where(point_cloud_world.data[2,:] > workspace_box.max_pt[2])[0]
point_cloud_world.data[2,high_indices] = workspace_box.max_pt[2]
# segment out the region in the workspace (including the table)
workspace_point_cloud_world, valid_indices = point_cloud_world.box_mask(workspace_box)
invalid_indices = np.setdiff1d(np.arange(point_cloud_world.num_points),
valid_indices)
if cluster:
# create new cloud
pcl_cloud = pcl.PointCloud(workspace_point_cloud_world.data.T.astype(np.float32))
tree = pcl_cloud.make_kdtree()
# find large clusters (likely to be real objects instead of noise)
ec = pcl_cloud.make_EuclideanClusterExtraction()
ec.set_ClusterTolerance(cluster_tolerance)
ec.set_MinClusterSize(min_cluster_size)
ec.set_MaxClusterSize(max_cluster_size)
ec.set_SearchMethod(tree)
cluster_indices = ec.Extract()
num_clusters = len(cluster_indices)
# read out all points in large clusters
filtered_points = np.zeros([3,workspace_point_cloud_world.num_points])
cur_i = 0
for j, indices in enumerate(cluster_indices):
num_points = len(indices)
points = np.zeros([3,num_points])
for i, index in enumerate(indices):
points[0,i] = pcl_cloud[index][0]
points[1,i] = pcl_cloud[index][1]
points[2,i] = pcl_cloud[index][2]
filtered_points[:,cur_i:cur_i+num_points] = points.copy()
cur_i = cur_i + num_points
# reconstruct the point cloud
all_points = np.c_[filtered_points[:,:cur_i], point_cloud_world.data[:,invalid_indices]]
else:
all_points = point_cloud_world.data
filtered_point_cloud_world = PointCloud(all_points,
frame='world')
# compute the filtered depth image
filtered_point_cloud_cam = T_camera_world.inverse() * filtered_point_cloud_world
depth_im = camera_intr.project_to_image(filtered_point_cloud_cam)
# form segmask
segmask = depth_im_seg.to_binary()
valid_px_segmask = depth_im.invalid_pixel_mask().inverse()
segmask = segmask.mask_binary(valid_px_segmask)
# inpaint
color_im = raw_color_im.inpaint(rescale_factor=inpaint_rescale_factor)
depth_im = depth_im.inpaint(rescale_factor=inpaint_rescale_factor)
return color_im, depth_im, segmask | [
"def",
"preprocess_images",
"(",
"raw_color_im",
",",
"raw_depth_im",
",",
"camera_intr",
",",
"T_camera_world",
",",
"workspace_box",
",",
"workspace_im",
",",
"image_proc_config",
")",
":",
"# read params",
"inpaint_rescale_factor",
"=",
"image_proc_config",
"[",
"'inpaint_rescale_factor'",
"]",
"cluster",
"=",
"image_proc_config",
"[",
"'cluster'",
"]",
"cluster_tolerance",
"=",
"image_proc_config",
"[",
"'cluster_tolerance'",
"]",
"min_cluster_size",
"=",
"image_proc_config",
"[",
"'min_cluster_size'",
"]",
"max_cluster_size",
"=",
"image_proc_config",
"[",
"'max_cluster_size'",
"]",
"# deproject into 3D world coordinates",
"point_cloud_cam",
"=",
"camera_intr",
".",
"deproject",
"(",
"raw_depth_im",
")",
"point_cloud_cam",
".",
"remove_zero_points",
"(",
")",
"point_cloud_world",
"=",
"T_camera_world",
"*",
"point_cloud_cam",
"# compute the segmask for points above the box",
"seg_point_cloud_world",
",",
"_",
"=",
"point_cloud_world",
".",
"box_mask",
"(",
"workspace_box",
")",
"seg_point_cloud_cam",
"=",
"T_camera_world",
".",
"inverse",
"(",
")",
"*",
"seg_point_cloud_world",
"depth_im_seg",
"=",
"camera_intr",
".",
"project_to_image",
"(",
"seg_point_cloud_cam",
")",
"# mask out objects in the known workspace",
"env_pixels",
"=",
"depth_im_seg",
".",
"pixels_farther_than",
"(",
"workspace_im",
")",
"depth_im_seg",
".",
"_data",
"[",
"env_pixels",
"[",
":",
",",
"0",
"]",
",",
"env_pixels",
"[",
":",
",",
"1",
"]",
"]",
"=",
"0",
"# REMOVE NOISE",
"# clip low points",
"low_indices",
"=",
"np",
".",
"where",
"(",
"point_cloud_world",
".",
"data",
"[",
"2",
",",
":",
"]",
"<",
"workspace_box",
".",
"min_pt",
"[",
"2",
"]",
")",
"[",
"0",
"]",
"point_cloud_world",
".",
"data",
"[",
"2",
",",
"low_indices",
"]",
"=",
"workspace_box",
".",
"min_pt",
"[",
"2",
"]",
"# clip high points",
"high_indices",
"=",
"np",
".",
"where",
"(",
"point_cloud_world",
".",
"data",
"[",
"2",
",",
":",
"]",
">",
"workspace_box",
".",
"max_pt",
"[",
"2",
"]",
")",
"[",
"0",
"]",
"point_cloud_world",
".",
"data",
"[",
"2",
",",
"high_indices",
"]",
"=",
"workspace_box",
".",
"max_pt",
"[",
"2",
"]",
"# segment out the region in the workspace (including the table)",
"workspace_point_cloud_world",
",",
"valid_indices",
"=",
"point_cloud_world",
".",
"box_mask",
"(",
"workspace_box",
")",
"invalid_indices",
"=",
"np",
".",
"setdiff1d",
"(",
"np",
".",
"arange",
"(",
"point_cloud_world",
".",
"num_points",
")",
",",
"valid_indices",
")",
"if",
"cluster",
":",
"# create new cloud",
"pcl_cloud",
"=",
"pcl",
".",
"PointCloud",
"(",
"workspace_point_cloud_world",
".",
"data",
".",
"T",
".",
"astype",
"(",
"np",
".",
"float32",
")",
")",
"tree",
"=",
"pcl_cloud",
".",
"make_kdtree",
"(",
")",
"# find large clusters (likely to be real objects instead of noise)",
"ec",
"=",
"pcl_cloud",
".",
"make_EuclideanClusterExtraction",
"(",
")",
"ec",
".",
"set_ClusterTolerance",
"(",
"cluster_tolerance",
")",
"ec",
".",
"set_MinClusterSize",
"(",
"min_cluster_size",
")",
"ec",
".",
"set_MaxClusterSize",
"(",
"max_cluster_size",
")",
"ec",
".",
"set_SearchMethod",
"(",
"tree",
")",
"cluster_indices",
"=",
"ec",
".",
"Extract",
"(",
")",
"num_clusters",
"=",
"len",
"(",
"cluster_indices",
")",
"# read out all points in large clusters",
"filtered_points",
"=",
"np",
".",
"zeros",
"(",
"[",
"3",
",",
"workspace_point_cloud_world",
".",
"num_points",
"]",
")",
"cur_i",
"=",
"0",
"for",
"j",
",",
"indices",
"in",
"enumerate",
"(",
"cluster_indices",
")",
":",
"num_points",
"=",
"len",
"(",
"indices",
")",
"points",
"=",
"np",
".",
"zeros",
"(",
"[",
"3",
",",
"num_points",
"]",
")",
"for",
"i",
",",
"index",
"in",
"enumerate",
"(",
"indices",
")",
":",
"points",
"[",
"0",
",",
"i",
"]",
"=",
"pcl_cloud",
"[",
"index",
"]",
"[",
"0",
"]",
"points",
"[",
"1",
",",
"i",
"]",
"=",
"pcl_cloud",
"[",
"index",
"]",
"[",
"1",
"]",
"points",
"[",
"2",
",",
"i",
"]",
"=",
"pcl_cloud",
"[",
"index",
"]",
"[",
"2",
"]",
"filtered_points",
"[",
":",
",",
"cur_i",
":",
"cur_i",
"+",
"num_points",
"]",
"=",
"points",
".",
"copy",
"(",
")",
"cur_i",
"=",
"cur_i",
"+",
"num_points",
"# reconstruct the point cloud",
"all_points",
"=",
"np",
".",
"c_",
"[",
"filtered_points",
"[",
":",
",",
":",
"cur_i",
"]",
",",
"point_cloud_world",
".",
"data",
"[",
":",
",",
"invalid_indices",
"]",
"]",
"else",
":",
"all_points",
"=",
"point_cloud_world",
".",
"data",
"filtered_point_cloud_world",
"=",
"PointCloud",
"(",
"all_points",
",",
"frame",
"=",
"'world'",
")",
"# compute the filtered depth image",
"filtered_point_cloud_cam",
"=",
"T_camera_world",
".",
"inverse",
"(",
")",
"*",
"filtered_point_cloud_world",
"depth_im",
"=",
"camera_intr",
".",
"project_to_image",
"(",
"filtered_point_cloud_cam",
")",
"# form segmask",
"segmask",
"=",
"depth_im_seg",
".",
"to_binary",
"(",
")",
"valid_px_segmask",
"=",
"depth_im",
".",
"invalid_pixel_mask",
"(",
")",
".",
"inverse",
"(",
")",
"segmask",
"=",
"segmask",
".",
"mask_binary",
"(",
"valid_px_segmask",
")",
"# inpaint",
"color_im",
"=",
"raw_color_im",
".",
"inpaint",
"(",
"rescale_factor",
"=",
"inpaint_rescale_factor",
")",
"depth_im",
"=",
"depth_im",
".",
"inpaint",
"(",
"rescale_factor",
"=",
"inpaint_rescale_factor",
")",
"return",
"color_im",
",",
"depth_im",
",",
"segmask"
] | Preprocess a set of color and depth images. | [
"Preprocess",
"a",
"set",
"of",
"color",
"and",
"depth",
"images",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/tools/capture_dataset.py#L31-L122 | train | Preprocess a set of color and depth images. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOVzf,YikXQdxs3VoO,UBvEeZympYSz,mRTjFWUmjlQA,QhZRiM1qvaW7,WbNHlDKp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XoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\062' + chr(1920 - 1871) + chr(890 - 842), 0b1000), nzTpIcepk0o8('\060' + chr(0b1001011 + 0o44) + chr(55) + chr(52), 0b1000), nzTpIcepk0o8(chr(48) + chr(7225 - 7114) + '\x33' + '\063' + chr(1176 - 1124), 0b1000), nzTpIcepk0o8(chr(0b11 + 0o55) + chr(10607 - 10496) + '\x33' + '\x31' + chr(0b110110), ord("\x08")), nzTpIcepk0o8('\x30' + chr(11519 - 11408) + chr(53) + '\064', 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(1824 - 1775) + chr(50) + chr(0b1101 + 0o51), 42624 - 42616), nzTpIcepk0o8(chr(2103 - 2055) + chr(0b1101111) + chr(0b110011) + '\067' + chr(696 - 641), 24718 - 24710), nzTpIcepk0o8('\x30' + chr(111) + chr(751 - 698) + chr(49), 0b1000), nzTpIcepk0o8(chr(1327 - 1279) + chr(6881 - 6770) + chr(251 - 202) + chr(49) + '\x31', 51031 - 51023), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(0b1001100 + 0o43) + '\064' + '\060', 6761 - 6753), nzTpIcepk0o8(chr(0b10110 + 0o32) + chr(0b110110 + 0o71) + '\x33' + '\062' + '\x32', 0b1000), nzTpIcepk0o8(chr(0b11111 + 0o21) + chr(9626 - 9515) + chr(553 - 502) + '\x30', 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(53) + '\060', 0o10), nzTpIcepk0o8(chr(0b1000 + 0o50) + chr(0b1011101 + 0o22) + chr(50) + chr(1329 - 1281) + chr(0b110000 + 0o3), 63340 - 63332), nzTpIcepk0o8(chr(48) + chr(8363 - 8252) + chr(50) + chr(739 - 686) + chr(0b110110), 0o10), nzTpIcepk0o8(chr(462 - 414) + '\x6f' + chr(2591 - 2540) + chr(0b110110) + chr(52), 34652 - 34644), nzTpIcepk0o8(chr(1920 - 1872) + '\157' + '\x36' + chr(52), 0o10), nzTpIcepk0o8(chr(0b0 + 0o60) + '\157' + '\x31' + chr(1599 - 1550) + '\063', ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + '\065' + '\067', 37848 - 37840), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110011) + chr(0b0 + 0o62) + '\x37', ord("\x08")), nzTpIcepk0o8(chr(0b10111 + 0o31) + '\157' + chr(2190 - 2139) + '\064' + '\x36', ord("\x08")), nzTpIcepk0o8(chr(1522 - 1474) + chr(111) + chr(0b10000 + 0o42), ord("\x08")), nzTpIcepk0o8(chr(0b11000 + 0o30) + '\157' + chr(50) + '\x35' + chr(0b11010 + 0o33), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110011) + '\060' + chr(0b110001), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(50) + '\062' + '\x36', 0b1000), nzTpIcepk0o8('\060' + chr(111) + '\x31' + '\063' + chr(0b100111 + 0o20), 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x31' + chr(0b100101 + 0o21) + chr(0b110001), 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(0b10000 + 0o44) + chr(55), 0o10), nzTpIcepk0o8(chr(1426 - 1378) + chr(0b1000100 + 0o53) + chr(1855 - 1805) + chr(55) + chr(1951 - 1903), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x33' + '\066' + chr(1528 - 1475), 6195 - 6187), nzTpIcepk0o8('\060' + chr(0b110001 + 0o76) + '\066' + chr(0b100000 + 0o26), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1000000 + 0o57) + '\x34', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110011) + chr(0b110100) + chr(425 - 375), 40595 - 40587), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(2783 - 2729), 0b1000), nzTpIcepk0o8(chr(0b111 + 0o51) + '\157' + chr(50) + chr(0b11101 + 0o31) + chr(2570 - 2517), 0b1000), nzTpIcepk0o8(chr(1522 - 1474) + chr(0b1101111) + chr(0b0 + 0o64) + chr(52), 0o10), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(111) + '\x31' + '\062' + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + '\065' + '\x30', 8), nzTpIcepk0o8(chr(0b110000) + chr(11739 - 11628) + '\064' + chr(0b10101 + 0o42), 8), nzTpIcepk0o8(chr(48) + chr(0b1101010 + 0o5) + chr(0b110001), 30353 - 30345)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(2076 - 2028) + chr(1976 - 1865) + '\x35' + chr(0b11100 + 0o24), 8)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xa6'), chr(100) + chr(5574 - 5473) + '\x63' + '\157' + '\x64' + chr(462 - 361))('\x75' + chr(0b111110 + 0o66) + chr(0b1100110) + chr(681 - 636) + chr(0b111000)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def KgSbv2Q8tbZN(pfLqyL7aNgbj, YNHGV_Ivkpru, wgYNRnQWtrEG, bml1vBwpIyzY, RymZWrkwURvx, gT0hBP73o2K6, jv2WwD2pjOhk):
OiuVUdCHfY19 = jv2WwD2pjOhk[roI3spqORKae(ES5oEprVxulp(b'\xe1R\xac\xafE8\x8bv;E\xa1{I\xef\xcb\xabR*L\xa3\x89p'), chr(514 - 414) + '\x65' + chr(0b1000100 + 0o37) + chr(111) + '\x64' + chr(0b1100101))('\165' + chr(0b0 + 0o164) + '\146' + chr(0b101101) + chr(1751 - 1695))]
D_e7l2vRgfcr = jv2WwD2pjOhk[roI3spqORKae(ES5oEprVxulp(b'\xebP\xa9\xbdX3\x8d'), '\144' + '\x65' + '\143' + '\x6f' + chr(100) + '\145')('\165' + chr(0b1110100) + chr(0b1100110) + chr(45) + '\070')]
uHZiyB6xkHt3 = jv2WwD2pjOhk[roI3spqORKae(ES5oEprVxulp(b'\xebP\xa9\xbdX3\x8dv=O\xbe}Z\xe2\xc0\x97Q'), chr(0b1100100) + '\145' + chr(3844 - 3745) + '\157' + '\x64' + '\x65')(chr(10754 - 10637) + '\x74' + chr(0b10010 + 0o124) + '\055' + chr(0b111000))]
ZOdgWWlxzh_u = jv2WwD2pjOhk[roI3spqORKae(ES5oEprVxulp(b'\xe5U\xb2\x91O:\x8aZ=E\xa0G[\xea\xd4\x91'), '\144' + '\145' + chr(9092 - 8993) + chr(8858 - 8747) + '\144' + chr(0b1000011 + 0o42))(chr(0b1110101) + chr(116) + chr(0b1100110) + chr(45) + '\x38')]
zxP8V2azbJud = jv2WwD2pjOhk[roI3spqORKae(ES5oEprVxulp(b'\xe5]\xa4\x91O:\x8aZ=E\xa0G[\xea\xd4\x91'), chr(100) + chr(0b1100101) + '\143' + chr(0b1101111) + chr(0b10111 + 0o115) + '\145')(chr(4488 - 4371) + chr(0b1110100) + chr(0b1001011 + 0o33) + '\x2d' + chr(2780 - 2724))]
YJfaVKM5IyxF = wgYNRnQWtrEG.deproject(YNHGV_Ivkpru)
roI3spqORKae(YJfaVKM5IyxF, roI3spqORKae(ES5oEprVxulp(b'\xfaY\xb1\xa1Z3\xa0S,R\xbdGX\xec\xc7\x9a@8'), chr(7114 - 7014) + '\x65' + chr(99) + '\157' + chr(0b10 + 0o142) + '\x65')(chr(117) + chr(0b100101 + 0o117) + chr(102) + chr(0b100110 + 0o7) + chr(56)))()
RuKkV4e0zClz = bml1vBwpIyzY * YJfaVKM5IyxF
(QN7WsPFph8Mo, zIqcgNgQ9U6F) = RuKkV4e0zClz.box_mask(RymZWrkwURvx)
iDVyDu0gUSai = bml1vBwpIyzY.inverse() * QN7WsPFph8Mo
za1fVRoLfY2A = wgYNRnQWtrEG.project_to_image(iDVyDu0gUSai)
hejYXGB250z8 = za1fVRoLfY2A.pixels_farther_than(gT0hBP73o2K6)
za1fVRoLfY2A.Fb5XNYcWu0O5[hejYXGB250z8[:, nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(11109 - 10998) + chr(48), 0b1000)], hejYXGB250z8[:, nzTpIcepk0o8(chr(606 - 558) + '\x6f' + chr(49), 8)]] = nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110000), 8)
mEMPlGCeEky5 = nDF4gVNx0u9Q.xWH4M7K6Qbd3(RuKkV4e0zClz.FfKOThdpoDTb[nzTpIcepk0o8('\x30' + '\157' + chr(50), 8), :] < RymZWrkwURvx.min_pt[nzTpIcepk0o8(chr(0b1100 + 0o44) + '\157' + chr(2140 - 2090), 8)])[nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(111) + '\x30', 8)]
RuKkV4e0zClz.FfKOThdpoDTb[nzTpIcepk0o8(chr(99 - 51) + chr(0b1101111) + chr(1926 - 1876), 8), mEMPlGCeEky5] = RymZWrkwURvx.min_pt[nzTpIcepk0o8(chr(0b11111 + 0o21) + '\x6f' + chr(0b110010), 8)]
OTysKha8i9Yv = nDF4gVNx0u9Q.xWH4M7K6Qbd3(RuKkV4e0zClz.FfKOThdpoDTb[nzTpIcepk0o8(chr(0b10000 + 0o40) + chr(0b11110 + 0o121) + chr(50), 8), :] > RymZWrkwURvx.max_pt[nzTpIcepk0o8(chr(0b110000) + chr(7413 - 7302) + '\x32', 8)])[nzTpIcepk0o8(chr(0b110000) + chr(0b1101110 + 0o1) + chr(48), 8)]
RuKkV4e0zClz.FfKOThdpoDTb[nzTpIcepk0o8('\060' + '\x6f' + '\062', 8), OTysKha8i9Yv] = RymZWrkwURvx.max_pt[nzTpIcepk0o8(chr(2137 - 2089) + chr(2924 - 2813) + chr(0b100010 + 0o20), 8)]
(FZRweULfcjMM, hKmgivmMt5Bs) = RuKkV4e0zClz.box_mask(RymZWrkwURvx)
XP2guuXQWU6P = nDF4gVNx0u9Q.setdiff1d(nDF4gVNx0u9Q.chmI_GMU_sEi(RuKkV4e0zClz.num_points), hKmgivmMt5Bs)
if D_e7l2vRgfcr:
QZwY3qkRMxtG = D7zNXhoV6JPl.PointCloud(FZRweULfcjMM.data.T.xqAChpcBkssb(nDF4gVNx0u9Q.float32))
BEwy6Gm_1uLr = QZwY3qkRMxtG.make_kdtree()
PuClr07Ni98U = QZwY3qkRMxtG.make_EuclideanClusterExtraction()
roI3spqORKae(PuClr07Ni98U, roI3spqORKae(ES5oEprVxulp(b'\xfbY\xa8\x91o:\x8aZ=E\xa0LG\xef\xcb\x86U%L\xb2'), chr(100) + '\145' + '\x63' + chr(0b1101111) + chr(9554 - 9454) + '\145')(chr(8092 - 7975) + '\164' + chr(0b1100000 + 0o6) + chr(182 - 137) + chr(0b111000)))(uHZiyB6xkHt3)
roI3spqORKae(PuClr07Ni98U, roI3spqORKae(ES5oEprVxulp(b'\xfbY\xa8\x91a?\x91j%U\xa1lM\xf1\xfd\x9dN.'), chr(0b1000001 + 0o43) + '\x65' + chr(0b1100011) + '\x6f' + chr(267 - 167) + '\x65')(chr(0b101001 + 0o114) + chr(0b111110 + 0o66) + chr(2677 - 2575) + chr(0b101101) + chr(0b100000 + 0o30)))(ZOdgWWlxzh_u)
roI3spqORKae(PuClr07Ni98U, roI3spqORKae(ES5oEprVxulp(b'\xfbY\xa8\x91a7\x87j%U\xa1lM\xf1\xfd\x9dN.'), '\144' + '\x65' + chr(99) + '\157' + chr(9378 - 9278) + '\145')('\x75' + chr(0b1110100) + '\146' + chr(105 - 60) + chr(0b111000)))(zxP8V2azbJud)
roI3spqORKae(PuClr07Ni98U, roI3spqORKae(ES5oEprVxulp(b'\xfbY\xa8\x91\x7f3\x9e[*H\x9f}\\\xeb\xc1\x90'), '\144' + chr(101) + chr(99) + chr(0b1101111) + '\x64' + '\x65')(chr(0b110111 + 0o76) + chr(116) + chr(0b1100110) + chr(1615 - 1570) + '\070'))(BEwy6Gm_1uLr)
IuIbgN3idY37 = PuClr07Ni98U.Extract()
ROuj5im8rk0O = ftfygxgFas5X(IuIbgN3idY37)
iZIFec5bumwm = nDF4gVNx0u9Q.UmwwEp7MzR6q([nzTpIcepk0o8(chr(71 - 23) + '\157' + '\063', 0o10), FZRweULfcjMM.num_points])
IJzIxjdioQFG = nzTpIcepk0o8(chr(0b110000) + chr(2059 - 1948) + chr(0b110000), 8)
for (sChW4gUsXrIC, eQBPfEuGz7C1) in _kV_Bomx8PZ4(IuIbgN3idY37):
YK_NPawMwgsX = ftfygxgFas5X(eQBPfEuGz7C1)
OI0pF0di2U3u = nDF4gVNx0u9Q.UmwwEp7MzR6q([nzTpIcepk0o8('\x30' + chr(11582 - 11471) + chr(51), 8), YK_NPawMwgsX])
for (ZlbFMSG8gCoF, ZpfN5tSLaZze) in _kV_Bomx8PZ4(eQBPfEuGz7C1):
OI0pF0di2U3u[nzTpIcepk0o8('\060' + chr(10325 - 10214) + '\x30', 8), ZlbFMSG8gCoF] = QZwY3qkRMxtG[ZpfN5tSLaZze][nzTpIcepk0o8('\060' + chr(4500 - 4389) + chr(561 - 513), 8)]
OI0pF0di2U3u[nzTpIcepk0o8(chr(48) + '\x6f' + chr(49), 8), ZlbFMSG8gCoF] = QZwY3qkRMxtG[ZpfN5tSLaZze][nzTpIcepk0o8('\060' + '\x6f' + chr(1183 - 1134), 8)]
OI0pF0di2U3u[nzTpIcepk0o8(chr(48) + '\x6f' + '\x32', 8), ZlbFMSG8gCoF] = QZwY3qkRMxtG[ZpfN5tSLaZze][nzTpIcepk0o8(chr(1356 - 1308) + '\157' + chr(50), 8)]
iZIFec5bumwm[:, IJzIxjdioQFG:IJzIxjdioQFG + YK_NPawMwgsX] = OI0pF0di2U3u.copy()
IJzIxjdioQFG = IJzIxjdioQFG + YK_NPawMwgsX
mbzK84D1vDYG = nDF4gVNx0u9Q.c_[iZIFec5bumwm[:, :IJzIxjdioQFG], RuKkV4e0zClz.FfKOThdpoDTb[:, XP2guuXQWU6P]]
else:
mbzK84D1vDYG = RuKkV4e0zClz.FfKOThdpoDTb
yjjyunVWJ4kH = CxSsxwk8McAE(mbzK84D1vDYG, frame=roI3spqORKae(ES5oEprVxulp(b'\xffS\xae\xa2H'), chr(100) + chr(0b1010110 + 0o17) + '\143' + '\x6f' + chr(0b1010100 + 0o20) + chr(0b110010 + 0o63))(chr(0b110111 + 0o76) + chr(0b11111 + 0o125) + '\x66' + chr(0b1111 + 0o36) + '\070'))
rJr5SWbWE9OZ = bml1vBwpIyzY.inverse() * yjjyunVWJ4kH
WZcCXRnThfxU = wgYNRnQWtrEG.project_to_image(rJr5SWbWE9OZ)
uGhmBzyWgv_A = za1fVRoLfY2A.to_binary()
Ftes6H6uA9VC = WZcCXRnThfxU.invalid_pixel_mask().inverse()
uGhmBzyWgv_A = uGhmBzyWgv_A.mask_binary(Ftes6H6uA9VC)
GFVgEmwvG0jZ = pfLqyL7aNgbj.inpaint(rescale_factor=OiuVUdCHfY19)
WZcCXRnThfxU = WZcCXRnThfxU.inpaint(rescale_factor=OiuVUdCHfY19)
return (GFVgEmwvG0jZ, WZcCXRnThfxU, uGhmBzyWgv_A) |
BerkeleyAutomation/perception | perception/cnn.py | conv | def conv(input, kernel, biases, k_h, k_w, c_o, s_h, s_w, padding="VALID", group=1):
"""
Convolution layer helper function
From https://github.com/ethereon/caffe-tensorflow
"""
c_i = input.get_shape()[-1]
assert c_i%group==0
assert c_o%group==0
convolve = lambda i, k: tf.nn.conv2d(i, k, [1, s_h, s_w, 1], padding=padding)
if group==1:
conv = convolve(input, kernel)
else:
input_groups = tf.split(input, group, axis=3)
kernel_groups = tf.split(kernel, group, axis=3)
output_groups = [convolve(i, k) for i,k in zip(input_groups, kernel_groups)]
conv = tf.concat(output_groups, axis=3)
return tf.reshape(tf.nn.bias_add(conv, biases), [-1]+conv.get_shape().as_list()[1:]) | python | def conv(input, kernel, biases, k_h, k_w, c_o, s_h, s_w, padding="VALID", group=1):
"""
Convolution layer helper function
From https://github.com/ethereon/caffe-tensorflow
"""
c_i = input.get_shape()[-1]
assert c_i%group==0
assert c_o%group==0
convolve = lambda i, k: tf.nn.conv2d(i, k, [1, s_h, s_w, 1], padding=padding)
if group==1:
conv = convolve(input, kernel)
else:
input_groups = tf.split(input, group, axis=3)
kernel_groups = tf.split(kernel, group, axis=3)
output_groups = [convolve(i, k) for i,k in zip(input_groups, kernel_groups)]
conv = tf.concat(output_groups, axis=3)
return tf.reshape(tf.nn.bias_add(conv, biases), [-1]+conv.get_shape().as_list()[1:]) | [
"def",
"conv",
"(",
"input",
",",
"kernel",
",",
"biases",
",",
"k_h",
",",
"k_w",
",",
"c_o",
",",
"s_h",
",",
"s_w",
",",
"padding",
"=",
"\"VALID\"",
",",
"group",
"=",
"1",
")",
":",
"c_i",
"=",
"input",
".",
"get_shape",
"(",
")",
"[",
"-",
"1",
"]",
"assert",
"c_i",
"%",
"group",
"==",
"0",
"assert",
"c_o",
"%",
"group",
"==",
"0",
"convolve",
"=",
"lambda",
"i",
",",
"k",
":",
"tf",
".",
"nn",
".",
"conv2d",
"(",
"i",
",",
"k",
",",
"[",
"1",
",",
"s_h",
",",
"s_w",
",",
"1",
"]",
",",
"padding",
"=",
"padding",
")",
"if",
"group",
"==",
"1",
":",
"conv",
"=",
"convolve",
"(",
"input",
",",
"kernel",
")",
"else",
":",
"input_groups",
"=",
"tf",
".",
"split",
"(",
"input",
",",
"group",
",",
"axis",
"=",
"3",
")",
"kernel_groups",
"=",
"tf",
".",
"split",
"(",
"kernel",
",",
"group",
",",
"axis",
"=",
"3",
")",
"output_groups",
"=",
"[",
"convolve",
"(",
"i",
",",
"k",
")",
"for",
"i",
",",
"k",
"in",
"zip",
"(",
"input_groups",
",",
"kernel_groups",
")",
"]",
"conv",
"=",
"tf",
".",
"concat",
"(",
"output_groups",
",",
"axis",
"=",
"3",
")",
"return",
"tf",
".",
"reshape",
"(",
"tf",
".",
"nn",
".",
"bias_add",
"(",
"conv",
",",
"biases",
")",
",",
"[",
"-",
"1",
"]",
"+",
"conv",
".",
"get_shape",
"(",
")",
".",
"as_list",
"(",
")",
"[",
"1",
":",
"]",
")"
] | Convolution layer helper function
From https://github.com/ethereon/caffe-tensorflow | [
"Convolution",
"layer",
"helper",
"function",
"From",
"https",
":",
"//",
"github",
".",
"com",
"/",
"ethereon",
"/",
"caffe",
"-",
"tensorflow"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/cnn.py#L14-L31 | train | Convolution layer helper function | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjV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vC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(7908 - 7797) + chr(49) + chr(0b110000), 0b1000), nzTpIcepk0o8('\060' + '\157' + '\x32' + chr(0b110001), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + chr(49) + chr(79 - 31) + '\x37', 0b1000), nzTpIcepk0o8(chr(2259 - 2211) + chr(0b1101111) + chr(363 - 312) + chr(0b100111 + 0o11) + chr(0b0 + 0o61), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(7241 - 7130) + chr(2335 - 2282), 41067 - 41059), nzTpIcepk0o8('\060' + chr(11670 - 11559) + '\x33' + chr(0b100011 + 0o23) + chr(0b1111 + 0o45), 0o10), nzTpIcepk0o8(chr(2302 - 2254) + chr(6759 - 6648) + '\062' + chr(0b110101) + '\062', 0o10), nzTpIcepk0o8(chr(48) + chr(1289 - 1178) + chr(50) + chr(0b110010) + chr(1448 - 1397), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b11100 + 0o123) + chr(0b100011 + 0o20) + chr(0b11110 + 0o30) + chr(0b110100), 8), nzTpIcepk0o8('\x30' + '\157' + chr(0b1001 + 0o50) + chr(53) + chr(0b110100), ord("\x08")), nzTpIcepk0o8(chr(0b101 + 0o53) + '\157' + chr(0b1000 + 0o52) + chr(1482 - 1432), 47732 - 47724), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110010) + '\x36' + chr(0b110110 + 0o1), ord("\x08")), nzTpIcepk0o8(chr(1912 - 1864) + chr(0b1110 + 0o141) + chr(0b110011) + '\x36' + '\066', 45327 - 45319), nzTpIcepk0o8(chr(48) + chr(111) + chr(2432 - 2382) + '\062' + chr(48), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1527 - 1478) + chr(2407 - 2357) + '\x30', 0o10), nzTpIcepk0o8(chr(0b100 + 0o54) + '\x6f' + chr(0b110011) + chr(0b110011) + chr(0b110 + 0o52), ord("\x08")), nzTpIcepk0o8(chr(1138 - 1090) + chr(3948 - 3837) + '\062' + chr(434 - 379) + chr(626 - 578), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b111010 + 0o65) + chr(0b100000 + 0o22) + '\066' + '\060', 1992 - 1984), nzTpIcepk0o8('\x30' + chr(9989 - 9878) + '\x31' + chr(53) + '\x36', 0b1000), nzTpIcepk0o8(chr(234 - 186) + chr(0b1101111) + chr(0b110010), 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(49) + chr(0b110101), ord("\x08")), nzTpIcepk0o8(chr(2208 - 2160) + chr(111) + '\063' + chr(49) + chr(776 - 722), 50163 - 50155), nzTpIcepk0o8(chr(419 - 371) + chr(111) + chr(71 - 22) + chr(0b110010) + '\063', 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(0b110010) + '\x37' + '\x31', 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(0b11111 + 0o22) + chr(0b110010) + '\x33', 8), nzTpIcepk0o8(chr(0b110000) + chr(0b1000010 + 0o55) + '\063' + '\x32' + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x33' + '\x31' + '\x34', 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + '\062' + '\x32' + '\x36', ord("\x08")), nzTpIcepk0o8(chr(561 - 513) + chr(0b1100011 + 0o14) + '\061' + chr(52) + '\064', ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + '\x33' + chr(53) + '\066', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(49) + '\064' + chr(0b101101 + 0o10), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x33' + chr(54), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(3826 - 3715) + chr(0b110101) + chr(0b110001), 59994 - 59986), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b11000 + 0o31) + chr(51) + '\x37', 16770 - 16762), nzTpIcepk0o8('\x30' + chr(111) + chr(0b10010 + 0o37) + chr(1750 - 1697) + chr(54), 8), nzTpIcepk0o8('\060' + chr(0b1010 + 0o145) + chr(52) + '\062', ord("\x08")), nzTpIcepk0o8(chr(0b0 + 0o60) + '\157' + chr(0b110001) + chr(2491 - 2436) + chr(52), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b1101 + 0o44) + '\x34' + chr(48), 27993 - 27985), nzTpIcepk0o8(chr(0b110000) + chr(248 - 137) + '\062' + '\065' + '\x36', 32655 - 32647), nzTpIcepk0o8(chr(974 - 926) + '\157' + chr(51) + '\065' + '\063', 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(1832 - 1784) + chr(0b1101111) + '\x35' + chr(640 - 592), 21773 - 21765)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'&'), '\x64' + chr(0b1100001 + 0o4) + chr(0b1100001 + 0o2) + chr(0b1101111) + '\x64' + '\x65')(chr(9675 - 9558) + '\164' + chr(0b1100011 + 0o3) + chr(0b101101) + chr(0b11011 + 0o35)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def pfzyJC7EQHEL(QnTXOd5N96r1, xjcI3EsIvP59, usVcjUPX60jk, uCjCtz1_Wn1U, a9Ac2dnRYSi0, b4gxT6pq1mdD, Dmvx9BTTia8x, fxq3Mf2lCtQN, UXh69pZlc4If=roI3spqORKae(ES5oEprVxulp(b'^P\x0b\x88A'), chr(8698 - 8598) + '\x65' + chr(0b111 + 0o134) + chr(111) + chr(8929 - 8829) + chr(9634 - 9533))('\x75' + chr(116) + '\146' + '\x2d' + chr(0b11100 + 0o34)), F9lJ8RbIonqb=nzTpIcepk0o8(chr(48) + '\157' + chr(0b100000 + 0o21), 18358 - 18350)):
IXnl2GvbXuom = QnTXOd5N96r1.IQBeAtTmkxwI()[-nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x31', 8)]
assert IXnl2GvbXuom % F9lJ8RbIonqb == nzTpIcepk0o8(chr(0b11101 + 0o23) + chr(0b1101111) + chr(0b10110 + 0o32), 20226 - 20218)
assert b4gxT6pq1mdD % F9lJ8RbIonqb == nzTpIcepk0o8(chr(48) + chr(1740 - 1629) + '\060', 8)
def ash1e7oBNGAS(ZlbFMSG8gCoF, B6UAF1zReOyJ):
return roI3spqORKae(FyZE4zrPCXjA.nn, roI3spqORKae(ES5oEprVxulp(b'k~)\xb77\x90'), '\144' + '\x65' + chr(99) + '\157' + chr(100) + chr(3400 - 3299))('\165' + chr(0b1100010 + 0o22) + chr(0b1100110) + chr(1386 - 1341) + chr(1769 - 1713)))(ZlbFMSG8gCoF, B6UAF1zReOyJ, [nzTpIcepk0o8(chr(48) + chr(2511 - 2400) + chr(887 - 838), 8), Dmvx9BTTia8x, fxq3Mf2lCtQN, nzTpIcepk0o8(chr(48) + chr(0b11001 + 0o126) + chr(0b110001), 8)], padding=UXh69pZlc4If)
if F9lJ8RbIonqb == nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110001), 8):
pfzyJC7EQHEL = ash1e7oBNGAS(QnTXOd5N96r1, xjcI3EsIvP59)
else:
uK6JtkgJ88ug = FyZE4zrPCXjA.LfRrQOxuDvnC(QnTXOd5N96r1, F9lJ8RbIonqb, axis=nzTpIcepk0o8(chr(48) + chr(9962 - 9851) + '\063', 0o10))
WccFbgMMCKG1 = FyZE4zrPCXjA.LfRrQOxuDvnC(xjcI3EsIvP59, F9lJ8RbIonqb, axis=nzTpIcepk0o8(chr(0b11001 + 0o27) + '\157' + '\x33', 8))
kFnJgZgSnpbV = [ash1e7oBNGAS(ZlbFMSG8gCoF, B6UAF1zReOyJ) for (ZlbFMSG8gCoF, B6UAF1zReOyJ) in TxMFWa_Xzviv(uK6JtkgJ88ug, WccFbgMMCKG1)]
pfzyJC7EQHEL = FyZE4zrPCXjA.concat(kFnJgZgSnpbV, axis=nzTpIcepk0o8(chr(0b101011 + 0o5) + '\x6f' + '\x33', 8))
return roI3spqORKae(FyZE4zrPCXjA, roI3spqORKae(ES5oEprVxulp(b'zt4\xa9d\x84\xcf'), chr(100) + chr(0b1100101) + chr(99) + chr(10216 - 10105) + chr(0b10101 + 0o117) + '\145')(chr(0b1110101) + '\x74' + chr(102) + '\055' + chr(56)))(roI3spqORKae(FyZE4zrPCXjA.nn, roI3spqORKae(ES5oEprVxulp(b'jx&\xb2Z\x95\xce\xf7'), chr(0b1100100) + chr(0b1100101) + chr(0b1100011) + chr(1191 - 1080) + chr(0b1100100) + chr(0b1100101))(chr(1041 - 924) + chr(116) + '\x66' + chr(379 - 334) + chr(0b111000)))(pfzyJC7EQHEL, usVcjUPX60jk), [-nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110001), 8)] + roI3spqORKae(pfzyJC7EQHEL.get_shape(), roI3spqORKae(ES5oEprVxulp(b'ib\x18\xadl\x87\xde'), chr(0b1100100) + chr(0b1011100 + 0o11) + '\x63' + chr(111) + chr(100) + chr(8074 - 7973))(chr(0b1110101) + '\164' + chr(0b1100110) + chr(0b101101) + '\070'))()[nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\061', 8):]) |
BerkeleyAutomation/perception | perception/cnn.py | AlexNet._parse_config | def _parse_config(self, config):
""" Parses a tensorflow configuration """
self._batch_size = config['batch_size']
self._im_height = config['im_height']
self._im_width = config['im_width']
self._num_channels = config['channels']
self._output_layer = config['out_layer']
self._feature_layer = config['feature_layer']
self._out_size = None
if 'out_size' in config.keys():
self._out_size = config['out_size']
self._input_arr = np.zeros([self._batch_size, self._im_height,
self._im_width, self._num_channels])
if self._model_dir is None:
self._net_data = np.load(config['caffe_weights']).item()
self._mean = np.load(config['mean_file'])
self._model_filename = None
else:
self._net_data = None
self._mean = np.load(os.path.join(self._model_dir, 'mean.npy'))
self._model_filename = os.path.join(self._model_dir, 'model.ckpt') | python | def _parse_config(self, config):
""" Parses a tensorflow configuration """
self._batch_size = config['batch_size']
self._im_height = config['im_height']
self._im_width = config['im_width']
self._num_channels = config['channels']
self._output_layer = config['out_layer']
self._feature_layer = config['feature_layer']
self._out_size = None
if 'out_size' in config.keys():
self._out_size = config['out_size']
self._input_arr = np.zeros([self._batch_size, self._im_height,
self._im_width, self._num_channels])
if self._model_dir is None:
self._net_data = np.load(config['caffe_weights']).item()
self._mean = np.load(config['mean_file'])
self._model_filename = None
else:
self._net_data = None
self._mean = np.load(os.path.join(self._model_dir, 'mean.npy'))
self._model_filename = os.path.join(self._model_dir, 'model.ckpt') | [
"def",
"_parse_config",
"(",
"self",
",",
"config",
")",
":",
"self",
".",
"_batch_size",
"=",
"config",
"[",
"'batch_size'",
"]",
"self",
".",
"_im_height",
"=",
"config",
"[",
"'im_height'",
"]",
"self",
".",
"_im_width",
"=",
"config",
"[",
"'im_width'",
"]",
"self",
".",
"_num_channels",
"=",
"config",
"[",
"'channels'",
"]",
"self",
".",
"_output_layer",
"=",
"config",
"[",
"'out_layer'",
"]",
"self",
".",
"_feature_layer",
"=",
"config",
"[",
"'feature_layer'",
"]",
"self",
".",
"_out_size",
"=",
"None",
"if",
"'out_size'",
"in",
"config",
".",
"keys",
"(",
")",
":",
"self",
".",
"_out_size",
"=",
"config",
"[",
"'out_size'",
"]",
"self",
".",
"_input_arr",
"=",
"np",
".",
"zeros",
"(",
"[",
"self",
".",
"_batch_size",
",",
"self",
".",
"_im_height",
",",
"self",
".",
"_im_width",
",",
"self",
".",
"_num_channels",
"]",
")",
"if",
"self",
".",
"_model_dir",
"is",
"None",
":",
"self",
".",
"_net_data",
"=",
"np",
".",
"load",
"(",
"config",
"[",
"'caffe_weights'",
"]",
")",
".",
"item",
"(",
")",
"self",
".",
"_mean",
"=",
"np",
".",
"load",
"(",
"config",
"[",
"'mean_file'",
"]",
")",
"self",
".",
"_model_filename",
"=",
"None",
"else",
":",
"self",
".",
"_net_data",
"=",
"None",
"self",
".",
"_mean",
"=",
"np",
".",
"load",
"(",
"os",
".",
"path",
".",
"join",
"(",
"self",
".",
"_model_dir",
",",
"'mean.npy'",
")",
")",
"self",
".",
"_model_filename",
"=",
"os",
".",
"path",
".",
"join",
"(",
"self",
".",
"_model_dir",
",",
"'model.ckpt'",
")"
] | Parses a tensorflow configuration | [
"Parses",
"a",
"tensorflow",
"configuration"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/cnn.py#L72-L93 | train | Parses a tensorflow configuration and populates the internal state of the object. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1g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IhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(2076 - 2028) + chr(0b110101 + 0o72) + chr(1677 - 1627), 21131 - 21123), nzTpIcepk0o8(chr(2060 - 2012) + '\x6f' + chr(1631 - 1581) + chr(0b101000 + 0o10) + chr(0b110101), 0o10), nzTpIcepk0o8('\060' + chr(0b11 + 0o154) + '\x30', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(53) + chr(55), 45063 - 45055), nzTpIcepk0o8('\x30' + '\x6f' + chr(50) + '\x33' + '\063', 0b1000), nzTpIcepk0o8(chr(1807 - 1759) + chr(11395 - 11284) + '\x33' + chr(0b11001 + 0o32) + chr(0b101000 + 0o12), ord("\x08")), nzTpIcepk0o8(chr(247 - 199) + '\x6f' + chr(1863 - 1812) + chr(50) + chr(0b110110), 0o10), nzTpIcepk0o8('\x30' + '\157' + '\062' + chr(48) + '\x36', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(2023 - 1974) + '\x37' + '\x37', 58039 - 58031), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\062' + '\062' + chr(51), 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x33' + chr(0b11101 + 0o27) + chr(0b110110), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(50) + chr(0b100 + 0o56), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110001) + chr(0b10100 + 0o43) + chr(1084 - 1030), 12853 - 12845), nzTpIcepk0o8(chr(779 - 731) + chr(0b1101111) + '\063' + chr(0b11010 + 0o30) + chr(55), ord("\x08")), nzTpIcepk0o8(chr(1760 - 1712) + chr(9712 - 9601) + '\061' + chr(206 - 157) + chr(55), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(50) + chr(2480 - 2429) + chr(0b100011 + 0o16), ord("\x08")), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(5234 - 5123) + chr(1837 - 1786) + '\062' + chr(0b1011 + 0o50), 48859 - 48851), nzTpIcepk0o8('\060' + chr(0b1001111 + 0o40) + '\x35' + chr(54), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1010010 + 0o35) + chr(50) + chr(2307 - 2254) + chr(53), 0o10), nzTpIcepk0o8(chr(48) + chr(1304 - 1193) + '\063' + chr(1436 - 1383) + chr(0b10010 + 0o41), 64188 - 64180), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\061' + chr(0b1111 + 0o42), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x31' + '\x37' + chr(2075 - 2023), 13986 - 13978), nzTpIcepk0o8(chr(1812 - 1764) + chr(111) + chr(0b110001) + chr(0b110 + 0o54) + chr(0b11001 + 0o34), ord("\x08")), nzTpIcepk0o8(chr(2102 - 2054) + '\x6f' + chr(0b100111 + 0o16), 11279 - 11271), nzTpIcepk0o8(chr(48) + chr(0b0 + 0o157) + '\x32' + chr(2080 - 2031), 0b1000), nzTpIcepk0o8(chr(48) + chr(5919 - 5808) + '\x31' + chr(0b11100 + 0o24) + '\063', 33386 - 33378), nzTpIcepk0o8(chr(226 - 178) + chr(0b1000000 + 0o57) + '\x32' + chr(0b1010 + 0o54) + chr(51), 19686 - 19678), nzTpIcepk0o8(chr(48) + '\157' + chr(0b100010 + 0o20) + '\067' + '\x35', 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(1246 - 1195) + chr(55) + chr(1342 - 1292), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b1 + 0o60) + '\060' + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + '\x32' + '\x34' + chr(50), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101 + 0o142) + '\062' + chr(151 - 98) + chr(1917 - 1864), 8), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(110 - 59) + chr(0b101000 + 0o12) + chr(1609 - 1554), 8), nzTpIcepk0o8('\x30' + '\157' + chr(0b10010 + 0o41) + '\065' + chr(0b11000 + 0o34), ord("\x08")), nzTpIcepk0o8(chr(0b101 + 0o53) + chr(0b1101111) + chr(52) + chr(0b110110), 30121 - 30113), nzTpIcepk0o8('\x30' + chr(0b1000101 + 0o52) + chr(0b1001 + 0o50) + chr(0b11100 + 0o33) + chr(2707 - 2652), 8), nzTpIcepk0o8(chr(0b110000) + chr(0b101010 + 0o105) + '\x33' + chr(0b110100) + chr(0b110000), 1575 - 1567), nzTpIcepk0o8('\060' + chr(0b1101111) + '\062' + '\x36' + chr(53), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1011101 + 0o22) + '\062' + '\064' + '\x33', 0o10), nzTpIcepk0o8(chr(1441 - 1393) + chr(0b1101011 + 0o4) + '\062' + chr(0b10100 + 0o41) + chr(54), 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + '\157' + chr(0b110010 + 0o3) + chr(0b110000), 24233 - 24225)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b','), '\144' + chr(0b101011 + 0o72) + '\x63' + chr(10885 - 10774) + chr(0b1100100) + chr(0b1011000 + 0o15))(chr(117) + chr(0b1000110 + 0o56) + chr(0b1100011 + 0o3) + chr(1715 - 1670) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def XCIo5I5yZWwf(hXMPsSrOQzbh, kgkKUcD36lls):
hXMPsSrOQzbh.hlKRiZyqMb3U = kgkKUcD36lls[roI3spqORKae(ES5oEprVxulp(b'`\xe4tL\xf3\x85\xa5\xef\x05\xf6'), chr(6583 - 6483) + chr(3839 - 3738) + '\x63' + '\157' + chr(100) + chr(3733 - 3632))('\165' + '\x74' + '\146' + chr(0b101101) + '\x38')]
hXMPsSrOQzbh.KaqN1m3tFi2T = kgkKUcD36lls[roI3spqORKae(ES5oEprVxulp(b'k\xe8_G\xfe\xb3\xb1\xee\x0b'), chr(0b1100100) + '\145' + chr(0b1100011) + chr(111) + chr(100) + '\x65')('\165' + chr(13403 - 13287) + '\x66' + chr(0b101101) + chr(0b100100 + 0o24))]
hXMPsSrOQzbh.LGqOPpuhore_ = kgkKUcD36lls[roI3spqORKae(ES5oEprVxulp(b'k\xe8_X\xf2\xbe\xa2\xee'), chr(100) + '\x65' + '\143' + '\x6f' + chr(8280 - 8180) + chr(8394 - 8293))(chr(0b11101 + 0o130) + chr(0b1110010 + 0o2) + '\146' + chr(495 - 450) + chr(0b111000))]
hXMPsSrOQzbh.qXSsKe_JWQLo = kgkKUcD36lls[roI3spqORKae(ES5oEprVxulp(b'a\xedaA\xf5\xbf\xba\xf5'), chr(0b1011001 + 0o13) + chr(101) + chr(0b1100011) + chr(10121 - 10010) + chr(8631 - 8531) + '\x65')('\x75' + chr(0b101 + 0o157) + chr(0b1100110) + '\055' + chr(0b10101 + 0o43))]
hXMPsSrOQzbh.AjiUau1IFHOs = kgkKUcD36lls[roI3spqORKae(ES5oEprVxulp(b'm\xf0tp\xf7\xbb\xaf\xe3\r'), '\144' + '\145' + chr(2249 - 2150) + chr(0b1101111) + chr(0b1100100) + chr(101))(chr(0b1110101) + '\164' + '\x66' + '\055' + chr(740 - 684))]
hXMPsSrOQzbh.fKG1GSv57ozo = kgkKUcD36lls[roI3spqORKae(ES5oEprVxulp(b'd\xe0a[\xee\xa8\xb3\xd9\x13\xf2\x9fw\x0c'), '\x64' + chr(10053 - 9952) + '\x63' + '\x6f' + '\144' + '\x65')(chr(2623 - 2506) + chr(0b1110100) + chr(0b100110 + 0o100) + chr(0b11000 + 0o25) + chr(1149 - 1093))]
hXMPsSrOQzbh.VXgBVhbVSHlI = None
if roI3spqORKae(ES5oEprVxulp(b'm\xf0tp\xe8\xb3\xac\xe3'), chr(0b111010 + 0o52) + chr(0b1100010 + 0o3) + '\143' + '\157' + '\144' + '\x65')('\x75' + '\x74' + chr(0b1111 + 0o127) + chr(0b101101) + chr(0b111000)) in roI3spqORKae(kgkKUcD36lls, roI3spqORKae(ES5oEprVxulp(b'i\xe0y\\'), chr(0b11001 + 0o113) + '\145' + chr(4315 - 4216) + chr(0b110011 + 0o74) + chr(0b1100100) + chr(101))(chr(117) + chr(0b10011 + 0o141) + '\146' + '\x2d' + chr(2821 - 2765)))():
hXMPsSrOQzbh.VXgBVhbVSHlI = kgkKUcD36lls[roI3spqORKae(ES5oEprVxulp(b'm\xf0tp\xe8\xb3\xac\xe3'), chr(2619 - 2519) + chr(101) + chr(0b1100011) + chr(0b1001011 + 0o44) + chr(0b1100100 + 0o0) + chr(4287 - 4186))('\x75' + chr(0b10 + 0o162) + chr(0b1010101 + 0o21) + '\x2d' + chr(368 - 312))]
hXMPsSrOQzbh.BC2TQIEMzNVj = nDF4gVNx0u9Q.UmwwEp7MzR6q([hXMPsSrOQzbh.hlKRiZyqMb3U, hXMPsSrOQzbh.KaqN1m3tFi2T, hXMPsSrOQzbh.LGqOPpuhore_, hXMPsSrOQzbh.qXSsKe_JWQLo])
if roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b']\xe8oK\xfe\xb6\x89\xe2\x16\xe1'), chr(100) + chr(8221 - 8120) + chr(99) + chr(3140 - 3029) + chr(100) + '\x65')(chr(13232 - 13115) + chr(9311 - 9195) + '\x66' + chr(0b101101) + chr(621 - 565))) is None:
hXMPsSrOQzbh.CWJ8y9rEaq7r = nDF4gVNx0u9Q.load(kgkKUcD36lls[roI3spqORKae(ES5oEprVxulp(b'a\xe4fI\xfe\x85\xa1\xe3\x16\xf4\x8ef\r'), '\x64' + chr(0b1100000 + 0o5) + chr(99) + chr(0b10110 + 0o131) + chr(0b1011 + 0o131) + '\145')(chr(8314 - 8197) + chr(0b1011111 + 0o25) + chr(2073 - 1971) + chr(0b11001 + 0o24) + '\x38')]).IZ1I2J8X1CQz()
hXMPsSrOQzbh.oO9mOHMYQJfV = nDF4gVNx0u9Q.ZERsdc7c1d8E(kgkKUcD36lls[roI3spqORKae(ES5oEprVxulp(b'o\xe0aA\xc4\xbc\xbf\xea\x1a'), '\x64' + chr(2079 - 1978) + chr(0b1100011) + chr(111) + '\144' + chr(0b100001 + 0o104))(chr(0b1110 + 0o147) + chr(0b101 + 0o157) + chr(7093 - 6991) + chr(1160 - 1115) + chr(0b110000 + 0o10))])
hXMPsSrOQzbh.fIFmjPRnREqI = None
else:
hXMPsSrOQzbh.CWJ8y9rEaq7r = None
hXMPsSrOQzbh.oO9mOHMYQJfV = nDF4gVNx0u9Q.ZERsdc7c1d8E(aHUqKstZLeS6.path.Y4yM9BcfTCNq(hXMPsSrOQzbh._model_dir, roI3spqORKae(ES5oEprVxulp(b'o\xe0aA\xb5\xb4\xa6\xff'), chr(0b1100100) + '\x65' + chr(0b1100011) + chr(111) + '\144' + chr(0b1000111 + 0o36))(chr(117) + chr(116) + chr(0b1100110) + chr(1508 - 1463) + chr(0b111000))))
hXMPsSrOQzbh.fIFmjPRnREqI = aHUqKstZLeS6.path.Y4yM9BcfTCNq(hXMPsSrOQzbh._model_dir, roI3spqORKae(ES5oEprVxulp(b'o\xeadJ\xf7\xf4\xb5\xed\x0f\xe7'), chr(100) + chr(101) + '\143' + chr(0b1101111) + '\x64' + chr(101))(chr(0b1110101) + '\x74' + chr(0b11111 + 0o107) + chr(45) + chr(0b100 + 0o64))) |
BerkeleyAutomation/perception | perception/cnn.py | AlexNet._load | def _load(self):
""" Loads a model into weights """
if self._model_filename is None:
raise ValueError('Model filename not specified')
# read the input image
self._graph = tf.Graph()
with self._graph.as_default():
# read in filenames
reader = tf.train.NewCheckpointReader(self._model_filename)
# load AlexNet weights
weights = AlexNetWeights()
weights.conv1W = tf.Variable(reader.get_tensor("Variable"))
weights.conv1b = tf.Variable(reader.get_tensor("Variable_1"))
weights.conv2W = tf.Variable(reader.get_tensor("Variable_2"))
weights.conv2b = tf.Variable(reader.get_tensor("Variable_3"))
weights.conv3W = tf.Variable(reader.get_tensor("Variable_4"))
weights.conv3b = tf.Variable(reader.get_tensor("Variable_5"))
weights.conv4W = tf.Variable(reader.get_tensor("Variable_6"))
weights.conv4b = tf.Variable(reader.get_tensor("Variable_7"))
weights.conv5W = tf.Variable(reader.get_tensor("Variable_8"))
weights.conv5b = tf.Variable(reader.get_tensor("Variable_9"))
weights.fc6W = tf.Variable(reader.get_tensor("Variable_10"))
weights.fc6b = tf.Variable(reader.get_tensor("Variable_11"))
weights.fc7W = tf.Variable(reader.get_tensor("Variable_12"))
weights.fc7b = tf.Variable(reader.get_tensor("Variable_13"))
weights.fc8W = tf.Variable(reader.get_tensor("Variable_14"))
weights.fc8b = tf.Variable(reader.get_tensor("Variable_15"))
# form network
self._input_node = tf.placeholder(tf.float32, (self._batch_size, self._im_height, self._im_width, self._num_channels))
self._output_tensor = self.build_alexnet(weights)
self._feature_tensor = self.build_alexnet(weights, output_layer=self._feature_layer)
self._initialized = True | python | def _load(self):
""" Loads a model into weights """
if self._model_filename is None:
raise ValueError('Model filename not specified')
# read the input image
self._graph = tf.Graph()
with self._graph.as_default():
# read in filenames
reader = tf.train.NewCheckpointReader(self._model_filename)
# load AlexNet weights
weights = AlexNetWeights()
weights.conv1W = tf.Variable(reader.get_tensor("Variable"))
weights.conv1b = tf.Variable(reader.get_tensor("Variable_1"))
weights.conv2W = tf.Variable(reader.get_tensor("Variable_2"))
weights.conv2b = tf.Variable(reader.get_tensor("Variable_3"))
weights.conv3W = tf.Variable(reader.get_tensor("Variable_4"))
weights.conv3b = tf.Variable(reader.get_tensor("Variable_5"))
weights.conv4W = tf.Variable(reader.get_tensor("Variable_6"))
weights.conv4b = tf.Variable(reader.get_tensor("Variable_7"))
weights.conv5W = tf.Variable(reader.get_tensor("Variable_8"))
weights.conv5b = tf.Variable(reader.get_tensor("Variable_9"))
weights.fc6W = tf.Variable(reader.get_tensor("Variable_10"))
weights.fc6b = tf.Variable(reader.get_tensor("Variable_11"))
weights.fc7W = tf.Variable(reader.get_tensor("Variable_12"))
weights.fc7b = tf.Variable(reader.get_tensor("Variable_13"))
weights.fc8W = tf.Variable(reader.get_tensor("Variable_14"))
weights.fc8b = tf.Variable(reader.get_tensor("Variable_15"))
# form network
self._input_node = tf.placeholder(tf.float32, (self._batch_size, self._im_height, self._im_width, self._num_channels))
self._output_tensor = self.build_alexnet(weights)
self._feature_tensor = self.build_alexnet(weights, output_layer=self._feature_layer)
self._initialized = True | [
"def",
"_load",
"(",
"self",
")",
":",
"if",
"self",
".",
"_model_filename",
"is",
"None",
":",
"raise",
"ValueError",
"(",
"'Model filename not specified'",
")",
"# read the input image",
"self",
".",
"_graph",
"=",
"tf",
".",
"Graph",
"(",
")",
"with",
"self",
".",
"_graph",
".",
"as_default",
"(",
")",
":",
"# read in filenames",
"reader",
"=",
"tf",
".",
"train",
".",
"NewCheckpointReader",
"(",
"self",
".",
"_model_filename",
")",
"# load AlexNet weights",
"weights",
"=",
"AlexNetWeights",
"(",
")",
"weights",
".",
"conv1W",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable\"",
")",
")",
"weights",
".",
"conv1b",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_1\"",
")",
")",
"weights",
".",
"conv2W",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_2\"",
")",
")",
"weights",
".",
"conv2b",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_3\"",
")",
")",
"weights",
".",
"conv3W",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_4\"",
")",
")",
"weights",
".",
"conv3b",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_5\"",
")",
")",
"weights",
".",
"conv4W",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_6\"",
")",
")",
"weights",
".",
"conv4b",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_7\"",
")",
")",
"weights",
".",
"conv5W",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_8\"",
")",
")",
"weights",
".",
"conv5b",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_9\"",
")",
")",
"weights",
".",
"fc6W",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_10\"",
")",
")",
"weights",
".",
"fc6b",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_11\"",
")",
")",
"weights",
".",
"fc7W",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_12\"",
")",
")",
"weights",
".",
"fc7b",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_13\"",
")",
")",
"weights",
".",
"fc8W",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_14\"",
")",
")",
"weights",
".",
"fc8b",
"=",
"tf",
".",
"Variable",
"(",
"reader",
".",
"get_tensor",
"(",
"\"Variable_15\"",
")",
")",
"# form network",
"self",
".",
"_input_node",
"=",
"tf",
".",
"placeholder",
"(",
"tf",
".",
"float32",
",",
"(",
"self",
".",
"_batch_size",
",",
"self",
".",
"_im_height",
",",
"self",
".",
"_im_width",
",",
"self",
".",
"_num_channels",
")",
")",
"self",
".",
"_output_tensor",
"=",
"self",
".",
"build_alexnet",
"(",
"weights",
")",
"self",
".",
"_feature_tensor",
"=",
"self",
".",
"build_alexnet",
"(",
"weights",
",",
"output_layer",
"=",
"self",
".",
"_feature_layer",
")",
"self",
".",
"_initialized",
"=",
"True"
] | Loads a model into weights | [
"Loads",
"a",
"model",
"into",
"weights"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/cnn.py#L95-L129 | train | Loads a model into the graph and populates the internal variables. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jf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ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + '\157' + chr(0b110011) + chr(50), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b11111 + 0o22) + chr(0b101111 + 0o3) + '\060', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x32' + '\x32', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\064' + chr(301 - 248), 9143 - 9135), nzTpIcepk0o8(chr(48) + chr(9886 - 9775) + chr(0b110011) + chr(55), ord("\x08")), nzTpIcepk0o8('\060' + chr(433 - 322) + '\061' + chr(0b100010 + 0o25) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(0b10 + 0o56) + chr(0b1001011 + 0o44) + '\x32' + chr(264 - 212) + chr(0b101111 + 0o6), 0o10), nzTpIcepk0o8('\x30' + chr(0b10111 + 0o130) + '\x37' + '\063', 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110111) + chr(939 - 886), 27921 - 27913), nzTpIcepk0o8('\x30' + chr(111) + '\x33' + chr(0b110111), 8), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x32' + chr(50), 8), nzTpIcepk0o8('\x30' + chr(111) + chr(0b11110 + 0o23) + chr(54) + '\x33', 927 - 919), nzTpIcepk0o8(chr(48) + '\157' + chr(1783 - 1732) + '\060' + '\060', 0o10), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110011) + '\x32' + chr(0b110011), 0o10), nzTpIcepk0o8(chr(0b1000 + 0o50) + '\x6f' + chr(321 - 272) + '\065' + '\x31', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110010) + chr(53) + chr(0b101100 + 0o4), ord("\x08")), nzTpIcepk0o8(chr(0b1000 + 0o50) + chr(0b1101111) + '\x32' + chr(52) + '\x30', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1111 + 0o140) + chr(49) + '\x36' + '\063', 8), nzTpIcepk0o8('\x30' + chr(111) + chr(0b1110 + 0o44) + chr(0b110110) + chr(52), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(622 - 573) + '\x33' + chr(0b110110), 0b1000), nzTpIcepk0o8('\060' + '\157' + '\x32' + chr(280 - 230), 8), nzTpIcepk0o8(chr(0b100111 + 0o11) + '\157' + chr(49) + chr(52) + chr(0b110101), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110010) + chr(0b110110), 33360 - 33352), nzTpIcepk0o8('\x30' + '\x6f' + '\062' + '\062' + chr(0b100110 + 0o20), 39032 - 39024), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x33' + chr(48) + chr(0b11111 + 0o22), 0o10), nzTpIcepk0o8('\x30' + chr(0b11101 + 0o122) + chr(722 - 672) + chr(743 - 693) + chr(54), 8), nzTpIcepk0o8(chr(0b110000) + chr(0b111110 + 0o61) + '\062' + '\x37' + chr(953 - 904), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110110) + '\064', 0b1000), nzTpIcepk0o8(chr(517 - 469) + chr(0b110010 + 0o75) + '\062' + chr(54) + '\x33', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\061' + '\062' + chr(0b101101 + 0o7), 0b1000), nzTpIcepk0o8(chr(917 - 869) + chr(0b1000000 + 0o57) + chr(0b101000 + 0o12) + chr(0b110110) + '\061', 3840 - 3832), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x33' + '\066', ord("\x08")), nzTpIcepk0o8(chr(1541 - 1493) + chr(111) + '\065' + chr(1131 - 1079), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x32' + chr(0b110011) + chr(48), 0o10), nzTpIcepk0o8(chr(86 - 38) + chr(0b1011011 + 0o24) + chr(1288 - 1237) + chr(52) + chr(48), 9288 - 9280), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\062' + chr(0b1011 + 0o53) + chr(53), 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111 + 0o0) + '\x32' + chr(0b1110 + 0o45) + chr(0b110011), 0o10), nzTpIcepk0o8(chr(0b101100 + 0o4) + chr(3008 - 2897) + chr(2101 - 2052) + chr(53) + chr(2315 - 2260), 0b1000), nzTpIcepk0o8(chr(603 - 555) + '\x6f' + '\062' + chr(1922 - 1869) + '\x32', ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(1270 - 1221) + '\065' + chr(0b110101), ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + chr(10235 - 10124) + '\065' + chr(2248 - 2200), 19049 - 19041)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'4'), chr(100) + '\145' + chr(0b1100011) + chr(0b1101111) + chr(0b1100100) + '\x65')(chr(0b1110101) + '\x74' + '\x66' + chr(1409 - 1364) + chr(467 - 411)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def VMBmLBsAADwH(hXMPsSrOQzbh):
if roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'|\x19THu)\xf7UoZc:'), chr(0b1011001 + 0o13) + chr(0b11111 + 0o106) + chr(0b1100011) + chr(0b1101111) + chr(100) + chr(5257 - 5156))(chr(0b1110101) + chr(116) + chr(0b11 + 0o143) + chr(45) + chr(2315 - 2259))) is None:
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'W?v@sY\xc3RQz|\x12\xad\xb6I\xc6\xcf\x07\x94-b\x00u\xff\xa7\xff\xdcP'), '\x64' + chr(2479 - 2378) + '\x63' + chr(7377 - 7266) + '\x64' + chr(0b111110 + 0o47))('\165' + chr(116) + '\x66' + chr(45) + '\070'))
hXMPsSrOQzbh.DgPzdyeP62dT = FyZE4zrPCXjA.Graph()
with roI3spqORKae(hXMPsSrOQzbh._graph, roI3spqORKae(ES5oEprVxulp(b'{#MAz\x1f\xc4NQk'), chr(7497 - 7397) + chr(0b110101 + 0o60) + chr(0b111101 + 0o46) + chr(0b1101111) + chr(0b10101 + 0o117) + chr(0b1100101))(chr(117) + chr(11540 - 11424) + '\x66' + chr(1738 - 1693) + '\070'))():
kWvgahJQKTiF = FyZE4zrPCXjA.train.NewCheckpointReader(hXMPsSrOQzbh.fIFmjPRnREqI)
TtzqJLqe_ecy = ZJSJLGEv5jD2()
TtzqJLqe_ecy.eGgaX_knDzuj = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^'), '\144' + chr(0b100110 + 0o77) + chr(0b1010100 + 0o17) + chr(9474 - 9363) + chr(0b10101 + 0o117) + chr(0b100101 + 0o100))('\x75' + chr(116) + chr(102) + chr(0b10111 + 0o26) + chr(56))))
TtzqJLqe_ecy.ILl5xuugQJyt = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b.'), chr(100) + '\x65' + chr(0b1001 + 0o132) + chr(111) + chr(0b1011101 + 0o7) + chr(9106 - 9005))(chr(0b1101110 + 0o7) + chr(0b1110100) + chr(0b1100110) + chr(1134 - 1089) + chr(56))))
TtzqJLqe_ecy.hMmsR3v_5zlf = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b-'), chr(0b1100100) + chr(0b1011001 + 0o14) + chr(0b100011 + 0o100) + '\157' + '\144' + chr(7663 - 7562))(chr(189 - 72) + '\164' + '\x66' + chr(470 - 425) + chr(56))))
TtzqJLqe_ecy.dhcvv52XXl2X = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b,'), chr(0b1100100) + chr(0b1100010 + 0o3) + chr(0b111000 + 0o53) + chr(1853 - 1742) + '\144' + chr(0b111011 + 0o52))('\x75' + chr(0b1110100) + chr(6498 - 6396) + '\055' + chr(657 - 601))))
TtzqJLqe_ecy.HeZpmUbQjEEE = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b+'), '\x64' + chr(101) + '\143' + chr(111) + chr(0b100011 + 0o101) + chr(0b1001000 + 0o35))('\165' + '\x74' + '\x66' + chr(0b101101) + '\070')))
TtzqJLqe_ecy.POiHY0wqE8KF = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b*'), chr(0b1100100) + chr(0b101111 + 0o66) + chr(99) + '\x6f' + chr(0b111000 + 0o54) + chr(0b1100000 + 0o5))(chr(117) + '\x74' + chr(0b1100110) + chr(0b101101) + '\070')))
TtzqJLqe_ecy.eFL79s_Lhsf8 = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b)'), chr(0b1100100) + chr(0b1 + 0o144) + chr(99) + chr(0b1 + 0o156) + chr(100) + chr(101))(chr(117) + '\x74' + chr(102) + '\x2d' + chr(2542 - 2486))))
TtzqJLqe_ecy.VL5thwtuXQK1 = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b('), chr(100) + chr(7429 - 7328) + chr(0b1100011) + chr(111) + chr(0b1100100) + '\145')(chr(0b1110101) + chr(13303 - 13187) + chr(0b11111 + 0o107) + chr(0b101101) + chr(56))))
TtzqJLqe_ecy.EV56evGx0Qhj = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b"L1`L~\x1b\xc9^b'"), chr(0b1010 + 0o132) + chr(0b1001101 + 0o30) + '\143' + chr(5358 - 5247) + '\144' + chr(0b100011 + 0o102))('\165' + chr(0b1100011 + 0o21) + chr(9456 - 9354) + chr(45) + chr(0b10100 + 0o44))))
TtzqJLqe_ecy.AfcIUN_Qr9y7 = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b&'), chr(7897 - 7797) + chr(0b1000001 + 0o44) + chr(0b1100011) + '\x6f' + '\x64' + chr(101))(chr(117) + '\x74' + '\146' + chr(0b101101) + '\070')))
TtzqJLqe_ecy.coPNsw2BJGFW = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b."'), chr(9540 - 9440) + chr(0b1100101) + chr(99) + chr(111) + chr(0b1100100) + '\145')(chr(0b1110101) + chr(0b1110100) + chr(102) + chr(962 - 917) + '\070')))
TtzqJLqe_ecy.vZO9v86f6hLZ = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b.#'), chr(100) + chr(0b111010 + 0o53) + chr(99) + chr(111) + '\x64' + chr(101))(chr(0b1001010 + 0o53) + '\x74' + '\146' + chr(0b101101) + chr(0b111000))))
TtzqJLqe_ecy.xALwK0_ExJij = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b. '), '\144' + chr(0b1100101) + '\x63' + chr(0b1001101 + 0o42) + chr(100) + '\145')('\x75' + chr(6715 - 6599) + '\146' + chr(0b101101) + chr(56))))
TtzqJLqe_ecy.xO_00mjyi58J = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b.!'), '\x64' + chr(0b1100101) + chr(0b1000110 + 0o35) + chr(0b1101111) + chr(4388 - 4288) + chr(1426 - 1325))('\x75' + chr(0b111101 + 0o67) + chr(0b1100110) + chr(1511 - 1466) + chr(1507 - 1451))))
TtzqJLqe_ecy.UlT2EGMjifwh = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b'L1`L~\x1b\xc9^b.&'), chr(100) + '\x65' + '\143' + chr(111) + chr(0b1100100) + '\x65')(chr(5269 - 5152) + '\164' + chr(102) + '\x2d' + chr(56))))
TtzqJLqe_ecy.Xt4s1gXuKEv0 = FyZE4zrPCXjA.Variable(kWvgahJQKTiF.get_tensor(roI3spqORKae(ES5oEprVxulp(b"L1`L~\x1b\xc9^b.'"), '\x64' + chr(0b10101 + 0o120) + chr(99) + chr(0b1101111) + '\x64' + '\145')(chr(0b1110101) + '\x74' + chr(102) + chr(0b101101) + chr(56))))
hXMPsSrOQzbh.ifKyDND3ENDe = FyZE4zrPCXjA.DezdrUdcfjvz(FyZE4zrPCXjA.float32, (hXMPsSrOQzbh.hlKRiZyqMb3U, hXMPsSrOQzbh.KaqN1m3tFi2T, hXMPsSrOQzbh.LGqOPpuhore_, hXMPsSrOQzbh.qXSsKe_JWQLo))
hXMPsSrOQzbh.ue_raBX_mG1y = hXMPsSrOQzbh.build_alexnet(TtzqJLqe_ecy)
hXMPsSrOQzbh.TFR26HxNlH5s = hXMPsSrOQzbh.build_alexnet(TtzqJLqe_ecy, output_layer=hXMPsSrOQzbh.fKG1GSv57ozo)
hXMPsSrOQzbh.qfJ1M6ynGKsn = nzTpIcepk0o8(chr(1965 - 1917) + chr(0b1101111) + chr(952 - 903), ord("\x08")) |
BerkeleyAutomation/perception | perception/cnn.py | AlexNet._initialize | def _initialize(self):
""" Open from caffe weights """
self._graph = tf.Graph()
with self._graph.as_default():
self._input_node = tf.placeholder(tf.float32, (self._batch_size, self._im_height, self._im_width, self._num_channels))
weights = self.build_alexnet_weights()
self._output_tensor = self.build_alexnet(weights)
self._feature_tensor = self.build_alexnet(weights, output_layer=self._feature_layer)
self._initialized = True | python | def _initialize(self):
""" Open from caffe weights """
self._graph = tf.Graph()
with self._graph.as_default():
self._input_node = tf.placeholder(tf.float32, (self._batch_size, self._im_height, self._im_width, self._num_channels))
weights = self.build_alexnet_weights()
self._output_tensor = self.build_alexnet(weights)
self._feature_tensor = self.build_alexnet(weights, output_layer=self._feature_layer)
self._initialized = True | [
"def",
"_initialize",
"(",
"self",
")",
":",
"self",
".",
"_graph",
"=",
"tf",
".",
"Graph",
"(",
")",
"with",
"self",
".",
"_graph",
".",
"as_default",
"(",
")",
":",
"self",
".",
"_input_node",
"=",
"tf",
".",
"placeholder",
"(",
"tf",
".",
"float32",
",",
"(",
"self",
".",
"_batch_size",
",",
"self",
".",
"_im_height",
",",
"self",
".",
"_im_width",
",",
"self",
".",
"_num_channels",
")",
")",
"weights",
"=",
"self",
".",
"build_alexnet_weights",
"(",
")",
"self",
".",
"_output_tensor",
"=",
"self",
".",
"build_alexnet",
"(",
"weights",
")",
"self",
".",
"_feature_tensor",
"=",
"self",
".",
"build_alexnet",
"(",
"weights",
",",
"output_layer",
"=",
"self",
".",
"_feature_layer",
")",
"self",
".",
"_initialized",
"=",
"True"
] | Open from caffe weights | [
"Open",
"from",
"caffe",
"weights"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/cnn.py#L131-L139 | train | Open from caffe weights | GiP5xwVCF98Z,B3LV8E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2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(50) + chr(0b110100) + chr(0b100100 + 0o22), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110110) + chr(820 - 772), 22295 - 22287), nzTpIcepk0o8(chr(1308 - 1260) + chr(11710 - 11599) + chr(49) + chr(0b110001) + chr(0b110110), 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(0b11110 + 0o23) + '\x35' + chr(54), 57794 - 57786), nzTpIcepk0o8(chr(1983 - 1935) + chr(111) + chr(1609 - 1558) + chr(48) + chr(0b11011 + 0o27), 48223 - 48215), nzTpIcepk0o8(chr(0b110000) + chr(0b1001101 + 0o42) + '\062' + chr(48) + chr(48), 0b1000), nzTpIcepk0o8(chr(440 - 392) + chr(5990 - 5879) + '\063' + chr(0b110010 + 0o2) + chr(1561 - 1509), 34009 - 34001), nzTpIcepk0o8(chr(0b110 + 0o52) + chr(0b1101111) + '\x34' + '\x36', 0o10), nzTpIcepk0o8('\060' + chr(0b1011001 + 0o26) + chr(1492 - 1443) + '\067' + '\062', ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(50) + chr(0b101 + 0o54) + chr(49), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b101 + 0o61) + chr(0b110001), 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\063' + '\060', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b101011 + 0o6) + chr(53) + chr(49), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b100111 + 0o13) + '\x33' + '\x36', 36428 - 36420), nzTpIcepk0o8(chr(0b100100 + 0o14) + '\x6f' + chr(0b110010) + chr(0b110101) + chr(0b10101 + 0o41), 0b1000), nzTpIcepk0o8(chr(0b100111 + 0o11) + '\157' + chr(0b110010) + chr(0b110010) + '\065', 0o10), nzTpIcepk0o8(chr(0b100 + 0o54) + '\x6f' + chr(53) + chr(1288 - 1235), ord("\x08")), nzTpIcepk0o8(chr(1130 - 1082) + chr(111) + chr(51) + chr(0b110010) + chr(0b110111), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110010) + '\x37' + '\x31', 0o10), nzTpIcepk0o8(chr(122 - 74) + '\157' + chr(51) + chr(0b110111) + '\x33', 0b1000), nzTpIcepk0o8('\x30' + chr(0b101010 + 0o105) + chr(51) + chr(0b101 + 0o61) + '\x32', 19219 - 19211), nzTpIcepk0o8('\x30' + chr(111) + '\062' + chr(0b1010 + 0o47) + chr(49), 8), nzTpIcepk0o8('\x30' + chr(8856 - 8745) + chr(50) + '\062' + chr(0b110001), 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(647 - 598) + '\062' + '\063', 0o10), nzTpIcepk0o8(chr(48) + '\157' + '\062' + '\x37' + '\x35', 3223 - 3215), nzTpIcepk0o8('\x30' + chr(7485 - 7374) + chr(0b110000 + 0o1) + chr(0b11000 + 0o36) + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(0b1101111) + chr(0b100100 + 0o17) + '\x33' + chr(0b11000 + 0o34), 0b1000), nzTpIcepk0o8(chr(846 - 798) + '\x6f' + chr(0b1000 + 0o52) + chr(103 - 49) + '\062', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b100111 + 0o14) + chr(0b110111) + chr(1320 - 1268), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(51), 0o10), nzTpIcepk0o8('\060' + chr(0b11011 + 0o124) + chr(51) + '\x31' + chr(52), 0o10), nzTpIcepk0o8(chr(0b101110 + 0o2) + '\157' + chr(1798 - 1748) + chr(1997 - 1948) + chr(1038 - 986), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110001) + '\x30' + '\062', 0b1000), nzTpIcepk0o8(chr(698 - 650) + chr(0b1101111) + chr(0b110011) + chr(49) + chr(965 - 917), 0b1000), nzTpIcepk0o8(chr(0b10100 + 0o34) + '\x6f' + chr(49) + '\061' + '\x33', 193 - 185), nzTpIcepk0o8(chr(48) + chr(5211 - 5100) + chr(0b10011 + 0o37) + chr(54) + chr(815 - 765), 8), nzTpIcepk0o8(chr(1484 - 1436) + chr(111) + chr(2436 - 2385) + chr(0b110101) + '\x33', 13463 - 13455), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110010) + chr(0b101111 + 0o3) + chr(0b1000 + 0o53), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(459 - 409) + chr(50) + chr(1661 - 1607), 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(0b110011) + '\x36' + chr(54), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(184 - 136) + '\157' + chr(0b11110 + 0o27) + chr(2001 - 1953), 54105 - 54097)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x88'), '\144' + '\145' + '\143' + '\x6f' + chr(0b1100010 + 0o2) + '\145')(chr(0b1110101) + chr(11105 - 10989) + '\146' + chr(45) + chr(0b110001 + 0o7)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def T0nX9PKgSWX4(hXMPsSrOQzbh):
hXMPsSrOQzbh.DgPzdyeP62dT = FyZE4zrPCXjA.Graph()
with roI3spqORKae(hXMPsSrOQzbh._graph, roI3spqORKae(ES5oEprVxulp(b'\xc7C\x11\n\xa7\xe6\x85S\x16\xfd'), chr(8290 - 8190) + chr(101) + chr(99) + chr(1352 - 1241) + '\144' + '\145')(chr(7437 - 7320) + '\x74' + chr(0b110000 + 0o66) + '\x2d' + chr(2641 - 2585)))():
hXMPsSrOQzbh.ifKyDND3ENDe = FyZE4zrPCXjA.DezdrUdcfjvz(FyZE4zrPCXjA.float32, (hXMPsSrOQzbh.hlKRiZyqMb3U, hXMPsSrOQzbh.KaqN1m3tFi2T, hXMPsSrOQzbh.LGqOPpuhore_, hXMPsSrOQzbh.qXSsKe_JWQLo))
TtzqJLqe_ecy = hXMPsSrOQzbh.build_alexnet_weights()
hXMPsSrOQzbh.ue_raBX_mG1y = hXMPsSrOQzbh.build_alexnet(TtzqJLqe_ecy)
hXMPsSrOQzbh.TFR26HxNlH5s = hXMPsSrOQzbh.build_alexnet(TtzqJLqe_ecy, output_layer=hXMPsSrOQzbh.fKG1GSv57ozo)
hXMPsSrOQzbh.qfJ1M6ynGKsn = nzTpIcepk0o8('\060' + '\157' + '\x31', ord("\x08")) |
BerkeleyAutomation/perception | perception/cnn.py | AlexNet.open_session | def open_session(self):
""" Open tensorflow session. Exposed for memory management. """
with self._graph.as_default():
init = tf.initialize_all_variables()
self._sess = tf.Session()
self._sess.run(init) | python | def open_session(self):
""" Open tensorflow session. Exposed for memory management. """
with self._graph.as_default():
init = tf.initialize_all_variables()
self._sess = tf.Session()
self._sess.run(init) | [
"def",
"open_session",
"(",
"self",
")",
":",
"with",
"self",
".",
"_graph",
".",
"as_default",
"(",
")",
":",
"init",
"=",
"tf",
".",
"initialize_all_variables",
"(",
")",
"self",
".",
"_sess",
"=",
"tf",
".",
"Session",
"(",
")",
"self",
".",
"_sess",
".",
"run",
"(",
"init",
")"
] | Open tensorflow session. Exposed for memory management. | [
"Open",
"tensorflow",
"session",
".",
"Exposed",
"for",
"memory",
"management",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/cnn.py#L141-L146 | train | Open tensorflow session. Exposed for memory management. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlC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,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + chr(111) + '\062' + chr(0b1010 + 0o54) + chr(1860 - 1808), 58889 - 58881), nzTpIcepk0o8(chr(48) + chr(0b1011001 + 0o26) + chr(53 - 2) + '\x34' + '\065', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(49) + chr(0b110010) + chr(1069 - 1020), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + '\x33' + chr(405 - 350) + '\063', 0b1000), nzTpIcepk0o8('\060' + chr(111) + chr(582 - 533) + chr(2638 - 2586) + chr(432 - 384), 30210 - 30202), nzTpIcepk0o8(chr(48) + '\157' + '\x32' + chr(0b101000 + 0o11), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b10011 + 0o40) + chr(48) + '\x31', 22921 - 22913), nzTpIcepk0o8('\x30' + chr(0b1010100 + 0o33) + chr(0b11000 + 0o32) + chr(843 - 795) + chr(49), 0o10), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(111) + '\063' + chr(0b110010) + chr(2415 - 2361), 0o10), nzTpIcepk0o8(chr(0b11110 + 0o22) + '\x6f' + '\x37' + '\063', 0b1000), nzTpIcepk0o8('\060' + chr(11938 - 11827) + '\063' + '\x36' + chr(0b100101 + 0o13), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(4539 - 4428) + '\065' + chr(0b110101), 0b1000), nzTpIcepk0o8('\x30' + chr(9245 - 9134) + chr(51) + '\x34' + '\x31', 36337 - 36329), nzTpIcepk0o8(chr(0b1111 + 0o41) + '\x6f' + chr(0b1111 + 0o42) + chr(53), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(51) + chr(0b110101) + chr(0b110001), 0o10), nzTpIcepk0o8('\060' + chr(415 - 304) + chr(1878 - 1829) + chr(0b100001 + 0o20) + chr(0b110100), 23922 - 23914), nzTpIcepk0o8(chr(0b101001 + 0o7) + chr(372 - 261) + '\060', 0o10), nzTpIcepk0o8(chr(48) + '\157' + chr(914 - 864) + chr(1434 - 1380) + '\x34', 8), nzTpIcepk0o8('\x30' + chr(3057 - 2946) + chr(50) + chr(0b110100) + chr(51), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b1111 + 0o42) + chr(0b1101 + 0o51) + chr(0b1110 + 0o45), ord("\x08")), nzTpIcepk0o8(chr(1816 - 1768) + chr(0b1101111) + chr(593 - 544) + chr(431 - 382) + chr(0b11111 + 0o25), 8), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110011) + chr(1441 - 1386) + chr(0b111 + 0o54), 8), nzTpIcepk0o8(chr(0b10011 + 0o35) + chr(10200 - 10089) + chr(0b110001) + chr(0b100100 + 0o16) + chr(0b110011), 8949 - 8941), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x33' + chr(50) + '\x37', 35454 - 35446), nzTpIcepk0o8('\x30' + chr(111) + '\x33' + chr(0b100010 + 0o20) + chr(51), 0o10), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(11084 - 10973) + chr(448 - 398) + chr(0b110011) + chr(51), 0b1000), nzTpIcepk0o8(chr(1653 - 1605) + chr(111) + '\063' + chr(561 - 510) + '\x31', 0o10), nzTpIcepk0o8(chr(0b101111 + 0o1) + chr(11531 - 11420) + chr(1058 - 1009) + chr(2138 - 2086) + chr(53), 6583 - 6575), nzTpIcepk0o8('\x30' + '\157' + chr(49) + chr(52) + chr(1900 - 1848), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110011) + '\x33', 0o10), nzTpIcepk0o8('\060' + chr(111) + '\062' + chr(0b10101 + 0o37) + chr(0b110110), 0o10), nzTpIcepk0o8(chr(0b101001 + 0o7) + chr(0b1101111) + chr(168 - 119) + '\x34', 0b1000), nzTpIcepk0o8(chr(48) + '\157' + chr(2575 - 2524) + chr(0b11011 + 0o30) + chr(1568 - 1518), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + '\062' + chr(0b101110 + 0o4) + '\065', 0o10), nzTpIcepk0o8('\060' + chr(111) + '\x33', 0b1000), nzTpIcepk0o8(chr(0b10 + 0o56) + chr(111) + chr(0b110001) + '\060' + chr(0b10 + 0o65), 0o10), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(6414 - 6303) + '\063' + chr(77 - 23) + chr(52), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(1063 - 1012) + chr(0b110010) + chr(107 - 58), 0o10), nzTpIcepk0o8('\060' + chr(2779 - 2668) + chr(0b110001) + chr(54) + '\x32', 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\065', 34681 - 34673)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(0b1011 + 0o144) + chr(0b0 + 0o65) + chr(0b1100 + 0o44), ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x9a'), chr(5381 - 5281) + '\x65' + chr(99) + chr(111) + chr(100) + '\145')('\x75' + '\164' + chr(0b1011110 + 0o10) + chr(45) + chr(0b110011 + 0o5)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def wfRtn48vIOrq(hXMPsSrOQzbh):
with roI3spqORKae(hXMPsSrOQzbh._graph, roI3spqORKae(ES5oEprVxulp(b'\xd5\x96\x0e\x9f\x05w\xa0\xf4\xbaO'), '\144' + chr(0b111000 + 0o55) + chr(99) + chr(111) + '\x64' + chr(0b1011001 + 0o14))(chr(6003 - 5886) + chr(10279 - 10163) + chr(102) + chr(45) + '\x38'))():
pp8xR9RCeTI4 = FyZE4zrPCXjA.initialize_all_variables()
hXMPsSrOQzbh.gMrFjmV2ELQ2 = FyZE4zrPCXjA.Session()
roI3spqORKae(hXMPsSrOQzbh._sess, roI3spqORKae(ES5oEprVxulp(b'\xc5\x8b\x01\xb4)u\x83\xd0\x9c_\x8at'), chr(100) + chr(1239 - 1138) + '\143' + chr(0b1101111) + chr(3235 - 3135) + chr(0b1011100 + 0o11))('\165' + '\164' + chr(0b100101 + 0o101) + chr(45) + chr(0b111000)))(pp8xR9RCeTI4) |
BerkeleyAutomation/perception | perception/cnn.py | AlexNet.close_session | def close_session(self):
""" Close tensorflow session. Exposes for memory management. """
with self._graph.as_default():
self._sess.close()
self._sess = None | python | def close_session(self):
""" Close tensorflow session. Exposes for memory management. """
with self._graph.as_default():
self._sess.close()
self._sess = None | [
"def",
"close_session",
"(",
"self",
")",
":",
"with",
"self",
".",
"_graph",
".",
"as_default",
"(",
")",
":",
"self",
".",
"_sess",
".",
"close",
"(",
")",
"self",
".",
"_sess",
"=",
"None"
] | Close tensorflow session. Exposes for memory management. | [
"Close",
"tensorflow",
"session",
".",
"Exposes",
"for",
"memory",
"management",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/cnn.py#L148-L152 | train | Closes tensorflow session. Exposes for memory management. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOVzf,YikXQdxs3VoO,UBvEeZympYSz,mRTjFWUmjl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y29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + '\157' + '\x33' + chr(1700 - 1652) + chr(51), ord("\x08")), nzTpIcepk0o8(chr(1801 - 1753) + '\157' + '\x32' + chr(470 - 420) + chr(51), 0b1000), nzTpIcepk0o8(chr(48) + chr(11858 - 11747) + '\063' + '\061' + '\x37', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(51) + chr(53) + chr(1216 - 1165), ord("\x08")), nzTpIcepk0o8(chr(0b11100 + 0o24) + chr(111) + chr(2238 - 2188) + '\063' + '\x30', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(6603 - 6492) + chr(0b110011) + chr(2186 - 2132) + chr(0b110010), 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110001 + 0o0) + '\065' + '\x31', 57951 - 57943), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(0b1100100 + 0o13) + chr(0b110001) + chr(0b101100 + 0o11), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + '\063' + '\x33' + chr(0b101001 + 0o13), 0b1000), nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(0b1101111) + '\062' + chr(0b110011) + '\066', 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + '\062' + chr(2510 - 2457), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b1001 + 0o50) + chr(2450 - 2396) + chr(0b110000), 0o10), nzTpIcepk0o8('\060' + '\x6f' + '\x32' + chr(0b110100) + chr(50), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x32' + chr(2163 - 2115), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(51) + chr(0b10000 + 0o42) + '\x30', ord("\x08")), nzTpIcepk0o8(chr(286 - 238) + chr(111) + '\x31' + '\x37' + chr(50), ord("\x08")), nzTpIcepk0o8(chr(2161 - 2113) + '\157' + '\061' + chr(52) + chr(0b11101 + 0o25), ord("\x08")), nzTpIcepk0o8(chr(1841 - 1793) + '\x6f' + '\061' + chr(996 - 948), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110011) + chr(735 - 681) + '\x33', ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(50) + '\067' + '\x37', 0o10), nzTpIcepk0o8(chr(2004 - 1956) + '\x6f' + chr(49) + chr(1497 - 1443) + '\063', ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110100) + chr(0b110100), 0b1000), nzTpIcepk0o8(chr(48) + '\157' + '\x33' + '\x31' + chr(0b1110 + 0o43), ord("\x08")), nzTpIcepk0o8('\x30' + chr(1618 - 1507) + '\067' + chr(412 - 359), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\061' + chr(0b110001) + '\064', 0b1000), nzTpIcepk0o8(chr(1869 - 1821) + chr(111) + chr(0b10011 + 0o37) + chr(51) + chr(1349 - 1294), 62388 - 62380), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110010 + 0o1) + '\x34' + '\060', 1769 - 1761), nzTpIcepk0o8(chr(48) + '\157' + chr(0b101 + 0o54) + chr(50), ord("\x08")), nzTpIcepk0o8(chr(0b10011 + 0o35) + chr(0b1101111) + chr(199 - 148) + '\x31' + chr(51), ord("\x08")), nzTpIcepk0o8(chr(902 - 854) + chr(111) + chr(0b10111 + 0o34) + chr(0b1000 + 0o57) + '\x32', 0o10), nzTpIcepk0o8(chr(0b101010 + 0o6) + chr(1293 - 1182) + '\061' + chr(54) + '\x32', 36742 - 36734), nzTpIcepk0o8(chr(48) + chr(7609 - 7498) + '\061' + '\x32' + '\x36', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(2271 - 2221) + chr(519 - 471), 8), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110001) + chr(0b110001) + chr(0b110100), 8), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(1689 - 1639) + chr(0b110000 + 0o2) + '\x37', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(3075 - 2964) + chr(50) + '\x33' + '\062', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b11011 + 0o124) + chr(0b110011) + chr(0b101010 + 0o13) + chr(0b110000), 0b1000), nzTpIcepk0o8(chr(48) + '\157' + '\x32' + '\x37' + chr(0b1001 + 0o56), 8), nzTpIcepk0o8('\x30' + chr(111) + chr(474 - 420) + chr(0b1010 + 0o46), 0b1000), nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(111) + chr(50) + '\062' + chr(0b10100 + 0o35), 19658 - 19650)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110011 + 0o2) + chr(0b100101 + 0o13), ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xed'), chr(100) + '\x65' + chr(3021 - 2922) + '\157' + chr(100) + chr(1592 - 1491))('\165' + chr(116) + '\146' + chr(0b100101 + 0o10) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def RPtpDNmDe2Ja(hXMPsSrOQzbh):
with roI3spqORKae(hXMPsSrOQzbh._graph, roI3spqORKae(ES5oEprVxulp(b'\xa2\xe0\x90\x8f\xfd\x94\x08x\xb0\xea'), chr(8448 - 8348) + chr(3228 - 3127) + '\x63' + chr(0b1101111) + chr(100) + '\x65')(chr(0b1011110 + 0o27) + chr(0b1110100) + '\x66' + '\055' + '\070'))():
roI3spqORKae(hXMPsSrOQzbh._sess, roI3spqORKae(ES5oEprVxulp(b'\x99\xf6\xbe\xdc\xdb\x91\x0f4\x89\xfa-\x1a'), chr(5551 - 5451) + chr(7856 - 7755) + '\x63' + chr(0b1101111) + chr(100) + chr(101))(chr(0b10101 + 0o140) + chr(116) + '\146' + chr(0b100101 + 0o10) + chr(56)))()
hXMPsSrOQzbh.gMrFjmV2ELQ2 = None |
BerkeleyAutomation/perception | perception/cnn.py | AlexNet.predict | def predict(self, image_arr, featurize=False):
""" Predict a set of images in batches.
Parameters
----------
image_arr : NxHxWxC :obj:`numpy.ndarray`
input set of images in a num_images x image height x image width x image channels array (must match parameters of network)
featurize : bool
whether or not to use the featurization layer or classification output layer
Returns
-------
:obj:`numpy.ndarray`
num_images x feature_dim containing the output values for each input image
"""
# setup prediction
num_images = image_arr.shape[0]
output_arr = None
# predict by filling in image array in batches
close_sess = False
if not self._initialized and self._dynamic_load:
self._load()
with self._graph.as_default():
if self._sess is None:
close_sess = True
self.open_session()
i = 0
while i < num_images:
dim = min(self._batch_size, num_images-i)
cur_ind = i
end_ind = cur_ind + dim
self._input_arr[:dim,:,:,:] = image_arr[cur_ind:end_ind,:,:,:] - self._mean
if featurize:
output = self._sess.run(self._feature_tensor,
feed_dict={self._input_node: self._input_arr})
else:
output = self._sess.run(self._output_tensor,
feed_dict={self._input_node: self._input_arr})
if output_arr is None:
output_arr = output
else:
output_arr = np.r_[output_arr, output]
i = end_ind
if close_sess:
self.close_session()
return output_arr[:num_images,...] | python | def predict(self, image_arr, featurize=False):
""" Predict a set of images in batches.
Parameters
----------
image_arr : NxHxWxC :obj:`numpy.ndarray`
input set of images in a num_images x image height x image width x image channels array (must match parameters of network)
featurize : bool
whether or not to use the featurization layer or classification output layer
Returns
-------
:obj:`numpy.ndarray`
num_images x feature_dim containing the output values for each input image
"""
# setup prediction
num_images = image_arr.shape[0]
output_arr = None
# predict by filling in image array in batches
close_sess = False
if not self._initialized and self._dynamic_load:
self._load()
with self._graph.as_default():
if self._sess is None:
close_sess = True
self.open_session()
i = 0
while i < num_images:
dim = min(self._batch_size, num_images-i)
cur_ind = i
end_ind = cur_ind + dim
self._input_arr[:dim,:,:,:] = image_arr[cur_ind:end_ind,:,:,:] - self._mean
if featurize:
output = self._sess.run(self._feature_tensor,
feed_dict={self._input_node: self._input_arr})
else:
output = self._sess.run(self._output_tensor,
feed_dict={self._input_node: self._input_arr})
if output_arr is None:
output_arr = output
else:
output_arr = np.r_[output_arr, output]
i = end_ind
if close_sess:
self.close_session()
return output_arr[:num_images,...] | [
"def",
"predict",
"(",
"self",
",",
"image_arr",
",",
"featurize",
"=",
"False",
")",
":",
"# setup prediction",
"num_images",
"=",
"image_arr",
".",
"shape",
"[",
"0",
"]",
"output_arr",
"=",
"None",
"# predict by filling in image array in batches",
"close_sess",
"=",
"False",
"if",
"not",
"self",
".",
"_initialized",
"and",
"self",
".",
"_dynamic_load",
":",
"self",
".",
"_load",
"(",
")",
"with",
"self",
".",
"_graph",
".",
"as_default",
"(",
")",
":",
"if",
"self",
".",
"_sess",
"is",
"None",
":",
"close_sess",
"=",
"True",
"self",
".",
"open_session",
"(",
")",
"i",
"=",
"0",
"while",
"i",
"<",
"num_images",
":",
"dim",
"=",
"min",
"(",
"self",
".",
"_batch_size",
",",
"num_images",
"-",
"i",
")",
"cur_ind",
"=",
"i",
"end_ind",
"=",
"cur_ind",
"+",
"dim",
"self",
".",
"_input_arr",
"[",
":",
"dim",
",",
":",
",",
":",
",",
":",
"]",
"=",
"image_arr",
"[",
"cur_ind",
":",
"end_ind",
",",
":",
",",
":",
",",
":",
"]",
"-",
"self",
".",
"_mean",
"if",
"featurize",
":",
"output",
"=",
"self",
".",
"_sess",
".",
"run",
"(",
"self",
".",
"_feature_tensor",
",",
"feed_dict",
"=",
"{",
"self",
".",
"_input_node",
":",
"self",
".",
"_input_arr",
"}",
")",
"else",
":",
"output",
"=",
"self",
".",
"_sess",
".",
"run",
"(",
"self",
".",
"_output_tensor",
",",
"feed_dict",
"=",
"{",
"self",
".",
"_input_node",
":",
"self",
".",
"_input_arr",
"}",
")",
"if",
"output_arr",
"is",
"None",
":",
"output_arr",
"=",
"output",
"else",
":",
"output_arr",
"=",
"np",
".",
"r_",
"[",
"output_arr",
",",
"output",
"]",
"i",
"=",
"end_ind",
"if",
"close_sess",
":",
"self",
".",
"close_session",
"(",
")",
"return",
"output_arr",
"[",
":",
"num_images",
",",
"...",
"]"
] | Predict a set of images in batches.
Parameters
----------
image_arr : NxHxWxC :obj:`numpy.ndarray`
input set of images in a num_images x image height x image width x image channels array (must match parameters of network)
featurize : bool
whether or not to use the featurization layer or classification output layer
Returns
-------
:obj:`numpy.ndarray`
num_images x feature_dim containing the output values for each input image | [
"Predict",
"a",
"set",
"of",
"images",
"in",
"batches",
"."
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/cnn.py#L154-L202 | train | Predict a set of images in batches. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1A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WCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + '\157' + chr(0b110001) + '\063', 35088 - 35080), nzTpIcepk0o8(chr(0b110000) + chr(0b1010101 + 0o32) + chr(2166 - 2116) + chr(1078 - 1029) + chr(0b110000), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(49) + '\x33' + '\060', 0b1000), nzTpIcepk0o8(chr(0b111 + 0o51) + chr(8600 - 8489) + chr(0b10011 + 0o36) + '\x34' + chr(0b110010), 0o10), nzTpIcepk0o8(chr(634 - 586) + chr(7339 - 7228) + '\x31' + '\061' + chr(1788 - 1740), 0o10), nzTpIcepk0o8(chr(48) + '\157' + chr(0b1010 + 0o47) + chr(0b11010 + 0o27) + chr(0b110111), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(50) + '\062' + chr(2768 - 2715), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(2562 - 2510) + chr(0b110100), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\063' + chr(1843 - 1790) + chr(0b110000), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b1110 + 0o44) + chr(927 - 878) + '\x33', 0o10), nzTpIcepk0o8(chr(48) + chr(111) + '\062' + chr(48), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + chr(1609 - 1559) + '\062' + chr(1861 - 1807), ord("\x08")), nzTpIcepk0o8(chr(1952 - 1904) + '\x6f' + chr(52) + chr(0b101001 + 0o12), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(7225 - 7114) + chr(1646 - 1595) + chr(50) + chr(0b101101 + 0o7), 0o10), nzTpIcepk0o8(chr(0b10010 + 0o36) + chr(111) + chr(0b1001 + 0o51) + chr(357 - 305) + chr(367 - 317), 0b1000), nzTpIcepk0o8(chr(66 - 18) + chr(111) + chr(0b101011 + 0o6) + '\062' + chr(53), ord("\x08")), nzTpIcepk0o8(chr(0b101000 + 0o10) + chr(0b1000100 + 0o53) + '\x33' + chr(1520 - 1467) + chr(0b110101), ord("\x08")), nzTpIcepk0o8(chr(697 - 649) + chr(7528 - 7417) + chr(50) + chr(48) + chr(0b1 + 0o60), 29992 - 29984), nzTpIcepk0o8('\060' + chr(4138 - 4027) + chr(49) + chr(0b110001) + chr(0b100101 + 0o17), 50415 - 50407), nzTpIcepk0o8('\060' + chr(0b100100 + 0o113) + chr(50) + chr(50) + chr(0b11 + 0o63), 8), nzTpIcepk0o8(chr(1483 - 1435) + chr(111) + chr(0b110101), 59782 - 59774), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(55) + '\x36', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(12168 - 12057) + '\066' + '\066', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b11110 + 0o24) + '\x30' + chr(1668 - 1618), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(51) + chr(0b110100), 8259 - 8251), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(51) + '\065' + chr(0b110011), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(51) + '\067', 0b1000), nzTpIcepk0o8(chr(1697 - 1649) + chr(11561 - 11450) + '\066' + '\064', 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(51) + '\063' + '\x35', 65403 - 65395), nzTpIcepk0o8(chr(1869 - 1821) + '\157' + '\063' + chr(0b101 + 0o57) + chr(0b100110 + 0o12), 42037 - 42029), nzTpIcepk0o8('\060' + chr(7521 - 7410) + chr(0b1001 + 0o55) + chr(55), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(2454 - 2404) + chr(0b111 + 0o54) + chr(413 - 362), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b101001 + 0o106) + '\063' + chr(0b11100 + 0o27) + chr(51), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(349 - 299) + chr(1662 - 1612) + '\x31', ord("\x08")), nzTpIcepk0o8('\x30' + chr(4011 - 3900) + chr(961 - 911) + chr(0b11000 + 0o30) + chr(0b100010 + 0o17), 8), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(3025 - 2970), ord("\x08")), nzTpIcepk0o8(chr(2253 - 2205) + chr(0b1000010 + 0o55) + chr(0b110110), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(1498 - 1444) + chr(0b110100), 8), nzTpIcepk0o8(chr(796 - 748) + chr(0b1101111) + chr(0b110011) + '\x36' + chr(1760 - 1708), 11526 - 11518), nzTpIcepk0o8(chr(0b101000 + 0o10) + chr(111) + chr(947 - 893) + chr(1473 - 1420), 20321 - 20313)][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + chr(0b1101111) + '\065' + chr(0b110000), 59269 - 59261)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'%'), chr(0b10010 + 0o122) + chr(0b1100101) + '\143' + chr(665 - 554) + chr(0b1100100) + '\145')('\165' + '\x74' + '\146' + '\055' + chr(0b111000)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def lm05ORHUIr2J(hXMPsSrOQzbh, elYnlWfgjJ0T, LCUmzNq2PDJk=nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b10100 + 0o34), 61628 - 61620)):
tV2Tkt07h3x3 = elYnlWfgjJ0T.lhbM092AFW8f[nzTpIcepk0o8(chr(48) + chr(0b10001 + 0o136) + chr(1700 - 1652), 8)]
fzDkgPmLnXLl = None
Uxe8_3AcUFDH = nzTpIcepk0o8(chr(1671 - 1623) + chr(0b1101111) + chr(1028 - 980), 8)
if not roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'z\xee\x12S\x05y\xecJ\xaf\xc0c\xf8'), chr(100) + '\145' + chr(99) + chr(0b1011 + 0o144) + chr(0b1100100) + '\x65')(chr(0b1110101) + chr(3433 - 3317) + chr(7181 - 7079) + chr(45) + chr(0b111000))) and roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'T\xec!\x0c)"\xfcG\xb7\xe7\x7f\xf7G'), '\x64' + chr(0b1100101) + chr(0b1100011) + chr(111) + chr(7526 - 7426) + chr(9280 - 9179))('\165' + chr(7459 - 7343) + chr(0b1011000 + 0o16) + chr(45) + '\070')):
roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b']\xc5\x1a\x0f\x04\r\xe6e\xa9\xcfg\xde'), chr(8334 - 8234) + '\x65' + '\x63' + '\157' + chr(4439 - 4339) + chr(0b101 + 0o140))(chr(0b1110101) + '\x74' + '\146' + chr(1696 - 1651) + chr(2189 - 2133)))()
with roI3spqORKae(hXMPsSrOQzbh._graph, roI3spqORKae(ES5oEprVxulp(b'j\xfb\x07\x06-)\xf4Q\x84\xff'), '\x64' + chr(3351 - 3250) + chr(0b1100011) + chr(111) + chr(0b110000 + 0o64) + chr(101))('\165' + chr(0b1110100) + chr(0b1000111 + 0o37) + chr(0b11010 + 0o23) + chr(840 - 784)))():
if roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'l\xc5*$""\xc3\x16\xad\xc7A\xa4'), chr(0b1100100) + '\145' + '\x63' + chr(0b1101111) + '\x64' + '\145')(chr(0b1110101) + '\164' + chr(102) + '\x2d' + chr(0b100111 + 0o21))) is None:
Uxe8_3AcUFDH = nzTpIcepk0o8(chr(2254 - 2206) + '\157' + chr(1136 - 1087), 0b1000)
roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'd\xf8=\x0c\x17<\xf0W\x9b\xe2\x7f\xf8'), chr(100) + '\x65' + '\x63' + '\x6f' + chr(573 - 473) + '\145')('\165' + chr(0b1110100) + '\x66' + chr(596 - 551) + chr(0b111000)))()
ZlbFMSG8gCoF = nzTpIcepk0o8(chr(0b101110 + 0o2) + chr(0b100100 + 0o113) + chr(0b110000), 8)
while ZlbFMSG8gCoF < tV2Tkt07h3x3:
L5CH4CVaTec6 = XURpmPuEWCNF(hXMPsSrOQzbh.hlKRiZyqMb3U, tV2Tkt07h3x3 - ZlbFMSG8gCoF)
EWNJVmPZBCkE = ZlbFMSG8gCoF
UbMQOlfEVLfP = EWNJVmPZBCkE + L5CH4CVaTec6
hXMPsSrOQzbh.BC2TQIEMzNVj[:L5CH4CVaTec6, :, :, :] = elYnlWfgjJ0T[EWNJVmPZBCkE:UbMQOlfEVLfP, :, :, :] - hXMPsSrOQzbh.oO9mOHMYQJfV
if LCUmzNq2PDJk:
toKQXlEvBKaK = hXMPsSrOQzbh._sess.qnPOIdBQJdzY(hXMPsSrOQzbh.TFR26HxNlH5s, feed_dict={hXMPsSrOQzbh.ifKyDND3ENDe: hXMPsSrOQzbh.BC2TQIEMzNVj})
else:
toKQXlEvBKaK = hXMPsSrOQzbh._sess.qnPOIdBQJdzY(hXMPsSrOQzbh.ue_raBX_mG1y, feed_dict={hXMPsSrOQzbh.ifKyDND3ENDe: hXMPsSrOQzbh.BC2TQIEMzNVj})
if fzDkgPmLnXLl is None:
fzDkgPmLnXLl = toKQXlEvBKaK
else:
fzDkgPmLnXLl = nDF4gVNx0u9Q.r_[fzDkgPmLnXLl, toKQXlEvBKaK]
ZlbFMSG8gCoF = UbMQOlfEVLfP
if Uxe8_3AcUFDH:
roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'h\xe47\x11-\x10\xe6A\x9b\xf8y\xf9M'), chr(2153 - 2053) + '\x65' + chr(99) + chr(8376 - 8265) + chr(4103 - 4003) + chr(0b10011 + 0o122))('\x75' + '\164' + chr(0b1100110) + chr(45) + '\x38'))()
return fzDkgPmLnXLl[:tV2Tkt07h3x3, ...] |
BerkeleyAutomation/perception | perception/cnn.py | AlexNet.build_alexnet_weights | def build_alexnet_weights(self):
""" Build a set of convnet weights for AlexNet """
net_data = self._net_data
#conv1
#conv(11, 11, 96, 4, 4, padding='VALID', name='conv1')
k_h = 11; k_w = 11; c_o = 96; s_h = 4; s_w = 4
conv1W = tf.Variable(net_data["conv1"][0])
conv1b = tf.Variable(net_data["conv1"][1])
#conv2
#conv(5, 5, 256, 1, 1, group=2, name='conv2')
k_h = 5; k_w = 5; c_o = 256; s_h = 1; s_w = 1; group = 2
conv2W = tf.Variable(net_data["conv2"][0])
conv2b = tf.Variable(net_data["conv2"][1])
#conv3
#conv(3, 3, 384, 1, 1, name='conv3')
k_h = 3; k_w = 3; c_o = 384; s_h = 1; s_w = 1; group = 1
conv3W = tf.Variable(net_data["conv3"][0])
conv3b = tf.Variable(net_data["conv3"][1])
#conv4
#conv(3, 3, 384, 1, 1, group=2, name='conv4')
k_h = 3; k_w = 3; c_o = 384; s_h = 1; s_w = 1; group = 2
conv4W = tf.Variable(net_data["conv4"][0])
conv4b = tf.Variable(net_data["conv4"][1])
#conv5
#conv(3, 3, 256, 1, 1, group=2, name='conv5')
k_h = 3; k_w = 3; c_o = 256; s_h = 1; s_w = 1; group = 2
conv5W = tf.Variable(net_data["conv5"][0])
conv5b = tf.Variable(net_data["conv5"][1])
#fc6
#fc(4096, name='fc6')
fc6_in_size = net_data["fc6"][0].shape[0]
fc6_out_size = net_data["fc6"][0].shape[1]
fc6W = tf.Variable(net_data["fc6"][0])
fc6b = tf.Variable(net_data["fc6"][1])
#fc7
#fc(4096, name='fc7')
fc7_in_size = fc6_out_size
fc7_out_size = net_data["fc7"][0].shape[1]
fc7W = tf.Variable(net_data["fc7"][0])
fc7b = tf.Variable(net_data["fc7"][1])
#fc8
#fc(num_cats, relu=False, name='fc8')
fc8_in_size = fc7_out_size
fc8_out_size = self._out_size
fc8W = tf.Variable(tf.truncated_normal([fc8_in_size, fc8_out_size],
stddev=0.01,
seed=None))
fc8b = tf.Variable(tf.constant(0.0, shape=[fc8_out_size]))
# make return object
weights = AlexNetWeights()
weights.conv1W = conv1W
weights.conv1b = conv1b
weights.conv2W = conv2W
weights.conv2b = conv2b
weights.conv3W = conv3W
weights.conv3b = conv3b
weights.conv4W = conv4W
weights.conv4b = conv4b
weights.conv5W = conv5W
weights.conv5b = conv5b
weights.fc6W = fc6W
weights.fc6b = fc6b
weights.fc7W = fc7W
weights.fc7b = fc7b
weights.fc8W = fc8W
weights.fc8b = fc8b
return weights | python | def build_alexnet_weights(self):
""" Build a set of convnet weights for AlexNet """
net_data = self._net_data
#conv1
#conv(11, 11, 96, 4, 4, padding='VALID', name='conv1')
k_h = 11; k_w = 11; c_o = 96; s_h = 4; s_w = 4
conv1W = tf.Variable(net_data["conv1"][0])
conv1b = tf.Variable(net_data["conv1"][1])
#conv2
#conv(5, 5, 256, 1, 1, group=2, name='conv2')
k_h = 5; k_w = 5; c_o = 256; s_h = 1; s_w = 1; group = 2
conv2W = tf.Variable(net_data["conv2"][0])
conv2b = tf.Variable(net_data["conv2"][1])
#conv3
#conv(3, 3, 384, 1, 1, name='conv3')
k_h = 3; k_w = 3; c_o = 384; s_h = 1; s_w = 1; group = 1
conv3W = tf.Variable(net_data["conv3"][0])
conv3b = tf.Variable(net_data["conv3"][1])
#conv4
#conv(3, 3, 384, 1, 1, group=2, name='conv4')
k_h = 3; k_w = 3; c_o = 384; s_h = 1; s_w = 1; group = 2
conv4W = tf.Variable(net_data["conv4"][0])
conv4b = tf.Variable(net_data["conv4"][1])
#conv5
#conv(3, 3, 256, 1, 1, group=2, name='conv5')
k_h = 3; k_w = 3; c_o = 256; s_h = 1; s_w = 1; group = 2
conv5W = tf.Variable(net_data["conv5"][0])
conv5b = tf.Variable(net_data["conv5"][1])
#fc6
#fc(4096, name='fc6')
fc6_in_size = net_data["fc6"][0].shape[0]
fc6_out_size = net_data["fc6"][0].shape[1]
fc6W = tf.Variable(net_data["fc6"][0])
fc6b = tf.Variable(net_data["fc6"][1])
#fc7
#fc(4096, name='fc7')
fc7_in_size = fc6_out_size
fc7_out_size = net_data["fc7"][0].shape[1]
fc7W = tf.Variable(net_data["fc7"][0])
fc7b = tf.Variable(net_data["fc7"][1])
#fc8
#fc(num_cats, relu=False, name='fc8')
fc8_in_size = fc7_out_size
fc8_out_size = self._out_size
fc8W = tf.Variable(tf.truncated_normal([fc8_in_size, fc8_out_size],
stddev=0.01,
seed=None))
fc8b = tf.Variable(tf.constant(0.0, shape=[fc8_out_size]))
# make return object
weights = AlexNetWeights()
weights.conv1W = conv1W
weights.conv1b = conv1b
weights.conv2W = conv2W
weights.conv2b = conv2b
weights.conv3W = conv3W
weights.conv3b = conv3b
weights.conv4W = conv4W
weights.conv4b = conv4b
weights.conv5W = conv5W
weights.conv5b = conv5b
weights.fc6W = fc6W
weights.fc6b = fc6b
weights.fc7W = fc7W
weights.fc7b = fc7b
weights.fc8W = fc8W
weights.fc8b = fc8b
return weights | [
"def",
"build_alexnet_weights",
"(",
"self",
")",
":",
"net_data",
"=",
"self",
".",
"_net_data",
"#conv1",
"#conv(11, 11, 96, 4, 4, padding='VALID', name='conv1')",
"k_h",
"=",
"11",
"k_w",
"=",
"11",
"c_o",
"=",
"96",
"s_h",
"=",
"4",
"s_w",
"=",
"4",
"conv1W",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"conv1\"",
"]",
"[",
"0",
"]",
")",
"conv1b",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"conv1\"",
"]",
"[",
"1",
"]",
")",
"#conv2",
"#conv(5, 5, 256, 1, 1, group=2, name='conv2')",
"k_h",
"=",
"5",
"k_w",
"=",
"5",
"c_o",
"=",
"256",
"s_h",
"=",
"1",
"s_w",
"=",
"1",
"group",
"=",
"2",
"conv2W",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"conv2\"",
"]",
"[",
"0",
"]",
")",
"conv2b",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"conv2\"",
"]",
"[",
"1",
"]",
")",
"#conv3",
"#conv(3, 3, 384, 1, 1, name='conv3')",
"k_h",
"=",
"3",
"k_w",
"=",
"3",
"c_o",
"=",
"384",
"s_h",
"=",
"1",
"s_w",
"=",
"1",
"group",
"=",
"1",
"conv3W",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"conv3\"",
"]",
"[",
"0",
"]",
")",
"conv3b",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"conv3\"",
"]",
"[",
"1",
"]",
")",
"#conv4",
"#conv(3, 3, 384, 1, 1, group=2, name='conv4')",
"k_h",
"=",
"3",
"k_w",
"=",
"3",
"c_o",
"=",
"384",
"s_h",
"=",
"1",
"s_w",
"=",
"1",
"group",
"=",
"2",
"conv4W",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"conv4\"",
"]",
"[",
"0",
"]",
")",
"conv4b",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"conv4\"",
"]",
"[",
"1",
"]",
")",
"#conv5",
"#conv(3, 3, 256, 1, 1, group=2, name='conv5')",
"k_h",
"=",
"3",
"k_w",
"=",
"3",
"c_o",
"=",
"256",
"s_h",
"=",
"1",
"s_w",
"=",
"1",
"group",
"=",
"2",
"conv5W",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"conv5\"",
"]",
"[",
"0",
"]",
")",
"conv5b",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"conv5\"",
"]",
"[",
"1",
"]",
")",
"#fc6",
"#fc(4096, name='fc6')",
"fc6_in_size",
"=",
"net_data",
"[",
"\"fc6\"",
"]",
"[",
"0",
"]",
".",
"shape",
"[",
"0",
"]",
"fc6_out_size",
"=",
"net_data",
"[",
"\"fc6\"",
"]",
"[",
"0",
"]",
".",
"shape",
"[",
"1",
"]",
"fc6W",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"fc6\"",
"]",
"[",
"0",
"]",
")",
"fc6b",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"fc6\"",
"]",
"[",
"1",
"]",
")",
"#fc7",
"#fc(4096, name='fc7') ",
"fc7_in_size",
"=",
"fc6_out_size",
"fc7_out_size",
"=",
"net_data",
"[",
"\"fc7\"",
"]",
"[",
"0",
"]",
".",
"shape",
"[",
"1",
"]",
"fc7W",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"fc7\"",
"]",
"[",
"0",
"]",
")",
"fc7b",
"=",
"tf",
".",
"Variable",
"(",
"net_data",
"[",
"\"fc7\"",
"]",
"[",
"1",
"]",
")",
"#fc8",
"#fc(num_cats, relu=False, name='fc8') ",
"fc8_in_size",
"=",
"fc7_out_size",
"fc8_out_size",
"=",
"self",
".",
"_out_size",
"fc8W",
"=",
"tf",
".",
"Variable",
"(",
"tf",
".",
"truncated_normal",
"(",
"[",
"fc8_in_size",
",",
"fc8_out_size",
"]",
",",
"stddev",
"=",
"0.01",
",",
"seed",
"=",
"None",
")",
")",
"fc8b",
"=",
"tf",
".",
"Variable",
"(",
"tf",
".",
"constant",
"(",
"0.0",
",",
"shape",
"=",
"[",
"fc8_out_size",
"]",
")",
")",
"# make return object",
"weights",
"=",
"AlexNetWeights",
"(",
")",
"weights",
".",
"conv1W",
"=",
"conv1W",
"weights",
".",
"conv1b",
"=",
"conv1b",
"weights",
".",
"conv2W",
"=",
"conv2W",
"weights",
".",
"conv2b",
"=",
"conv2b",
"weights",
".",
"conv3W",
"=",
"conv3W",
"weights",
".",
"conv3b",
"=",
"conv3b",
"weights",
".",
"conv4W",
"=",
"conv4W",
"weights",
".",
"conv4b",
"=",
"conv4b",
"weights",
".",
"conv5W",
"=",
"conv5W",
"weights",
".",
"conv5b",
"=",
"conv5b",
"weights",
".",
"fc6W",
"=",
"fc6W",
"weights",
".",
"fc6b",
"=",
"fc6b",
"weights",
".",
"fc7W",
"=",
"fc7W",
"weights",
".",
"fc7b",
"=",
"fc7b",
"weights",
".",
"fc8W",
"=",
"fc8W",
"weights",
".",
"fc8b",
"=",
"fc8b",
"return",
"weights"
] | Build a set of convnet weights for AlexNet | [
"Build",
"a",
"set",
"of",
"convnet",
"weights",
"for",
"AlexNet"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/cnn.py#L219-L293 | train | Builds a set of convnet weights for AlexNet | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,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T,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(1528 - 1417) + '\x31' + '\x30' + chr(0b110010), 22714 - 22706), nzTpIcepk0o8(chr(0b10000 + 0o40) + '\x6f' + chr(0b10100 + 0o36) + chr(53) + chr(1613 - 1565), 0o10), nzTpIcepk0o8(chr(48) + '\157' + chr(856 - 805) + '\x32' + '\060', 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(51) + chr(50) + chr(0b11011 + 0o26), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(0b10101 + 0o35) + chr(0b101101 + 0o3) + '\x31', 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(50) + chr(687 - 636) + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(410 - 362) + '\157' + '\066' + chr(0b110100), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1010111 + 0o30) + chr(0b101 + 0o62) + chr(55), 0o10), nzTpIcepk0o8(chr(0b10010 + 0o36) + chr(11351 - 11240) + chr(0b1100 + 0o45) + '\x33' + chr(2804 - 2749), 0o10), nzTpIcepk0o8(chr(0b10100 + 0o34) + '\x6f' + '\x36' + chr(0b110000), 0b1000), nzTpIcepk0o8(chr(0b10010 + 0o36) + chr(0b1111 + 0o140) + chr(1046 - 996) + chr(1374 - 1324) + chr(50), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\064' + chr(0b100100 + 0o23), 45624 - 45616), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110001) + chr(0b110110) + '\x30', 0o10), nzTpIcepk0o8(chr(943 - 895) + '\157' + '\062' + chr(2031 - 1981) + chr(48), 0o10), nzTpIcepk0o8(chr(0b11110 + 0o22) + chr(10618 - 10507) + chr(2354 - 2303) + chr(0b110111) + chr(0b100011 + 0o15), 20737 - 20729), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110100) + chr(0b1101 + 0o47), 0o10), nzTpIcepk0o8(chr(594 - 546) + chr(0b100100 + 0o113) + chr(0b10010 + 0o40) + chr(962 - 911) + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(2153 - 2105) + '\157' + chr(0b1 + 0o62) + chr(0b110001) + '\x36', 0o10), nzTpIcepk0o8(chr(1851 - 1803) + chr(0b1100010 + 0o15) + chr(0b110100) + chr(323 - 273), 23838 - 23830), nzTpIcepk0o8(chr(0b100011 + 0o15) + chr(111) + chr(48), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x35' + '\x37', 16038 - 16030), nzTpIcepk0o8(chr(0b11110 + 0o22) + '\157' + '\061' + '\x35', 0o10), nzTpIcepk0o8('\060' + '\157' + chr(0b10100 + 0o36) + '\066' + chr(2835 - 2780), 32487 - 32479), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(1766 - 1717) + chr(0b110101) + '\067', ord("\x08")), nzTpIcepk0o8(chr(411 - 363) + chr(0b1101111) + '\063' + chr(49) + chr(51), ord("\x08")), nzTpIcepk0o8(chr(0b101101 + 0o3) + chr(2476 - 2365) + '\062' + '\061' + chr(49), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(51) + chr(54) + chr(0b110010), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b111111 + 0o60) + chr(0b100111 + 0o14) + chr(2177 - 2128) + chr(1528 - 1479), 0o10), nzTpIcepk0o8('\x30' + chr(2924 - 2813) + '\062' + chr(1924 - 1875) + '\064', 0o10), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110101) + chr(54), 0b1000), nzTpIcepk0o8(chr(1601 - 1553) + chr(0b1101111) + chr(2168 - 2117) + chr(1747 - 1695) + chr(0b1110 + 0o45), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + '\063' + chr(2521 - 2466) + '\x33', 33559 - 33551), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b1100 + 0o47) + chr(50) + '\x30', 8), nzTpIcepk0o8(chr(0b1 + 0o57) + chr(10146 - 10035) + chr(0b110010 + 0o1) + '\066' + '\060', 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(0b10000 + 0o42) + '\x35' + '\062', 0o10), nzTpIcepk0o8(chr(2129 - 2081) + chr(0b10111 + 0o130) + '\065' + chr(51), 0o10), nzTpIcepk0o8('\060' + chr(0b101 + 0o152) + chr(0b111 + 0o54) + '\061', 34050 - 34042), nzTpIcepk0o8('\060' + '\x6f' + '\062' + chr(0b11010 + 0o31) + chr(723 - 674), 8), nzTpIcepk0o8('\060' + '\157' + chr(50) + chr(0b1110 + 0o50) + '\065', ord("\x08")), nzTpIcepk0o8(chr(0b101 + 0o53) + '\157' + chr(949 - 899) + chr(0b10 + 0o57) + '\x36', 24848 - 24840)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(111) + chr(1801 - 1748) + chr(0b110000), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'l'), chr(0b1100100) + chr(0b1010000 + 0o25) + chr(0b1100011) + chr(5204 - 5093) + chr(0b1100100) + '\145')(chr(0b1110101) + chr(116) + '\146' + chr(1785 - 1740) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def IqyFkxU4XkJM(hXMPsSrOQzbh):
ZJUOvOWAqJQB = hXMPsSrOQzbh.CWJ8y9rEaq7r
uCjCtz1_Wn1U = nzTpIcepk0o8(chr(0b110000) + '\157' + chr(49) + '\063', 0o10)
a9Ac2dnRYSi0 = nzTpIcepk0o8(chr(0b101101 + 0o3) + chr(0b1101111) + '\061' + chr(485 - 434), 8)
b4gxT6pq1mdD = nzTpIcepk0o8(chr(0b110000) + chr(0b1001011 + 0o44) + chr(763 - 714) + chr(0b110100) + chr(0b110000), ord("\x08"))
Dmvx9BTTia8x = nzTpIcepk0o8(chr(1469 - 1421) + chr(0b101000 + 0o107) + chr(0b10110 + 0o36), ord("\x08"))
fxq3Mf2lCtQN = nzTpIcepk0o8('\060' + '\157' + '\x34', 8)
eGgaX_knDzuj = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'!\xc7\xbe\xa7\xb0'), chr(0b1100100) + chr(7719 - 7618) + chr(5113 - 5014) + chr(0b1101111) + chr(100) + chr(9396 - 9295))(chr(117) + chr(116) + '\146' + '\x2d' + chr(0b110100 + 0o4))][nzTpIcepk0o8(chr(2294 - 2246) + chr(111) + '\060', 8)])
ILl5xuugQJyt = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'!\xc7\xbe\xa7\xb0'), chr(3129 - 3029) + chr(0b111 + 0o136) + chr(6831 - 6732) + chr(0b1101111) + chr(3915 - 3815) + chr(101))(chr(9012 - 8895) + '\164' + '\146' + '\x2d' + '\x38')][nzTpIcepk0o8(chr(48) + '\x6f' + chr(49), ord("\x08"))])
uCjCtz1_Wn1U = nzTpIcepk0o8('\x30' + '\x6f' + chr(68 - 15), 64204 - 64196)
a9Ac2dnRYSi0 = nzTpIcepk0o8('\060' + chr(0b1101111) + '\065', 8)
b4gxT6pq1mdD = nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x34' + '\x30' + chr(0b110000), 0o10)
Dmvx9BTTia8x = nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110001), 8)
fxq3Mf2lCtQN = nzTpIcepk0o8(chr(0b1 + 0o57) + '\157' + '\x31', 8)
F9lJ8RbIonqb = nzTpIcepk0o8('\x30' + chr(0b1100 + 0o143) + chr(0b110010), 0o10)
hMmsR3v_5zlf = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'!\xc7\xbe\xa7\xb3'), '\144' + chr(0b111110 + 0o47) + chr(0b1100011) + '\x6f' + chr(100) + chr(0b1100101))(chr(117) + '\164' + '\146' + '\055' + chr(921 - 865))][nzTpIcepk0o8('\060' + chr(111) + chr(0b110000), 8)])
dhcvv52XXl2X = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'!\xc7\xbe\xa7\xb3'), chr(100) + chr(0b1100101) + chr(0b1100011) + chr(111) + chr(0b1100100) + chr(101))(chr(0b1110010 + 0o3) + chr(0b1110001 + 0o3) + chr(102) + chr(0b101 + 0o50) + chr(459 - 403))][nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110001), 8)])
uCjCtz1_Wn1U = nzTpIcepk0o8(chr(0b1001 + 0o47) + chr(111) + '\063', ord("\x08"))
a9Ac2dnRYSi0 = nzTpIcepk0o8('\060' + chr(0b11000 + 0o127) + chr(0b110011 + 0o0), 8)
b4gxT6pq1mdD = nzTpIcepk0o8(chr(1595 - 1547) + chr(111) + chr(0b110110 + 0o0) + chr(0b110000) + chr(48), ord("\x08"))
Dmvx9BTTia8x = nzTpIcepk0o8(chr(0b100100 + 0o14) + chr(1130 - 1019) + chr(49), 8)
fxq3Mf2lCtQN = nzTpIcepk0o8('\x30' + chr(0b1101111) + '\061', 8)
F9lJ8RbIonqb = nzTpIcepk0o8('\x30' + chr(0b10011 + 0o134) + chr(1039 - 990), 8)
HeZpmUbQjEEE = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'!\xc7\xbe\xa7\xb2'), chr(0b1100100) + chr(0b1100101) + '\x63' + '\157' + chr(8769 - 8669) + chr(0b1100101))(chr(117) + chr(116) + '\x66' + chr(45) + '\070')][nzTpIcepk0o8(chr(782 - 734) + chr(111) + chr(0b110000), 8)])
POiHY0wqE8KF = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'!\xc7\xbe\xa7\xb2'), chr(0b1100100) + chr(0b111001 + 0o54) + chr(99) + chr(111) + '\x64' + chr(8380 - 8279))(chr(0b1110101) + chr(0b101111 + 0o105) + chr(7357 - 7255) + chr(45) + chr(56))][nzTpIcepk0o8(chr(517 - 469) + chr(1192 - 1081) + chr(1142 - 1093), 8)])
uCjCtz1_Wn1U = nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b100 + 0o57), 8)
a9Ac2dnRYSi0 = nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\063', 8)
b4gxT6pq1mdD = nzTpIcepk0o8(chr(53 - 5) + '\x6f' + '\066' + chr(0b10110 + 0o32) + '\060', 8)
Dmvx9BTTia8x = nzTpIcepk0o8('\060' + '\x6f' + chr(0b110001), 8)
fxq3Mf2lCtQN = nzTpIcepk0o8(chr(924 - 876) + chr(2594 - 2483) + '\061', 8)
F9lJ8RbIonqb = nzTpIcepk0o8(chr(48) + chr(7136 - 7025) + '\x32', 8)
eFL79s_Lhsf8 = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'!\xc7\xbe\xa7\xb5'), '\144' + '\x65' + chr(0b1100011) + chr(111) + '\x64' + chr(0b11 + 0o142))(chr(0b111100 + 0o71) + chr(0b1110100) + '\x66' + chr(0b1100 + 0o41) + chr(442 - 386))][nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x30', 8)])
VL5thwtuXQK1 = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'!\xc7\xbe\xa7\xb5'), chr(0b1100100) + '\145' + chr(0b10101 + 0o116) + '\x6f' + chr(5656 - 5556) + '\145')(chr(0b1100101 + 0o20) + chr(116) + '\146' + chr(0b100101 + 0o10) + chr(642 - 586))][nzTpIcepk0o8(chr(48) + '\157' + '\x31', 8)])
uCjCtz1_Wn1U = nzTpIcepk0o8('\x30' + '\157' + chr(0b10101 + 0o36), 8)
a9Ac2dnRYSi0 = nzTpIcepk0o8(chr(0b1010 + 0o46) + chr(0b1101111) + '\x33', 8)
b4gxT6pq1mdD = nzTpIcepk0o8('\x30' + chr(0b11110 + 0o121) + '\x34' + chr(48) + '\060', 8)
Dmvx9BTTia8x = nzTpIcepk0o8(chr(48) + chr(111) + chr(1683 - 1634), 8)
fxq3Mf2lCtQN = nzTpIcepk0o8('\060' + chr(111) + chr(49), 8)
F9lJ8RbIonqb = nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x32', 8)
EV56evGx0Qhj = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'!\xc7\xbe\xa7\xb4'), '\x64' + chr(0b1100101) + chr(0b1100011) + chr(0b1101111) + chr(100) + '\145')(chr(117) + '\x74' + chr(0b1100110) + chr(0b101101) + '\070')][nzTpIcepk0o8('\x30' + chr(111) + chr(0b110000), 8)])
AfcIUN_Qr9y7 = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'!\xc7\xbe\xa7\xb4'), '\x64' + '\x65' + chr(0b1001111 + 0o24) + chr(7798 - 7687) + chr(0b1100100) + '\x65')('\x75' + chr(116) + chr(5828 - 5726) + chr(0b100111 + 0o6) + chr(0b111000))][nzTpIcepk0o8(chr(0b110000) + '\157' + '\061', 8)])
GpGKmTZKWbmC = ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'$\xcb\xe6'), chr(0b1100100 + 0o0) + '\145' + '\143' + chr(111) + '\x64' + chr(8913 - 8812))(chr(5758 - 5641) + chr(0b1110100) + '\146' + '\055' + chr(642 - 586))][nzTpIcepk0o8(chr(1353 - 1305) + '\x6f' + chr(1193 - 1145), 8)].lhbM092AFW8f[nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(125 - 77), 8)]
RUwyhF6XBUKd = ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'$\xcb\xe6'), '\144' + chr(0b1010001 + 0o24) + '\143' + chr(0b1101111) + '\144' + '\x65')(chr(0b110111 + 0o76) + chr(0b1110100) + '\x66' + chr(0b101101) + '\x38')][nzTpIcepk0o8(chr(1527 - 1479) + chr(0b111111 + 0o60) + chr(48), 8)].lhbM092AFW8f[nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(1899 - 1850), 8)]
coPNsw2BJGFW = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'$\xcb\xe6'), chr(100) + '\x65' + chr(99) + chr(0b1010011 + 0o34) + chr(0b1011101 + 0o7) + chr(101))(chr(3403 - 3286) + '\164' + chr(0b1100110) + chr(45) + '\x38')][nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x30', 8)])
vZO9v86f6hLZ = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'$\xcb\xe6'), chr(100) + '\x65' + chr(0b1100011) + '\157' + chr(100) + '\x65')(chr(117) + chr(0b1110100) + chr(5753 - 5651) + chr(0b100001 + 0o14) + chr(0b111000))][nzTpIcepk0o8(chr(0b0 + 0o60) + chr(0b1101111) + chr(1891 - 1842), 8)])
nM2f5UrDDYgv = RUwyhF6XBUKd
vC4G4C2AA0Np = ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'$\xcb\xe7'), chr(0b1100100) + chr(0b10100 + 0o121) + chr(99) + chr(0b1101111) + chr(9003 - 8903) + '\145')('\165' + '\164' + '\146' + chr(45) + chr(2724 - 2668))][nzTpIcepk0o8('\060' + '\157' + chr(0b110000), 8)].lhbM092AFW8f[nzTpIcepk0o8(chr(0b10010 + 0o36) + '\157' + chr(1538 - 1489), 8)]
xALwK0_ExJij = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'$\xcb\xe7'), chr(9464 - 9364) + chr(101) + chr(99) + chr(111) + chr(4881 - 4781) + chr(0b1100101))(chr(10072 - 9955) + chr(0b1110100) + '\x66' + '\x2d' + chr(56))][nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(1660 - 1612), 8)])
xO_00mjyi58J = FyZE4zrPCXjA.Variable(ZJUOvOWAqJQB[roI3spqORKae(ES5oEprVxulp(b'$\xcb\xe7'), chr(8647 - 8547) + '\145' + chr(0b1100011) + chr(8515 - 8404) + chr(3816 - 3716) + '\x65')(chr(0b100100 + 0o121) + chr(4427 - 4311) + chr(0b1100110) + '\055' + chr(720 - 664))][nzTpIcepk0o8(chr(0b110000) + chr(8231 - 8120) + chr(0b100111 + 0o12), 8)])
iyYse1SM3lOa = vC4G4C2AA0Np
NAtBg9oXS1hw = hXMPsSrOQzbh.VXgBVhbVSHlI
UlT2EGMjifwh = FyZE4zrPCXjA.Variable(FyZE4zrPCXjA.truncated_normal([iyYse1SM3lOa, NAtBg9oXS1hw], stddev=0.01, seed=None))
Xt4s1gXuKEv0 = FyZE4zrPCXjA.Variable(FyZE4zrPCXjA.RXDyvkMftvYY(0.0, shape=[NAtBg9oXS1hw]))
TtzqJLqe_ecy = ZJSJLGEv5jD2()
TtzqJLqe_ecy.eGgaX_knDzuj = eGgaX_knDzuj
TtzqJLqe_ecy.ILl5xuugQJyt = ILl5xuugQJyt
TtzqJLqe_ecy.hMmsR3v_5zlf = hMmsR3v_5zlf
TtzqJLqe_ecy.dhcvv52XXl2X = dhcvv52XXl2X
TtzqJLqe_ecy.HeZpmUbQjEEE = HeZpmUbQjEEE
TtzqJLqe_ecy.POiHY0wqE8KF = POiHY0wqE8KF
TtzqJLqe_ecy.eFL79s_Lhsf8 = eFL79s_Lhsf8
TtzqJLqe_ecy.VL5thwtuXQK1 = VL5thwtuXQK1
TtzqJLqe_ecy.EV56evGx0Qhj = EV56evGx0Qhj
TtzqJLqe_ecy.AfcIUN_Qr9y7 = AfcIUN_Qr9y7
TtzqJLqe_ecy.coPNsw2BJGFW = coPNsw2BJGFW
TtzqJLqe_ecy.vZO9v86f6hLZ = vZO9v86f6hLZ
TtzqJLqe_ecy.xALwK0_ExJij = xALwK0_ExJij
TtzqJLqe_ecy.xO_00mjyi58J = xO_00mjyi58J
TtzqJLqe_ecy.UlT2EGMjifwh = UlT2EGMjifwh
TtzqJLqe_ecy.Xt4s1gXuKEv0 = Xt4s1gXuKEv0
return TtzqJLqe_ecy |
BerkeleyAutomation/perception | perception/cnn.py | AlexNet.build_alexnet | def build_alexnet(self, weights, output_layer=None):
""" Connects graph of alexnet from weights """
if output_layer is None:
output_layer = self._output_layer
#conv1
#conv(11, 11, 96, 4, 4, padding='VALID', name='conv1')
k_h = 11; k_w = 11; c_o = 96; s_h = 4; s_w = 4
conv1_in = conv(self._input_node, weights.conv1W, weights.conv1b, k_h, k_w, c_o, s_h, s_w, padding="SAME", group=1)
conv1 = tf.nn.relu(conv1_in)
if output_layer == 'conv1':
return tf.contrib.layers.flatten(conv1)
#lrn1
#lrn(2, 2e-05, 0.75, name='norm1')
radius = 2; alpha = 2e-05; beta = 0.75; bias = 1.0
lrn1 = tf.nn.local_response_normalization(conv1,
depth_radius=radius,
alpha=alpha,
beta=beta,
bias=bias)
#maxpool1
#max_pool(3, 3, 2, 2, padding='VALID', name='pool1')
k_h = 3; k_w = 3; s_h = 2; s_w = 2; padding = 'VALID'
maxpool1 = tf.nn.max_pool(lrn1, ksize=[1, k_h, k_w, 1], strides=[1, s_h, s_w, 1], padding=padding)
#conv2
#conv(5, 5, 256, 1, 1, group=2, name='conv2')
k_h = 5; k_w = 5; c_o = 256; s_h = 1; s_w = 1; group = 2
conv2_in = conv(maxpool1, weights.conv2W, weights.conv2b, k_h, k_w, c_o, s_h, s_w, padding="SAME", group=group)
conv2 = tf.nn.relu(conv2_in)
if output_layer == 'conv2':
return tf.contrib.layers.flatten(conv2)
#lrn2
#lrn(2, 2e-05, 0.75, name='norm2')
radius = 2; alpha = 2e-05; beta = 0.75; bias = 1.0
lrn2 = tf.nn.local_response_normalization(conv2,
depth_radius=radius,
alpha=alpha,
beta=beta,
bias=bias)
#maxpool2
#max_pool(3, 3, 2, 2, padding='VALID', name='pool2')
k_h = 3; k_w = 3; s_h = 2; s_w = 2; padding = 'VALID'
maxpool2 = tf.nn.max_pool(lrn2, ksize=[1, k_h, k_w, 1], strides=[1, s_h, s_w, 1], padding=padding)
#conv3
#conv(3, 3, 384, 1, 1, name='conv3')
k_h = 3; k_w = 3; c_o = 384; s_h = 1; s_w = 1; group = 1
conv3_in = conv(maxpool2, weights.conv3W, weights.conv3b, k_h, k_w, c_o, s_h, s_w, padding="SAME", group=group)
conv3 = tf.nn.relu(conv3_in)
if output_layer == 'conv3':
return tf.contrib.layers.flatten(conv3)
#conv4
#conv(3, 3, 384, 1, 1, group=2, name='conv4')
k_h = 3; k_w = 3; c_o = 384; s_h = 1; s_w = 1; group = 2
conv4_in = conv(conv3, weights.conv4W, weights.conv4b, k_h, k_w, c_o, s_h, s_w, padding="SAME", group=group)
conv4 = tf.nn.relu(conv4_in)
if output_layer == 'conv4':
return tf.contrib.layers.flatten(conv4)
#conv5
#conv(3, 3, 256, 1, 1, group=2, name='conv5')
k_h = 3; k_w = 3; c_o = 256; s_h = 1; s_w = 1; group = 2
conv5_in = conv(conv4, weights.conv5W, weights.conv5b, k_h, k_w, c_o, s_h, s_w, padding="SAME", group=group)
conv5 = tf.nn.relu(conv5_in)
if output_layer == 'conv5':
return tf.contrib.layers.flatten(conv5)
#maxpool5
#max_pool(3, 3, 2, 2, padding='VALID', name='pool5')
k_h = 3; k_w = 3; s_h = 2; s_w = 2; padding = 'VALID'
maxpool5 = tf.nn.max_pool(conv5, ksize=[1, k_h, k_w, 1], strides=[1, s_h, s_w, 1], padding=padding)
#fc6
#fc(4096, name='fc6')
fc6 = tf.nn.relu_layer(tf.reshape(maxpool5, [-1, int(np.prod(maxpool5.get_shape()[1:]))]), weights.fc6W, weights.fc6b)
if output_layer == 'fc6':
return fc6
#fc7
#fc(4096, name='fc7')
fc7 = tf.nn.relu_layer(fc6, weights.fc7W, weights.fc7b)
if output_layer == 'fc7':
return fc7
#fc8
#fc(num_cats, relu=False, name='fc8')
fc8 = tf.nn.xw_plus_b(fc7, weights.fc8W, weights.fc8b)
if output_layer == 'fc8':
return fc8
#softmax
sm = tf.nn.softmax(fc8)
return sm | python | def build_alexnet(self, weights, output_layer=None):
""" Connects graph of alexnet from weights """
if output_layer is None:
output_layer = self._output_layer
#conv1
#conv(11, 11, 96, 4, 4, padding='VALID', name='conv1')
k_h = 11; k_w = 11; c_o = 96; s_h = 4; s_w = 4
conv1_in = conv(self._input_node, weights.conv1W, weights.conv1b, k_h, k_w, c_o, s_h, s_w, padding="SAME", group=1)
conv1 = tf.nn.relu(conv1_in)
if output_layer == 'conv1':
return tf.contrib.layers.flatten(conv1)
#lrn1
#lrn(2, 2e-05, 0.75, name='norm1')
radius = 2; alpha = 2e-05; beta = 0.75; bias = 1.0
lrn1 = tf.nn.local_response_normalization(conv1,
depth_radius=radius,
alpha=alpha,
beta=beta,
bias=bias)
#maxpool1
#max_pool(3, 3, 2, 2, padding='VALID', name='pool1')
k_h = 3; k_w = 3; s_h = 2; s_w = 2; padding = 'VALID'
maxpool1 = tf.nn.max_pool(lrn1, ksize=[1, k_h, k_w, 1], strides=[1, s_h, s_w, 1], padding=padding)
#conv2
#conv(5, 5, 256, 1, 1, group=2, name='conv2')
k_h = 5; k_w = 5; c_o = 256; s_h = 1; s_w = 1; group = 2
conv2_in = conv(maxpool1, weights.conv2W, weights.conv2b, k_h, k_w, c_o, s_h, s_w, padding="SAME", group=group)
conv2 = tf.nn.relu(conv2_in)
if output_layer == 'conv2':
return tf.contrib.layers.flatten(conv2)
#lrn2
#lrn(2, 2e-05, 0.75, name='norm2')
radius = 2; alpha = 2e-05; beta = 0.75; bias = 1.0
lrn2 = tf.nn.local_response_normalization(conv2,
depth_radius=radius,
alpha=alpha,
beta=beta,
bias=bias)
#maxpool2
#max_pool(3, 3, 2, 2, padding='VALID', name='pool2')
k_h = 3; k_w = 3; s_h = 2; s_w = 2; padding = 'VALID'
maxpool2 = tf.nn.max_pool(lrn2, ksize=[1, k_h, k_w, 1], strides=[1, s_h, s_w, 1], padding=padding)
#conv3
#conv(3, 3, 384, 1, 1, name='conv3')
k_h = 3; k_w = 3; c_o = 384; s_h = 1; s_w = 1; group = 1
conv3_in = conv(maxpool2, weights.conv3W, weights.conv3b, k_h, k_w, c_o, s_h, s_w, padding="SAME", group=group)
conv3 = tf.nn.relu(conv3_in)
if output_layer == 'conv3':
return tf.contrib.layers.flatten(conv3)
#conv4
#conv(3, 3, 384, 1, 1, group=2, name='conv4')
k_h = 3; k_w = 3; c_o = 384; s_h = 1; s_w = 1; group = 2
conv4_in = conv(conv3, weights.conv4W, weights.conv4b, k_h, k_w, c_o, s_h, s_w, padding="SAME", group=group)
conv4 = tf.nn.relu(conv4_in)
if output_layer == 'conv4':
return tf.contrib.layers.flatten(conv4)
#conv5
#conv(3, 3, 256, 1, 1, group=2, name='conv5')
k_h = 3; k_w = 3; c_o = 256; s_h = 1; s_w = 1; group = 2
conv5_in = conv(conv4, weights.conv5W, weights.conv5b, k_h, k_w, c_o, s_h, s_w, padding="SAME", group=group)
conv5 = tf.nn.relu(conv5_in)
if output_layer == 'conv5':
return tf.contrib.layers.flatten(conv5)
#maxpool5
#max_pool(3, 3, 2, 2, padding='VALID', name='pool5')
k_h = 3; k_w = 3; s_h = 2; s_w = 2; padding = 'VALID'
maxpool5 = tf.nn.max_pool(conv5, ksize=[1, k_h, k_w, 1], strides=[1, s_h, s_w, 1], padding=padding)
#fc6
#fc(4096, name='fc6')
fc6 = tf.nn.relu_layer(tf.reshape(maxpool5, [-1, int(np.prod(maxpool5.get_shape()[1:]))]), weights.fc6W, weights.fc6b)
if output_layer == 'fc6':
return fc6
#fc7
#fc(4096, name='fc7')
fc7 = tf.nn.relu_layer(fc6, weights.fc7W, weights.fc7b)
if output_layer == 'fc7':
return fc7
#fc8
#fc(num_cats, relu=False, name='fc8')
fc8 = tf.nn.xw_plus_b(fc7, weights.fc8W, weights.fc8b)
if output_layer == 'fc8':
return fc8
#softmax
sm = tf.nn.softmax(fc8)
return sm | [
"def",
"build_alexnet",
"(",
"self",
",",
"weights",
",",
"output_layer",
"=",
"None",
")",
":",
"if",
"output_layer",
"is",
"None",
":",
"output_layer",
"=",
"self",
".",
"_output_layer",
"#conv1",
"#conv(11, 11, 96, 4, 4, padding='VALID', name='conv1')",
"k_h",
"=",
"11",
"k_w",
"=",
"11",
"c_o",
"=",
"96",
"s_h",
"=",
"4",
"s_w",
"=",
"4",
"conv1_in",
"=",
"conv",
"(",
"self",
".",
"_input_node",
",",
"weights",
".",
"conv1W",
",",
"weights",
".",
"conv1b",
",",
"k_h",
",",
"k_w",
",",
"c_o",
",",
"s_h",
",",
"s_w",
",",
"padding",
"=",
"\"SAME\"",
",",
"group",
"=",
"1",
")",
"conv1",
"=",
"tf",
".",
"nn",
".",
"relu",
"(",
"conv1_in",
")",
"if",
"output_layer",
"==",
"'conv1'",
":",
"return",
"tf",
".",
"contrib",
".",
"layers",
".",
"flatten",
"(",
"conv1",
")",
"#lrn1",
"#lrn(2, 2e-05, 0.75, name='norm1')",
"radius",
"=",
"2",
"alpha",
"=",
"2e-05",
"beta",
"=",
"0.75",
"bias",
"=",
"1.0",
"lrn1",
"=",
"tf",
".",
"nn",
".",
"local_response_normalization",
"(",
"conv1",
",",
"depth_radius",
"=",
"radius",
",",
"alpha",
"=",
"alpha",
",",
"beta",
"=",
"beta",
",",
"bias",
"=",
"bias",
")",
"#maxpool1",
"#max_pool(3, 3, 2, 2, padding='VALID', name='pool1')",
"k_h",
"=",
"3",
"k_w",
"=",
"3",
"s_h",
"=",
"2",
"s_w",
"=",
"2",
"padding",
"=",
"'VALID'",
"maxpool1",
"=",
"tf",
".",
"nn",
".",
"max_pool",
"(",
"lrn1",
",",
"ksize",
"=",
"[",
"1",
",",
"k_h",
",",
"k_w",
",",
"1",
"]",
",",
"strides",
"=",
"[",
"1",
",",
"s_h",
",",
"s_w",
",",
"1",
"]",
",",
"padding",
"=",
"padding",
")",
"#conv2",
"#conv(5, 5, 256, 1, 1, group=2, name='conv2')",
"k_h",
"=",
"5",
"k_w",
"=",
"5",
"c_o",
"=",
"256",
"s_h",
"=",
"1",
"s_w",
"=",
"1",
"group",
"=",
"2",
"conv2_in",
"=",
"conv",
"(",
"maxpool1",
",",
"weights",
".",
"conv2W",
",",
"weights",
".",
"conv2b",
",",
"k_h",
",",
"k_w",
",",
"c_o",
",",
"s_h",
",",
"s_w",
",",
"padding",
"=",
"\"SAME\"",
",",
"group",
"=",
"group",
")",
"conv2",
"=",
"tf",
".",
"nn",
".",
"relu",
"(",
"conv2_in",
")",
"if",
"output_layer",
"==",
"'conv2'",
":",
"return",
"tf",
".",
"contrib",
".",
"layers",
".",
"flatten",
"(",
"conv2",
")",
"#lrn2",
"#lrn(2, 2e-05, 0.75, name='norm2')",
"radius",
"=",
"2",
"alpha",
"=",
"2e-05",
"beta",
"=",
"0.75",
"bias",
"=",
"1.0",
"lrn2",
"=",
"tf",
".",
"nn",
".",
"local_response_normalization",
"(",
"conv2",
",",
"depth_radius",
"=",
"radius",
",",
"alpha",
"=",
"alpha",
",",
"beta",
"=",
"beta",
",",
"bias",
"=",
"bias",
")",
"#maxpool2",
"#max_pool(3, 3, 2, 2, padding='VALID', name='pool2') ",
"k_h",
"=",
"3",
"k_w",
"=",
"3",
"s_h",
"=",
"2",
"s_w",
"=",
"2",
"padding",
"=",
"'VALID'",
"maxpool2",
"=",
"tf",
".",
"nn",
".",
"max_pool",
"(",
"lrn2",
",",
"ksize",
"=",
"[",
"1",
",",
"k_h",
",",
"k_w",
",",
"1",
"]",
",",
"strides",
"=",
"[",
"1",
",",
"s_h",
",",
"s_w",
",",
"1",
"]",
",",
"padding",
"=",
"padding",
")",
"#conv3",
"#conv(3, 3, 384, 1, 1, name='conv3')",
"k_h",
"=",
"3",
"k_w",
"=",
"3",
"c_o",
"=",
"384",
"s_h",
"=",
"1",
"s_w",
"=",
"1",
"group",
"=",
"1",
"conv3_in",
"=",
"conv",
"(",
"maxpool2",
",",
"weights",
".",
"conv3W",
",",
"weights",
".",
"conv3b",
",",
"k_h",
",",
"k_w",
",",
"c_o",
",",
"s_h",
",",
"s_w",
",",
"padding",
"=",
"\"SAME\"",
",",
"group",
"=",
"group",
")",
"conv3",
"=",
"tf",
".",
"nn",
".",
"relu",
"(",
"conv3_in",
")",
"if",
"output_layer",
"==",
"'conv3'",
":",
"return",
"tf",
".",
"contrib",
".",
"layers",
".",
"flatten",
"(",
"conv3",
")",
"#conv4",
"#conv(3, 3, 384, 1, 1, group=2, name='conv4')",
"k_h",
"=",
"3",
"k_w",
"=",
"3",
"c_o",
"=",
"384",
"s_h",
"=",
"1",
"s_w",
"=",
"1",
"group",
"=",
"2",
"conv4_in",
"=",
"conv",
"(",
"conv3",
",",
"weights",
".",
"conv4W",
",",
"weights",
".",
"conv4b",
",",
"k_h",
",",
"k_w",
",",
"c_o",
",",
"s_h",
",",
"s_w",
",",
"padding",
"=",
"\"SAME\"",
",",
"group",
"=",
"group",
")",
"conv4",
"=",
"tf",
".",
"nn",
".",
"relu",
"(",
"conv4_in",
")",
"if",
"output_layer",
"==",
"'conv4'",
":",
"return",
"tf",
".",
"contrib",
".",
"layers",
".",
"flatten",
"(",
"conv4",
")",
"#conv5",
"#conv(3, 3, 256, 1, 1, group=2, name='conv5')",
"k_h",
"=",
"3",
"k_w",
"=",
"3",
"c_o",
"=",
"256",
"s_h",
"=",
"1",
"s_w",
"=",
"1",
"group",
"=",
"2",
"conv5_in",
"=",
"conv",
"(",
"conv4",
",",
"weights",
".",
"conv5W",
",",
"weights",
".",
"conv5b",
",",
"k_h",
",",
"k_w",
",",
"c_o",
",",
"s_h",
",",
"s_w",
",",
"padding",
"=",
"\"SAME\"",
",",
"group",
"=",
"group",
")",
"conv5",
"=",
"tf",
".",
"nn",
".",
"relu",
"(",
"conv5_in",
")",
"if",
"output_layer",
"==",
"'conv5'",
":",
"return",
"tf",
".",
"contrib",
".",
"layers",
".",
"flatten",
"(",
"conv5",
")",
"#maxpool5",
"#max_pool(3, 3, 2, 2, padding='VALID', name='pool5')",
"k_h",
"=",
"3",
"k_w",
"=",
"3",
"s_h",
"=",
"2",
"s_w",
"=",
"2",
"padding",
"=",
"'VALID'",
"maxpool5",
"=",
"tf",
".",
"nn",
".",
"max_pool",
"(",
"conv5",
",",
"ksize",
"=",
"[",
"1",
",",
"k_h",
",",
"k_w",
",",
"1",
"]",
",",
"strides",
"=",
"[",
"1",
",",
"s_h",
",",
"s_w",
",",
"1",
"]",
",",
"padding",
"=",
"padding",
")",
"#fc6",
"#fc(4096, name='fc6')",
"fc6",
"=",
"tf",
".",
"nn",
".",
"relu_layer",
"(",
"tf",
".",
"reshape",
"(",
"maxpool5",
",",
"[",
"-",
"1",
",",
"int",
"(",
"np",
".",
"prod",
"(",
"maxpool5",
".",
"get_shape",
"(",
")",
"[",
"1",
":",
"]",
")",
")",
"]",
")",
",",
"weights",
".",
"fc6W",
",",
"weights",
".",
"fc6b",
")",
"if",
"output_layer",
"==",
"'fc6'",
":",
"return",
"fc6",
"#fc7",
"#fc(4096, name='fc7') ",
"fc7",
"=",
"tf",
".",
"nn",
".",
"relu_layer",
"(",
"fc6",
",",
"weights",
".",
"fc7W",
",",
"weights",
".",
"fc7b",
")",
"if",
"output_layer",
"==",
"'fc7'",
":",
"return",
"fc7",
"#fc8",
"#fc(num_cats, relu=False, name='fc8')",
"fc8",
"=",
"tf",
".",
"nn",
".",
"xw_plus_b",
"(",
"fc7",
",",
"weights",
".",
"fc8W",
",",
"weights",
".",
"fc8b",
")",
"if",
"output_layer",
"==",
"'fc8'",
":",
"return",
"fc8",
"#softmax",
"sm",
"=",
"tf",
".",
"nn",
".",
"softmax",
"(",
"fc8",
")",
"return",
"sm"
] | Connects graph of alexnet from weights | [
"Connects",
"graph",
"of",
"alexnet",
"from",
"weights"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/cnn.py#L295-L394 | train | Builds the Alexnet graph from the given weights. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,w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4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + chr(111) + chr(0b110011) + chr(0b11010 + 0o34) + '\063', 9612 - 9604), nzTpIcepk0o8(chr(2036 - 1988) + '\x6f' + '\x33' + chr(0b110011) + chr(48), ord("\x08")), nzTpIcepk0o8(chr(2277 - 2229) + '\x6f' + '\063' + chr(1031 - 979) + chr(981 - 933), 60137 - 60129), nzTpIcepk0o8('\060' + '\x6f' + '\x33' + chr(302 - 248) + '\x36', 0b1000), nzTpIcepk0o8('\060' + chr(0b110001 + 0o76) + '\062' + chr(49) + chr(2135 - 2087), 44467 - 44459), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b11110 + 0o23) + chr(660 - 612) + chr(0b110101), 0b1000), nzTpIcepk0o8(chr(110 - 62) + chr(111) + '\x32' + chr(193 - 140) + chr(0b100111 + 0o16), 18721 - 18713), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(1938 - 1889) + '\060' + '\x35', 8), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(53) + chr(48), 48049 - 48041), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b10010 + 0o41) + '\x31' + '\067', 64208 - 64200), nzTpIcepk0o8(chr(1836 - 1788) + chr(0b111111 + 0o60) + '\062' + chr(51) + '\067', 47668 - 47660), nzTpIcepk0o8('\060' + chr(0b1011010 + 0o25) + chr(48), 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(0b11111 + 0o23) + chr(0b110111) + chr(0b1000 + 0o55), ord("\x08")), nzTpIcepk0o8('\060' + '\157' + '\x32' + '\x34' + chr(0b10 + 0o63), ord("\x08")), nzTpIcepk0o8(chr(0b10001 + 0o37) + chr(0b1101111) + chr(50) + chr(155 - 104) + chr(0b100111 + 0o17), 0b1000), nzTpIcepk0o8(chr(2149 - 2101) + chr(111) + chr(1474 - 1425) + '\060' + chr(232 - 179), 8), nzTpIcepk0o8(chr(572 - 524) + chr(0b1101111) + chr(0b110001) + chr(1084 - 1031) + chr(0b110011 + 0o3), 0b1000), nzTpIcepk0o8(chr(1047 - 999) + chr(111) + '\063' + '\063' + chr(467 - 414), 0o10), nzTpIcepk0o8('\x30' + chr(0b11011 + 0o124) + '\062' + chr(850 - 797) + chr(0b110111), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1000111 + 0o50) + chr(49) + chr(0b110010) + chr(50), 35282 - 35274), nzTpIcepk0o8('\060' + chr(111) + chr(0b110010) + '\x32', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(51) + chr(0b110011) + '\062', 0o10), nzTpIcepk0o8('\x30' + chr(800 - 689) + chr(510 - 459) + chr(0b110110 + 0o1) + chr(0b110000), 20624 - 20616), nzTpIcepk0o8(chr(0b1010 + 0o46) + chr(111) + chr(0b101111 + 0o3) + chr(0b110100) + chr(0b101001 + 0o16), 47970 - 47962), nzTpIcepk0o8(chr(48) + chr(2410 - 2299) + '\x35', 17866 - 17858), nzTpIcepk0o8(chr(0b110 + 0o52) + '\x6f' + chr(0b110100) + chr(688 - 637), 52121 - 52113), nzTpIcepk0o8('\x30' + '\x6f' + chr(762 - 712) + chr(0b111 + 0o51) + chr(2121 - 2073), 0o10), nzTpIcepk0o8(chr(309 - 261) + '\x6f' + '\x34' + chr(0b110100), 57675 - 57667), nzTpIcepk0o8(chr(0b110000) + chr(0b1100111 + 0o10) + '\x31' + chr(0b11001 + 0o31) + chr(49), ord("\x08")), nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(0b1101111) + chr(0b11000 + 0o32) + chr(0b110011) + chr(567 - 514), 63360 - 63352), nzTpIcepk0o8('\060' + chr(111) + chr(0b110010) + chr(0b101001 + 0o12) + '\x35', 8), nzTpIcepk0o8(chr(0b101011 + 0o5) + '\157' + '\x31' + chr(0b11010 + 0o31) + chr(2504 - 2451), 0o10), nzTpIcepk0o8(chr(2174 - 2126) + chr(0b1101111) + '\063' + '\063' + chr(0b110101 + 0o2), 0b1000), nzTpIcepk0o8(chr(1246 - 1198) + '\x6f' + '\x33' + chr(0b110111) + chr(50), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + '\060', 8), nzTpIcepk0o8('\x30' + '\x6f' + '\x31' + '\062' + chr(0b1001 + 0o52), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(1705 - 1654) + chr(0b110100) + '\061', 32526 - 32518), nzTpIcepk0o8('\x30' + chr(9914 - 9803) + chr(894 - 844) + '\x32', 8), nzTpIcepk0o8('\x30' + chr(111) + chr(51) + '\x30' + chr(0b11000 + 0o33), 0o10), nzTpIcepk0o8(chr(0b101110 + 0o2) + '\x6f' + chr(0b110011) + chr(0b1001 + 0o55) + '\060', ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(53) + chr(0b111 + 0o51), 8)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xdd'), chr(4213 - 4113) + '\145' + chr(0b1100011) + '\157' + '\144' + '\145')(chr(117) + chr(116) + chr(102) + '\x2d' + chr(2027 - 1971)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def iUV04ZrgJSMh(hXMPsSrOQzbh, TtzqJLqe_ecy, vLThzTu86svC=None):
if vLThzTu86svC is None:
vLThzTu86svC = hXMPsSrOQzbh.AjiUau1IFHOs
uCjCtz1_Wn1U = nzTpIcepk0o8('\x30' + chr(0b1101111) + '\061' + chr(0b110011), 0o10)
a9Ac2dnRYSi0 = nzTpIcepk0o8(chr(314 - 266) + chr(0b1101111) + chr(0b110001) + '\x33', 8)
b4gxT6pq1mdD = nzTpIcepk0o8(chr(1083 - 1035) + '\157' + chr(0b110001) + '\x34' + '\x30', 0o10)
Dmvx9BTTia8x = nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110100), ord("\x08"))
fxq3Mf2lCtQN = nzTpIcepk0o8('\060' + '\x6f' + '\x34', 8)
qNwcCxO_QBDN = pfzyJC7EQHEL(hXMPsSrOQzbh.ifKyDND3ENDe, TtzqJLqe_ecy.eGgaX_knDzuj, TtzqJLqe_ecy.ILl5xuugQJyt, uCjCtz1_Wn1U, a9Ac2dnRYSi0, b4gxT6pq1mdD, Dmvx9BTTia8x, fxq3Mf2lCtQN, padding=roI3spqORKae(ES5oEprVxulp(b'\xa0\x99\xad\xb3'), chr(4562 - 4462) + chr(864 - 763) + chr(0b101 + 0o136) + '\x6f' + '\144' + chr(101))('\165' + chr(532 - 416) + '\146' + '\x2d' + chr(0b111000)), group=nzTpIcepk0o8('\060' + chr(111) + chr(0b10100 + 0o35), 0o10))
ExJJeFPr3896 = FyZE4zrPCXjA.nn.relu(qNwcCxO_QBDN)
if vLThzTu86svC == roI3spqORKae(ES5oEprVxulp(b'\x90\xb7\x8e\x80\xb9'), chr(100) + chr(101) + '\x63' + '\157' + chr(100) + chr(3430 - 3329))(chr(0b100010 + 0o123) + '\x74' + '\x66' + chr(0b11111 + 0o16) + chr(0b111000)):
return roI3spqORKae(FyZE4zrPCXjA.contrib.layers, roI3spqORKae(ES5oEprVxulp(b'\x84\xb7\x9a\x87\xcc2\xc1)z\xae\xc0T'), '\144' + '\x65' + chr(0b111011 + 0o50) + chr(111) + chr(0b1100100) + '\145')(chr(2821 - 2704) + '\164' + chr(0b100011 + 0o103) + chr(45) + chr(0b10110 + 0o42)))(ExJJeFPr3896)
qGhcQMWNyIbI = nzTpIcepk0o8(chr(761 - 713) + chr(0b1101111) + '\062', 0b1000)
t3TBppk7s7__ = 2e-05
ckp_CDGnFsFr = 0.75
gNPmnEzB7YJo = 1.0
ujATsK1YILyU = FyZE4zrPCXjA.nn.local_response_normalization(ExJJeFPr3896, depth_radius=qGhcQMWNyIbI, alpha=t3TBppk7s7__, beta=ckp_CDGnFsFr, bias=gNPmnEzB7YJo)
uCjCtz1_Wn1U = nzTpIcepk0o8('\x30' + '\x6f' + chr(0b101001 + 0o12), 0o10)
a9Ac2dnRYSi0 = nzTpIcepk0o8(chr(0b110000) + chr(111) + '\063', 8)
Dmvx9BTTia8x = nzTpIcepk0o8('\060' + '\157' + '\062', 8)
fxq3Mf2lCtQN = nzTpIcepk0o8('\060' + '\157' + chr(0b110010), 8)
UXh69pZlc4If = roI3spqORKae(ES5oEprVxulp(b'\xa5\x99\xac\xbf\xcc'), chr(0b110011 + 0o61) + chr(0b1100101) + chr(0b11010 + 0o111) + chr(8342 - 8231) + chr(0b1100100) + chr(101))('\x75' + chr(0b1110100) + chr(0b100011 + 0o103) + '\x2d' + chr(0b111000))
hPXdHNNlcRQZ = FyZE4zrPCXjA.nn.max_pool(ujATsK1YILyU, ksize=[nzTpIcepk0o8(chr(604 - 556) + '\157' + chr(0b1101 + 0o44), 8), uCjCtz1_Wn1U, a9Ac2dnRYSi0, nzTpIcepk0o8('\x30' + '\x6f' + '\061', 8)], strides=[nzTpIcepk0o8(chr(880 - 832) + chr(0b1101111) + chr(0b110001), 8), Dmvx9BTTia8x, fxq3Mf2lCtQN, nzTpIcepk0o8(chr(2242 - 2194) + chr(0b1101111) + chr(49), 8)], padding=UXh69pZlc4If)
uCjCtz1_Wn1U = nzTpIcepk0o8(chr(0b110000) + '\157' + '\x35', 8)
a9Ac2dnRYSi0 = nzTpIcepk0o8('\060' + chr(111) + chr(0b110101), 8)
b4gxT6pq1mdD = nzTpIcepk0o8(chr(0b110000) + chr(9676 - 9565) + '\064' + chr(650 - 602) + '\060', 0b1000)
Dmvx9BTTia8x = nzTpIcepk0o8(chr(48) + '\157' + '\061', 8)
fxq3Mf2lCtQN = nzTpIcepk0o8(chr(48) + chr(111) + chr(0b1011 + 0o46), 8)
F9lJ8RbIonqb = nzTpIcepk0o8('\060' + chr(521 - 410) + chr(0b110010), 8)
F6z02ZNBGlJb = pfzyJC7EQHEL(hPXdHNNlcRQZ, TtzqJLqe_ecy.hMmsR3v_5zlf, TtzqJLqe_ecy.dhcvv52XXl2X, uCjCtz1_Wn1U, a9Ac2dnRYSi0, b4gxT6pq1mdD, Dmvx9BTTia8x, fxq3Mf2lCtQN, padding=roI3spqORKae(ES5oEprVxulp(b'\xa0\x99\xad\xb3'), '\x64' + chr(0b1100101) + chr(0b100000 + 0o103) + '\x6f' + chr(0b111100 + 0o50) + chr(0b1100101))(chr(6551 - 6434) + '\x74' + '\146' + chr(45) + chr(2937 - 2881)), group=F9lJ8RbIonqb)
xeJJvPCeg9ZP = FyZE4zrPCXjA.nn.relu(F6z02ZNBGlJb)
if vLThzTu86svC == roI3spqORKae(ES5oEprVxulp(b'\x90\xb7\x8e\x80\xba'), chr(100) + chr(3972 - 3871) + '\x63' + chr(111) + '\x64' + chr(0b111111 + 0o46))(chr(117) + chr(0b1011010 + 0o32) + '\x66' + chr(1633 - 1588) + chr(1553 - 1497)):
return roI3spqORKae(FyZE4zrPCXjA.contrib.layers, roI3spqORKae(ES5oEprVxulp(b'\x84\xb7\x9a\x87\xcc2\xc1)z\xae\xc0T'), chr(100) + chr(0b1100101) + chr(99) + '\x6f' + '\x64' + chr(0b1100101 + 0o0))(chr(117) + chr(0b1110100) + '\x66' + chr(1732 - 1687) + chr(706 - 650)))(xeJJvPCeg9ZP)
qGhcQMWNyIbI = nzTpIcepk0o8(chr(2168 - 2120) + '\x6f' + '\062', 8)
t3TBppk7s7__ = 2e-05
ckp_CDGnFsFr = 0.75
gNPmnEzB7YJo = 1.0
rRz5_TH5qNim = FyZE4zrPCXjA.nn.local_response_normalization(xeJJvPCeg9ZP, depth_radius=qGhcQMWNyIbI, alpha=t3TBppk7s7__, beta=ckp_CDGnFsFr, bias=gNPmnEzB7YJo)
uCjCtz1_Wn1U = nzTpIcepk0o8(chr(48) + '\157' + chr(0b1110 + 0o45), 8)
a9Ac2dnRYSi0 = nzTpIcepk0o8('\x30' + chr(0b111100 + 0o63) + chr(51), 8)
Dmvx9BTTia8x = nzTpIcepk0o8(chr(1652 - 1604) + chr(4124 - 4013) + '\062', 8)
fxq3Mf2lCtQN = nzTpIcepk0o8('\060' + chr(0b1100101 + 0o12) + chr(0b1 + 0o61), 8)
UXh69pZlc4If = roI3spqORKae(ES5oEprVxulp(b'\xa5\x99\xac\xbf\xcc'), chr(2033 - 1933) + chr(0b1100101) + '\x63' + chr(2779 - 2668) + '\144' + '\145')(chr(117) + chr(116) + chr(497 - 395) + '\055' + chr(0b1000 + 0o60))
en0IqBt452pj = FyZE4zrPCXjA.nn.max_pool(rRz5_TH5qNim, ksize=[nzTpIcepk0o8(chr(0b110000) + '\157' + '\061', 8), uCjCtz1_Wn1U, a9Ac2dnRYSi0, nzTpIcepk0o8(chr(0b110000) + '\157' + chr(49), 8)], strides=[nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110001), 8), Dmvx9BTTia8x, fxq3Mf2lCtQN, nzTpIcepk0o8(chr(2246 - 2198) + '\157' + chr(49), 8)], padding=UXh69pZlc4If)
uCjCtz1_Wn1U = nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110011), 8)
a9Ac2dnRYSi0 = nzTpIcepk0o8(chr(48) + chr(0b110110 + 0o71) + chr(0b10000 + 0o43), 8)
b4gxT6pq1mdD = nzTpIcepk0o8(chr(0b110000) + chr(0b1010111 + 0o30) + chr(0b100101 + 0o21) + '\060' + chr(0b110000), 61215 - 61207)
Dmvx9BTTia8x = nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b0 + 0o61), 8)
fxq3Mf2lCtQN = nzTpIcepk0o8(chr(48) + chr(111) + chr(0b10010 + 0o37), 8)
F9lJ8RbIonqb = nzTpIcepk0o8(chr(1522 - 1474) + chr(4928 - 4817) + chr(0b110001), 8)
ZMgbfX5PKj0U = pfzyJC7EQHEL(en0IqBt452pj, TtzqJLqe_ecy.HeZpmUbQjEEE, TtzqJLqe_ecy.POiHY0wqE8KF, uCjCtz1_Wn1U, a9Ac2dnRYSi0, b4gxT6pq1mdD, Dmvx9BTTia8x, fxq3Mf2lCtQN, padding=roI3spqORKae(ES5oEprVxulp(b'\xa0\x99\xad\xb3'), '\144' + chr(101) + chr(99) + '\157' + chr(0b1011101 + 0o7) + chr(0b1100101))(chr(0b1110101) + '\164' + chr(4571 - 4469) + chr(0b10101 + 0o30) + '\x38'), group=F9lJ8RbIonqb)
skdOoGAGvO18 = FyZE4zrPCXjA.nn.relu(ZMgbfX5PKj0U)
if vLThzTu86svC == roI3spqORKae(ES5oEprVxulp(b'\x90\xb7\x8e\x80\xbb'), '\x64' + '\x65' + chr(0b1100011) + chr(0b1001110 + 0o41) + '\x64' + chr(0b1100101))(chr(0b1110101) + chr(0b1000001 + 0o63) + chr(0b1100110) + chr(0b10000 + 0o35) + '\x38'):
return roI3spqORKae(FyZE4zrPCXjA.contrib.layers, roI3spqORKae(ES5oEprVxulp(b'\x84\xb7\x9a\x87\xcc2\xc1)z\xae\xc0T'), '\144' + chr(0b10000 + 0o125) + chr(5572 - 5473) + chr(0b10010 + 0o135) + chr(100) + chr(5965 - 5864))(chr(2479 - 2362) + chr(0b1101000 + 0o14) + '\146' + '\x2d' + '\x38'))(skdOoGAGvO18)
uCjCtz1_Wn1U = nzTpIcepk0o8('\x30' + chr(572 - 461) + chr(51), 8)
a9Ac2dnRYSi0 = nzTpIcepk0o8(chr(0b110000) + '\157' + chr(51), 8)
b4gxT6pq1mdD = nzTpIcepk0o8(chr(48) + '\157' + chr(0b11000 + 0o36) + chr(0b110000) + chr(0b101001 + 0o7), 8)
Dmvx9BTTia8x = nzTpIcepk0o8(chr(48) + chr(10734 - 10623) + chr(49), 8)
fxq3Mf2lCtQN = nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(49), 8)
F9lJ8RbIonqb = nzTpIcepk0o8(chr(0b110000) + chr(11975 - 11864) + chr(50), 8)
WCldaWkFi85c = pfzyJC7EQHEL(skdOoGAGvO18, TtzqJLqe_ecy.eFL79s_Lhsf8, TtzqJLqe_ecy.VL5thwtuXQK1, uCjCtz1_Wn1U, a9Ac2dnRYSi0, b4gxT6pq1mdD, Dmvx9BTTia8x, fxq3Mf2lCtQN, padding=roI3spqORKae(ES5oEprVxulp(b'\xa0\x99\xad\xb3'), chr(0b1100100) + '\x65' + chr(0b1100011) + '\157' + '\144' + '\145')('\x75' + chr(0b1110100) + '\146' + '\x2d' + '\070'), group=F9lJ8RbIonqb)
v3VgwKX8w9JZ = FyZE4zrPCXjA.nn.relu(WCldaWkFi85c)
if vLThzTu86svC == roI3spqORKae(ES5oEprVxulp(b'\x90\xb7\x8e\x80\xbc'), chr(2517 - 2417) + '\x65' + '\x63' + chr(0b111111 + 0o60) + chr(0b1100100) + chr(0b1100101))('\165' + '\164' + '\146' + chr(45) + '\070'):
return roI3spqORKae(FyZE4zrPCXjA.contrib.layers, roI3spqORKae(ES5oEprVxulp(b'\x84\xb7\x9a\x87\xcc2\xc1)z\xae\xc0T'), chr(100) + '\145' + '\143' + chr(0b101111 + 0o100) + '\x64' + chr(0b101000 + 0o75))(chr(0b1100100 + 0o21) + chr(0b111101 + 0o67) + '\146' + chr(1635 - 1590) + chr(0b11100 + 0o34)))(v3VgwKX8w9JZ)
uCjCtz1_Wn1U = nzTpIcepk0o8('\x30' + chr(0b1000111 + 0o50) + chr(51), 8)
a9Ac2dnRYSi0 = nzTpIcepk0o8(chr(48) + '\157' + chr(0b110 + 0o55), 8)
b4gxT6pq1mdD = nzTpIcepk0o8('\060' + chr(10826 - 10715) + chr(0b110100) + chr(0b110000) + '\x30', 8)
Dmvx9BTTia8x = nzTpIcepk0o8(chr(0b110000) + chr(0b1001000 + 0o47) + chr(148 - 99), 8)
fxq3Mf2lCtQN = nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b100000 + 0o21), 8)
F9lJ8RbIonqb = nzTpIcepk0o8(chr(48) + chr(0b1110 + 0o141) + chr(0b1010 + 0o50), 8)
dvwd5q1TuiWX = pfzyJC7EQHEL(v3VgwKX8w9JZ, TtzqJLqe_ecy.EV56evGx0Qhj, TtzqJLqe_ecy.AfcIUN_Qr9y7, uCjCtz1_Wn1U, a9Ac2dnRYSi0, b4gxT6pq1mdD, Dmvx9BTTia8x, fxq3Mf2lCtQN, padding=roI3spqORKae(ES5oEprVxulp(b'\xa0\x99\xad\xb3'), '\x64' + '\145' + '\x63' + '\157' + chr(0b1100100) + chr(1584 - 1483))(chr(117) + '\164' + chr(102) + chr(0b11101 + 0o20) + chr(56)), group=F9lJ8RbIonqb)
jZutunlou7ZD = FyZE4zrPCXjA.nn.relu(dvwd5q1TuiWX)
if vLThzTu86svC == roI3spqORKae(ES5oEprVxulp(b'\x90\xb7\x8e\x80\xbd'), chr(0b1010000 + 0o24) + '\145' + '\x63' + '\157' + chr(100) + '\145')(chr(5684 - 5567) + chr(0b100011 + 0o121) + '\x66' + chr(45) + chr(56)):
return roI3spqORKae(FyZE4zrPCXjA.contrib.layers, roI3spqORKae(ES5oEprVxulp(b'\x84\xb7\x9a\x87\xcc2\xc1)z\xae\xc0T'), chr(0b111001 + 0o53) + '\145' + '\143' + chr(0b1101111) + chr(100) + chr(0b1100101))(chr(0b1110101) + chr(0b1110100) + chr(0b1100110) + chr(0b1010 + 0o43) + chr(811 - 755)))(jZutunlou7ZD)
uCjCtz1_Wn1U = nzTpIcepk0o8(chr(0b1110 + 0o42) + chr(0b1101111) + chr(0b110011), 8)
a9Ac2dnRYSi0 = nzTpIcepk0o8('\x30' + chr(0b1100010 + 0o15) + chr(0b110011), 8)
Dmvx9BTTia8x = nzTpIcepk0o8(chr(1668 - 1620) + '\157' + chr(414 - 364), 8)
fxq3Mf2lCtQN = nzTpIcepk0o8(chr(48) + '\x6f' + '\062', 8)
UXh69pZlc4If = roI3spqORKae(ES5oEprVxulp(b'\xa5\x99\xac\xbf\xcc'), chr(100) + chr(0b1100101) + '\x63' + '\x6f' + '\x64' + '\145')(chr(10794 - 10677) + chr(0b1101011 + 0o11) + chr(0b101100 + 0o72) + chr(0b11000 + 0o25) + chr(0b100101 + 0o23))
eutVo_hWyc5Y = FyZE4zrPCXjA.nn.max_pool(jZutunlou7ZD, ksize=[nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(2752 - 2641) + chr(0b100110 + 0o13), 8), uCjCtz1_Wn1U, a9Ac2dnRYSi0, nzTpIcepk0o8(chr(2016 - 1968) + chr(11552 - 11441) + '\061', 8)], strides=[nzTpIcepk0o8(chr(48) + chr(111) + '\x31', 8), Dmvx9BTTia8x, fxq3Mf2lCtQN, nzTpIcepk0o8('\060' + chr(0b1100011 + 0o14) + chr(49), 8)], padding=UXh69pZlc4If)
kOMW0E7u89i9 = FyZE4zrPCXjA.nn.relu_layer(FyZE4zrPCXjA.reshape(eutVo_hWyc5Y, [-nzTpIcepk0o8(chr(1915 - 1867) + chr(0b1101001 + 0o6) + '\061', 8), nzTpIcepk0o8(nDF4gVNx0u9Q.prod(eutVo_hWyc5Y.IQBeAtTmkxwI()[nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(107 - 58), 8):]))]), TtzqJLqe_ecy.coPNsw2BJGFW, TtzqJLqe_ecy.vZO9v86f6hLZ)
if vLThzTu86svC == roI3spqORKae(ES5oEprVxulp(b'\x95\xbb\xd6'), chr(0b10010 + 0o122) + '\145' + '\143' + '\x6f' + '\x64' + chr(101))('\165' + chr(0b1001001 + 0o53) + chr(102) + chr(45) + chr(250 - 194)):
return kOMW0E7u89i9
x8jUSvfUyJTc = FyZE4zrPCXjA.nn.relu_layer(kOMW0E7u89i9, TtzqJLqe_ecy.xALwK0_ExJij, TtzqJLqe_ecy.xO_00mjyi58J)
if vLThzTu86svC == roI3spqORKae(ES5oEprVxulp(b'\x95\xbb\xd7'), chr(4304 - 4204) + chr(101) + '\143' + chr(5200 - 5089) + '\x64' + chr(0b1100011 + 0o2))('\x75' + chr(116) + chr(3425 - 3323) + '\x2d' + chr(0b11011 + 0o35)):
return x8jUSvfUyJTc
S52qSu_SG477 = FyZE4zrPCXjA.nn.xw_plus_b(x8jUSvfUyJTc, TtzqJLqe_ecy.UlT2EGMjifwh, TtzqJLqe_ecy.Xt4s1gXuKEv0)
if vLThzTu86svC == roI3spqORKae(ES5oEprVxulp(b'\x95\xbb\xd8'), chr(0b1100100) + chr(9227 - 9126) + chr(99) + chr(0b1101111) + chr(100) + '\x65')('\x75' + chr(0b1110100) + chr(1105 - 1003) + '\055' + chr(0b111000)):
return S52qSu_SG477
miZza6ggsjTu = FyZE4zrPCXjA.nn.softmax(S52qSu_SG477)
return miZza6ggsjTu |
BerkeleyAutomation/perception | perception/feature_extractors.py | CNNBatchFeatureExtractor._forward_pass | def _forward_pass(self, images):
""" Forward pass a list of images through the CNN """
# form image array
num_images = len(images)
if num_images == 0:
return None
for image in images:
if not isinstance(image, Image):
new_images = []
for image in images:
if len(image.shape) > 2:
new_images.append(ColorImage(image, frame='unspecified'))
elif image.dtype == np.float32 or image.dtype == np.float64:
new_images.append(DepthImage(image, frame='unspecified'))
else:
raise ValueError('Image type not understood')
images = new_images
break
im_height = images[0].height
im_width = images[0].width
channels = images[0].channels
tensor_channels = 3
image_arr = np.zeros([num_images, im_height, im_width, tensor_channels])
for j, image in enumerate(images):
if channels == 3:
image_arr[j,:,:,:] = image.raw_data
else:
image_arr[j,:,:,:] = np.tile(image.raw_data, [1,1,1,3])
# predict
fp_start = time.time()
final_blobs = self.cnn_.featurize(image_arr)
fp_stop = time.time()
logging.debug('Featurization took %f sec per image' %((fp_stop - fp_start) / len(images)))
return final_blobs.reshape(final_blobs.shape[0], -1) | python | def _forward_pass(self, images):
""" Forward pass a list of images through the CNN """
# form image array
num_images = len(images)
if num_images == 0:
return None
for image in images:
if not isinstance(image, Image):
new_images = []
for image in images:
if len(image.shape) > 2:
new_images.append(ColorImage(image, frame='unspecified'))
elif image.dtype == np.float32 or image.dtype == np.float64:
new_images.append(DepthImage(image, frame='unspecified'))
else:
raise ValueError('Image type not understood')
images = new_images
break
im_height = images[0].height
im_width = images[0].width
channels = images[0].channels
tensor_channels = 3
image_arr = np.zeros([num_images, im_height, im_width, tensor_channels])
for j, image in enumerate(images):
if channels == 3:
image_arr[j,:,:,:] = image.raw_data
else:
image_arr[j,:,:,:] = np.tile(image.raw_data, [1,1,1,3])
# predict
fp_start = time.time()
final_blobs = self.cnn_.featurize(image_arr)
fp_stop = time.time()
logging.debug('Featurization took %f sec per image' %((fp_stop - fp_start) / len(images)))
return final_blobs.reshape(final_blobs.shape[0], -1) | [
"def",
"_forward_pass",
"(",
"self",
",",
"images",
")",
":",
"# form image array",
"num_images",
"=",
"len",
"(",
"images",
")",
"if",
"num_images",
"==",
"0",
":",
"return",
"None",
"for",
"image",
"in",
"images",
":",
"if",
"not",
"isinstance",
"(",
"image",
",",
"Image",
")",
":",
"new_images",
"=",
"[",
"]",
"for",
"image",
"in",
"images",
":",
"if",
"len",
"(",
"image",
".",
"shape",
")",
">",
"2",
":",
"new_images",
".",
"append",
"(",
"ColorImage",
"(",
"image",
",",
"frame",
"=",
"'unspecified'",
")",
")",
"elif",
"image",
".",
"dtype",
"==",
"np",
".",
"float32",
"or",
"image",
".",
"dtype",
"==",
"np",
".",
"float64",
":",
"new_images",
".",
"append",
"(",
"DepthImage",
"(",
"image",
",",
"frame",
"=",
"'unspecified'",
")",
")",
"else",
":",
"raise",
"ValueError",
"(",
"'Image type not understood'",
")",
"images",
"=",
"new_images",
"break",
"im_height",
"=",
"images",
"[",
"0",
"]",
".",
"height",
"im_width",
"=",
"images",
"[",
"0",
"]",
".",
"width",
"channels",
"=",
"images",
"[",
"0",
"]",
".",
"channels",
"tensor_channels",
"=",
"3",
"image_arr",
"=",
"np",
".",
"zeros",
"(",
"[",
"num_images",
",",
"im_height",
",",
"im_width",
",",
"tensor_channels",
"]",
")",
"for",
"j",
",",
"image",
"in",
"enumerate",
"(",
"images",
")",
":",
"if",
"channels",
"==",
"3",
":",
"image_arr",
"[",
"j",
",",
":",
",",
":",
",",
":",
"]",
"=",
"image",
".",
"raw_data",
"else",
":",
"image_arr",
"[",
"j",
",",
":",
",",
":",
",",
":",
"]",
"=",
"np",
".",
"tile",
"(",
"image",
".",
"raw_data",
",",
"[",
"1",
",",
"1",
",",
"1",
",",
"3",
"]",
")",
"# predict",
"fp_start",
"=",
"time",
".",
"time",
"(",
")",
"final_blobs",
"=",
"self",
".",
"cnn_",
".",
"featurize",
"(",
"image_arr",
")",
"fp_stop",
"=",
"time",
".",
"time",
"(",
")",
"logging",
".",
"debug",
"(",
"'Featurization took %f sec per image'",
"%",
"(",
"(",
"fp_stop",
"-",
"fp_start",
")",
"/",
"len",
"(",
"images",
")",
")",
")",
"return",
"final_blobs",
".",
"reshape",
"(",
"final_blobs",
".",
"shape",
"[",
"0",
"]",
",",
"-",
"1",
")"
] | Forward pass a list of images through the CNN | [
"Forward",
"pass",
"a",
"list",
"of",
"images",
"through",
"the",
"CNN"
] | 03d9b37dd6b66896cdfe173905c9413c8c3c5df6 | https://github.com/BerkeleyAutomation/perception/blob/03d9b37dd6b66896cdfe173905c9413c8c3c5df6/perception/feature_extractors.py#L51-L86 | train | Forward pass a list of images through the CNN | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,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8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + chr(0b110000 + 0o77) + chr(0b101111 + 0o2) + '\x36', ord("\x08")), nzTpIcepk0o8(chr(673 - 625) + chr(111) + chr(0b110001) + '\061' + chr(0b110101), 0o10), nzTpIcepk0o8('\060' + chr(2173 - 2062) + chr(0b110111) + chr(0b100 + 0o54), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110011) + chr(0b1100 + 0o50) + chr(55), 0b1000), nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(111) + '\x35', 0b1000), nzTpIcepk0o8('\x30' + chr(111) + chr(49) + chr(0b110011) + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + '\063' + chr(0b10 + 0o62) + chr(49), 30366 - 30358), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110001) + '\060' + chr(48), 18614 - 18606), nzTpIcepk0o8(chr(0b110000) + chr(5607 - 5496) + chr(0b110010) + chr(0b110111) + chr(1757 - 1708), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b100 + 0o153) + chr(0b11110 + 0o23) + chr(181 - 127) + chr(1459 - 1405), 0o10), nzTpIcepk0o8('\060' + chr(4231 - 4120) + chr(0b101111 + 0o5) + chr(850 - 799), 0o10), nzTpIcepk0o8(chr(1178 - 1130) + chr(11992 - 11881) + chr(830 - 781) + chr(49) + chr(53), 8), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(51) + chr(0b100101 + 0o15) + chr(0b110100), 0b1000), nzTpIcepk0o8(chr(0b100110 + 0o12) + chr(111) + '\x32' + '\061' + '\061', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b100000 + 0o21) + '\x31', 0o10), nzTpIcepk0o8(chr(0b1001 + 0o47) + chr(0b11110 + 0o121) + chr(1082 - 1032) + '\067' + '\066', 0b1000), nzTpIcepk0o8(chr(544 - 496) + '\157' + chr(49) + chr(836 - 783) + '\066', 0o10), nzTpIcepk0o8(chr(0b1000 + 0o50) + chr(0b1010111 + 0o30) + '\065' + '\x32', 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b101001 + 0o11) + chr(52) + '\062', ord("\x08")), nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(0b1101111) + chr(0b11100 + 0o27) + '\065' + chr(55), 58843 - 58835), nzTpIcepk0o8(chr(48) + chr(230 - 119) + '\x33' + chr(2736 - 2681) + chr(53), 0o10), nzTpIcepk0o8(chr(0b100100 + 0o14) + chr(0b1011000 + 0o27) + chr(0b10010 + 0o40) + chr(0b110000) + chr(610 - 556), 0o10), nzTpIcepk0o8('\x30' + chr(3418 - 3307) + chr(0b110001) + chr(53) + '\x37', 0b1000), nzTpIcepk0o8(chr(2289 - 2241) + chr(1952 - 1841) + chr(962 - 912) + '\x33', 0o10), nzTpIcepk0o8(chr(1035 - 987) + chr(111) + '\062' + chr(0b110110) + chr(0b11010 + 0o31), 21797 - 21789), nzTpIcepk0o8('\060' + chr(0b110110 + 0o71) + '\x31' + chr(0b110001) + chr(0b110010 + 0o1), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + '\062' + chr(0b110101) + chr(0b11111 + 0o26), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\062' + chr(2066 - 2011) + chr(1560 - 1507), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(108 - 57) + '\x32' + chr(49), 0b1000), nzTpIcepk0o8(chr(1052 - 1004) + '\x6f' + '\063' + chr(0b1110 + 0o44) + '\x36', 0o10), nzTpIcepk0o8('\x30' + chr(0b101101 + 0o102) + '\061' + chr(0b100100 + 0o17) + '\063', 30304 - 30296), nzTpIcepk0o8('\x30' + '\x6f' + '\x33' + chr(0b11111 + 0o27) + '\x35', 50082 - 50074), nzTpIcepk0o8('\060' + chr(11581 - 11470) + chr(0b101110 + 0o11), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110 + 0o56) + '\064', ord("\x08")), nzTpIcepk0o8(chr(0b1110 + 0o42) + chr(0b1101111) + '\x37' + '\x34', ord("\x08")), nzTpIcepk0o8(chr(0b101101 + 0o3) + chr(0b1101111) + '\067' + chr(0b11011 + 0o32), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + chr(0b10000 + 0o45) + '\064', 63901 - 63893), nzTpIcepk0o8(chr(0b110000) + chr(6419 - 6308) + chr(0b101101 + 0o4) + chr(532 - 477) + chr(0b110011), ord("\x08")), nzTpIcepk0o8(chr(0b100010 + 0o16) + chr(5829 - 5718) + '\062' + chr(2356 - 2304) + chr(2378 - 2329), 0o10), nzTpIcepk0o8(chr(1349 - 1301) + '\157' + chr(49), 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + chr(0b110010 + 0o75) + chr(53) + chr(48), ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b' '), chr(0b1100100) + '\x65' + '\x63' + '\157' + chr(100) + chr(101))(chr(0b1110101) + chr(2167 - 2051) + chr(0b11 + 0o143) + '\x2d' + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def hUUjz0JSNo8P(hXMPsSrOQzbh, e3y2UaQM9LGW):
tV2Tkt07h3x3 = ftfygxgFas5X(e3y2UaQM9LGW)
if tV2Tkt07h3x3 == nzTpIcepk0o8(chr(0b101001 + 0o7) + chr(0b1101111) + '\060', 0o10):
return None
for qqETtneJqWI2 in e3y2UaQM9LGW:
if not suIjIS24Zkqw(qqETtneJqWI2, RvV7ueTH51Uy):
VydwZnR7sef5 = []
for qqETtneJqWI2 in e3y2UaQM9LGW:
if ftfygxgFas5X(roI3spqORKae(qqETtneJqWI2, roI3spqORKae(ES5oEprVxulp(b'b%Z\xaa5c\xd3\x01\xff!\x1b+'), chr(1343 - 1243) + chr(6882 - 6781) + chr(99) + chr(111) + chr(0b101100 + 0o70) + chr(9685 - 9584))(chr(5774 - 5657) + chr(0b1110100) + chr(0b11001 + 0o115) + chr(0b101101) + chr(56)))) > nzTpIcepk0o8('\060' + '\x6f' + chr(50), 0o10):
roI3spqORKae(VydwZnR7sef5, roI3spqORKae(ES5oEprVxulp(b'F\x19k\xd3}=\xa6/\xd3\x19vx'), '\x64' + '\145' + '\143' + '\157' + chr(100) + chr(0b1100101))(chr(117) + chr(9139 - 9023) + '\x66' + chr(0b101101) + chr(2925 - 2869)))(lPn7XfHAFaXG(qqETtneJqWI2, frame=roI3spqORKae(ES5oEprVxulp(b'{#K\x97`9\x88&\xd0\x13G'), '\x64' + chr(2234 - 2133) + '\x63' + chr(0b1011011 + 0o24) + chr(100) + chr(10182 - 10081))(chr(0b1100101 + 0o20) + chr(5071 - 4955) + chr(5781 - 5679) + chr(45) + chr(0b1010 + 0o56))))
elif roI3spqORKae(qqETtneJqWI2, roI3spqORKae(ES5oEprVxulp(b'\\.`\xdeg8\x94\x0f\xc3\x1e\x16\x01'), chr(0b110 + 0o136) + chr(101) + chr(99) + chr(11519 - 11408) + chr(100) + chr(0b111 + 0o136))(chr(0b1110101) + chr(0b1110100) + '\146' + chr(45) + chr(56))) == roI3spqORKae(nDF4gVNx0u9Q, roI3spqORKae(ES5oEprVxulp(b'h!W\x86qi\xd3'), chr(100) + chr(101) + chr(99) + chr(0b111101 + 0o62) + chr(5556 - 5456) + chr(0b1100101))('\165' + '\x74' + chr(4138 - 4036) + '\055' + chr(0b1011 + 0o55))) or roI3spqORKae(qqETtneJqWI2, roI3spqORKae(ES5oEprVxulp(b'\\.`\xdeg8\x94\x0f\xc3\x1e\x16\x01'), chr(0b1100100) + chr(0b1100101) + chr(7598 - 7499) + '\x6f' + chr(3052 - 2952) + chr(0b1100101))(chr(0b11 + 0o162) + chr(0b1101 + 0o147) + chr(0b1110 + 0o130) + chr(0b100110 + 0o7) + '\070')) == roI3spqORKae(nDF4gVNx0u9Q, roI3spqORKae(ES5oEprVxulp(b'h!W\x86ql\xd5'), '\x64' + chr(101) + chr(0b110010 + 0o61) + chr(111) + chr(100) + '\x65')(chr(0b1110101) + '\164' + chr(102) + '\x2d' + chr(0b111000))):
roI3spqORKae(VydwZnR7sef5, roI3spqORKae(ES5oEprVxulp(b'F\x19k\xd3}=\xa6/\xd3\x19vx'), chr(0b1100100) + chr(9090 - 8989) + '\x63' + chr(111) + chr(0b1011111 + 0o5) + chr(0b1100101))('\x75' + chr(0b1110100) + chr(0b1100110) + chr(45) + '\x38'))(Ctd7ihpXT1E5(qqETtneJqWI2, frame=roI3spqORKae(ES5oEprVxulp(b'{#K\x97`9\x88&\xd0\x13G'), '\x64' + chr(4775 - 4674) + chr(0b1100011) + chr(0b1101111) + '\x64' + chr(0b1100101))(chr(117) + chr(116) + chr(0b1100110) + '\x2d' + '\070')))
else:
raise WbNHlDKpyPtQ(roI3spqORKae(ES5oEprVxulp(b'G Y\x80`z\x959\xc9\x13\x03#\xbb\xfd)\xcb\x00N\xc7\x9d\x8e\xf2\x00|\xd7'), chr(4890 - 4790) + chr(0b1100101) + '\x63' + '\x6f' + '\144' + chr(0b1001100 + 0o31))(chr(117) + chr(116) + chr(102) + '\x2d' + chr(0b111000)))
e3y2UaQM9LGW = VydwZnR7sef5
break
yThR6__gV4Fw = e3y2UaQM9LGW[nzTpIcepk0o8(chr(48) + chr(0b100011 + 0o114) + chr(0b110000), 8)].PaEBmun9J0YJ
SIbWxUnmkU6E = e3y2UaQM9LGW[nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b101001 + 0o7), 8)].dH3vcKdvgBu0
oOCpoykUobsP = e3y2UaQM9LGW[nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b1010 + 0o46), 8)].oOCpoykUobsP
fhMRdt9jrwe2 = nzTpIcepk0o8('\060' + chr(111) + chr(1852 - 1801), 0b1000)
elYnlWfgjJ0T = nDF4gVNx0u9Q.UmwwEp7MzR6q([tV2Tkt07h3x3, yThR6__gV4Fw, SIbWxUnmkU6E, fhMRdt9jrwe2])
for (sChW4gUsXrIC, qqETtneJqWI2) in _kV_Bomx8PZ4(e3y2UaQM9LGW):
if oOCpoykUobsP == nzTpIcepk0o8(chr(164 - 116) + '\x6f' + '\063', 8):
elYnlWfgjJ0T[sChW4gUsXrIC, :, :, :] = qqETtneJqWI2.nQhrgbgnEJqd
else:
elYnlWfgjJ0T[sChW4gUsXrIC, :, :, :] = nDF4gVNx0u9Q.udtPco1xxZHr(qqETtneJqWI2.nQhrgbgnEJqd, [nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(49), 8), nzTpIcepk0o8(chr(0b10000 + 0o40) + chr(0b1101111) + chr(0b110001), 8), nzTpIcepk0o8(chr(0b11101 + 0o23) + chr(0b1101111) + '\x31', 8), nzTpIcepk0o8(chr(877 - 829) + chr(0b1101111) + chr(0b110011), 8)])
KYMhGFIjy3_P = oprIvDIRQyCb.oprIvDIRQyCb()
abwo7tY59h3F = hXMPsSrOQzbh.cnn_.featurize(elYnlWfgjJ0T)
ZbrtMIJ1pIXt = oprIvDIRQyCb.oprIvDIRQyCb()
roI3spqORKae(Lj4gcNafqrcl, roI3spqORKae(ES5oEprVxulp(b'i\x0c\x01\xbd<>\x8ev\xec\x1bf\x17'), chr(0b10000 + 0o124) + chr(426 - 325) + '\x63' + chr(111) + chr(8261 - 8161) + chr(0b1100101))(chr(11663 - 11546) + chr(0b1110100) + chr(102) + chr(0b101001 + 0o4) + '\070'))(roI3spqORKae(ES5oEprVxulp(b'H(Y\x93p(\x88:\xd8\x02J"\xba\xa9}\xd1\x01A\x82\xca\x9b\xa6\x1cv\xd0k\xdd\xd8\xa3\xf62\x98fCY'), chr(0b1100100) + '\145' + chr(0b1100011) + '\157' + '\x64' + chr(101))(chr(0b1110101) + chr(9309 - 9193) + chr(0b1100110) + '\x2d' + chr(0b111000)) % ((ZbrtMIJ1pIXt - KYMhGFIjy3_P) / ftfygxgFas5X(e3y2UaQM9LGW)))
return roI3spqORKae(abwo7tY59h3F, roI3spqORKae(ES5oEprVxulp(b'|(K\x8fd*\x84'), '\144' + chr(101) + chr(99) + chr(0b1101111) + chr(5797 - 5697) + '\145')(chr(12517 - 12400) + chr(0b110010 + 0o102) + chr(0b1100110) + chr(1069 - 1024) + '\070'))(roI3spqORKae(abwo7tY59h3F, roI3spqORKae(ES5oEprVxulp(b'b%Z\xaa5c\xd3\x01\xff!\x1b+'), '\144' + chr(9686 - 9585) + '\143' + '\157' + '\x64' + '\x65')(chr(117) + chr(116) + chr(10185 - 10083) + '\x2d' + '\070'))[nzTpIcepk0o8(chr(0b110000) + chr(0b101 + 0o152) + chr(129 - 81), 8)], -nzTpIcepk0o8('\x30' + '\x6f' + chr(49), 8)) |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | Engine.repositories | def repositories(self):
"""
Returns a DataFrame with the data about the repositories found at
the specified repositories path in the form of siva files.
>>> repos_df = engine.repositories
:rtype: RepositoriesDataFrame
"""
return RepositoriesDataFrame(self.__engine.getRepositories(),
self.session, self.__implicits) | python | def repositories(self):
"""
Returns a DataFrame with the data about the repositories found at
the specified repositories path in the form of siva files.
>>> repos_df = engine.repositories
:rtype: RepositoriesDataFrame
"""
return RepositoriesDataFrame(self.__engine.getRepositories(),
self.session, self.__implicits) | [
"def",
"repositories",
"(",
"self",
")",
":",
"return",
"RepositoriesDataFrame",
"(",
"self",
".",
"__engine",
".",
"getRepositories",
"(",
")",
",",
"self",
".",
"session",
",",
"self",
".",
"__implicits",
")"
] | Returns a DataFrame with the data about the repositories found at
the specified repositories path in the form of siva files.
>>> repos_df = engine.repositories
:rtype: RepositoriesDataFrame | [
"Returns",
"a",
"DataFrame",
"with",
"the",
"data",
"about",
"the",
"repositories",
"found",
"at",
"the",
"specified",
"repositories",
"path",
"in",
"the",
"form",
"of",
"siva",
"files",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L57-L67 | train | Returns a DataFrame with the data about the repositories found at
the specified repositories path in the form of siva files. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st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dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b101000 + 0o10) + chr(0b1101111) + '\x30', 47569 - 47561), nzTpIcepk0o8('\x30' + chr(0b1101010 + 0o5) + chr(0b11000 + 0o31) + chr(2407 - 2357) + chr(1209 - 1159), 0b1000), nzTpIcepk0o8(chr(0b11110 + 0o22) + '\x6f' + chr(2151 - 2102) + chr(51) + chr(1184 - 1136), 0o10), nzTpIcepk0o8('\060' + chr(0b11111 + 0o120) + chr(0b11111 + 0o25) + '\x34', 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(518 - 468) + '\x36' + '\x37', 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\061' + chr(49) + '\061', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(51) + '\064' + '\063', ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + chr(50) + chr(0b110010) + chr(0b110010 + 0o1), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b101 + 0o55) + '\063' + chr(0b1011 + 0o50), 0b1000), nzTpIcepk0o8(chr(490 - 442) + chr(1484 - 1373) + chr(1979 - 1930) + '\x36' + chr(50), 0o10), nzTpIcepk0o8('\x30' + '\157' + chr(2233 - 2183) + chr(55) + chr(52), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(51) + chr(0b110101) + '\x33', 0b1000), nzTpIcepk0o8(chr(0b11101 + 0o23) + '\157' + chr(50) + chr(1374 - 1326) + chr(0b110101), 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(0b100000 + 0o22) + '\061', 0o10), nzTpIcepk0o8(chr(1395 - 1347) + chr(0b1101111) + chr(537 - 487) + chr(48) + '\x32', 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(54) + chr(1080 - 1027), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110101) + '\067', ord("\x08")), nzTpIcepk0o8(chr(418 - 370) + '\x6f' + '\x34' + chr(1419 - 1371), 55555 - 55547), nzTpIcepk0o8('\x30' + '\157' + chr(0b10011 + 0o36) + chr(0b110001) + chr(48), 0b1000), nzTpIcepk0o8(chr(0b11011 + 0o25) + chr(0b1101111) + chr(399 - 349) + chr(0b110000) + chr(1029 - 974), 61022 - 61014), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(1146 - 1094), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110011) + chr(51) + chr(2145 - 2096), 0o10), nzTpIcepk0o8('\x30' + chr(9153 - 9042) + chr(0b101100 + 0o6) + chr(0b100100 + 0o22) + chr(54), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b110001) + chr(52) + chr(0b101001 + 0o11), 50326 - 50318), nzTpIcepk0o8('\x30' + '\157' + chr(0b110010) + '\x33' + chr(2649 - 2597), ord("\x08")), nzTpIcepk0o8(chr(0b1010 + 0o46) + chr(6270 - 6159) + chr(50) + chr(0b100 + 0o56) + chr(1183 - 1134), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b0 + 0o64) + chr(0b110100), 8), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(1929 - 1875) + '\063', 0o10), nzTpIcepk0o8('\060' + '\157' + '\062' + chr(0b110000), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + chr(1811 - 1760) + '\066' + '\064', 0b1000), nzTpIcepk0o8(chr(48) + '\157' + '\061' + chr(0b111 + 0o57) + chr(48), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + chr(50) + chr(0b110100) + '\066', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(49) + chr(0b101100 + 0o10) + chr(0b10111 + 0o32), 0b1000), nzTpIcepk0o8('\060' + chr(0b1100011 + 0o14) + chr(0b110011) + chr(48) + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b1 + 0o63) + chr(53), 35541 - 35533), nzTpIcepk0o8(chr(0b110000) + chr(0b1010111 + 0o30) + chr(0b10010 + 0o41) + chr(1139 - 1091) + chr(49), 41281 - 41273), nzTpIcepk0o8(chr(0b1010 + 0o46) + chr(0b110 + 0o151) + '\x31' + chr(808 - 757) + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(1811 - 1763) + chr(0b10011 + 0o134) + chr(465 - 415) + '\066' + chr(905 - 853), 37176 - 37168), nzTpIcepk0o8(chr(0b100 + 0o54) + chr(0b1010101 + 0o32) + chr(210 - 157) + chr(49), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(10278 - 10167) + '\062' + chr(52), 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(434 - 386) + chr(0b1101111) + '\065' + chr(0b110000), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'.'), chr(100) + '\145' + chr(0b1100011) + chr(0b1101111) + chr(0b1100100) + chr(0b1100101))('\165' + chr(0b110111 + 0o75) + '\146' + chr(45) + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def nX3Bt32n_tcy(hXMPsSrOQzbh):
return bB5fFHS2Ze0m(roI3spqORKae(hXMPsSrOQzbh.__engine, roI3spqORKae(ES5oEprVxulp(b'g7,v\xd29\x8c\xe0\xf2\x06\xd3\x99\xect\xf1'), chr(0b110 + 0o136) + '\145' + '\x63' + '\157' + chr(0b1010000 + 0o24) + chr(0b1001000 + 0o35))(chr(0b1011110 + 0o27) + chr(0b1110100) + chr(0b1100110) + '\055' + chr(0b111000)))(), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'Oa\tr\xc7p\x87\xe0\xff1\xdb\x93'), chr(0b10000 + 0o124) + '\x65' + '\x63' + '\x6f' + chr(0b101111 + 0o65) + '\145')(chr(0b1110101) + '\x74' + chr(0b1101 + 0o131) + chr(0b101 + 0o50) + chr(56))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'_\r1I\xc7%\x8a\xf0\xf2\x06\xcf'), chr(0b11001 + 0o113) + chr(2445 - 2344) + chr(0b1100011) + '\157' + chr(2140 - 2040) + chr(8639 - 8538))('\x75' + chr(0b1110100) + chr(5015 - 4913) + chr(45) + chr(56)))) |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | Engine.blobs | def blobs(self, repository_ids=[], reference_names=[], commit_hashes=[]):
"""
Retrieves the blobs of a list of repositories, reference names and commit hashes.
So the result will be a DataFrame of all the blobs in the given commits that are
in the given references that belong to the given repositories.
>>> blobs_df = engine.blobs(repo_ids, ref_names, hashes)
Calling this function with no arguments is the same as:
>>> engine.repositories.references.commits.tree_entries.blobs
:param repository_ids: list of repository ids to filter by (optional)
:type repository_ids: list of strings
:param reference_names: list of reference names to filter by (optional)
:type reference_names: list of strings
:param commit_hashes: list of hashes to filter by (optional)
:type commit_hashes: list of strings
:rtype: BlobsDataFrame
"""
if not isinstance(repository_ids, list):
raise Exception("repository_ids must be a list")
if not isinstance(reference_names, list):
raise Exception("reference_names must be a list")
if not isinstance(commit_hashes, list):
raise Exception("commit_hashes must be a list")
return BlobsDataFrame(self.__engine.getBlobs(repository_ids,
reference_names,
commit_hashes),
self.session,
self.__implicits) | python | def blobs(self, repository_ids=[], reference_names=[], commit_hashes=[]):
"""
Retrieves the blobs of a list of repositories, reference names and commit hashes.
So the result will be a DataFrame of all the blobs in the given commits that are
in the given references that belong to the given repositories.
>>> blobs_df = engine.blobs(repo_ids, ref_names, hashes)
Calling this function with no arguments is the same as:
>>> engine.repositories.references.commits.tree_entries.blobs
:param repository_ids: list of repository ids to filter by (optional)
:type repository_ids: list of strings
:param reference_names: list of reference names to filter by (optional)
:type reference_names: list of strings
:param commit_hashes: list of hashes to filter by (optional)
:type commit_hashes: list of strings
:rtype: BlobsDataFrame
"""
if not isinstance(repository_ids, list):
raise Exception("repository_ids must be a list")
if not isinstance(reference_names, list):
raise Exception("reference_names must be a list")
if not isinstance(commit_hashes, list):
raise Exception("commit_hashes must be a list")
return BlobsDataFrame(self.__engine.getBlobs(repository_ids,
reference_names,
commit_hashes),
self.session,
self.__implicits) | [
"def",
"blobs",
"(",
"self",
",",
"repository_ids",
"=",
"[",
"]",
",",
"reference_names",
"=",
"[",
"]",
",",
"commit_hashes",
"=",
"[",
"]",
")",
":",
"if",
"not",
"isinstance",
"(",
"repository_ids",
",",
"list",
")",
":",
"raise",
"Exception",
"(",
"\"repository_ids must be a list\"",
")",
"if",
"not",
"isinstance",
"(",
"reference_names",
",",
"list",
")",
":",
"raise",
"Exception",
"(",
"\"reference_names must be a list\"",
")",
"if",
"not",
"isinstance",
"(",
"commit_hashes",
",",
"list",
")",
":",
"raise",
"Exception",
"(",
"\"commit_hashes must be a list\"",
")",
"return",
"BlobsDataFrame",
"(",
"self",
".",
"__engine",
".",
"getBlobs",
"(",
"repository_ids",
",",
"reference_names",
",",
"commit_hashes",
")",
",",
"self",
".",
"session",
",",
"self",
".",
"__implicits",
")"
] | Retrieves the blobs of a list of repositories, reference names and commit hashes.
So the result will be a DataFrame of all the blobs in the given commits that are
in the given references that belong to the given repositories.
>>> blobs_df = engine.blobs(repo_ids, ref_names, hashes)
Calling this function with no arguments is the same as:
>>> engine.repositories.references.commits.tree_entries.blobs
:param repository_ids: list of repository ids to filter by (optional)
:type repository_ids: list of strings
:param reference_names: list of reference names to filter by (optional)
:type reference_names: list of strings
:param commit_hashes: list of hashes to filter by (optional)
:type commit_hashes: list of strings
:rtype: BlobsDataFrame | [
"Retrieves",
"the",
"blobs",
"of",
"a",
"list",
"of",
"repositories",
"reference",
"names",
"and",
"commit",
"hashes",
".",
"So",
"the",
"result",
"will",
"be",
"a",
"DataFrame",
"of",
"all",
"the",
"blobs",
"in",
"the",
"given",
"commits",
"that",
"are",
"in",
"the",
"given",
"references",
"that",
"belong",
"to",
"the",
"given",
"repositories",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L70-L103 | train | Returns the blobs of a list of repositories reference names and commit hashes. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU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3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(933 - 885) + chr(111) + chr(50) + chr(52) + chr(0b110101), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110010) + chr(0b110100) + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b100101 + 0o16) + chr(0b11110 + 0o26), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b111 + 0o53) + '\060' + chr(1464 - 1411), 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(51) + chr(0b11000 + 0o34) + '\x30', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + '\064' + chr(48), 2416 - 2408), nzTpIcepk0o8('\060' + chr(0b1101110 + 0o1) + chr(0b110111) + '\062', 0b1000), nzTpIcepk0o8('\060' + chr(0b11000 + 0o127) + '\067' + '\x36', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110011) + chr(52), 8), nzTpIcepk0o8('\060' + chr(111) + '\x33' + chr(0b111 + 0o54) + chr(0b1011 + 0o47), ord("\x08")), nzTpIcepk0o8(chr(904 - 856) + chr(0b101 + 0o152) + '\063', 60755 - 60747), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(54) + '\x34', 0o10), nzTpIcepk0o8(chr(1660 - 1612) + chr(0b1101111) + '\x33' + '\x32' + chr(2227 - 2175), 1243 - 1235), nzTpIcepk0o8(chr(1281 - 1233) + chr(111) + '\x32' + chr(53) + '\x34', ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + '\061' + '\060', 45686 - 45678), nzTpIcepk0o8(chr(0b100101 + 0o13) + '\157' + '\x31' + chr(1067 - 1012) + '\x35', 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(0b110011) + chr(0b110010) + chr(49), 24870 - 24862), nzTpIcepk0o8(chr(0b11110 + 0o22) + '\157' + chr(54) + chr(0b110101), 0o10), nzTpIcepk0o8('\060' + '\157' + '\062' + chr(0b110011) + '\060', 19780 - 19772), nzTpIcepk0o8(chr(0b1100 + 0o44) + chr(111) + chr(0b110010) + chr(0b0 + 0o64) + chr(0b100100 + 0o22), 0o10), nzTpIcepk0o8(chr(1062 - 1014) + chr(0b1101111) + '\063' + '\x36' + '\x36', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(9800 - 9689) + '\x31' + '\062' + chr(2637 - 2585), 0o10), nzTpIcepk0o8(chr(70 - 22) + chr(139 - 28) + '\x32' + chr(53) + chr(2095 - 2044), 0o10), nzTpIcepk0o8(chr(48) + chr(1049 - 938) + '\x33' + '\060' + '\067', 0o10), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(0b1101111) + chr(0b10110 + 0o35) + chr(1453 - 1405), 51013 - 51005), nzTpIcepk0o8('\x30' + chr(111) + '\062' + chr(51) + chr(0b110110), ord("\x08")), nzTpIcepk0o8(chr(823 - 775) + chr(0b1110 + 0o141) + '\x33' + chr(52), 8), nzTpIcepk0o8('\060' + chr(1069 - 958) + chr(0b110110 + 0o0) + '\x35', 8), nzTpIcepk0o8(chr(0b100000 + 0o20) + '\157' + chr(51) + chr(0b100101 + 0o20) + '\x33', 7045 - 7037), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110010) + chr(272 - 221) + chr(0b110110 + 0o0), 8), nzTpIcepk0o8('\x30' + '\157' + chr(0b110011) + chr(51) + chr(192 - 140), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b10111 + 0o34) + chr(2499 - 2447) + '\060', 8), nzTpIcepk0o8(chr(1033 - 985) + chr(111) + '\066' + chr(0b110011), 736 - 728), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\062' + chr(2048 - 1996) + '\x31', 8), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b101111 + 0o4) + chr(48) + chr(0b110110), 0b1000), nzTpIcepk0o8(chr(0b10000 + 0o40) + '\x6f' + chr(0b11111 + 0o22) + chr(1896 - 1844) + chr(1344 - 1291), 0o10), nzTpIcepk0o8(chr(48) + chr(0b111010 + 0o65) + chr(191 - 142) + '\x33' + chr(48), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(0b101110 + 0o3) + '\061' + '\063', 0b1000), nzTpIcepk0o8('\060' + '\157' + '\x33' + chr(52) + '\x33', 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(2347 - 2294), 54940 - 54932)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + '\x6f' + chr(921 - 868) + chr(48), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x8b'), chr(0b1100100) + chr(101) + '\143' + '\x6f' + chr(100) + '\x65')(chr(117) + chr(0b1110100) + chr(0b110010 + 0o64) + '\x2d' + chr(56)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def pSFFgmGLEZNQ(hXMPsSrOQzbh, _y9Bo2JVy6Sv=[], Y7Y5gH6X6SNy=[], vUGHYUji2zan=[]):
if not suIjIS24Zkqw(_y9Bo2JVy6Sv, H4NoA26ON7iG):
raise zfo2Sgkz3IVJ(roI3spqORKae(ES5oEprVxulp(b'\xd7\xc4l\xea\x93INQn\xa3\\]\xb0\xdf(\x10\xa4F\xec\x86\x941\x8b\xa68\xf2uF\x9f'), chr(1417 - 1317) + chr(2643 - 2542) + chr(8856 - 8757) + chr(111) + chr(100) + chr(5171 - 5070))(chr(117) + chr(3691 - 3575) + chr(0b1011111 + 0o7) + chr(45) + '\070'))
if not suIjIS24Zkqw(Y7Y5gH6X6SNy, H4NoA26ON7iG):
raise zfo2Sgkz3IVJ(roI3spqORKae(ES5oEprVxulp(b'\xd7\xc4z\xe0\x92ET]y\x85mU\xb9\xc9{]\xbc@\xeb\xd2\xd66\xce\xe7y\xbep\\\x98\xea'), chr(100) + '\145' + '\143' + chr(1805 - 1694) + chr(0b1010 + 0o132) + '\145')(chr(4967 - 4850) + chr(2483 - 2367) + chr(8800 - 8698) + chr(0b1000 + 0o45) + chr(0b111000)))
if not suIjIS24Zkqw(vUGHYUji2zan, H4NoA26ON7iG):
raise zfo2Sgkz3IVJ(roI3spqORKae(ES5oEprVxulp(b'\xc6\xceq\xe8\x89TeV}\xa9kQ\xa7\x8ce\x08\xa2A\xb8\xc4\x93t\xca\xe7t\xf7oA'), chr(100) + chr(2101 - 2000) + chr(99) + chr(0b1101111) + chr(0b11011 + 0o111) + chr(0b1100101))('\x75' + chr(0b1110100) + '\x66' + '\x2d' + '\070'))
return gS351CfKgJ3N(roI3spqORKae(hXMPsSrOQzbh.__engine, roI3spqORKae(ES5oEprVxulp(b'\xc2\xc4h\xc7\x8cOXM'), chr(0b111100 + 0o50) + '\145' + chr(0b1100011) + chr(0b1101111) + chr(3331 - 3231) + chr(0b1100101))('\x75' + chr(0b1110100) + chr(0b1100110) + chr(0b100001 + 0o14) + '\x38'))(_y9Bo2JVy6Sv, Y7Y5gH6X6SNy, vUGHYUji2zan), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xea\x92M\xd3\x90\x19^Mx\x99dL'), chr(0b10110 + 0o116) + '\145' + chr(0b1010101 + 0o16) + chr(10828 - 10717) + '\144' + chr(0b1100101))(chr(0b1000111 + 0o56) + chr(183 - 67) + chr(102) + chr(0b101101) + chr(824 - 768))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xfa\xfeu\xe8\x90LS]u\xaep'), chr(1648 - 1548) + chr(101) + chr(7581 - 7482) + chr(0b100001 + 0o116) + chr(100) + chr(101))('\x75' + chr(5949 - 5833) + chr(0b110101 + 0o61) + chr(45) + '\070'))) |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | Engine.from_metadata | def from_metadata(self, db_path, db_name='engine_metadata.db'):
"""
Registers in the current session the views of the MetadataSource so the
data is obtained from the metadata database instead of reading the
repositories with the DefaultSource.
:param db_path: path to the folder that contains the database.
:type db_path: str
:param db_name: name of the database file (engine_metadata.db) by default.
:type db_name: str
:returns: the same instance of the engine
:rtype: Engine
"""
self.__engine.fromMetadata(db_path, db_name)
return self | python | def from_metadata(self, db_path, db_name='engine_metadata.db'):
"""
Registers in the current session the views of the MetadataSource so the
data is obtained from the metadata database instead of reading the
repositories with the DefaultSource.
:param db_path: path to the folder that contains the database.
:type db_path: str
:param db_name: name of the database file (engine_metadata.db) by default.
:type db_name: str
:returns: the same instance of the engine
:rtype: Engine
"""
self.__engine.fromMetadata(db_path, db_name)
return self | [
"def",
"from_metadata",
"(",
"self",
",",
"db_path",
",",
"db_name",
"=",
"'engine_metadata.db'",
")",
":",
"self",
".",
"__engine",
".",
"fromMetadata",
"(",
"db_path",
",",
"db_name",
")",
"return",
"self"
] | Registers in the current session the views of the MetadataSource so the
data is obtained from the metadata database instead of reading the
repositories with the DefaultSource.
:param db_path: path to the folder that contains the database.
:type db_path: str
:param db_name: name of the database file (engine_metadata.db) by default.
:type db_name: str
:returns: the same instance of the engine
:rtype: Engine | [
"Registers",
"in",
"the",
"current",
"session",
"the",
"views",
"of",
"the",
"MetadataSource",
"so",
"the",
"data",
"is",
"obtained",
"from",
"the",
"metadata",
"database",
"instead",
"of",
"reading",
"the",
"repositories",
"with",
"the",
"DefaultSource",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L106-L121 | train | Loads the metadata from the database at the specified path. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,Z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0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110010) + '\061' + chr(0b11011 + 0o30), 0o10), nzTpIcepk0o8(chr(224 - 176) + '\x6f' + chr(0b110000 + 0o1) + '\060' + chr(49), 0o10), nzTpIcepk0o8(chr(0b1011 + 0o45) + '\157' + '\x35' + chr(48), 0o10), nzTpIcepk0o8('\060' + '\x6f' + chr(241 - 191) + chr(50) + chr(0b110010), 0b1000), nzTpIcepk0o8('\060' + '\157' + '\061' + chr(0b110010) + chr(52), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1000110 + 0o51) + chr(0b10100 + 0o41) + '\x30', 8), nzTpIcepk0o8('\060' + chr(111) + '\x32' + chr(0b110011 + 0o1) + chr(0b110110), 0b1000), nzTpIcepk0o8('\060' + chr(5833 - 5722) + '\x37' + chr(0b110100), 35605 - 35597), nzTpIcepk0o8(chr(2000 - 1952) + chr(0b1101111) + chr(50) + '\x33', 36555 - 36547), nzTpIcepk0o8(chr(0b100100 + 0o14) + chr(0b1101111) + chr(51) + chr(1620 - 1569), 0o10), nzTpIcepk0o8('\060' + chr(8889 - 8778) + chr(2382 - 2333) + chr(2480 - 2429) + chr(0b110000 + 0o2), 2026 - 2018), nzTpIcepk0o8(chr(0b10000 + 0o40) + '\157' + '\x31' + '\066' + '\065', 39584 - 39576), nzTpIcepk0o8(chr(80 - 32) + '\157' + '\061' + chr(0b110111) + '\x34', 37631 - 37623), nzTpIcepk0o8(chr(0b101000 + 0o10) + '\157' + chr(57 - 8) + '\x35' + chr(0b110110), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1100010 + 0o15) + '\061' + chr(50) + '\062', 0o10), nzTpIcepk0o8(chr(2141 - 2093) + chr(0b111110 + 0o61) + '\066' + chr(0b100001 + 0o22), 4458 - 4450), nzTpIcepk0o8(chr(0b101100 + 0o4) + '\x6f' + chr(0b110101) + chr(0b110100), 48922 - 48914), nzTpIcepk0o8(chr(59 - 11) + '\157' + chr(0b0 + 0o61) + chr(0b110110 + 0o1) + '\x33', ord("\x08")), nzTpIcepk0o8(chr(766 - 718) + '\x6f' + '\x32' + chr(0b110011 + 0o2) + '\x36', 0o10), nzTpIcepk0o8(chr(53 - 5) + chr(111) + chr(49) + chr(0b110000) + chr(0b10011 + 0o43), 65367 - 65359), nzTpIcepk0o8(chr(1399 - 1351) + chr(0b1010000 + 0o37) + '\062' + '\060' + chr(0b100 + 0o57), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x32' + chr(2185 - 2134) + chr(49), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\x31' + '\x32' + chr(0b110111), 0o10), nzTpIcepk0o8(chr(1778 - 1730) + '\157' + chr(48), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1100111 + 0o10) + '\x36' + chr(2051 - 1996), 31335 - 31327), nzTpIcepk0o8(chr(0b11010 + 0o26) + chr(111) + chr(1623 - 1569) + chr(0b110101), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b11010 + 0o125) + chr(956 - 906) + chr(0b100011 + 0o15) + '\067', 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b110011) + chr(0b110001) + chr(921 - 866), 0b1000), nzTpIcepk0o8('\060' + chr(4387 - 4276) + chr(131 - 82) + chr(0b100101 + 0o16), 18723 - 18715), nzTpIcepk0o8(chr(516 - 468) + chr(111) + chr(55) + chr(53), 0b1000), nzTpIcepk0o8(chr(1735 - 1687) + chr(0b1010101 + 0o32) + chr(0b110001) + chr(1166 - 1112) + chr(2296 - 2244), 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + '\x32' + chr(48) + chr(386 - 331), 8), nzTpIcepk0o8(chr(2200 - 2152) + '\157' + chr(1928 - 1879) + chr(54) + '\x34', 8), nzTpIcepk0o8(chr(0b110000) + chr(3787 - 3676) + '\x34' + chr(0b110010), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\062' + chr(2099 - 2050) + '\064', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b1111 + 0o43) + chr(0b110101 + 0o1) + chr(0b100110 + 0o15), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + '\063' + '\062' + '\067', 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b10111 + 0o34) + '\x30' + '\067', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1000011 + 0o54) + chr(1548 - 1498) + chr(48) + chr(51), 8), nzTpIcepk0o8('\060' + '\157' + '\x31' + chr(176 - 126) + '\x37', 8)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(111) + chr(2641 - 2588) + '\060', 8)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xa5'), chr(0b111101 + 0o47) + '\145' + chr(1919 - 1820) + chr(6659 - 6548) + chr(9388 - 9288) + '\145')('\x75' + chr(0b1010011 + 0o41) + chr(0b1001000 + 0o36) + chr(981 - 936) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def FIRCM5xnOssB(hXMPsSrOQzbh, mnidVjaAt9P3, WoqWyHJXFrZv=roI3spqORKae(ES5oEprVxulp(b'\xee/O\xfb:M\xf9Qvo;\x11\x1d\x1a3\x1dH\x19'), chr(0b1000 + 0o134) + chr(9457 - 9356) + '\143' + chr(0b1100010 + 0o15) + '\144' + chr(4136 - 4035))('\x75' + '\x74' + '\x66' + chr(332 - 287) + chr(0b111000))):
roI3spqORKae(hXMPsSrOQzbh.__engine, roI3spqORKae(ES5oEprVxulp(b'\xed3G\xff\x19M\xd2]wz.\x14'), chr(100) + chr(0b1011111 + 0o6) + chr(0b0 + 0o143) + '\157' + chr(0b1011 + 0o131) + chr(0b1010100 + 0o21))('\x75' + chr(0b11011 + 0o131) + chr(102) + '\x2d' + '\070'))(mnidVjaAt9P3, WoqWyHJXFrZv)
return hXMPsSrOQzbh |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | SourcedDataFrame.__generate_method | def __generate_method(name):
"""
Wraps the DataFrame's original method by name to return the derived class instance.
"""
try:
func = getattr(DataFrame, name)
except AttributeError as e:
# PySpark version is too old
def func(self, *args, **kwargs):
raise e
return func
wraps = getattr(functools, "wraps", lambda _: lambda f: f) # py3.4+
@wraps(func)
def _wrapper(self, *args, **kwargs):
dataframe = func(self, *args, **kwargs)
if self.__class__ != SourcedDataFrame \
and isinstance(self, SourcedDataFrame) \
and isinstance(dataframe, DataFrame):
return self.__class__(dataframe._jdf, self._session, self._implicits)
return dataframe
return _wrapper | python | def __generate_method(name):
"""
Wraps the DataFrame's original method by name to return the derived class instance.
"""
try:
func = getattr(DataFrame, name)
except AttributeError as e:
# PySpark version is too old
def func(self, *args, **kwargs):
raise e
return func
wraps = getattr(functools, "wraps", lambda _: lambda f: f) # py3.4+
@wraps(func)
def _wrapper(self, *args, **kwargs):
dataframe = func(self, *args, **kwargs)
if self.__class__ != SourcedDataFrame \
and isinstance(self, SourcedDataFrame) \
and isinstance(dataframe, DataFrame):
return self.__class__(dataframe._jdf, self._session, self._implicits)
return dataframe
return _wrapper | [
"def",
"__generate_method",
"(",
"name",
")",
":",
"try",
":",
"func",
"=",
"getattr",
"(",
"DataFrame",
",",
"name",
")",
"except",
"AttributeError",
"as",
"e",
":",
"# PySpark version is too old",
"def",
"func",
"(",
"self",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"raise",
"e",
"return",
"func",
"wraps",
"=",
"getattr",
"(",
"functools",
",",
"\"wraps\"",
",",
"lambda",
"_",
":",
"lambda",
"f",
":",
"f",
")",
"# py3.4+",
"@",
"wraps",
"(",
"func",
")",
"def",
"_wrapper",
"(",
"self",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"dataframe",
"=",
"func",
"(",
"self",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
"if",
"self",
".",
"__class__",
"!=",
"SourcedDataFrame",
"and",
"isinstance",
"(",
"self",
",",
"SourcedDataFrame",
")",
"and",
"isinstance",
"(",
"dataframe",
",",
"DataFrame",
")",
":",
"return",
"self",
".",
"__class__",
"(",
"dataframe",
".",
"_jdf",
",",
"self",
".",
"_session",
",",
"self",
".",
"_implicits",
")",
"return",
"dataframe",
"return",
"_wrapper"
] | Wraps the DataFrame's original method by name to return the derived class instance. | [
"Wraps",
"the",
"DataFrame",
"s",
"original",
"method",
"by",
"name",
"to",
"return",
"the",
"derived",
"class",
"instance",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L176-L198 | train | A decorator that returns the original method by name to return the derived class instance. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmW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qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(428 - 380) + chr(0b1100110 + 0o11) + chr(0b100011 + 0o17) + chr(776 - 726) + chr(0b10001 + 0o41), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(1385 - 1334) + chr(50) + chr(1545 - 1495), 0b1000), nzTpIcepk0o8(chr(2123 - 2075) + chr(0b1101111) + chr(0b110011) + '\066' + chr(0b110001 + 0o1), 0b1000), nzTpIcepk0o8(chr(0b100001 + 0o17) + chr(0b100001 + 0o116) + '\067' + chr(55), ord("\x08")), nzTpIcepk0o8(chr(832 - 784) + chr(111) + chr(0b1011 + 0o50) + chr(51), 45670 - 45662), nzTpIcepk0o8(chr(0b110000) + chr(4735 - 4624) + chr(49) + chr(0b110001) + '\066', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110001) + chr(51) + chr(460 - 408), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(11394 - 11283) + '\063' + chr(0b110110) + '\x35', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x31' + chr(0b1010 + 0o51) + chr(0b110001), 0o10), nzTpIcepk0o8('\060' + chr(7757 - 7646) + chr(743 - 689) + chr(1672 - 1617), 8895 - 8887), nzTpIcepk0o8(chr(48) + chr(6807 - 6696) + chr(0b110011) + chr(49) + chr(0b100111 + 0o15), 15800 - 15792), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b10 + 0o60), ord("\x08")), nzTpIcepk0o8(chr(1610 - 1562) + chr(111) + chr(0b10 + 0o57) + '\x37' + '\061', 55684 - 55676), nzTpIcepk0o8('\x30' + chr(111) + chr(0b101110 + 0o4) + chr(0b110111) + '\x30', 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(0b10101 + 0o35) + chr(0b1 + 0o65) + '\x36', ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + '\x33' + chr(0b110110) + chr(0b100010 + 0o17), 0o10), nzTpIcepk0o8(chr(922 - 874) + chr(111) + chr(2106 - 2057) + chr(49) + chr(0b100010 + 0o24), 8), nzTpIcepk0o8('\060' + chr(2070 - 1959) + chr(0b110100) + chr(500 - 446), 0b1000), nzTpIcepk0o8(chr(48) + '\157' + chr(50) + '\x31' + chr(51), 0o10), nzTpIcepk0o8(chr(0b1110 + 0o42) + '\157' + chr(50) + '\x36' + chr(55), ord("\x08")), nzTpIcepk0o8(chr(0b1010 + 0o46) + '\x6f' + '\x32' + chr(0b101011 + 0o7) + chr(1994 - 1942), ord("\x08")), nzTpIcepk0o8(chr(819 - 771) + chr(2086 - 1975) + chr(2348 - 2297) + chr(0b110000) + chr(2646 - 2592), 0o10), nzTpIcepk0o8(chr(87 - 39) + '\157' + chr(51) + '\063', 8), nzTpIcepk0o8(chr(1657 - 1609) + chr(2538 - 2427) + chr(0b110111) + '\x34', 0b1000), nzTpIcepk0o8(chr(960 - 912) + '\x6f' + chr(0b110011) + '\x31' + chr(0b1011 + 0o46), ord("\x08")), nzTpIcepk0o8(chr(0b111 + 0o51) + '\x6f' + chr(0b1100 + 0o45) + '\064' + '\x32', 0b1000), nzTpIcepk0o8(chr(48) + '\x6f' + chr(50) + chr(0b110101) + chr(1438 - 1384), 0o10), nzTpIcepk0o8(chr(0b100111 + 0o11) + chr(111) + chr(2311 - 2260) + chr(49) + chr(0b10010 + 0o37), 8), nzTpIcepk0o8(chr(48) + chr(0b100 + 0o153) + chr(0b110001) + chr(1505 - 1451) + chr(51), ord("\x08")), nzTpIcepk0o8(chr(0b1010 + 0o46) + chr(4270 - 4159) + chr(50) + chr(51) + chr(0b100110 + 0o12), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101010 + 0o5) + chr(984 - 933) + chr(0b110000) + '\x36', 8), nzTpIcepk0o8('\060' + chr(508 - 397) + '\x31' + chr(55) + chr(2168 - 2113), 46317 - 46309), nzTpIcepk0o8(chr(0b100100 + 0o14) + chr(11664 - 11553) + chr(2077 - 2026) + chr(1024 - 973) + chr(48), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(0b10 + 0o61) + '\065' + chr(51), 6878 - 6870), nzTpIcepk0o8(chr(48) + chr(0b111010 + 0o65) + chr(50) + chr(50) + '\060', 0b1000), nzTpIcepk0o8('\x30' + chr(0b1001111 + 0o40) + chr(0b110010 + 0o0) + '\x36' + chr(0b100100 + 0o17), 64651 - 64643), nzTpIcepk0o8(chr(48) + chr(0b1101000 + 0o7) + chr(0b100000 + 0o27) + chr(1753 - 1704), 56534 - 56526), nzTpIcepk0o8(chr(0b11111 + 0o21) + chr(111) + '\x32' + chr(52) + chr(0b101101 + 0o7), 0o10), nzTpIcepk0o8(chr(1961 - 1913) + '\x6f' + chr(0b110001) + chr(54) + chr(0b101101 + 0o10), 0o10), nzTpIcepk0o8('\060' + chr(0b101 + 0o152) + '\063' + chr(0b100111 + 0o14) + chr(0b110100 + 0o0), 0b1000)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + '\x6f' + '\065' + chr(48), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xbc'), chr(7408 - 7308) + '\145' + '\143' + chr(0b1101111) + chr(100) + '\x65')('\165' + chr(0b1110100) + '\146' + chr(1917 - 1872) + chr(0b111000)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def RFIOVmhFkyB8(SLVB2BPA_mIe):
try:
h0klhChk4Vv6 = roI3spqORKae(sjZGDTWo_6_o, SLVB2BPA_mIe)
except bIsJhlpYrrU2 as wgf0sgcu_xPL:
def h0klhChk4Vv6(hXMPsSrOQzbh, *eemPYp2vtTSr, **q5n0sHDDTy90):
raise wgf0sgcu_xPL
return h0klhChk4Vv6
pyQaWxg2ZDJP = roI3spqORKae(NveCASsculZA, roI3spqORKae(ES5oEprVxulp(b'\xe5\xa0\x93Oh'), '\144' + '\x65' + '\143' + chr(0b1101111) + chr(0b1000100 + 0o40) + chr(0b1001011 + 0o32))(chr(0b1011100 + 0o31) + '\164' + chr(6984 - 6882) + chr(0b101101) + chr(2255 - 2199)), lambda zIqcgNgQ9U6F: lambda _R8IKF5IwAfX: _R8IKF5IwAfX)
@pyQaWxg2ZDJP(h0klhChk4Vv6)
def fvICIDG2JLAs(hXMPsSrOQzbh, *eemPYp2vtTSr, **q5n0sHDDTy90):
JGOfJ3ibSnmm = h0klhChk4Vv6(hXMPsSrOQzbh, *eemPYp2vtTSr, **q5n0sHDDTy90)
if roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xff\xa1\xc6\x06o,\r\x94\x0f|\xbbC'), chr(0b1100100) + chr(0b1100101) + chr(99) + '\157' + chr(0b110000 + 0o64) + '\145')(chr(0b1110101) + '\x74' + '\x66' + chr(45) + '\x38')) != Oqph4uIOTSu0 and suIjIS24Zkqw(hXMPsSrOQzbh, Oqph4uIOTSu0) and suIjIS24Zkqw(JGOfJ3ibSnmm, sjZGDTWo_6_o):
return roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xff\xa1\xc6\x06o,\r\x94\x0f|\xbbC'), chr(0b1100100) + '\145' + chr(0b1010000 + 0o23) + chr(8447 - 8336) + chr(100) + chr(0b1101 + 0o130))('\x75' + '\x74' + chr(4461 - 4359) + chr(0b100 + 0o51) + '\070'))(roI3spqORKae(JGOfJ3ibSnmm, roI3spqORKae(ES5oEprVxulp(b'\xcd\xb8\x96Y'), chr(2561 - 2461) + chr(0b1100101) + '\143' + chr(2661 - 2550) + chr(7472 - 7372) + chr(0b1100101))('\165' + chr(7997 - 7881) + chr(0b1110 + 0o130) + '\x2d' + chr(56))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xc4\xbd\xc1F]#\x18\x9c1\x07\x86c'), chr(0b100001 + 0o103) + chr(0b1100101) + '\143' + chr(0b1100010 + 0o15) + '\x64' + chr(0b110000 + 0o65))('\165' + chr(0b1110100) + '\x66' + '\055' + chr(0b110001 + 0o7))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b"\xcd\xbb\x9fOw'?\x9c-D"), chr(8727 - 8627) + chr(0b110 + 0o137) + chr(1049 - 950) + '\x6f' + chr(623 - 523) + chr(0b1100101))(chr(12419 - 12302) + chr(0b1010010 + 0o42) + chr(2399 - 2297) + chr(1555 - 1510) + chr(1586 - 1530))))
return JGOfJ3ibSnmm
return fvICIDG2JLAs |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | RepositoriesDataFrame.references | def references(self):
"""
Returns the joined DataFrame of references and repositories.
>>> refs_df = repos_df.references
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self._engine_dataframe.getReferences(),
self._session, self._implicits) | python | def references(self):
"""
Returns the joined DataFrame of references and repositories.
>>> refs_df = repos_df.references
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self._engine_dataframe.getReferences(),
self._session, self._implicits) | [
"def",
"references",
"(",
"self",
")",
":",
"return",
"ReferencesDataFrame",
"(",
"self",
".",
"_engine_dataframe",
".",
"getReferences",
"(",
")",
",",
"self",
".",
"_session",
",",
"self",
".",
"_implicits",
")"
] | Returns the joined DataFrame of references and repositories.
>>> refs_df = repos_df.references
:rtype: ReferencesDataFrame | [
"Returns",
"the",
"joined",
"DataFrame",
"of",
"references",
"and",
"repositories",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L261-L270 | train | Returns the joined DataFrame of references and repositories. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DH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VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(1850 - 1802) + '\157' + '\062' + '\x34' + '\064', ord("\x08")), nzTpIcepk0o8(chr(0b101 + 0o53) + chr(921 - 810) + chr(0b1100 + 0o46) + chr(50) + '\x34', ord("\x08")), nzTpIcepk0o8('\060' + chr(0b110110 + 0o71) + '\x32' + '\x34' + chr(1220 - 1166), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\062' + chr(0b110001) + '\x37', 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(51) + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(0b100 + 0o54) + chr(0b1010 + 0o145) + chr(0b110011) + chr(0b100100 + 0o17), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(0b10111 + 0o32) + '\064' + chr(49), ord("\x08")), nzTpIcepk0o8(chr(1718 - 1670) + chr(11719 - 11608) + '\063' + chr(48) + chr(0b110110), 61501 - 61493), nzTpIcepk0o8(chr(0b110000) + chr(6603 - 6492) + '\061' + '\x34', 0o10), nzTpIcepk0o8(chr(48) + chr(7016 - 6905) + chr(0b100 + 0o55) + '\061' + chr(177 - 125), ord("\x08")), nzTpIcepk0o8(chr(0b101011 + 0o5) + chr(0b1000 + 0o147) + chr(0b110001) + chr(0b101001 + 0o15) + chr(0b100101 + 0o20), 0o10), nzTpIcepk0o8(chr(48) + chr(0b0 + 0o157) + chr(346 - 295) + '\x37' + '\061', 0b1000), nzTpIcepk0o8(chr(905 - 857) + chr(0b1101111) + '\062' + chr(0b100 + 0o60) + chr(0b1011 + 0o52), 0o10), nzTpIcepk0o8(chr(175 - 127) + '\x6f' + chr(0b110001) + chr(0b110110) + chr(0b110001), 34016 - 34008), nzTpIcepk0o8('\060' + chr(111) + '\x32' + chr(160 - 109) + chr(0b11001 + 0o27), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(0b11000 + 0o33) + chr(0b101100 + 0o6) + '\062', 34721 - 34713), nzTpIcepk0o8(chr(48) + chr(475 - 364) + chr(0b110011) + chr(48) + chr(0b110001), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b11 + 0o57) + chr(51) + chr(0b110111), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + chr(50) + chr(2491 - 2440) + chr(400 - 352), 8), nzTpIcepk0o8(chr(48) + '\x6f' + chr(49) + chr(0b1 + 0o60) + '\x37', 10279 - 10271), nzTpIcepk0o8(chr(1205 - 1157) + '\x6f' + chr(0b110011) + chr(48) + chr(802 - 754), 0b1000), nzTpIcepk0o8(chr(737 - 689) + chr(111) + chr(51) + chr(54) + '\x35', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(11828 - 11717) + chr(319 - 270) + '\063' + chr(0b1110 + 0o50), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + '\x31' + chr(0b110101) + chr(0b110100), ord("\x08")), nzTpIcepk0o8('\060' + chr(8199 - 8088) + chr(2265 - 2216) + '\x36', ord("\x08")), nzTpIcepk0o8(chr(0b100011 + 0o15) + chr(111) + chr(1388 - 1339) + chr(0b100000 + 0o26) + '\x37', 0b1000), nzTpIcepk0o8('\060' + chr(0b1000110 + 0o51) + chr(52) + chr(0b1101 + 0o50), 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(1266 - 1216) + chr(0b1011 + 0o53) + chr(581 - 531), ord("\x08")), nzTpIcepk0o8('\x30' + chr(10004 - 9893) + chr(51) + chr(50), ord("\x08")), nzTpIcepk0o8(chr(0b110 + 0o52) + '\157' + chr(0b100 + 0o56) + '\067' + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(48) + '\157' + chr(0b110001) + chr(51) + chr(55), ord("\x08")), nzTpIcepk0o8(chr(1611 - 1563) + chr(111) + chr(498 - 447) + chr(272 - 218) + chr(1072 - 1023), 15310 - 15302), nzTpIcepk0o8(chr(0b110000) + chr(0b101000 + 0o107) + chr(0b110011) + '\x37' + chr(0b110110), 0b1000), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(0b1101111) + '\063' + chr(1010 - 962) + chr(0b110100), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b10100 + 0o133) + chr(1193 - 1143) + chr(0b111 + 0o54) + chr(2700 - 2645), 8), nzTpIcepk0o8('\060' + '\157' + chr(2017 - 1968) + chr(55) + '\060', 0o10), nzTpIcepk0o8(chr(0b101111 + 0o1) + '\157' + '\061' + chr(48) + '\067', 56162 - 56154), nzTpIcepk0o8('\060' + chr(0b1100100 + 0o13) + '\067' + chr(1171 - 1118), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(7138 - 7027) + chr(0b110001) + chr(2223 - 2171) + chr(52), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(111) + chr(2067 - 2017), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8('\x30' + chr(0b1011100 + 0o23) + chr(1418 - 1365) + chr(0b110000), 18314 - 18306)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x8a'), chr(6138 - 6038) + '\145' + '\143' + '\x6f' + chr(100) + chr(0b101100 + 0o71))(chr(0b1001001 + 0o54) + '\x74' + chr(0b1100110) + chr(45) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def hzye4wU5t4Tl(hXMPsSrOQzbh):
return eqhlVS96SzjF(roI3spqORKae(hXMPsSrOQzbh._engine_dataframe, roI3spqORKae(ES5oEprVxulp(b'\xc3\xf1\xd2\xddz}\x04\xb4i"\x16\x9c\xd6'), '\x64' + chr(2726 - 2625) + chr(0b100100 + 0o77) + chr(7657 - 7546) + '\144' + chr(0b1100101))(chr(4151 - 4034) + chr(116) + '\146' + chr(0b0 + 0o55) + chr(0b110011 + 0o5)))(), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xf2\xfb\x95\xf6Yv%\xafd|?\x98'), chr(100) + chr(290 - 189) + chr(0b1000000 + 0o43) + chr(0b1101111) + '\x64' + chr(0b1100101))('\165' + chr(116) + chr(0b1100110) + chr(433 - 388) + '\x38')), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xfb\xfd\xcb\xffsr\x02\xafx?'), chr(1464 - 1364) + chr(101) + chr(0b1100011) + chr(0b1101111) + '\144' + chr(101))(chr(117) + chr(0b1110100) + chr(102) + chr(0b101101) + '\070'))) |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | RepositoriesDataFrame.remote_references | def remote_references(self):
"""
Returns a new DataFrame with only the remote references of the
current repositories.
>>> remote_refs_df = repos_df.remote_references
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self._engine_dataframe.getRemoteReferences(),
self._session, self._implicits) | python | def remote_references(self):
"""
Returns a new DataFrame with only the remote references of the
current repositories.
>>> remote_refs_df = repos_df.remote_references
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self._engine_dataframe.getRemoteReferences(),
self._session, self._implicits) | [
"def",
"remote_references",
"(",
"self",
")",
":",
"return",
"ReferencesDataFrame",
"(",
"self",
".",
"_engine_dataframe",
".",
"getRemoteReferences",
"(",
")",
",",
"self",
".",
"_session",
",",
"self",
".",
"_implicits",
")"
] | Returns a new DataFrame with only the remote references of the
current repositories.
>>> remote_refs_df = repos_df.remote_references
:rtype: ReferencesDataFrame | [
"Returns",
"a",
"new",
"DataFrame",
"with",
"only",
"the",
"remote",
"references",
"of",
"the",
"current",
"repositories",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L274-L284 | train | Returns a new DataFrame with only the remote references of the
current repositories. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60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Ie5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b101001 + 0o7) + chr(111) + '\061' + '\063' + chr(241 - 193), 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(650 - 601) + '\x35' + '\062', 0o10), nzTpIcepk0o8(chr(1940 - 1892) + chr(7963 - 7852) + chr(0b11010 + 0o31) + chr(2893 - 2839) + '\x36', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(279 - 168) + '\x32' + chr(0b100000 + 0o22) + chr(1058 - 1010), 0b1000), nzTpIcepk0o8(chr(48) + chr(7353 - 7242) + chr(49) + chr(0b100110 + 0o15) + chr(0b10100 + 0o42), 0b1000), nzTpIcepk0o8(chr(1530 - 1482) + chr(9541 - 9430) + chr(995 - 945) + '\064' + chr(0b11101 + 0o23), 57878 - 57870), nzTpIcepk0o8(chr(0b110000) + chr(0b100111 + 0o110) + chr(0b110001) + chr(54) + '\x30', 0b1000), nzTpIcepk0o8('\060' + chr(111) + chr(0b11011 + 0o26) + chr(590 - 538) + chr(186 - 136), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(54) + chr(0b11000 + 0o32), 45538 - 45530), nzTpIcepk0o8(chr(1417 - 1369) + chr(111) + chr(344 - 292) + chr(0b101000 + 0o15), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(1594 - 1544) + '\x30' + '\061', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b110 + 0o151) + chr(1512 - 1462) + chr(55), ord("\x08")), nzTpIcepk0o8(chr(698 - 650) + chr(111) + '\x37' + chr(1941 - 1886), 45512 - 45504), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110001) + '\064' + chr(52), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(0b110 + 0o53) + chr(0b11011 + 0o25) + chr(0b110000 + 0o5), 49131 - 49123), nzTpIcepk0o8(chr(2246 - 2198) + chr(2687 - 2576) + chr(0b110001) + chr(0b1100 + 0o50) + '\x32', 8), nzTpIcepk0o8(chr(178 - 130) + '\157' + chr(0b101001 + 0o11) + '\x37' + '\067', 42114 - 42106), nzTpIcepk0o8(chr(0b110000) + '\x6f' + chr(0b110011) + chr(0b110011) + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1011000 + 0o27) + '\061' + chr(0b110111) + '\060', 45750 - 45742), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\061' + chr(52) + chr(54), 0b1000), nzTpIcepk0o8(chr(1926 - 1878) + chr(0b1100000 + 0o17) + chr(0b11101 + 0o26) + '\064', 0b1000), nzTpIcepk0o8('\x30' + chr(111) + '\061' + chr(55) + '\065', ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x32' + chr(49) + chr(341 - 293), 0o10), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b11110 + 0o23) + chr(0b101111 + 0o6) + chr(0b110001), 0b1000), nzTpIcepk0o8(chr(1423 - 1375) + chr(0b1100100 + 0o13) + '\064' + chr(1270 - 1221), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(2018 - 1969) + chr(55) + '\x35', 8), nzTpIcepk0o8(chr(48) + chr(111) + chr(54) + chr(567 - 519), ord("\x08")), nzTpIcepk0o8(chr(0b10011 + 0o35) + chr(0b1101111) + chr(0b110001) + chr(1708 - 1656), ord("\x08")), nzTpIcepk0o8(chr(829 - 781) + '\x6f' + chr(0b110011) + chr(50) + chr(0b101010 + 0o6), 0o10), nzTpIcepk0o8(chr(0b110000 + 0o0) + chr(0b101111 + 0o100) + chr(49) + chr(51), ord("\x08")), nzTpIcepk0o8(chr(0b10111 + 0o31) + chr(111) + '\x33' + chr(0b110011) + chr(0b0 + 0o63), 61089 - 61081), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b110001) + chr(50) + chr(748 - 700), ord("\x08")), nzTpIcepk0o8(chr(790 - 742) + chr(11049 - 10938) + '\x33' + chr(50) + chr(325 - 275), ord("\x08")), nzTpIcepk0o8('\x30' + chr(407 - 296) + '\061' + chr(53) + chr(2048 - 1994), 0o10), nzTpIcepk0o8('\060' + chr(0b110111 + 0o70) + chr(516 - 467) + '\x36' + chr(51), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(252 - 200), 0o10), nzTpIcepk0o8('\x30' + chr(111) + chr(1028 - 978) + chr(951 - 897) + chr(50), 52996 - 52988), nzTpIcepk0o8(chr(197 - 149) + chr(111) + chr(0b1111 + 0o43) + '\064' + chr(0b110011), 16259 - 16251), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x37' + chr(0b100100 + 0o21), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + '\x33' + chr(1462 - 1408) + chr(0b110011), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b10110 + 0o37) + chr(0b100000 + 0o20), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'v'), chr(3004 - 2904) + chr(0b1100101) + '\143' + chr(0b110010 + 0o75) + chr(0b11111 + 0o105) + '\x65')(chr(0b1110101) + chr(0b1110100) + '\x66' + chr(45) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def KcTknoTEHDE1(hXMPsSrOQzbh):
return eqhlVS96SzjF(roI3spqORKae(hXMPsSrOQzbh._engine_dataframe, roI3spqORKae(ES5oEprVxulp(b'?\x0f\x82\xc2;\xcd\x1f\x16Ww\xe4qZ\x16 \x0c\xdc\xba\x0b'), '\144' + '\x65' + chr(0b100100 + 0o77) + '\x6f' + '\144' + '\145')(chr(1349 - 1232) + chr(116) + '\146' + chr(45) + chr(56)))(), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\x0e\x05\xc5\xe9\x18\xcd4\x0bZ\x15\xcbv'), '\144' + '\145' + '\143' + chr(0b1101111) + '\x64' + chr(0b100000 + 0o105))(chr(0b110 + 0o157) + chr(0b1110100) + '\146' + '\x2d' + chr(0b10 + 0o66))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\x07\x03\x9b\xe02\xc9\x13\x0bFV'), '\144' + chr(101) + chr(0b1100011) + chr(111) + '\x64' + chr(8141 - 8040))(chr(0b100010 + 0o123) + '\164' + chr(0b1100110) + chr(0b10110 + 0o27) + chr(0b111000)))) |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | RepositoriesDataFrame.master_ref | def master_ref(self):
"""
Filters the current DataFrame references to only contain those rows whose reference is master.
>>> master_df = repos_df.master_ref
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self._engine_dataframe.getReferences().getHEAD(),
self._session, self._implicits) | python | def master_ref(self):
"""
Filters the current DataFrame references to only contain those rows whose reference is master.
>>> master_df = repos_df.master_ref
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self._engine_dataframe.getReferences().getHEAD(),
self._session, self._implicits) | [
"def",
"master_ref",
"(",
"self",
")",
":",
"return",
"ReferencesDataFrame",
"(",
"self",
".",
"_engine_dataframe",
".",
"getReferences",
"(",
")",
".",
"getHEAD",
"(",
")",
",",
"self",
".",
"_session",
",",
"self",
".",
"_implicits",
")"
] | Filters the current DataFrame references to only contain those rows whose reference is master.
>>> master_df = repos_df.master_ref
:rtype: ReferencesDataFrame | [
"Filters",
"the",
"current",
"DataFrame",
"references",
"to",
"only",
"contain",
"those",
"rows",
"whose",
"reference",
"is",
"master",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L301-L310 | train | Filters the current DataFrame references to only contain those rows whose reference is master. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOVzf,YikXQdxs3VoO,UBvEeZympYSz,mRTjFWUmjlQA,QhZRiM1qvaW7,WbNHlDKpyPtQ,z18h6aCn31dg,ox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Y,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\066' + chr(0b101100 + 0o6), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x32' + chr(53) + '\061', ord("\x08")), nzTpIcepk0o8(chr(0b100100 + 0o14) + chr(111) + chr(960 - 910) + chr(0b110001) + '\x35', ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b10 + 0o155) + chr(0b110001 + 0o1) + '\067', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(11037 - 10926) + chr(49) + chr(0b10000 + 0o40) + '\061', 27963 - 27955), nzTpIcepk0o8(chr(0b1100 + 0o44) + '\x6f' + chr(0b110111) + '\066', 0o10), nzTpIcepk0o8('\x30' + chr(111) + '\061' + chr(1193 - 1142) + chr(0b110010), 0b1000), nzTpIcepk0o8('\060' + '\157' + chr(0b10011 + 0o44), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + '\064' + chr(50), ord("\x08")), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b110011) + chr(51) + '\x31', 0b1000), nzTpIcepk0o8(chr(48) + chr(7706 - 7595) + chr(854 - 803) + chr(0b10011 + 0o41) + '\060', 54748 - 54740), nzTpIcepk0o8(chr(48) + '\157' + chr(471 - 422) + chr(2679 - 2624), 0b1000), nzTpIcepk0o8(chr(0b101011 + 0o5) + '\157' + '\061' + chr(55) + '\061', 16746 - 16738), nzTpIcepk0o8('\060' + chr(3639 - 3528) + chr(1509 - 1457) + chr(0b111 + 0o56), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b1010 + 0o51) + '\x33' + chr(0b101100 + 0o12), 0o10), nzTpIcepk0o8('\x30' + chr(7323 - 7212) + '\061' + chr(0b100101 + 0o15) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x33' + '\x33', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b111101 + 0o62) + chr(0b110010) + '\065' + chr(0b101111 + 0o7), 42326 - 42318), nzTpIcepk0o8(chr(0b100011 + 0o15) + chr(0b1101100 + 0o3) + chr(0b110011) + chr(1086 - 1032) + chr(1248 - 1198), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + chr(50) + chr(0b110100) + chr(54), 0b1000), nzTpIcepk0o8('\x30' + '\157' + chr(0b110010 + 0o1) + '\x36' + chr(0b110100), 0b1000), nzTpIcepk0o8(chr(424 - 376) + chr(0b1011101 + 0o22) + chr(1265 - 1213) + chr(1243 - 1190), 8), nzTpIcepk0o8(chr(0b1010 + 0o46) + '\157' + chr(0b110001) + '\060' + chr(0b101 + 0o56), 31904 - 31896), nzTpIcepk0o8(chr(48) + chr(0b1100100 + 0o13) + '\x32', 0o10), nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(4341 - 4230) + '\x32' + '\x32' + '\063', 23620 - 23612), nzTpIcepk0o8('\x30' + chr(0b1000101 + 0o52) + chr(0b110001) + chr(0b110111) + '\x31', 8), nzTpIcepk0o8(chr(0b100 + 0o54) + chr(0b1101111) + chr(0b1000 + 0o52) + chr(0b110011) + chr(0b110001), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1010101 + 0o32) + chr(55) + chr(2287 - 2238), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(9198 - 9087) + chr(1644 - 1593) + '\065' + chr(54), 0b1000), nzTpIcepk0o8(chr(1992 - 1944) + chr(111) + chr(230 - 181) + chr(0b110101 + 0o2) + chr(0b110011), ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(2033 - 1984) + chr(1188 - 1133) + chr(0b10011 + 0o43), 37475 - 37467), nzTpIcepk0o8(chr(0b100 + 0o54) + '\157' + chr(0b10101 + 0o34) + chr(0b1010 + 0o54) + chr(706 - 656), 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\x31' + '\063' + '\x34', 0b1000), nzTpIcepk0o8(chr(801 - 753) + '\x6f' + '\x31' + '\x31' + chr(0b101001 + 0o16), 51171 - 51163), nzTpIcepk0o8(chr(0b101110 + 0o2) + chr(0b1101111) + '\064' + chr(804 - 753), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1011001 + 0o26) + chr(1646 - 1597) + chr(54) + '\x31', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(51) + '\x31' + chr(0b100001 + 0o24), ord("\x08")), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(111) + chr(53) + chr(744 - 693), 0b1000), nzTpIcepk0o8(chr(0b10000 + 0o40) + chr(0b1101111) + chr(389 - 340) + chr(51), 0o10), nzTpIcepk0o8('\060' + chr(2710 - 2599) + '\062' + '\x30' + chr(55), 0o10)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b11100 + 0o24) + '\157' + chr(1110 - 1057) + '\x30', ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x1c'), chr(5515 - 5415) + '\145' + chr(0b1100011) + chr(7317 - 7206) + chr(0b1100100) + chr(101))('\x75' + chr(0b10110 + 0o136) + chr(0b1001101 + 0o31) + chr(0b1 + 0o54) + chr(56)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def l7dDtIdmZhgT(hXMPsSrOQzbh):
return eqhlVS96SzjF(roI3spqORKae(hXMPsSrOQzbh._engine_dataframe.getReferences(), roI3spqORKae(ES5oEprVxulp(b'U\xcc\xf9_\x04\x7f\x1e'), chr(0b1100100) + chr(101) + chr(99) + '\157' + chr(9973 - 9873) + chr(101))(chr(0b10 + 0o163) + '\x74' + chr(0b1010011 + 0o23) + '\x2d' + '\x38'))(), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'd\xc6\xben\x07S\x1enJ\xe9\xaan'), '\144' + chr(5535 - 5434) + chr(8151 - 8052) + chr(0b1101111) + '\x64' + chr(101))(chr(117) + chr(0b10111 + 0o135) + chr(102) + '\055' + chr(1033 - 977))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'm\xc0\xe0g-W9nV\xaa'), chr(0b100100 + 0o100) + chr(101) + chr(99) + chr(3712 - 3601) + chr(0b1100100) + '\145')(chr(0b1110101) + chr(902 - 786) + chr(102) + chr(1426 - 1381) + chr(0b10010 + 0o46)))) |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | ReferencesDataFrame.head_ref | def head_ref(self):
"""
Filters the current DataFrame to only contain those rows whose reference is HEAD.
>>> heads_df = refs_df.head_ref
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self._engine_dataframe.getHEAD(),
self._session, self._implicits) | python | def head_ref(self):
"""
Filters the current DataFrame to only contain those rows whose reference is HEAD.
>>> heads_df = refs_df.head_ref
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self._engine_dataframe.getHEAD(),
self._session, self._implicits) | [
"def",
"head_ref",
"(",
"self",
")",
":",
"return",
"ReferencesDataFrame",
"(",
"self",
".",
"_engine_dataframe",
".",
"getHEAD",
"(",
")",
",",
"self",
".",
"_session",
",",
"self",
".",
"_implicits",
")"
] | Filters the current DataFrame to only contain those rows whose reference is HEAD.
>>> heads_df = refs_df.head_ref
:rtype: ReferencesDataFrame | [
"Filters",
"the",
"current",
"DataFrame",
"to",
"only",
"contain",
"those",
"rows",
"whose",
"reference",
"is",
"HEAD",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L346-L355 | train | Returns a new DataFrame containing only those rows whose reference is HEAD. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,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S,WtdkIpFeYozM,MdkNqd1bagO6,QNQS9e6tJqMV,typojWN5Phrq,gufQJgTAhMnI,uPAcezIXzQNA,i739myaCTbWD,AtYHTsImz86v,pWZq9QOaZbhU,lI5UiuqoXdKZ,qZ4DivK_Doaa,znjnJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b101000 + 0o10) + chr(5507 - 5396) + '\061' + '\064' + chr(0b110010 + 0o1), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + '\063' + chr(0b110010 + 0o0) + chr(49), 0o10), nzTpIcepk0o8(chr(695 - 647) + chr(10796 - 10685) + chr(0b110010) + chr(1050 - 997) + chr(0b110111), 0o10), nzTpIcepk0o8(chr(515 - 467) + '\157' + chr(0b1111 + 0o43) + chr(1019 - 969) + chr(52), 0o10), nzTpIcepk0o8(chr(48) + chr(5250 - 5139) + chr(1995 - 1941) + chr(0b110000 + 0o3), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + '\x32' + chr(0b100100 + 0o15), ord("\x08")), nzTpIcepk0o8(chr(2273 - 2225) + '\157' + '\062' + chr(0b110111) + chr(796 - 743), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(1865 - 1813) + '\065', ord("\x08")), nzTpIcepk0o8(chr(0b101100 + 0o4) + '\157' + chr(50) + chr(52) + chr(51), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(385 - 334) + chr(2345 - 2293) + chr(0b110001), ord("\x08")), nzTpIcepk0o8('\060' + chr(387 - 276) + chr(55), 0o10), nzTpIcepk0o8(chr(0b1011 + 0o45) + chr(2978 - 2867) + '\x32' + '\060' + chr(0b110111), 41118 - 41110), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(0b101 + 0o55) + '\x35' + chr(1167 - 1115), 33058 - 33050), nzTpIcepk0o8(chr(0b11011 + 0o25) + chr(111) + chr(49) + chr(0b110110) + chr(0b101010 + 0o13), 0b1000), nzTpIcepk0o8(chr(1253 - 1205) + chr(111) + chr(0b10101 + 0o35) + chr(0b101010 + 0o13) + '\066', ord("\x08")), nzTpIcepk0o8(chr(0b100001 + 0o17) + chr(6759 - 6648) + chr(0b101011 + 0o7) + chr(1261 - 1212) + '\x30', 0o10), nzTpIcepk0o8('\060' + chr(4789 - 4678) + '\x37', 8), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(150 - 101) + chr(967 - 913) + chr(0b110110), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(0b110001) + chr(0b110101) + '\066', 11839 - 11831), nzTpIcepk0o8(chr(0b101111 + 0o1) + chr(0b1100000 + 0o17) + chr(0b1010 + 0o50) + '\x33' + chr(0b110011), ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(50) + chr(48) + chr(50), 0b1000), nzTpIcepk0o8('\x30' + chr(0b101101 + 0o102) + chr(0b110011) + chr(54) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1261 - 1212) + chr(0b0 + 0o62), 0b1000), nzTpIcepk0o8(chr(529 - 481) + '\x6f' + chr(0b10001 + 0o40) + chr(0b10001 + 0o45) + chr(1043 - 995), 0b1000), nzTpIcepk0o8(chr(0b101 + 0o53) + chr(111) + chr(0b100110 + 0o13) + '\x35' + chr(50), 0o10), nzTpIcepk0o8('\060' + chr(111) + chr(484 - 434) + chr(0b110000) + '\065', 0b1000), nzTpIcepk0o8('\x30' + chr(9608 - 9497) + chr(51) + chr(55) + chr(0b110110), 0o10), nzTpIcepk0o8('\x30' + chr(6655 - 6544) + '\x33' + chr(440 - 390) + chr(48), 22910 - 22902), nzTpIcepk0o8(chr(0b101000 + 0o10) + chr(0b1101001 + 0o6) + '\x32', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b110100 + 0o73) + chr(0b1010 + 0o47) + chr(0b110011 + 0o3) + chr(0b110010 + 0o5), 10502 - 10494), nzTpIcepk0o8(chr(0b110000) + chr(0b111110 + 0o61) + chr(0b110011) + chr(0b100100 + 0o20) + chr(55), 53460 - 53452), nzTpIcepk0o8(chr(0b101000 + 0o10) + '\x6f' + '\x32' + chr(0b110000) + chr(1073 - 1025), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(51) + '\x33' + chr(0b101000 + 0o12), 0b1000), nzTpIcepk0o8(chr(0b100101 + 0o13) + chr(0b1010011 + 0o34) + '\065', 7455 - 7447), nzTpIcepk0o8(chr(544 - 496) + chr(0b1101111) + chr(533 - 482) + '\062' + '\x37', 12352 - 12344), nzTpIcepk0o8(chr(0b110000) + chr(4959 - 4848) + '\x32' + chr(2342 - 2288) + chr(0b10110 + 0o34), 0b1000), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(2371 - 2321) + '\x35', 0b1000), nzTpIcepk0o8(chr(48) + chr(0b111100 + 0o63) + chr(0b11011 + 0o27) + chr(0b110110) + chr(0b1 + 0o64), 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + '\x33' + chr(53) + '\067', 1691 - 1683), nzTpIcepk0o8(chr(48) + chr(0b11001 + 0o126) + chr(51) + chr(55) + chr(2706 - 2652), 8)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(830 - 777) + chr(2020 - 1972), 0b1000)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'M'), chr(0b1100100) + '\145' + chr(99) + '\157' + '\x64' + '\x65')(chr(0b1110101) + '\x74' + chr(2894 - 2792) + chr(45) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def LCB1MmSdYvJT(hXMPsSrOQzbh):
return eqhlVS96SzjF(roI3spqORKae(hXMPsSrOQzbh._engine_dataframe, roI3spqORKae(ES5oEprVxulp(b'\x04\xb4\xdb\xdcvP\xf9'), '\x64' + chr(101) + chr(0b1010010 + 0o21) + chr(6462 - 6351) + '\x64' + '\145')(chr(0b1110101) + chr(116) + '\x66' + chr(45) + chr(405 - 349)))(), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'5\xbe\x9c\xedu|\xf9L\xcb\xd1M\xe6'), chr(0b1100100) + '\145' + chr(0b10000 + 0o123) + chr(9170 - 9059) + chr(100) + chr(0b1011001 + 0o14))('\165' + chr(0b1110100) + '\146' + '\055' + chr(0b111000))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'<\xb8\xc2\xe4_x\xdeL\xd7\x92'), chr(0b110110 + 0o56) + chr(0b1001111 + 0o26) + '\x63' + chr(111) + chr(7058 - 6958) + '\145')('\x75' + chr(0b1110100) + chr(9465 - 9363) + chr(928 - 883) + chr(2527 - 2471)))) |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | ReferencesDataFrame.master_ref | def master_ref(self):
"""
Filters the current DataFrame to only contain those rows whose reference is master.
>>> master_df = refs_df.master_ref
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self._engine_dataframe.getMaster(),
self._session, self._implicits)
return self.ref('refs/heads/master') | python | def master_ref(self):
"""
Filters the current DataFrame to only contain those rows whose reference is master.
>>> master_df = refs_df.master_ref
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self._engine_dataframe.getMaster(),
self._session, self._implicits)
return self.ref('refs/heads/master') | [
"def",
"master_ref",
"(",
"self",
")",
":",
"return",
"ReferencesDataFrame",
"(",
"self",
".",
"_engine_dataframe",
".",
"getMaster",
"(",
")",
",",
"self",
".",
"_session",
",",
"self",
".",
"_implicits",
")",
"return",
"self",
".",
"ref",
"(",
"'refs/heads/master'",
")"
] | Filters the current DataFrame to only contain those rows whose reference is master.
>>> master_df = refs_df.master_ref
:rtype: ReferencesDataFrame | [
"Filters",
"the",
"current",
"DataFrame",
"to",
"only",
"contain",
"those",
"rows",
"whose",
"reference",
"is",
"master",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L359-L369 | train | Returns a new DataFrame with only those rows whose reference is master. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,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K_Doaa,znjnJWK64FDT,iJbw0iNQ06Xw,Jq33HEV_XqZE,_kV_Bomx8PZ4,Z5xOfqIptFuc,_9cznYtBZk6k,ZurjcUL1ssA8,qEahrGEDF7Tq,jLW6pRf2DSRk,q33KG3foQ_CJ,PNaRkv8AjHWU,roI3spqORKae,CFUos7dinCa7,dRKdVnHPFq7C,dMJNtLk2mncQ,Mq8h41ilRngb,vgO67Nkl7Kt9,maLnLg8O5zPT,QnTXOd5N96r1,nzTpIcepk0o8,suIjIS24Zkqw,CmsH_0IVxIiZ,b8MSkfijeeBr,ftfygxgFas5X,xM0vTMWcJQBa,H4NoA26ON7iG,y0cCpS6dh4OT,VVP82lOIz6CD,KV9ckIhroIia,D2M3XQk26HKr,XURpmPuEWCNF,ltB3XhPy2rYf,mxgO6GAb3Xup,llEg6op6Lr8F,DnU3Rq9N5ala,RmKXV0QRcrJP,JEroPXRTriYU,v8jsMqaYV6U2,X1QyyvXSAOQt,PWTqT_PKIfuW,bbT2xIe5pzk7,VWshwTzZfwvC,DoS4vLAglV8A,sOS7b2Ofrbne,Bvi71nNyvlqO,lCf1uzpaIUMv,nDEnDEV3Lc5Z,V3OlOVg98A85,WsP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(2012 - 1964) + chr(0b1101111) + chr(53) + chr(0b110100), 0o10), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b110011) + '\x35' + chr(48), 0o10), nzTpIcepk0o8('\x30' + chr(111) + '\x32' + chr(49) + chr(0b110100), ord("\x08")), nzTpIcepk0o8(chr(1941 - 1893) + '\x6f' + chr(0b110001) + chr(2430 - 2376) + chr(0b1010 + 0o52), 26242 - 26234), nzTpIcepk0o8('\060' + chr(6694 - 6583) + chr(49) + '\x34' + '\x33', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\157' + chr(80 - 29) + '\065' + chr(102 - 54), 8), nzTpIcepk0o8(chr(48) + chr(111) + '\x35' + chr(48), 9519 - 9511), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x31' + chr(1201 - 1150) + chr(1610 - 1555), 21578 - 21570), nzTpIcepk0o8(chr(48) + chr(9544 - 9433) + chr(0b110001) + '\064', 11037 - 11029), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\061' + chr(53) + chr(850 - 800), 0o10), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x33' + chr(2641 - 2587) + '\064', 8504 - 8496), nzTpIcepk0o8('\x30' + chr(0b111111 + 0o60) + '\061' + '\064' + chr(0b100110 + 0o14), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(1381 - 1332) + chr(522 - 468) + chr(1025 - 976), 0o10), nzTpIcepk0o8(chr(48) + chr(6392 - 6281) + '\067' + chr(929 - 880), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(52), 27577 - 27569), nzTpIcepk0o8('\060' + chr(0b101111 + 0o100) + chr(0b1100 + 0o46) + chr(0b1101 + 0o52) + chr(0b110000), ord("\x08")), nzTpIcepk0o8(chr(0b0 + 0o60) + chr(0b100 + 0o153) + '\062' + chr(1660 - 1608) + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(687 - 639) + chr(0b1101111) + chr(1370 - 1315) + '\x33', 22037 - 22029), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x37' + chr(786 - 736), 4906 - 4898), nzTpIcepk0o8('\x30' + chr(8584 - 8473) + '\061' + '\065' + chr(51), 0b1000), nzTpIcepk0o8('\x30' + chr(0b11011 + 0o124) + '\x33' + chr(0b110001) + chr(50), 2339 - 2331), nzTpIcepk0o8(chr(0b110000 + 0o0) + chr(0b1101111) + chr(49) + chr(974 - 919) + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(0b101110 + 0o2) + chr(111) + chr(0b10101 + 0o36) + chr(1915 - 1867) + '\062', ord("\x08")), nzTpIcepk0o8(chr(0b100010 + 0o16) + '\157' + chr(51) + '\x37' + '\x35', 0b1000), nzTpIcepk0o8(chr(0b11000 + 0o30) + '\157' + chr(0b110011) + '\062' + chr(1280 - 1225), 31537 - 31529), nzTpIcepk0o8('\060' + '\157' + chr(50) + chr(0b111 + 0o53) + chr(48), ord("\x08")), nzTpIcepk0o8(chr(0b100001 + 0o17) + chr(111) + chr(0b11011 + 0o32) + chr(2165 - 2114), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\062' + chr(0b11 + 0o57) + chr(0b101110 + 0o6), 36597 - 36589), nzTpIcepk0o8('\x30' + chr(0b1101111) + chr(0b11000 + 0o31) + '\x36' + chr(50), 0b1000), nzTpIcepk0o8(chr(0b10010 + 0o36) + chr(111) + '\062' + chr(423 - 373) + chr(49), ord("\x08")), nzTpIcepk0o8('\060' + chr(111) + chr(55) + chr(1729 - 1679), 8), nzTpIcepk0o8(chr(1937 - 1889) + chr(111) + chr(0b100 + 0o60) + chr(0b110101), ord("\x08")), nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(0b1101111) + chr(2329 - 2278) + chr(48) + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101110 + 0o1) + chr(0b110011) + chr(0b110100) + chr(48), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(1531 - 1480) + '\x37' + chr(49), 6223 - 6215), nzTpIcepk0o8(chr(48) + chr(0b1010000 + 0o37) + chr(0b100001 + 0o23) + chr(0b1001 + 0o52), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(1753 - 1701) + '\065', 8), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x37' + chr(2095 - 2040), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(0b110011), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(0b11101 + 0o122) + chr(0b100011 + 0o20) + chr(55) + '\065', 8)][ZlbFMSG8gCoF % nzTpIcepk0o8('\060' + chr(111) + '\065' + chr(0b101111 + 0o1), 8)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x02'), '\x64' + '\x65' + chr(0b1100011) + chr(0b1101111) + '\x64' + '\145')('\x75' + '\x74' + chr(6319 - 6217) + '\055' + '\070') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def l7dDtIdmZhgT(hXMPsSrOQzbh):
return eqhlVS96SzjF(roI3spqORKae(hXMPsSrOQzbh._engine_dataframe, roI3spqORKae(ES5oEprVxulp(b'K\x8d\xf89\x02\x9b\\:~'), chr(0b1100100) + '\x65' + chr(0b1100011) + chr(10627 - 10516) + chr(0b1100100) + '\x65')('\x75' + '\x74' + '\x66' + '\x2d' + '\070'))(), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'z\x87\xbf\r%\x85l6dZ\xbe\x03'), '\x64' + '\145' + chr(2437 - 2338) + chr(8491 - 8380) + chr(0b1100100) + '\145')('\x75' + chr(0b1011000 + 0o34) + '\146' + chr(915 - 870) + '\x38')), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b's\x81\xe1\x04\x0f\x81K6x\x19'), '\x64' + chr(6991 - 6890) + '\143' + chr(111) + chr(100) + chr(0b1011110 + 0o7))('\x75' + chr(0b11011 + 0o131) + '\x66' + chr(45) + chr(0b111000))))
return roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b"o\x85\xc2'\x00\x8eP\x15=?\x9d\n"), chr(0b1100100) + chr(0b11010 + 0o113) + chr(0b1010111 + 0o14) + chr(0b1000001 + 0o56) + chr(0b1010000 + 0o24) + '\x65')(chr(117) + chr(2632 - 2516) + '\x66' + chr(0b101101) + chr(146 - 90)))(roI3spqORKae(ES5oEprVxulp(b'^\x8d\xea\x07L\x80M>h\x19\xdb\x0f\x10Jp\xdd\xd0'), chr(4616 - 4516) + chr(0b1100101) + chr(943 - 844) + '\157' + '\x64' + chr(0b1000110 + 0o37))(chr(0b1101001 + 0o14) + chr(0b110 + 0o156) + chr(102) + chr(608 - 563) + '\x38')) |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | ReferencesDataFrame.ref | def ref(self, ref):
"""
Filters the current DataFrame to only contain those rows whose reference is the given
reference name.
>>> heads_df = refs_df.ref('refs/heads/HEAD')
:param ref: Reference to get
:type ref: str
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self.filter(self.name == ref)._jdf,
self._session, self._implicits) | python | def ref(self, ref):
"""
Filters the current DataFrame to only contain those rows whose reference is the given
reference name.
>>> heads_df = refs_df.ref('refs/heads/HEAD')
:param ref: Reference to get
:type ref: str
:rtype: ReferencesDataFrame
"""
return ReferencesDataFrame(self.filter(self.name == ref)._jdf,
self._session, self._implicits) | [
"def",
"ref",
"(",
"self",
",",
"ref",
")",
":",
"return",
"ReferencesDataFrame",
"(",
"self",
".",
"filter",
"(",
"self",
".",
"name",
"==",
"ref",
")",
".",
"_jdf",
",",
"self",
".",
"_session",
",",
"self",
".",
"_implicits",
")"
] | Filters the current DataFrame to only contain those rows whose reference is the given
reference name.
>>> heads_df = refs_df.ref('refs/heads/HEAD')
:param ref: Reference to get
:type ref: str
:rtype: ReferencesDataFrame | [
"Filters",
"the",
"current",
"DataFrame",
"to",
"only",
"contain",
"those",
"rows",
"whose",
"reference",
"is",
"the",
"given",
"reference",
"name",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L372-L384 | train | Returns a new DataFrame containing only those rows whose reference is the given reference name. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eD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arning,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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8(chr(0b10100 + 0o34) + chr(0b110011 + 0o74) + '\065' + '\061', 12646 - 12638), nzTpIcepk0o8('\060' + chr(0b1001110 + 0o41) + '\061' + chr(2022 - 1970) + '\x36', 0o10), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(0b110100) + chr(0b110001), 0o10), nzTpIcepk0o8(chr(331 - 283) + chr(111) + '\061' + '\065' + chr(369 - 319), ord("\x08")), nzTpIcepk0o8('\x30' + chr(4254 - 4143) + '\061' + '\065', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(776 - 665) + '\x33' + chr(51) + '\x32', 0o10), nzTpIcepk0o8('\060' + '\x6f' + '\x37', ord("\x08")), nzTpIcepk0o8('\x30' + '\157' + chr(49) + chr(0b11110 + 0o22), 34336 - 34328), nzTpIcepk0o8('\x30' + chr(0b100111 + 0o110) + chr(49) + '\x33' + '\x37', ord("\x08")), nzTpIcepk0o8(chr(906 - 858) + chr(0b1100111 + 0o10) + chr(0b110011) + '\x32' + chr(1833 - 1782), ord("\x08")), nzTpIcepk0o8(chr(0b100011 + 0o15) + chr(111) + '\x31' + '\x34' + '\x31', 0o10), nzTpIcepk0o8('\x30' + chr(3695 - 3584) + chr(0b101010 + 0o10) + '\067' + '\x30', 0o10), nzTpIcepk0o8(chr(0b100 + 0o54) + chr(7109 - 6998) + chr(0b110010) + chr(53), 22256 - 22248), nzTpIcepk0o8(chr(2149 - 2101) + chr(6788 - 6677) + '\x32' + chr(1605 - 1550) + '\x32', 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + chr(2317 - 2266) + '\x35' + chr(1110 - 1062), 1120 - 1112), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + chr(50) + chr(0b110010) + '\x30', 54316 - 54308), nzTpIcepk0o8(chr(0b11110 + 0o22) + chr(111) + '\062' + chr(53) + chr(0b110110), 22026 - 22018), nzTpIcepk0o8('\x30' + '\157' + chr(0b110001) + chr(0b110101) + chr(0b110000), 0b1000), nzTpIcepk0o8('\x30' + chr(0b1011111 + 0o20) + chr(2110 - 2059) + '\x37', 0o10), nzTpIcepk0o8(chr(48) + chr(1077 - 966) + '\x31' + chr(48) + '\060', 0o10), nzTpIcepk0o8(chr(48) + chr(0b1100110 + 0o11) + '\x33' + chr(0b10110 + 0o33) + chr(0b100011 + 0o20), 0o10), nzTpIcepk0o8(chr(0b1010 + 0o46) + chr(0b10010 + 0o135) + chr(49) + chr(0b110011) + chr(53), 0o10), nzTpIcepk0o8('\060' + chr(0b111010 + 0o65) + chr(55) + chr(0b110101 + 0o0), 50048 - 50040), nzTpIcepk0o8(chr(0b110000) + chr(10727 - 10616) + '\061' + chr(48) + chr(0b100000 + 0o24), ord("\x08")), nzTpIcepk0o8(chr(1236 - 1188) + '\x6f' + chr(0b110011) + chr(0b110111) + '\062', 0b1000), nzTpIcepk0o8(chr(0b101001 + 0o7) + chr(111) + '\063' + chr(0b100010 + 0o21) + chr(1727 - 1675), 28590 - 28582), nzTpIcepk0o8('\060' + '\x6f' + chr(353 - 303) + chr(2081 - 2028) + '\060', 0o10), nzTpIcepk0o8('\x30' + '\x6f' + '\x31' + '\x35', 8), nzTpIcepk0o8('\060' + '\x6f' + chr(1340 - 1292), 0b1000), nzTpIcepk0o8('\060' + '\x6f' + '\x31' + chr(1734 - 1679) + chr(0b10001 + 0o46), 36033 - 36025), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b110011) + chr(0b110100) + chr(53), 0o10), nzTpIcepk0o8('\x30' + '\x6f' + '\x31' + '\x32' + chr(0b110001), 0b1000), nzTpIcepk0o8('\060' + chr(0b1110 + 0o141) + '\063' + chr(54) + '\x35', 33529 - 33521), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(1390 - 1341) + chr(0b1010 + 0o47), 0b1000), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(2399 - 2349) + chr(2278 - 2224) + chr(1897 - 1844), 0o10), nzTpIcepk0o8(chr(48) + '\x6f' + '\062' + chr(0b110100) + '\x32', ord("\x08")), nzTpIcepk0o8(chr(0b10110 + 0o32) + '\157' + '\x32' + chr(54) + '\060', ord("\x08")), nzTpIcepk0o8(chr(0b11011 + 0o25) + '\x6f' + chr(0b110001) + chr(1203 - 1154) + '\x34', ord("\x08")), nzTpIcepk0o8('\060' + '\157' + chr(1647 - 1598) + chr(0b110000) + chr(0b110010), 63966 - 63958), nzTpIcepk0o8(chr(48) + chr(0b101100 + 0o103) + '\x31' + chr(0b10010 + 0o41) + '\064', 21668 - 21660)][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(828 - 780) + '\x6f' + chr(0b11001 + 0o34) + chr(48), ord("\x08"))] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\x07'), chr(0b1100100) + chr(0b1100101) + '\143' + chr(111) + chr(2212 - 2112) + '\x65')(chr(0b1000000 + 0o65) + chr(116) + '\146' + chr(45) + chr(1930 - 1874)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def CmNScfxJ1Uih(hXMPsSrOQzbh, CmNScfxJ1Uih):
return eqhlVS96SzjF(roI3spqORKae(hXMPsSrOQzbh.filter(hXMPsSrOQzbh.name == CmNScfxJ1Uih), roI3spqORKae(ES5oEprVxulp(b'v\x0cE\x0c'), '\x64' + '\145' + chr(0b1100011) + chr(111) + chr(7481 - 7381) + chr(101))(chr(0b1110101) + chr(116) + chr(6023 - 5921) + chr(0b101101) + chr(0b100001 + 0o27))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\x7f\t\x12\x13K\xb7Ca7\xe3+\xd9'), chr(0b1100001 + 0o3) + chr(0b1100101) + chr(99) + '\x6f' + chr(100) + '\145')('\165' + chr(116) + '\146' + chr(0b101100 + 0o1) + chr(56))), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'v\x0fL\x1aa\xb3da+\xa0'), chr(100) + chr(6481 - 6380) + chr(0b1100011) + chr(7597 - 7486) + chr(0b10011 + 0o121) + chr(0b1100101))(chr(0b1100010 + 0o23) + chr(116) + chr(8411 - 8309) + '\x2d' + chr(0b111000)))) |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | ReferencesDataFrame.all_reference_commits | def all_reference_commits(self):
"""
Returns the current DataFrame joined with the commits DataFrame, with all of the commits
in all references.
>>> commits_df = refs_df.all_reference_commits
Take into account that getting all the commits will lead to a lot of repeated tree
entries and blobs, thus making your query very slow.
Most of the time, you just want the HEAD commit of each reference:
>>> commits_df = refs_df.commits
:rtype: CommitsDataFrame
"""
return CommitsDataFrame(self._engine_dataframe.getAllReferenceCommits(), self._session, self._implicits) | python | def all_reference_commits(self):
"""
Returns the current DataFrame joined with the commits DataFrame, with all of the commits
in all references.
>>> commits_df = refs_df.all_reference_commits
Take into account that getting all the commits will lead to a lot of repeated tree
entries and blobs, thus making your query very slow.
Most of the time, you just want the HEAD commit of each reference:
>>> commits_df = refs_df.commits
:rtype: CommitsDataFrame
"""
return CommitsDataFrame(self._engine_dataframe.getAllReferenceCommits(), self._session, self._implicits) | [
"def",
"all_reference_commits",
"(",
"self",
")",
":",
"return",
"CommitsDataFrame",
"(",
"self",
".",
"_engine_dataframe",
".",
"getAllReferenceCommits",
"(",
")",
",",
"self",
".",
"_session",
",",
"self",
".",
"_implicits",
")"
] | Returns the current DataFrame joined with the commits DataFrame, with all of the commits
in all references.
>>> commits_df = refs_df.all_reference_commits
Take into account that getting all the commits will lead to a lot of repeated tree
entries and blobs, thus making your query very slow.
Most of the time, you just want the HEAD commit of each reference:
>>> commits_df = refs_df.commits
:rtype: CommitsDataFrame | [
"Returns",
"the",
"current",
"DataFrame",
"joined",
"with",
"the",
"commits",
"DataFrame",
"with",
"all",
"of",
"the",
"commits",
"in",
"all",
"references",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L388-L404 | train | Returns the current DataFrame joined with the commits DataFrame with all of the tree
entries in all references. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p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lockingIOError,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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + chr(0b110011 + 0o74) + chr(837 - 786) + chr(1972 - 1924) + chr(0b111 + 0o57), 0o10), nzTpIcepk0o8(chr(1168 - 1120) + '\157' + chr(0b110001) + chr(0b110001) + chr(53), 0b1000), nzTpIcepk0o8(chr(477 - 429) + chr(0b111111 + 0o60) + '\x35' + chr(629 - 574), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(6023 - 5912) + chr(2287 - 2237) + chr(0b101010 + 0o14) + chr(1866 - 1818), 0b1000), nzTpIcepk0o8('\060' + chr(4066 - 3955) + chr(0b110111) + chr(0b100010 + 0o20), ord("\x08")), nzTpIcepk0o8(chr(0b1100 + 0o44) + chr(10336 - 10225) + chr(50) + chr(0b101110 + 0o10) + chr(1141 - 1091), 39989 - 39981), nzTpIcepk0o8(chr(0b110000) + chr(0b1001111 + 0o40) + chr(0b10 + 0o57) + chr(0b101 + 0o54) + chr(0b110111), 59803 - 59795), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\064' + '\x37', ord("\x08")), nzTpIcepk0o8(chr(2184 - 2136) + '\157' + chr(0b110010) + '\x32' + chr(0b11010 + 0o32), 0b1000), nzTpIcepk0o8('\x30' + chr(0b110 + 0o151) + chr(2378 - 2324) + '\060', 0o10), nzTpIcepk0o8(chr(0b11101 + 0o23) + chr(8559 - 8448) + chr(50) + '\062' + chr(51), 0b1000), nzTpIcepk0o8('\x30' + '\x6f' + chr(51) + chr(224 - 175) + '\060', 0b1000), nzTpIcepk0o8(chr(609 - 561) + chr(111) + '\x31' + chr(49) + chr(0b110101), 8), nzTpIcepk0o8('\060' + chr(111) + chr(1157 - 1106) + '\066' + chr(49), ord("\x08")), nzTpIcepk0o8('\060' + chr(6799 - 6688) + chr(51) + '\x32', 0b1000), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x33' + chr(1959 - 1909) + '\x30', 0b1000), nzTpIcepk0o8('\060' + chr(111) + '\x32' + '\x32', 0o10), nzTpIcepk0o8(chr(0b100000 + 0o20) + chr(111) + chr(0b110011) + '\x35' + chr(0b110111), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(7480 - 7369) + chr(0b10011 + 0o37) + chr(54) + chr(0b110001 + 0o2), 0o10), nzTpIcepk0o8(chr(0b100000 + 0o20) + chr(5815 - 5704) + '\x31' + chr(1339 - 1285) + chr(0b110001), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(8043 - 7932) + '\x32' + '\060' + '\061', 0b1000), nzTpIcepk0o8(chr(194 - 146) + chr(111) + chr(0b1110 + 0o45) + '\065' + chr(2116 - 2061), 8), nzTpIcepk0o8(chr(0b110000) + '\x6f' + '\x33' + chr(0b110101) + chr(0b10101 + 0o36), ord("\x08")), nzTpIcepk0o8(chr(0b10110 + 0o32) + chr(1374 - 1263) + chr(51) + chr(0b100000 + 0o24) + chr(52), 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(1067 - 956) + chr(368 - 315) + chr(0b101100 + 0o5), 21174 - 21166), nzTpIcepk0o8(chr(0b110000) + '\157' + '\063' + chr(55) + chr(53), 58386 - 58378), nzTpIcepk0o8(chr(0b110000) + chr(111) + chr(409 - 356) + '\061', 8), nzTpIcepk0o8(chr(0b110000) + chr(0b1101111) + '\x33' + chr(141 - 90) + '\060', ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(1679 - 1628) + '\x37' + chr(50), 3953 - 3945), nzTpIcepk0o8(chr(0b1111 + 0o41) + '\x6f' + chr(2053 - 2003) + '\066' + chr(2154 - 2099), ord("\x08")), nzTpIcepk0o8(chr(2248 - 2200) + '\x6f' + chr(1761 - 1706), 0o10), nzTpIcepk0o8(chr(0b11011 + 0o25) + chr(0b1010101 + 0o32) + chr(1142 - 1092) + chr(49) + chr(957 - 902), 0o10), nzTpIcepk0o8(chr(1701 - 1653) + chr(111) + chr(1477 - 1428) + '\060' + chr(0b110110), 0b1000), nzTpIcepk0o8(chr(0b100 + 0o54) + chr(6611 - 6500) + chr(49) + chr(0b101010 + 0o11) + chr(49), 0o10), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(499 - 450) + chr(648 - 593) + '\x30', 27841 - 27833), nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(111) + chr(0b110011) + '\x36' + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(0b11011 + 0o25) + chr(12285 - 12174) + '\061' + chr(52), 55489 - 55481), nzTpIcepk0o8(chr(48) + chr(5080 - 4969) + chr(104 - 55) + chr(50) + chr(0b1010 + 0o55), 15706 - 15698), nzTpIcepk0o8(chr(48) + chr(0b1101111) + '\x37' + chr(0b101000 + 0o16), 0o10), nzTpIcepk0o8('\060' + chr(3655 - 3544) + chr(0b110001) + chr(0b110101) + '\x33', ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(48) + chr(111) + chr(1548 - 1495) + chr(48), 0o10)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xe8'), '\x64' + chr(101) + '\143' + '\x6f' + '\x64' + chr(0b111100 + 0o51))(chr(0b1110101) + chr(0b1110100) + chr(643 - 541) + chr(0b11 + 0o52) + '\x38') + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def Qe2hrToUV0AT(hXMPsSrOQzbh):
return _kudIlzRRRgt(roI3spqORKae(hXMPsSrOQzbh._engine_dataframe, roI3spqORKae(ES5oEprVxulp(b'\xa1([\xf1V\xde\x1dB\xf2U\xe1\xad#\x92\x7f\x93}\x82\xde\x18\xf5\x9c'), chr(819 - 719) + chr(3626 - 3525) + chr(0b111000 + 0o53) + chr(9987 - 9876) + chr(0b1100100) + chr(0b1110 + 0o127))(chr(0b111101 + 0o70) + chr(0b1110001 + 0o3) + chr(102) + '\x2d' + '\x38'))(), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\x90"\x1c\xc9|\xdf\x0bN\xfc\x00\xd9\xa9'), chr(9092 - 8992) + '\x65' + chr(9390 - 9291) + chr(0b1101111) + '\x64' + chr(0b1100101))(chr(0b100011 + 0o122) + chr(9785 - 9669) + '\x66' + chr(1066 - 1021) + '\070')), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\x99$B\xc0V\xdb,N\xe0C'), '\x64' + chr(2654 - 2553) + chr(99) + chr(0b1101111) + chr(6796 - 6696) + chr(0b10010 + 0o123))(chr(0b110010 + 0o103) + chr(0b1110100) + chr(6982 - 6880) + chr(0b100 + 0o51) + chr(0b111000)))) |
src-d/jgit-spark-connector | python/sourced/engine/engine.py | ReferencesDataFrame.commits | def commits(self):
"""
Returns the current DataFrame joined with the commits DataFrame. It just returns
the last commit in a reference (aka the current state).
>>> commits_df = refs_df.commits
If you want all commits from the references, use the `all_reference_commits` method,
but take into account that getting all the commits will lead to a lot of repeated tree
entries and blobs, thus making your query very slow.
>>> commits_df = refs_df.all_reference_commits
:rtype: CommitsDataFrame
"""
return CommitsDataFrame(self._engine_dataframe.getCommits(), self._session, self._implicits) | python | def commits(self):
"""
Returns the current DataFrame joined with the commits DataFrame. It just returns
the last commit in a reference (aka the current state).
>>> commits_df = refs_df.commits
If you want all commits from the references, use the `all_reference_commits` method,
but take into account that getting all the commits will lead to a lot of repeated tree
entries and blobs, thus making your query very slow.
>>> commits_df = refs_df.all_reference_commits
:rtype: CommitsDataFrame
"""
return CommitsDataFrame(self._engine_dataframe.getCommits(), self._session, self._implicits) | [
"def",
"commits",
"(",
"self",
")",
":",
"return",
"CommitsDataFrame",
"(",
"self",
".",
"_engine_dataframe",
".",
"getCommits",
"(",
")",
",",
"self",
".",
"_session",
",",
"self",
".",
"_implicits",
")"
] | Returns the current DataFrame joined with the commits DataFrame. It just returns
the last commit in a reference (aka the current state).
>>> commits_df = refs_df.commits
If you want all commits from the references, use the `all_reference_commits` method,
but take into account that getting all the commits will lead to a lot of repeated tree
entries and blobs, thus making your query very slow.
>>> commits_df = refs_df.all_reference_commits
:rtype: CommitsDataFrame | [
"Returns",
"the",
"current",
"DataFrame",
"joined",
"with",
"the",
"commits",
"DataFrame",
".",
"It",
"just",
"returns",
"the",
"last",
"commit",
"in",
"a",
"reference",
"(",
"aka",
"the",
"current",
"state",
")",
"."
] | 79d05a0bcf0da435685d6118828a8884e2fe4b94 | https://github.com/src-d/jgit-spark-connector/blob/79d05a0bcf0da435685d6118828a8884e2fe4b94/python/sourced/engine/engine.py#L408-L423 | train | Returns the current DataFrame joined with the commits DataFrame. | GiP5xwVCF98Z,B3LV8Eo811Ma,bIsJhlpYrrU2,UtiWT6f6p9yZ,sY2ClS3bs_Vs,cXy7eDEmqBLX,WBIJpxagI_Bm,oiYQtqKByLVy,pKtZbyLPTF7M,N5KuUvtbiyqB,Y8CO_HpFZe1H,lFpHwHL3xiEO,QT_5wdIFQ3WX,gn988v5t9NEf,dVZxwLTOCtbO,RjQP07DYIdkf,Wun5u3i1rn23,m64e4RQAlmFd,zfo2Sgkz3IVJ,aWb0eXvJHTT7,s2y8nAB4S7UF,znAfcqx_89tO,ZnHlCcECsuOK,TdYHRT1SBW60,mBmBrDJUSN6g,Awc2QmWaiVq8,fPFTJxVnGShv,Kqv3Zaj1M9P0,uKsHT175xV8E,ah0DLMBSEU5j,EsFcqWRT9elq,d9st0HqZDng1,knUxyjfq07F9,Fc8q2OvvlH7d,KSw3AkHkJy1a,JD7LadPikpPw,VwkB9reRDydR,aHxuT4bIDdeg,Qn0k4xGfJpuL,NfwEQ1VKf5DV,WdoB9EK8ABTr,Y1otPTwLRJvi,zsedrPqY_EmW,CJFGX4uBWMak,DB9Ra8FNEf7o,DHq8A6v2Wg4n,Migy1gLCcYvQ,IAGRfZDRyjN_,ze1AhR_jfpze,ej204HIOxzoZ,_1qUu0gKi9gH,Wa8JM2k53wi5,aFaxROHyT7UJ,ZOdpVDJPWn4I,LqOf4dRsAg72,K3alqetBMgas,ZtIuyIq3ta7g,UIHY5MV5X5uS,C60ELahXqfKV,FB4_7GjVy3pW,wXIYU_4UfQFa,jZIjKu8IFANs,REazVyvp6OIp,pZy5DBJ8WJod,aP29ipGsOVzf,YikXQdxs3VoO,UBv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sP3Nc3n6e0b,N9zlRy29S1SS,oclC8DLjA_lV,CO2YiXoIEhJY,nfNqtJL5aRaY,MJ07XsN5uFgW,cL4sFo6RhVJa,TxMFWa_Xzviv,bpTSxj4JFQ8o,zL_YcxPEZPhm,yfEeqQiUoqWT,OHWDi_URd_WF,NKGkaWkPPkT2,AYtDRlqeP0tq,vQqJeSQfHM0X,FUdwyfT9sfj2=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__
ES5oEprVxulp = lambda R7ltlgvcKSD4: QNQS9e6tJqMV([bI5jsQ9OkQtj ^ [nzTpIcepk0o8('\x30' + '\x6f' + chr(0b110010) + '\061' + chr(0b1100 + 0o53), 15367 - 15359), nzTpIcepk0o8('\060' + chr(11394 - 11283) + '\061' + '\063' + chr(48), 0b1000), nzTpIcepk0o8(chr(0b11000 + 0o30) + chr(111) + '\061' + chr(0b101001 + 0o7), 0b1000), nzTpIcepk0o8(chr(1014 - 966) + '\x6f' + chr(738 - 689) + chr(289 - 237) + chr(0b110010), ord("\x08")), nzTpIcepk0o8(chr(0b110000) + chr(9849 - 9738) + chr(54) + '\x34', ord("\x08")), nzTpIcepk0o8(chr(998 - 950) + '\157' + chr(0b110001) + chr(50) + '\061', 0o10), nzTpIcepk0o8('\060' + chr(0b1101111) + chr(0b1000 + 0o52) + '\062' + chr(0b11110 + 0o26), 0o10), nzTpIcepk0o8(chr(638 - 590) + '\x6f' + chr(0b10101 + 0o34) + '\x32' + chr(0b10 + 0o57), 8), nzTpIcepk0o8(chr(0b110000) + chr(0b1011 + 0o144) + chr(0b110011) + chr(1038 - 983) + chr(555 - 502), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\062' + chr(0b10001 + 0o42), 65407 - 65399), nzTpIcepk0o8(chr(48) + '\157' + '\x32' + chr(0b100100 + 0o23) + '\065', 62936 - 62928), nzTpIcepk0o8(chr(48) + '\x6f' + '\063' + '\x33' + chr(0b11001 + 0o30), 0b1000), nzTpIcepk0o8(chr(0b0 + 0o60) + chr(1283 - 1172) + chr(2250 - 2201) + chr(48) + chr(51), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(1110 - 999) + chr(66 - 16), 0b1000), nzTpIcepk0o8(chr(48) + chr(111) + chr(0b110010), 8), nzTpIcepk0o8(chr(258 - 210) + '\157' + '\064' + chr(534 - 484), ord("\x08")), nzTpIcepk0o8('\x30' + '\x6f' + chr(0b11111 + 0o22) + chr(0b110111), ord("\x08")), nzTpIcepk0o8(chr(103 - 55) + chr(111) + chr(50) + chr(1965 - 1915) + chr(2306 - 2252), 0o10), nzTpIcepk0o8(chr(0b101101 + 0o3) + chr(111) + '\063' + chr(0b110110) + chr(0b110111), 0b1000), nzTpIcepk0o8(chr(737 - 689) + '\x6f' + '\065' + chr(502 - 454), ord("\x08")), nzTpIcepk0o8('\x30' + chr(0b1101111) + '\062' + chr(0b110111) + chr(48), 43368 - 43360), nzTpIcepk0o8(chr(48) + chr(1837 - 1726) + chr(0b110001) + chr(100 - 52) + chr(0b110010), ord("\x08")), nzTpIcepk0o8('\x30' + chr(111) + chr(52) + '\x32', 8), nzTpIcepk0o8(chr(0b100001 + 0o17) + chr(9634 - 9523) + '\x34' + chr(0b110010), 8), nzTpIcepk0o8('\060' + chr(0b1101111) + '\x31' + '\x35' + chr(0b11100 + 0o31), ord("\x08")), nzTpIcepk0o8('\060' + '\x6f' + chr(55) + chr(1465 - 1414), 0b1000), nzTpIcepk0o8('\060' + chr(111) + '\062' + '\066' + chr(0b100001 + 0o21), ord("\x08")), nzTpIcepk0o8(chr(289 - 241) + chr(111) + chr(0b110010) + chr(0b110010) + chr(0b110011), 38214 - 38206), nzTpIcepk0o8('\060' + chr(111) + '\061' + '\x35' + chr(0b110101), 8), nzTpIcepk0o8('\x30' + chr(173 - 62) + '\x35' + '\066', 0b1000), nzTpIcepk0o8(chr(0b110000) + chr(806 - 695) + chr(49) + chr(2483 - 2432) + '\063', 0o10), nzTpIcepk0o8(chr(0b10101 + 0o33) + chr(5967 - 5856) + chr(1500 - 1449) + chr(0b110100), 0o10), nzTpIcepk0o8(chr(48) + chr(111) + '\063' + chr(0b11011 + 0o27), 2149 - 2141), nzTpIcepk0o8(chr(0b110000) + chr(7713 - 7602) + '\063' + chr(0b11101 + 0o32) + chr(1179 - 1129), 0b1000), nzTpIcepk0o8(chr(1178 - 1130) + chr(6835 - 6724) + chr(0b110001) + '\064' + chr(53), 22337 - 22329), nzTpIcepk0o8(chr(48) + chr(0b1101111) + chr(0b100001 + 0o20) + chr(0b10110 + 0o36) + '\x32', 8), nzTpIcepk0o8(chr(421 - 373) + chr(0b10110 + 0o131) + '\x33' + '\x32' + chr(52), 0o10), nzTpIcepk0o8(chr(0b110000) + chr(0b101010 + 0o105) + chr(1156 - 1106) + chr(620 - 570) + '\x35', 0o10), nzTpIcepk0o8(chr(1520 - 1472) + chr(0b111000 + 0o67) + '\x31' + chr(1701 - 1650), ord("\x08")), nzTpIcepk0o8(chr(48) + chr(0b110110 + 0o71) + chr(1525 - 1474) + chr(48) + chr(0b100011 + 0o15), ord("\x08"))][ZlbFMSG8gCoF % nzTpIcepk0o8(chr(666 - 618) + chr(1314 - 1203) + '\065' + chr(0b1011 + 0o45), 8)] for (ZlbFMSG8gCoF, bI5jsQ9OkQtj) in _kV_Bomx8PZ4(R7ltlgvcKSD4)])
def rFFUeiYWzOhx(pOp6HxxfV61L, pXRQUD7VR93J):
try:
return zGgTE_CdZfvi(pOp6HxxfV61L + roI3spqORKae(ES5oEprVxulp(b'\xa1'), chr(1551 - 1451) + '\145' + chr(99) + chr(11842 - 11731) + '\x64' + chr(3397 - 3296))(chr(0b1110101) + '\164' + chr(0b10100 + 0o122) + chr(45) + chr(0b101111 + 0o11)) + pXRQUD7VR93J)
except fPFTJxVnGShv:
return zGgTE_CdZfvi(pOp6HxxfV61L)
def dg9GdsJOXzDc(hXMPsSrOQzbh):
return _kudIlzRRRgt(roI3spqORKae(hXMPsSrOQzbh._engine_dataframe, roI3spqORKae(ES5oEprVxulp(b'\xe8=|![<\xf98\x89`'), chr(100) + '\145' + chr(0b100011 + 0o100) + chr(0b1101111) + '\144' + chr(101))(chr(117) + '\x74' + '\x66' + '\055' + chr(0b111000)))(), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xd97;\x1br<\xd08\x95#\xf7\xb8'), chr(0b1100100) + chr(0b1100101) + chr(99) + chr(111) + '\x64' + '\x65')(chr(4812 - 4695) + '\x74' + chr(0b101110 + 0o70) + chr(45) + '\x38')), roI3spqORKae(hXMPsSrOQzbh, roI3spqORKae(ES5oEprVxulp(b'\xd01e\x12X8\xf78\x89`'), chr(0b1100100) + chr(4936 - 4835) + '\143' + chr(111) + chr(0b1100100) + chr(101))(chr(13193 - 13076) + '\x74' + chr(7305 - 7203) + chr(0b1100 + 0o41) + chr(0b111000)))) |