Open source coffee sorter project

Hi Matthias

Glad you got back so quick. My main drive Convery will be 4" wide and I can get 3 slow convers about 1/2" with air blow offs. I can use either Arduino or Raspberry Pi I have both.
I have a CNC to make the components. My biggest problem is I am not much of a programmer CCD camera
I have a Grove I2C Color Sensor, Also have 1000TVL CCD camera and OV7670. So I have several ways I can go with this. If can figure out the software for them I’ll be doing great.

Keep up your good work and I’ll get back to ya soon

Bob

2 Likes

We have mini coffee sorter for small scale farmer.The price is not scared.
The machine is very small and portable .It could sort many different grains,rice.It is full color.

you could find more information from our websites
Please visit our website for more information

I like the machine you have on offer … indeed one of the smallest and lightest ones I saw (80 kg, 40 × 100 × 100 cm). If you read through this thread you’ll notice that we try to build an even smaller one, and that there is commercial demand for it from different kinds of small agricultural industries (incl. small coffee growers and cooperatives, of course).

In other words, if you’d make a sorter with 10% of your MINI-32 sorter’s capacity and sell it for 10% of its price, @anu and I would buy one immediately. To my knowledge, no company is making something like that right now :slight_frown: It’s an untapped market! Maybe your company wants to develop such a model?

1 Like

Hi everybody.
I agree with Matthias.
Try to make a smaller sorter.
With 25 to 30kg per hour at a cheap price and small footprint, you will find a market of small producers, small roasters and even coffee geeks.
If you also can make it compliant with electric generators, it will be almost perfect.
Thanks you all!

2 Likes

Hi Matthias
why do you need so small machine? for that small capacity,the human can manually sort it .It just take a few minutes to finish the job.

Well of course manual sorting is possible, and 80% of the coffee worldwide is still hand-sorted (or so I’ve read).

But in many cases, these people would also choose a color sorter if one would be available for their size of operations, matching in both capacity and price. This might be a small to medium farm, a coffee cooperative of small farmers, or a small artisanal roastery in coffee-consuming countries. For all of these cases, even your small color sorter is too expensive and has way more capacity than they need. So there is the opportunity that they’d buy a cheaper, smaller machine.

As we found out, a worker can sort 5 kg of green beans per hour under average conditions. So, 200 kg in a 40 hour work week. On the other hand, your small sorter, when running 24/7, can process 250 kg/h * 24 hours/day * 7 days = 42 tons per week, as much as 42,000 kg/week / 200 kg/worker/week = 210 workers. That’s way more than most manual sorting operations need. They might have 5 - 30 workers for sorting, could be replaced with a sorter sorting 25 kg per hour, replacing 21 workers.

I’m not proposing to put these workers out of business, but to enable small farms etc. to produce higher quality coffee instead of selling it unsorted to wholesalers. Because then they get a much better price for their coffee as well.

I hope this makes it clear, otherwise I can explain it more. And let me know when your company decides to make a “micro color sorter” :smile:

2 Likes

Hi :slight_smile: I like this project! You have a lot of notes here, but they are mostly from the last year. You wrote that

The major development will happen from January to April 2018 during the OpenVillage Academy in Sidi Kaouki,

Did this happen? Do you have a video of working machine? Are there some newer updates about this project, about things you’ve learned from the actual prototype?

Thanks a lot!

Ah yes, I did not yet update the time plan.

In reality, we worked on that between January and April but got stuck with the image classifier. I now think that neural networks are not good at sorting something based on “fuzzy spots of color”, they want to see edges and clear lines. So maybe creating color histograms from the bean images and running a classifier on that would help, but we did not try that yet.

If you want to do some experiments on your own, I could upload our dataset of coffee beans images at least.

Yes, that would be cool :slight_smile: How many beans per second (on the conveyor belt) did you process? Were the pictures too blurry? How did you manage consistent lighting?

Ok, I will upload the picture set then. It’s just the first training set for the image classifier though, not yet produced with a coffee sorter machine. We simply made photos of 20-30 beans at once (unordered) and I wrote a small script that split these up into individual images with one been each. For consistent lighting, the best trick was direct sun and a white translucent plastic bowl over the beans when taking a photo.

How did you want to sort them out when they were clumped together? Once you find that some bean is bad, you’d throw away also the neighbours?

They should not be clumped together because the two conveyors and funnels in the current machine design will place the beans into a single line, with enough distance between them so that each can be removed individually.

Throwing out the whole group of beans together would also be an option, though. Commercial optical sorters do it similarly: they create “first rejects” in a first pass, which includes some good beans. The first rejects are then fed to the machine again. This time, the beans will be grouped differently and so the machine will only throw out the bad ones (with a few exceptions of course). These are then called the “final rejects”.

Ok then @xixli, I have just converted and uploaded our coffee bean images in a manageable size. they in our repo in the training-data-jpg directory, and to download them you can either git clone the whole repository or download it as a ZIP archive. Happy experimenting! :slight_smile:

2 Likes

Thanks for your explain .I will report to our company for your request.
By the way,we have some mini color sorter videos on YOUTUBE ,you could check for your reference

MINI COLOR SORTER WORKING VIDEO

This video for sorting rice.We also have video for sorting green coffee.If you need I could send you for your reference.

2 Likes

Hello,
May I suggest a thin shard of glass at a certain angle, so beans can slide and offer both sides to cameras?
Free fall is another option, and analyze it at the beginning of the fall, when the speed is low.
A lot cheaper than conveyor belts, and faster than flipping them over to see the other side (or trying to).
I really hope this project is a success.

1 Like

Oh, that’s a great idea, thank you! I was thinking repeatedly about some alternatives, which seem inferior now:

  • a setup with mirrors – but still they can’t see under a bean, just its top and sides
  • a setup with a transparent conveyor – but that will accumulate dust, and also a material that is both flexible and optically clear and does not distort the picture is difficult to find

I think that’s suitable for more industrial-scale machines that can guarantee a maximum processing time for the pictures – because when analyzing in free fall and without conveyors, the machine needs to rely on timing to kick the right beans into the right destinations.

I’m so happy to be of any help.
I really hate sorting bad beans (read: hate to convince my wife to do it}. :smile:
If you need a financial push, I can pre-buy my $300 unit right now. :smiley:
I’m romanian, not native english, so mistakes made are unintentional.

1 Like

Just wanted to say hi, wow and thanks! This looks like an AWESOME project! My wife has a small coffee roasting company, and I can confirm that much of her time is spent sorting beans. I have very basic coding knowledge (python, html, php etc) and access to 3D printers and raspberry pis. I would love to help out in any way possible with my limited skillsets. Perhaps some testing of software as we have a stock of green beans also? Hope things are still progressing with this project :slight_smile:

2 Likes

Hello Neil, welcome here and thank you for the motivating comment!

Where we got stuck (for the moment) is creating a reliable image classifier to distinguish good and bad beans. Normal deep learning based approaches with pre-trained networks are too fixed on recognizing shapes and edges – fuzzy color areas etc. as in green beans do not sit well with them, we tried that.

But there is a lot of other software that could help, including applications of OpenCV. This is not necessarily complex coding but you need to have the right idea. Python is a good language of choice for that, actually. So, if you want to give it a try :slight_smile: (We have a repo with training and testing images of individual green beans, see here.)

Once we have a working classifier algorithm, I promise to finish a machine and publish its designs under an open licence. A crowdfunding campaign for that seems within reach then. Just right now, I’m a bit stuck, also since I don’t have much time to spend on this right now.

1 Like

Hey Matthias,

Sorry to hear things are being difficult - I guess that’s what proves it’s a worthwhile project!

I’ve started to slowly look through the documentation on opencv and am finding it interesting and not so complex that my brain hurts! I’m still nowhere near skilled enough to even think about how this could work for this project, but I’ll keep learning when I get the chance and see if any eureka moments pop up later on!

Fingers crossed we manage to pull something together between us all. Come on internet!

1 Like