Improved callbacks - added a method to obtain dimension