facer icon indicating copy to clipboard operation
facer copied to clipboard

lazy wrapper should be called at most once

Open deisler134 opened this issue 9 months ago • 0 comments

when run face_parser with multi-threading, get error

  File "/root/.local/lib/python3.10/site-packages/facer/face_parsing/farl.py", line 79, in forward
[2024-05-14 21:41:31,730][mif-ml09.marz.vfx][__main__:_segment:130][INFO] - process track 5
    grid = setting['get_grid_fn'](matrix=matrix, orig_shape=(h, w))
  File "/root/.local/lib/python3.10/site-packages/facer/transform.py", line 353, in make_tanh_warp_grid
    return _forge_grid(
  File "/root/.local/lib/python3.10/site-packages/facer/transform.py", line 225, in _forge_grid
    out_xxyy: torch.Tensor = fn(in_xxyy)  # (h x w) x 2
  File "/root/.local/lib/python3.10/site-packages/facer/transform.py", line 279, in inverted_tanh_warp_transform
    inv_matrix = torch.linalg.inv(matrix)  # b x 3 x 3
RuntimeError: lazy wrapper should be called at most once

deisler134 avatar May 14 '24 22:05 deisler134