| CONSOLIDATED STATEMENTS OF STOCKHOLDERS' EQUITY - USD ($) | Total | Warrants Exercise One [Member] | Warrants Exercise Two [Member] | Common Stock Issuance One [Member] | Common Stock Issuance Two [Member] | Common Stock [Member] | Common Stock [Member]  Warrants Exercise One [Member] | Common Stock [Member]  Warrants Exercise Two [Member] | Common Stock [Member]  Common Stock Issuance One [Member] | Common Stock [Member]  Common Stock Issuance Two [Member] | Additional Paid-in Capital [Member] | Additional Paid-in Capital [Member]  Warrants Exercise One [Member] | Additional Paid-in Capital [Member]  Warrants Exercise Two [Member] | Additional Paid-in Capital [Member]  Common Stock Issuance One [Member] | Additional Paid-in Capital [Member]  Common Stock Issuance Two [Member] | Accumulated deficit [Member] | Accumulated deficit [Member]  Warrants Exercise One [Member] | Accumulated deficit [Member]  Warrants Exercise Two [Member] | Accumulated deficit [Member]  Common Stock Issuance One [Member] | Accumulated deficit [Member]  Common Stock Issuance Two [Member] | 
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Balance at Dec. 31, 2015 | $ 67,721,000 | $ 328,000 | $ 377,993,000 | $ (310,600,000) | ||||||||||||||||
| Balance (in shares) at Dec. 31, 2015 | 32,743,013 | |||||||||||||||||||
| Stock-based compensation expense | 4,829,000 | $ 0 | 4,829,000 | 0 | ||||||||||||||||
| Restricted stock-based compensation expense | 3,432,000 | $ 1,000 | 3,431,000 | 0 | ||||||||||||||||
| Restricted stock-based compensation expense (in shares) | 100,000 | |||||||||||||||||||
| Restricted common stock issued | 150,000 | $ 0 | 150,000 | 0 | ||||||||||||||||
| Restricted common stock issued (in shares) | 52,690 | |||||||||||||||||||
| Exercise of $5.00 warrants | 0 | $ 0 | 0 | 0 | ||||||||||||||||
| Exercise of $5.00 warrants (in shares) | 5,836 | |||||||||||||||||||
| Common stock issued for services | 2,452,000 | $ 8,000 | 2,444,000 | 0 | ||||||||||||||||
| Common stock issued for services (in shares) | 750,000 | |||||||||||||||||||
| Common stock issued for an average, net of costs | $ 969,000 | $ 2,000 | $ 6,293,889 | $ 967,000 | $ 0 | |||||||||||||||
| Common stock issued for an average, net of costs (in shares) | 41,068,000 | 158,029 | 63,000 | 41,005,000 | 0 | |||||||||||||||
| Common stock issued for cash exercise of options | 350,000 | $ 1,000 | 349,000 | 0 | ||||||||||||||||
| Common stock issued for cash exercise of options (in shares) | 151,000 | |||||||||||||||||||
| Net loss | (21,873,000) | $ 0 | 0 | (21,873,000) | ||||||||||||||||
| Balance (in shares) at Dec. 31, 2016 | 40,254,457 | |||||||||||||||||||
| Balance at Dec. 31, 2016 | 99,098,000 | $ 403,000 | 431,168,000 | (332,473,000) | ||||||||||||||||
| Stock-based compensation expense | 4,644,000 | 0 | 4,644,000 | 0 | ||||||||||||||||
| Restricted stock-based compensation expense | 1,272,000 | $ 0 | 1,272,000 | 0 | ||||||||||||||||
| Restricted stock-based compensation expense (in shares) | 0 | |||||||||||||||||||
| Exercise of $8.00 warrants | $ 5,000,000 | $ 6,000 | $ 4,994,000 | $ 0 | ||||||||||||||||
| Exercise of $8.00 warrants (in shares) | 625,000 | |||||||||||||||||||
| Exercise of $5.00 warrants | $ 885,000 | $ 2,000 | $ 883,000 | $ 0 | ||||||||||||||||
| Exercise of $5.00 warrants (in shares) | 176,932 | |||||||||||||||||||
| Common stock issued for an average, net of costs | $ 86,174,000 | $ 58,000 | $ 86,116,000 | $ 0 | ||||||||||||||||
| Common stock issued for an average, net of costs (in shares) | 5,750,000 | |||||||||||||||||||
| Common stock issued for cash exercise of options | 344,000 | $ 0 | 344,000 | 0 | ||||||||||||||||
| Common stock issued for cash exercise of options (in shares) | 81,719 | |||||||||||||||||||
| Net loss | (27,319,000) | $ 0 | 0 | (27,319,000) | ||||||||||||||||
| Balance (in shares) at Dec. 31, 2017 | 46,888,108 | |||||||||||||||||||
| Balance at Dec. 31, 2017 | 170,098,000 | $ 469,000 | 529,421,000 | (359,792,000) | ||||||||||||||||
| Cumulative effect adjustment of ASC 606 on January 1, 2018 | 6,275,000 | 0 | 0 | 6,275,000 | ||||||||||||||||
| Stock-based compensation expense | 8,178,000 | 0 | 8,178,000 | 0 | ||||||||||||||||
| Restricted stock-based compensation expense | 688,000 | $ 0 | 688,000 | 0 | ||||||||||||||||
| Restricted stock-based compensation expense (in shares) | 0 | |||||||||||||||||||
| Exercise of $5.00 warrants | 3,233,000 | $ 6,000 | 3,227,000 | 0 | ||||||||||||||||
| Exercise of $5.00 warrants (in shares) | 646,763 | |||||||||||||||||||
| Common stock issued for cash exercise of options | 2,244,000 | $ 4,000 | 2,240,000 | 0 | ||||||||||||||||
| Common stock issued for cash exercise of options (in shares) | 360,853 | |||||||||||||||||||
| cashless warrant exercises (in shares) | 48,762 | |||||||||||||||||||
| Net loss | (56,671,000) | $ 0 | 0 | (56,671,000) | ||||||||||||||||
| cashless warrant exercises | 0 | $ 0 | 0 | 0 | ||||||||||||||||
| Balance (in shares) at Dec. 31, 2018 | 47,944,486 | |||||||||||||||||||
| Balance at Dec. 31, 2018 | $ 134,045,000 | $ 479,000 | $ 543,754,000 | $ (410,188,000) |