Tuners calculate this all the time so they know what size injectors to use and how much flow. The only inaccuracy comes from predicting the efficiency of the engine at different RPM. Since you know the fuel flow, you know how much power you are putting in.
Don't get too presumptuous about what can and what can not be calculated. I have a desktop Dyno software program to predict HP and Torque based on engine specs. Ran the numbers and it was dead on to what Edelbrock published on their dyno tests. (within 5 HP at any RPM). I then added in the modifications that I've put on and did acceleration tests. Those tests came within 20 HP of predicted HP.
While this in all very interesting, it really doesn't tell you anything useful, as it assumes the engine is in good operating condition. If the engine is having problems, the accuracy goes out the window, as it is based on known facts about how engines operate. HP reading won't tell you if there is something wrong, although if you loose power and the HP numbers are skyrocketing, you know you ran out of fuel.