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-grayscale-equalized #62

Merged
merged 1 commit into from
Dec 6, 2022
Merged

add-grayscale-equalized #62

merged 1 commit into from
Dec 6, 2022

Conversation

fbtravi
Copy link
Member

@fbtravi fbtravi commented Nov 21, 2022

Added new face detector, the 'face_grayscale_equalized_detector'.

This detector can be used as the 'face_detector', but it is not part of the 'all', this happens so as not to change the use of whom I have the 'all' instantiated.

Issue

Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33366 lines exceeds the maximum allowed for the inline comments feature.

Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33366 lines exceeds the maximum allowed for the inline comments feature.

Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33364 lines exceeds the maximum allowed for the inline comments feature.

Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33366 lines exceeds the maximum allowed for the inline comments feature.

Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33362 lines exceeds the maximum allowed for the inline comments feature.

Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33369 lines exceeds the maximum allowed for the inline comments feature.

Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33369 lines exceeds the maximum allowed for the inline comments feature.

@coveralls
Copy link

coveralls commented Nov 22, 2022

Pull Request Test Coverage Report for Build 3620736147

  • 7 of 7 (100.0%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.4%) to 61.896%

Totals Coverage Status
Change from base Build 3433138123: 0.4%
Covered Lines: 277
Relevant Lines: 448

💛 - Coveralls

@fbtravi fbtravi changed the title Draft: add-grayscale-equalized add-grayscale-equalized Nov 23, 2022
Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33430 lines exceeds the maximum allowed for the inline comments feature.

Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33428 lines exceeds the maximum allowed for the inline comments feature.

@maiagripp
Copy link
Contributor

LGTM 🎉

Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33426 lines exceeds the maximum allowed for the inline comments feature.

Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33427 lines exceeds the maximum allowed for the inline comments feature.

Copy link
Contributor

@devppjr devppjr left a comment

Choose a reason for hiding this comment

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

LGTM 🚀

@guilhermef
Copy link
Member

@fbtravi, we can add your new detector as part of all, then make it clear on the major release.
Can you address the code climate issues?

@fbtravi
Copy link
Member Author

fbtravi commented Dec 2, 2022

hi @guilhermef

Yes, I could put it in all, but the doubt would be here.

class CompleteDetector(CascadeLoaderDetector):
    def detect(self, image):
        face_detector = FaceDetector()
        glasses_detector = GlassesDetector()
        profile_detector = ProfileDetector()
        feature_detector = FeatureDetector()

        face_points = face_detector.detect(image) or []
        glasses_points = glasses_detector.detect(image) or []
        profile_points = profile_detector.detect(image) or []
        feature_points = feature_detector.detect(image) or []

        return face_points + glasses_points + profile_points + feature_points

With two face decteres which points do we use? Do we use the points of both?

@guilhermef
Copy link
Member

@fbtravi yes, it's not a problem to have overlapping detection unless one of them is giving false positives.

@fbtravi fbtravi force-pushed the add-grayscale-equalized branch 2 times, most recently from c2252ae to 465273c Compare December 2, 2022 18:05
Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33470 lines exceeds the maximum allowed for the inline comments feature.

Copy link

@codeclimate codeclimate bot left a comment

Choose a reason for hiding this comment

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

The PR diff size of 33477 lines exceeds the maximum allowed for the inline comments feature.

@fbtravi
Copy link
Member Author

fbtravi commented Dec 2, 2022

Hi @guilhermef, changes made.

@guilhermef
Copy link
Member

Awesome work @fbtravi

# -*- coding: utf-8 -*-

# thumbor imaging service
# https://github.com/globocom/thumbor/wiki

# Licensed under the MIT license:
# http://www.opensource.org/licenses/mit-license
# Copyright (c) 2011 globo.com timehome@corp.globo.com
# Copyright (c) 2022 globo.com <thumbor@g.globo>
Copy link
Member

Choose a reason for hiding this comment

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

We should not change year from copyright on old files.

# -*- coding: utf-8 -*-

# thumbor imaging service
# https://github.com/globocom/thumbor/wiki

# Licensed under the MIT license:
# http://www.opensource.org/licenses/mit-license
# Copyright (c) 2011 globo.com timehome@corp.globo.com
# Copyright (c) 2022 globo.com <thumbor@g.globo>
Copy link
Member

Choose a reason for hiding this comment

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

We should not change year from copyright on old files.

# -*- coding: utf-8 -*-

# thumbor imaging service
# https://github.com/globocom/thumbor/wiki

# Licensed under the MIT license:
# http://www.opensource.org/licenses/mit-license
# Copyright (c) 2011 globo.com timehome@corp.globo.com
# Copyright (c) 2022 globo.com <thumbor@g.globo>
Copy link
Member

Choose a reason for hiding this comment

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

We should not change year from copyright on old files.

@heynemann
Copy link
Member

Sorry to come late to the party, but I don't think we should merge this. The goal of the entire team of committers should be to reduce thumbor's codebase, not increase it. This detector seems like an awesome addition to the ecosystem, we can even host it in thumbor's org as a separate project, but I'd love if we could trim thumbor's codebase. The more code we have the slower we move. Sorry for taking so long to review this.
That said, I'm ok with merging if you all feel like creating a new project is more trouble than it's worth.

@guilhermef
Copy link
Member

@heynemann, given the data presented on #59, shouldn't we make this the default behavior for face detection instead of adding a new detector?
It seems that this would improve the accuracy.

@heynemann
Copy link
Member

heynemann commented Dec 4, 2022 via email

@fbtravi
Copy link
Member Author

fbtravi commented Dec 5, 2022

The first idea was to create a new detector and sharing almost all the code, not changing the existing one so as not to break any users.
Leaving this unification for a future refactor, but if you think it's better, we can start with this change in the current detector.

If possible, let me know so I can continue with the implementation or not.

@guilhermef @heynemann

@guilhermef
Copy link
Member

@fbtravi let's refactor the existing face detection to include your change, then we can release it as a major change.

@codeclimate
Copy link

codeclimate bot commented Dec 5, 2022

Code Climate has analyzed commit 2e23ddc and detected 0 issues on this pull request.

View more on Code Climate.

@fbtravi
Copy link
Member Author

fbtravi commented Dec 5, 2022

Would they be able to analyze the changes?

We had a decrease in the lines tested, but this compared to my last commit, the last merge in master is like this

@guilhermef
@heynemann

@RaphaelVRossi RaphaelVRossi merged commit 9888703 into master Dec 6, 2022
@RaphaelVRossi
Copy link
Member

Great job @fbtravi 🚀

@RaphaelVRossi RaphaelVRossi deleted the add-grayscale-equalized branch December 21, 2022 21:08
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.

7 participants