I was trying to understand how BasicTemplateFuturesHistoryAlgorithm.py works - when I use it, it breaks when I try to request more than 12*60 + 30 minutes (it works when I request 12 hours and 30 minutes and breaks when I request 12 hours and 35 minutes). I get the following error Fatal Python error: deallocating None
The only changes I've made was increasing the window size from 10 minutes to 12.5 hours.
Lean comes with a week of data (2013,10,7) - (2013,10,11), so if I request a historical data on October, 10th I should get at least 2-3 days of historical data.
Same BasicTemplateFuturesHistoryAlgorithm.cs works ok in CSharp.
I wonder if I'm using futures history wrongly or there is some problem in QC python implementation.
Help is much appreciated as I'm a little stuck here.
Jared Broad
Hey Dmitry it sounds like an out of ram error. Deallocation is releasing a variable normally during a garbage collection. If there was an error in GC its likely just a symptom of "out of ram" in general. If you can share an example with support or here we can help further.
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
Dmitry Kovalevskiy
Hey Jared, thank you for the prompt answer.
I've attached the example algorithm - which is the exact copy of BasicTemplateFuturesHistoryAlgorithm.py except that I request 755 bars of minute history, not 10 bars as in the example.
This code works perfectly fine in quantconnect online, but fails when I try to run it locally in Lean. Lean comes with a week of futures minute bars, so it should be able to give me 755 minute bars and more. I'm running Lean on Windows 10 with VS15 and Anaconda Python 3.6.5,
I also tried the same algo in C# and it works OK when I request 755 minute bars or more history.
Dmitry Kovalevskiy
the BasicTemplateFuturesHistoryAlgorithm
Jared Broad
If running in LEAN it'll likely be an issue with your local data provider // IB History Provider etc? You'll need to look into the limitations of whatever provider you are using.
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
Dmitry Kovalevskiy
Jared, I've been using the sample data which comes with Lean on Github, so it shouldn't be the issue with my data provider. Lean comes with a week of futures minute bars, so I should be able to request two days of history.
Alexandre Catarino
Hi Dmitry Kovalevskiy, I couldn't reproduce the issue locally with your algorithm locally.
Could you please verify this is still an issue?
Dmitry Kovalevskiy
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
To unlock posting to the community forums please complete at least 30% of Boot Camp.
You can continue your Boot Camp training progress from the terminal. We hope to see you in the community soon!