Clear Filters
Clear Filters

Determining Minpts and Eps value automatically on matlab? (DBSCAN ALGORITHM)

7 views (last 30 days)
Hello,
How can i determine Minpts and Eps value automaticly for DBSCAN 2d images on matlab?

Answers (1)

Walter Roberson
Walter Roberson on 30 Jun 2021
Edited: Walter Roberson on 2 Jul 2021
We sometimes get questions from people who want to automatically determine the best number of clusters to use for kmeans.
The response to that is, "The best number of clusters to use, is the number of unique points. For any other configuration, you can always reduce the error by creating a new cluster centered at a point that is not already part of an existing cluster; when you have number of clusters == number of unique points, the error is 0 because each point is distance 0 from its cluster centre."
So... you can alter Minpts and Eps through any means you want. Randomize. Sweep squentially. Do a grid search. Use Surrogate Optimization.
But you will find the same thing: the error will be lowest when every unique point is its own cluster center.
If you are not prepared to be told that a given image has 20000 or 30000 "objects", then you have limit on the number of clusters. In that case the "best" number of clusters to use will be that upper limit (unless it exceeds the number of unique points.)
.... Or perhaps you have a cost associated with each cluster, and you want to somehow balance the total "cost" against the accuracy. Designing that kind of balance can be difficult. Would you be willing to add an additional $5000 sensor if it made detection 1% more accurate? Depends what the consequences of inaccuracy are. Car scrapes its paint job against a nail sticking out of the wall? One mango out of 100 goes out Fine Quality instead of Extra Fine? One more avacodo out of 100 goes out carrying enough salmonella to make someone ill? https://www.sacbee.com/news/nation-world/national/article223495930.html

Categories

Find more on Introduction to Installation and Licensing in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!