---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb Cell 8 in <cell line: 3>()
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=0'>1</a> df = DF.copy()
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=1'>2</a> im = IM.copy()
----> <a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=2'>3</a> im, df = rescale(im, df, (400, 600))
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=3'>4</a> show(im, df=df, sz=5)
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=4'>5</a> df.head()
/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb Cell 8 in rescale(im, bbs, sz)
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=110'>111</a> H, W = get_size(sz, h, w)
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=111'>112</a> aug = iaa.Resize({"height": H, "width": W})
--> <a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=112'>113</a> im, bbs = do(im, bbs, aug)
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=113'>114</a> if to_pil:
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=114'>115</a> im = PIL.Image.fromarray(im)
/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb Cell 8 in do(img, bbs, aug, cval)
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=41'>42</a> __df = combine_xyXY_to_bb(__df)
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=42'>43</a> bbs = __df
---> <a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=43'>44</a> if bbs == []:
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=44'>45</a> return img, []
<a href='vscode-notebook-cell:/Users/yeshwanth.y/code/torch_snippets/nbs/imgaug_loader.ipynb#W6sZmlsZQ%3D%3D?line=45'>46</a> return img, bbs
File ~/miniconda3/lib/python3.9/site-packages/pandas/core/ops/__init__.py:705, in _comp_method_FRAME.<locals>.f(self, other)
701 @Appender(f"Wrapper for comparison method {op_name}")
702 def f(self, other):
703 axis = 1 # only relevant for Series other case
--> 705 self, other = _align_method_FRAME(self, other, axis, level=None, flex=False)
707 # See GH#4537 for discussion of scalar op behavior
708 new_data = dispatch_to_series(self, other, op, axis=axis)
File ~/miniconda3/lib/python3.9/site-packages/pandas/core/ops/__init__.py:503, in _align_method_FRAME(left, right, axis, flex, level)
496 raise ValueError(
497 "Unable to coerce to Series/DataFrame, "
498 f"dimension must be <= 2: {right.shape}"
499 )
501 elif is_list_like(right) and not isinstance(right, (ABCSeries, ABCDataFrame)):
502 # GH17901
--> 503 right = to_series(right)
505 if flex is not None and isinstance(right, ABCDataFrame):
506 if not left._indexed_same(right):
File ~/miniconda3/lib/python3.9/site-packages/pandas/core/ops/__init__.py:465, in _align_method_FRAME.<locals>.to_series(right)
463 else:
464 if len(left.columns) != len(right):
--> 465 raise ValueError(
466 msg.format(req_len=len(left.columns), given_len=len(right))
467 )
468 right = left._constructor_sliced(right, index=left.columns)
469 return right
ValueError: Unable to coerce to Series, length must be 6: given 0