You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I have been using pyxspec for a while and I have been trying to run the example threads here too, however, whenever I try to plot outside of the the Matplotlib option I never get an output (see image attached). This is the case when running the PyXspecWalkthrough1.ipynb as well. Is there something I am missing?
The text was updated successfully, but these errors were encountered:
This is a known problem with the svg plotting driver in Heasoft-6.34 (and earlier) when used with recent versions of Jupyter Notebook. We've made a fix that will be in the next release of Heasoft. But in the meantime if you have the Heasoft-6.34 source code distribution and would like to make a patch fix yourself in your local build, please follow these instructions:
Copy and paste the following into a file named "sgdriv.patch"
@@ -523,7 +523,7 @@
/* ... or writing to stdout, so just save the viewbox here because that's
all we can do. */
- fprintf(cdev->fp,"<!-- _PGPLOT_SVG_ATEND: viewbox=\"%20f %20f %20f %20f\" -->\n",
+ fprintf(cdev->fp,"<!-- _PGPLOT_SVG_ATEND: viewBox=\"%20f %20f %20f %20f\" -->\n",
cdev->bbox[0], cdev->bbox[1],
cdev->bbox[2]-cdev->bbox[0],
cdev->bbox[3]-cdev->bbox[1]);
@@ -1804,7 +1804,7 @@
store the location of the viewbox string position for later, so we can
fill in bounding box information upon close. */
if (!cdev->sgstdout) {
- fprintf(cdev->fp, "viewbox=\"");
+ fprintf(cdev->fp, "viewBox=\"");
cdev->viewbox_pos = ftell(cdev->fp);
fprintf(cdev->fp,"%20s %20s %20s %20s\" \n",
"","","","");
Copy your sgdriv.patch file into the directory heasoft-6.34/tcltk/pgplot/drivers
From that same directory, do:
patch sgdriv.c sgdriv.patch
(This final step assumes you have already run your $HEADAS/headas-init.(c)sh script.
Otherwise you'll get an "hmake: Command not found." error.)
'cd' up 1 level into the directory heasoft-6.34/tcltk/pgplot and run the following 2 commands:
Hello, I have been using pyxspec for a while and I have been trying to run the example threads here too, however, whenever I try to plot outside of the the Matplotlib option I never get an output (see image attached). This is the case when running the PyXspecWalkthrough1.ipynb as well. Is there something I am missing?
The text was updated successfully, but these errors were encountered: