get_attached_media() on author page not working

I assume that you have a simple misunderstanding of what this function actually does and what it should be used for: get_attached_media() simply fetches all child posts for a given posts:

if ( ! $post = get_post( $post ) )
    return array();

$args = array(
    'post_parent'    => $post->ID,
    'post_type'      => 'attachment',
    'post_mime_type' => $type,
    'posts_per_page' => -1,
    'orderby'        => 'menu_order',
    'order'          => 'ASC',
);

From Codex:

Retrieve media attached to the passed post. Uses get_children().

If you are using this on an author archive, the main query will be retrievable by using $GLOBALS['wpdb']->get_queried_object() or just get_queried_object(). Again from the Codex page:

If you’re on an author archive, it will return the author object

Now, an author per default is a WP_User and not a post object that can have children. To retrieve all media that an author attached to posts, you will have to loop through the posts of an author and then query for the media inside the loop by using $media = get_attached_media( get_the_ID() );.