smartin015 / continuousprint

Octoprint plugin to allow the creation of a print queue that prints, clears the bed and then prints again
40 stars 38 forks source link

Computer vision assisted print quality checks #229

Open smartin015 opened 1 year ago

smartin015 commented 1 year ago

Is your feature request related to a problem? Please describe.

Discussion in #57 outlines the disconnect between printing and inventory - there's usually a manual QA and data entry step involved as "completing a print" may not actually produce a functional part. There may be opportunity here to eliminate some of the manual work for egregiously bad prints - ones you could see at a glance aren't what is intended to be printed.

Describe the solution you'd like

There may be some value in performing initial QA via a webcam or other camera pointed at the completed print. This is functionally similar to the image diffing capabilities in the BedReady plugin, but for incrementing an inventory value rather than blocking the start of a new print.

I expect the most general purpose solution would be one that adds preprocessor symbol table functions for

We can then, take a snapshot of print that's completed for the first time (examining via metadata), then diff snapshots of subsequent completed prints and submit an "increment inventory" HTTP request to an external system whenever the print is successful.

Describe alternatives you've considered

I could also implement this specifically in the driver state machine and include it as an additional check when printing multiple copies of the same job. That'd be pretty slick, especially since it could make use of retry behavior and possibly lead to other more intelligent diagnosis (as in #216).

QA could also be completed via probe or some other mechanical test, but a zero-touch webcam based solution seems the lowest effort vs the benefit.

Additional context

I contributed some PRs to BedReady that allow programmatic image capture and comparison - the most recent is https://github.com/jneilliii/OctoPrint-BedReady/pull/19