How do I get the user avatar picture?
you can get Url it by   get('user_picture')-&gt;entity-&gt;url()( you can get URI too with get('user_picture')-&gt;entity-&gt;getFileUri()), So  

function tropical_preprocess_page(&amp;$variables){
  // gets current user name
  $user_logged_in_name = $variables['user']-&gt;getDisplayName();

  // creates value to ouput in the DOM &amp; capitalize first letter
  $variables['user_logged_in_name'] = ucfirst($user_logged_in_name);

  // gets user email
  $user_email = $variables['user']-&gt;getEmail();
  $variables['user_email'] = $user_email;

  // get user picture
  $user = \Drupal\user\Entity\User::load(\Drupal::currentUser()-&gt;id())
  $variables['user_picture'] = $user-&gt;get('user_picture')-&gt;entity-&gt;url();

}


Additionally,  If you want to get the default image when the user account doesn't have an image associated, use the following code.

$field = \Drupal\field\Entity\FieldConfig::loadByName('user', 'user', 'user_picture');
$default_image = $field-&gt;getSetting('default_image');
$file = \Drupal::entityManager()-&gt;loadEntityByUuid('file', $default_image['uuid']);
$picture = file_create_url($file-&gt;getFileUri());