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

feat: Add OCR to detect mod names, retrieve plat prices from warframe.market #4

Merged
merged 30 commits into from
Jan 10, 2022
Merged

Conversation

Tiebe
Copy link
Contributor

@Tiebe Tiebe commented Jan 5, 2022

Add OCR for Mod names, still needs some work, check readme for TODO

@Tiebe Tiebe marked this pull request as ready for review January 7, 2022 22:49
@Tiebe
Copy link
Contributor Author

Tiebe commented Jan 7, 2022

Could be merged, but still needs a bit of work

@Tiebe Tiebe changed the title Add some stuff Add OCR to detect mod names Jan 8, 2022
Sorry I just spent an hour debugging a stupid error (and I still don't know what caused it)
@Tiebe
Copy link
Contributor Author

Tiebe commented Jan 8, 2022

I think the only thing left to add is some multithreading

@Tiebe Tiebe changed the title Add OCR to detect mod names Add OCR to detect mod names, retrieve plat prices from warframe.market Jan 8, 2022
README.md Outdated Show resolved Hide resolved
pom.xml Outdated Show resolved Hide resolved
@Bourne-ID
Copy link
Contributor

It's been 5 years so I'm excited someone is wanting to contribute towards this project, however much I had hoped the WF devs would have produced a public API endpoint to do what this project attempted to achieve.

I agree with Tobi's comments, and I'm as guilty of not fully documenting my code when I did this, and looking back I struggle to remember some of the parts I wrote from 5 years ago.

Given the lack of CI/CT I'm happy to help give the PR a test before merging down into main.

@TobiTenno
Copy link
Member

yeah, could we look at doing a round of setting up tests with some test images and what they should output, with varying amounts of mods in them?

@Tiebe
Copy link
Contributor Author

Tiebe commented Jan 9, 2022

Yeah, I believe there are already some test images in the test folder, I'll setup some tests later, and add all the javadocs of course. Problem with rivens is that their names are semi-randomized. Maybe I can split those names into parts and check each part separately.

@TobiTenno
Copy link
Member

TobiTenno commented Jan 9, 2022

I have a regex someplace for rivens, I'll try to drop it in a comment on here.

'((Ampi|Manti|Argi|Pura|Geli|Tori|Uti|Tempi|Crita|Pleci|Acri|Visi|Vexi|Igni|Exi|Croni|Conci|Magna|Arma|Sati|Toxi|Lexi|Insi|Feva|Locti|Sci|Hexa|Deci|Zeti|Hera)-)?(Ampi|Manti|Argi|Pura|Geli|Tori|Uti|Tempi|Crita|Pleci|Acri|Visi|Vexi|Igni|Exi|Croni|Conci|Magna|Arma|Sati|Toxi|Lexi|Insi|Feva|Locti|Sci|Hexa|Deci|Zeti|Hera)[- ]?(Bin|Tron|Con|Ada|Do|Bo|Tia|Nem|Cron|Nent|Tis|Ata|Tio|Pha|Cta|Dra|Nak|Ton|Tin|Can|Tox|Nok|Cak|Tak|Tor|Sus|Dex|Des|Mag|Lis)

@Tiebe
Copy link
Contributor Author

Tiebe commented Jan 9, 2022

Awesome!! Thank you

@TobiTenno
Copy link
Member

@Bourne-ID would you be horribly against re-scoping the packages to be like us.warframestat.* so they match the org's domain?

@Bourne-ID
Copy link
Contributor

@TobiTenno None - Want me to action in a different PR or crunch the change with this one? If the prior then raise an issue against my name and I'll be happy to action it.

@TobiTenno
Copy link
Member

@TobiTenno None - Want me to action in a different PR or crunch the change with this one? If the prior then raise an issue against my name and I'll be happy to action it.

yeah, makes more sense to do in a subsequent. so maybe throw out an issue and do it once we get this one and some good tests?

@Tiebe
Copy link
Contributor Author

Tiebe commented Jan 10, 2022

I don't think I'll be able to use OCR on rivens. It's because the colors on the image are so different, it requires a different image process to allow the OCR to read it at all, and since I can't know whether a mod is a riven or not, I won't be able to do this. Also, it will be hard to do a price estimation, since the prices for riven vary so much, because the better the stats the higher the price

@Tiebe
Copy link
Contributor Author

Tiebe commented Jan 10, 2022

That should be all, could someone else review and test?

@TobiTenno
Copy link
Member

i think bourne was going to. i'm good with it once they do, since I've not ever set this up before

@Tiebe
Copy link
Contributor Author

Tiebe commented Jan 10, 2022

i think bourne was going to. i'm good with it once they do, since I've not ever set this up before

I believe I've made some changes so that you can run it by just pressing start on RunApplication#main without any special args or setup

Copy link
Member

@TobiTenno TobiTenno left a comment

Choose a reason for hiding this comment

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

  • needs the 2 extra dependencies we found
  • needs docs about requiring tesseract installed for development

pom.xml Outdated Show resolved Hide resolved
@TobiTenno TobiTenno changed the title Add OCR to detect mod names, retrieve plat prices from warframe.market feat: Add OCR to detect mod names, retrieve plat prices from warframe.market Jan 10, 2022
@TobiTenno TobiTenno enabled auto-merge (squash) January 10, 2022 18:42
auto-merge was automatically disabled January 10, 2022 18:43

Head branch was pushed to by a user without write access

Copy link
Member

@TobiTenno TobiTenno left a comment

Choose a reason for hiding this comment

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

ran on linux. despite a couple weird cpp errors, ran well

@TobiTenno TobiTenno merged commit 01f29f1 into WFCD:master Jan 10, 2022
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.

None yet

3 participants