-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Headless scenario error: _tkinter.TclError: no display name and no $DISPLAY environment variable #5
Comments
Hello, try with this:
import matplotlib before the line:
Best, |
Thank you Ramón :) |
Hi Ramón, I made the suggested change to the /src/process_infrablue.py then rebuilt, re-installed, and ran a test with the fix. During the test, the following warning messages showed up but the code didn't crash :) Yay! Progress :) root@hgbnoircam:/home/hygrowbot/pics# infrapix_single -i latest.jpg --show_histogram -o latest_noir.jpg We're on the right track, however, the resulting image was nearly entirely black as you can see below: |
Hi Fabien, do you remember if you moved the camera while taking the picture? I have Best, Fabien Royer wrote:
|
Hi Ramón, The source images aren't the issue: . the IR camera itself is rigged at a fixed location and never moves It's only when processing the IR pictures through the infrapix code with the recommended changes import matplotlib that the color mapping stops working (see the Runtime warnings) I hope this clarifies things a bit. Thank you, Best regards, |
same issue here, running on odroid u3 (modified ubuntu) but not in a headless enviroment. |
Hi Bernhard, Unfortunately, this issue had to be put on the back burner and I did not investigate it any further, at least for the time being. Best regards, |
When using infrapix on a Raspberry Pi from the command line, the following error occurs. It would be great to be able to use infrapix in headless scenarios. Thanks and regards.
root@hgbnoircam:/home/hygrowbot/pics# infrapix_single -i 2014-01-02-17:28:16.337740.jpg --show_histogram -o ndvi.jpg
Rendering infrablue input image '2014-01-02-17:28:16.337740.jpg' to NDVI output image 'ndvi.jpg'
2014-01-02-17:28:16.337740.jpg ndvi.jpg
Converting to NDVI...
Traceback (most recent call last):
File "/usr/local/bin/infrapix_single", line 9, in
load_entry_point('infrapix==dev', 'console_scripts', 'infrapix_single')()
File "/usr/local/lib/python2.7/dist-packages/infrapix-dev-py2.7.egg/infrapix/commands/single.py", line 139, in main
app.render()
File "/usr/local/lib/python2.7/dist-packages/infrapix-dev-py2.7.egg/infrapix/commands/single.py", line 43, in render
self.render_single(**kwargs)
File "/usr/local/lib/python2.7/dist-packages/infrapix-dev-py2.7.egg/infrapix/commands/single.py", line 53, in render_single
ndvi(self.input_file,self.output_file,**self.ndvi_kwargs)
File "/usr/local/lib/python2.7/dist-packages/infrapix-dev-py2.7.egg/infrapix/process_infrablue.py", line 115, in ndvi
fig=plt.figure(figsize=(fig_w,fig_h),dpi=dpi)
File "/usr/lib/pymodules/python2.7/matplotlib/pyplot.py", line 343, in figure
**kwargs)
File "/usr/lib/pymodules/python2.7/matplotlib/backends/backend_tkagg.py", line 80, in new_figure_manager
window = Tk.Tk()
File "/usr/lib/python2.7/lib-tk/Tkinter.py", line 1712, in init
self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
_tkinter.TclError: no display name and no $DISPLAY environment variable
The text was updated successfully, but these errors were encountered: