Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a Crop operation for Android Bitmap #478

Merged
merged 2 commits into from
Nov 7, 2022

Conversation

juliabeliaeva
Copy link
Contributor

This operation is useful for combining face detection and face alignment models (since face alignment model needs to have an approximate face location on the image).

return when (inputShape.rank()) {
2 -> TensorShape(width.toLong(), height.toLong())
3 -> TensorShape(width.toLong(), height.toLong(), inputShape[2])
else -> throw IllegalArgumentException("Input shape must expected to be 2D or 3D")
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo 'must expected'

Fix error message and remove duplication
@juliabeliaeva juliabeliaeva merged commit d2cecf8 into Kotlin:master Nov 7, 2022
@juliabeliaeva juliabeliaeva deleted the cropping branch November 7, 2022 20:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants