This question is building on Getting List elements from .reduceRegion() results in Google Earth Engine?
My issue is identical, I need to calculate histograms for polygons and extract pixel counts.
As I need to process many polygons and getInfo inteferes with client side operations, how else can I iterate through a list of feature and extract the histogram counts?
The Earth Engine help suggests this maybe possible with "callback" functions, but I am unsure how to make this work, and in any case it is not recommended.
Linked below is my example code and the Earth Engine help page for Client vs. Server issues: