"Thou wilt keep him in perfect peace, whose mind is stayed on thee: because he trusteth in thee." (Isaiah 26: 3)
God keeps us in perfect peace, and this peace causes our minds, our imaginations, to rest in Him.
This rest we receive through our trust in Him:
"Come unto me, all ye that labour and are heavy laden, and I will give you rest." (Matthew 11: 28)
Literally, Jesus offers us the following promise: "I will rest you."
He is our perfect peace (Ephesians 2: 14), and because of what Jesus did at the Cross, we have peace with God (Romans 5: 1)
Our one responsibility is to believe:
"Jesus answered and said unto them, This is the work of God, that ye believe on him whom he hath sent." (John 6: 29)
Take a look at the verse again. This believing is the work of God, which we receive as a gift of grace:
"8For by grace are ye saved through faith; and that not of yourselves: it is the gift of God: 9Not of works, lest any man should boast." (Ephesians 2: 8-9)
Because believe that we died with Christ, and that we live through Him, we live by the faith of the Son of God (Galatians 2: 20-21)
Looking at the original Hebrew of Isaiah 26: 3, I find that one can also read it as:
He keeps our minds in perfect peace, because we trust in Him.
Everything depends on believing on Him, that He makes us righteousness by grace through faith in His Son.