I took a look through the
Search & Sort section of the calibre manual but didn't see a reserved keyword that holds an author book count. Calibre definitely uses an equivalent function (per
Tag Browser>Authors) but its either an internal function and/or computed on demand.
It would appear that a count is possible for any "multiple-valued fields". Unfortunately you're counting number of titles per author, a staggered count instead of a straight one, so this isn't quite the functionality you need.
The only other thing I can think of is taking a look at some of the plugins to see if there counting method can be borrowed and altered to fit your needs (with the programmer's permission, of course). The catalog and possibly Quality Check might have something along these lines (among other PIs). Programmatically this might require several lines of code as I think you're dealing with an array, not just a simple count. So... probably not a minor task.