Skip to content

Commit

Permalink
Merge pull request #157 from cosanlab/fix_video
Browse files Browse the repository at this point in the history
Fix multiple bugs arising from detections that contain no faces
  • Loading branch information
ejolly authored Feb 6, 2023
2 parents 03337f4 + c7dd182 commit 4beba11
Show file tree
Hide file tree
Showing 19 changed files with 810 additions and 236 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Py-FEAT: Python Facial Expression Analysis Toolbox
[![arXiv-badge](https://img.shields.io/badge/arXiv-2104.03509-red.svg)](https://arxiv.org/abs/2104.03509)
[![Package versioning](https://img.shields.io/pypi/v/py-feat.svg)](https://pypi.org/project/py-feat/)
[![Tests](https://github.com/cosanlab/py-feat/actions/workflows/tests_and_docs.yml/badge.svg)](https://github.com/cosanlab/py-feat/actions/workflows/tests_and_docs.yml)
[![Coverage Status](https://coveralls.io/repos/github/cosanlab/py-feat/badge.svg?branch=master)](https://coveralls.io/github/cosanlab/py-feat?branch=master)
Expand Down
11 changes: 11 additions & 0 deletions docs/pages/changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
# Change Log

# 0.5.1

## Notes

This is a maintenance release that addresses multiple under-the-hood issues with `py-feat` failing when images or videos contain 0 faces. It addresses the following specific issues amongst others and is recommended for all users:

- [#153](https://github.com/cosanlab/py-feat/issues/153)
- [#155](https://github.com/cosanlab/py-feat/issues/155)
- [#158](https://github.com/cosanlab/py-feat/issues/158)
- [#160](https://github.com/cosanlab/py-feat/issues/160)

# 0.5.0

## Notes
Expand Down
1 change: 1 addition & 0 deletions docs/pages/intro.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
Py-Feat: Python Facial Expression Analysis Toolbox
============================
[![arXiv-badge](https://img.shields.io/badge/arXiv-2104.03509-red.svg)](https://arxiv.org/abs/2104.03509)
[![Package versioning](https://img.shields.io/pypi/v/py-feat.svg)](https://pypi.org/project/py-feat/)
[![Tests](https://github.com/cosanlab/py-feat/actions/workflows/tests_and_docs.yml/badge.svg)](https://github.com/cosanlab/py-feat/actions/workflows/tests_and_docs.yml)
[![Coverage Status](https://coveralls.io/repos/github/cosanlab/py-feat/badge.svg?branch=master)](https://coveralls.io/github/cosanlab/py-feat?branch=master)
Expand Down
28 changes: 15 additions & 13 deletions feat/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -1974,19 +1974,21 @@ def _inverse_face_transform(faces, batch_data):
out_face = []
for face in frame:
out_face.append(
np.append(
(
np.array(
[
face[0] - left,
face[1] - top,
face[2] - left,
face[3] - top,
]
)
/ scale
),
face[4],
list(
np.append(
(
np.array(
[
face[0] - left,
face[1] - top,
face[2] - left,
face[3] - top,
]
)
/ scale
),
face[4],
)
)
)
out_frame.append(out_face)
Expand Down
Loading

0 comments on commit 4beba11

Please sign in to comment.