Using to user_profile_form being used on a page thats not /user/#/edit
You're likely using module_load_include() to include modules/user/user.pages.inc.

However, you need to use form_load_include() whenever you attempt to load, build, process, and render a form that is defined and constructed in an entirely different include file.

form_load_include() requires to pass the $form_state in order to record the file to include (and automatically load it later, if needed). This needs to happen before the form structure is cached (which happens directly after invoking the constructor).

In order to do that, you can resemble what drupal_get_form() does, and inject the needed form_load_include() prior to building the form, like this:

$form_id = 'user_profile_form';
$form_state = array();
$form_state['build_info']['args'] = array($user);

// Load user.pages.inc and ensure it is automatically reloaded if
// this form is rebuilt via AJAX or other means.
form_load_include($form_state, 'inc', 'user', 'user.pages');

$form = drupal_build_form($form_id, $form_state);


More details:

Normally, Form API automatically takes over the include file to load (if any) from the menu router item definition in hook_menu().

In your case, your custom 'my/account' menu router item is not directly related to user.module, nor user.pages.inc, so the system does not know that this include file is required to build the form, especially when the form is submitted and rebuilt via AJAX — which happens on yet another system path/menu router item, namely 'system/ajax' (which, by default, would only know about an include file of your 'my/account' menu router item, if any).

In turn, Form API gets a request to rebuild user_profile_form, but the form constructor function user_profile_form() is not defined, because user.pages.inc was not loaded, since the cached $form_state does not contain a pointer that the file needs to be loaded.