Not all drawable images are loading using picasso
<p>I used picasso to load my drawable image because they have high resolution.</p>

<p>the problem now is: Not all images are loading, Sometimes 3 out 4 images showed in the activity, Sometimes 1 out 4 images.</p>

<p>Here is the code:</p>

<pre><code>import android.content.Context;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.widget.ImageView;

import com.squareup.picasso.MemoryPolicy;
import com.squareup.picasso.Picasso;




public class SummaryOfTour extends AppCompatActivity {
    Context context;

    ImageView imageView ,imageView1,imageView2,imageView3,imageView4,imageView5;


    static int ms1,ms2,ms3,ms4,ms5;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_summary_of_tour);

        imageView = (ImageView) findViewById(R.id.img1);
        imageView1 = (ImageView) findViewById(R.id.img2);
        imageView2 = (ImageView) findViewById(R.id.img3);
        imageView3 = (ImageView) findViewById(R.id.img4);
        imageView4 = (ImageView) findViewById(R.id.img5);

if(ms1 ==1) {

    Picasso.with(this)
            .load(R.drawable.mp1)
            .resize(1000, 1690)

            .into(imageView);


    Picasso.with(this)
            .load(R.drawable.mp2)
            .resize(1000, 1690)
            .into(imageView1);

    Picasso.with(this)
            .load(R.drawable.mp3)
            .resize(1000, 1690)
            .into(imageView2);

    Picasso.with(this)
            .load(R.drawable.mp4)
            .resize(1000, 1690)
            .into(imageView3);

    Picasso.with(this)
            .load(R.drawable.bg)
            .resize(1000, 1700)
            .into(imageView4);

}
        else if (ms2 ==1) {
            Picasso.with(this)
                    .load(R.drawable.mp11)
                    .resize(1000, 1690)
                    .into(imageView);

            Picasso.with(this)
                    .load(R.drawable.mp22)
                    .resize(1000, 1690)
                    .into(imageView1);

            Picasso.with(this)
                    .load(R.drawable.mp33)
                    .resize(1000, 1690)
                    .into(imageView2);

            Picasso.with(this)
                    .load(R.drawable.mp44)
                    .resize(1000, 1690)
                    .into(imageView3);

            Picasso.with(this)
                    .load(R.drawable.bg)
                    .resize(1000, 1700)
                    .into(imageView4);

        }

else if (ms3 ==1) {
    Picasso.with(this)
            .load(R.drawable.mp111)
            .resize(1000, 1690)
            .into(imageView);

    Picasso.with(this)
            .load(R.drawable.mp222)
            .resize(1000, 1690)
            .into(imageView1);

    Picasso.with(this)
            .load(R.drawable.mp333)
            .resize(1000, 1690)
            .into(imageView2);

    Picasso.with(this)
            .load(R.drawable.mp444)
            .resize(1000, 1690)
            .into(imageView3);

    Picasso.with(this)
            .load(R.drawable.bg)
            .resize(1000, 1700)
            .into(imageView4);

}

else if (ms4 ==1) {
    Picasso.with(this)
            .load(R.drawable.mp1111)
            .resize(1000, 1690)
            .into(imageView);

    Picasso.with(this)
            .load(R.drawable.mp2222)
            .resize(1000, 1690)
            .into(imageView1);

    Picasso.with(this)
            .load(R.drawable.mp5555)
            .resize(1000, 1690)
            .into(imageView2);

    Picasso.with(this)
            .load(R.drawable.mp7777)
            .resize(1000, 1690)
            .into(imageView3);

    Picasso.with(this)
            .load(R.drawable.mp66666)
            .resize(1000, 1700)
            .into(imageView4);

}





    }
}
</code></pre>

<p>Here is my XML:</p>

<pre><code>&lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    xmlns:tools="http://schemas.android.com/tools"
    android:paddingBottom="@dimen/activity_vertical_margin"
    android:paddingLeft="@dimen/activity_horizontal_margin"
    android:paddingRight="@dimen/activity_horizontal_margin"
    android:paddingTop="@dimen/activity_vertical_margin"
    tools:context="com.sumo.traffic.InfoOfArtInIsland"
    android:background="#87E886"
    android:orientation="vertical"&gt;
    &lt;ScrollView
        android:id="@+id/scrollView1"
        android:layout_width="match_parent"
        android:layout_height="500dp" &gt;
        &lt;LinearLayout
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:orientation="vertical"
            android:weightSum="1"&gt;



            &lt;LinearLayout
                android:layout_width="fill_parent"
                android:layout_height="wrap_content"
                android:orientation="horizontal"
                android:layout_marginTop="10dp"&gt;
                &lt;ImageView
                    android:layout_width="100dp"
                    android:layout_height="100dp"
                    android:id="@+id/imageView5"
                    android:src="@drawable/loaders"
                    android:layout_alignParentTop="true"
                    android:layout_centerHorizontal="true"
                    android:layout_marginLeft="100dp"
                    android:layout_gravity="right" /&gt;
            &lt;/LinearLayout&gt;



            &lt;RelativeLayout
                android:layout_width="320dp"
                android:layout_height="550dp"
                android:orientation="horizontal"
                android:layout_marginTop="10dp"
                android:background="#BEFFB6"
                android:layout_marginLeft="10dp"&gt;



                &lt;ImageView
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:id="@+id/img1"

                    android:layout_alignParentTop="true"
                    android:layout_alignStart="@+id/bckgrndViewFlipper1" /&gt;
            &lt;/RelativeLayout&gt;
            &lt;RelativeLayout
                android:layout_width="320dp"
                android:layout_height="550dp"
                android:orientation="horizontal"
                android:layout_marginTop="10dp"
                android:background="#BEFFB6"
                android:layout_marginLeft="10dp"&gt;



                &lt;ImageView
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:id="@+id/img2"

                    android:layout_alignParentTop="true"
                    android:layout_alignStart="@+id/bckgrndViewFlipper1" /&gt;
            &lt;/RelativeLayout&gt;

            &lt;RelativeLayout
                android:layout_width="320dp"
                android:layout_height="550dp"
                android:orientation="horizontal"
                android:layout_marginTop="10dp"
                android:background="#BEFFB6"
                android:layout_marginLeft="10dp"&gt;



                &lt;ImageView
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:id="@+id/img3"

                    android:layout_alignParentTop="true"
                    android:layout_alignStart="@+id/bckgrndViewFlipper1" /&gt;
            &lt;/RelativeLayout&gt;


            &lt;RelativeLayout
                android:layout_width="320dp"
                android:layout_height="550dp"
                android:orientation="horizontal"
                android:layout_marginTop="10dp"
                android:background="#BEFFB6"
                android:layout_marginLeft="10dp"&gt;



                &lt;ImageView
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:id="@+id/img4"

                    android:layout_alignParentTop="true"
                    android:layout_alignStart="@+id/bckgrndViewFlipper1" /&gt;
            &lt;/RelativeLayout&gt;


            &lt;RelativeLayout
                android:layout_width="320dp"
                android:layout_height="550dp"
                android:orientation="horizontal"
                android:layout_marginTop="10dp"
                android:background="#BEFFB6"
                android:layout_marginLeft="10dp"&gt;



                &lt;ImageView
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:id="@+id/img5"

                    android:layout_alignParentTop="true"
                    android:layout_alignStart="@+id/bckgrndViewFlipper1" /&gt;
            &lt;/RelativeLayout&gt;







            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

            &lt;!-- to be commented xml block goes here --&gt;

        &lt;/LinearLayout&gt;






        &lt;!-- to be commented xml block goes here --&gt;

        &lt;!-- to be commented xml block goes here --&gt;

        &lt;!-- to be commented xml block goes here --&gt;

        &lt;!-- to be commented xml block goes here --&gt;

        &lt;!-- to be commented xml block goes here --&gt;




        &lt;!--       &lt;LinearLayout
                   android:layout_width="fill_parent"
                   android:layout_height="wrap_content"
                   android:orientation="horizontal"
                   android:layout_marginTop="20dp"&gt;
                   &lt;ImageButton
                       android:layout_width="wrap_content"
                       android:layout_height="100dp"
                       android:id="@+id/imageButton3"
                       android:background="@drawable/faqz"
                       android:layout_alignParentBottom="true"
                       android:layout_alignParentStart="true"
                       android:layout_marginBottom="10dp"/&gt;

               &lt;/LinearLayout&gt;

   --&gt;




    &lt;/ScrollView&gt;
&lt;/LinearLayout&gt;
</code></pre>