# Optimize() error: "Initial value and slope must be finite"

**URL:** https://discourse.julialang.org/t/optimize-error-initial-value-and-slope-must-be-finite/11320
**Category:** Optimization (Mathematical)
**Created:** [June 1, 2018, 3:08am UTC](https://discourse.julialang.org/t/optimize-error-initial-value-and-slope-must-be-finite/11320 "2018-06-01T03:08:59Z")
**Posts on this page:** 1
**Showing post:** 5

<div class="post-metadata">

### Author: ![stst](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stst/32/17252_2.png) [@stst](https://discourse.julialang.org/u/stst)
#### Post date: [June 1, 2018, 10:14pm UTC](https://discourse.julialang.org/t/optimize-error-initial-value-and-slope-must-be-finite/11320/5 "2018-06-01T22:14:42Z")

</div>

That worked - thanks for your help! `ConjugateGradient` is indeed significantly faster than `GradientDescent` (but still much slower than the NNLS solver I posted in [this topic](https://discourse.julialang.org/t/speedup-of-solver-bottleneck/11279)).

---

_[View the full topic](https://discourse.julialang.org/t/optimize-error-initial-value-and-slope-must-be-finite/11320)._
