Skip to content
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

rgt-hint differential "GPL Ghostscript 8.70: Can't find initialization file gs_init.ps." #61

Closed
mdurante1 opened this issue Jan 4, 2018 · 9 comments
Assignees
Labels
Projects

Comments

@mdurante1
Copy link

Hi,

After running rgt-hint differential I noticed that no output was produced even though the job looks as if it had completed successfully. When looking at the error output file I see the following error:

GPL Ghostscript 8.70: Can't find initialization file gs_init.ps.
GPL Ghostscript 8.70: Can't find initialization file gs_init.ps.
GPL Ghostscript 8.70: Can't find initialization file gs_init.ps.
GPL Ghostscript 8.70: Can't find initialization file gs_init.ps.

The error file contained multiple lines with this error. Any suggestions on how to resolve this?

Thanks,
Michael

@lzj1769
Copy link
Member

lzj1769 commented Jan 4, 2018

Hi @mdurante1 ,

It seems that rgt-hint cannot find Ghostscript.

In rgt-hint differential, we use command 'epstopdf' to convert the plots from .eps to .pdf,
can you check if you can run this command successfully on you machine?

Thanks,

@mdurante1
Copy link
Author

Yes, this command works

(atac_danpos) [mdurante@pegasus hint]$ epstopdf
EPSTOPDF 2.9.5gw, 2006/01/29 - Copyright 1998-2006 by Sebastian Rahtz et al.
Syntax:  epstopdf [options] <eps file>
Options:
  --help:           print usage
  --outfile=<file>: write result to <file>
  --(no)filter:     read standard input   (default: false)
  --(no)gs:         run ghostscript       (default: true)
  --(no)compress:   use compression       (default: true)
  --(no)hires:      scan HiResBoundingBox (default: false)
  --(no)exact:      scan ExactBoundingBox (default: false)
  --(no)debug:      debug informations    (default: false)
Examples for producing 'test.pdf':
  * epstopdf test.eps
  * produce postscript | epstopdf --filter >test.pdf
  * produce postscript | epstopdf -f -d -o=test.pdf
Example: look for HiResBoundingBox and produce corrected PostScript:
  * epstopdf -d --nogs -hires test.ps>testcorr.ps

!!! Error: Input filename missing!

@lzj1769
Copy link
Member

lzj1769 commented Jan 4, 2018

Hi, @mdurante1

well, to make sure it works correctly, can you download the below example file and try to convert it to pdf using command:
epstopdf example.eps

https://www.dropbox.com/s/f6wul0ibbofiyiu/example.eps?dl

Thanks,

@mdurante1
Copy link
Author

Yes, it's working correctly:

example.pdf

@lzj1769
Copy link
Member

lzj1769 commented Jan 4, 2018

ok, thanks.

It would better if you can provide more information about your:

  1. opertion system (Ubuntu? Centos? or MacOS)
  2. python version
  3. rgt version

In addtion, please check if the file gs_init.ps exists on you machine using command:
locate gs_init.ps

I find some people also reported this problem:
https://bugs.launchpad.net/ubuntu/+source/ghostscript/+bug/262000
https://bbs.archlinux.org/viewtopic.php?id=1331

@mdurante1
Copy link
Author

(atac_danpos) [mdurante@pegasus ~]$ rgt-motifanalysis --version
Motif Analysis - Regulatory Analysis Toolbox (RGT) - v0.11.1
(atac_danpos) [mdurante@pegasus ~]$ python --version
Python 2.7.14
(atac_danpos) [mdurante@pegasus ~]$ cat /etc/centos-release
CentOS release 6.5 (Final)
(atac_danpos) [mdurante@pegasus ~]$ locate gs_init.ps
/usr/share/ghostscript/8.70/Resource/Init/gs_init.ps

I am also seeing this same issue separately on Ubuntu 16.04 with the same version of python and rgt

@lzj1769
Copy link
Member

lzj1769 commented Jan 4, 2018

thanks for the information.

can you run our tutorial:
http://www.regulatory-genomics.org/hint/tutorial/
and see if it works?

Maybe setting environment variable GS_LIB will fix it:
GS_LIB=/usr/share/ghostscript/8.70/lib:/usr/share/ghostscript/8.70/Resource/Init/

Meanwhile, I will try to reproduce the error.

@lzj1769 lzj1769 self-assigned this Jan 4, 2018
@lzj1769 lzj1769 added the bug label Jan 4, 2018
@lzj1769 lzj1769 added this to TODO in HINT via automation Jan 5, 2018
@lzj1769
Copy link
Member

lzj1769 commented Jan 5, 2018

I can't reproduce the error on Ubtuntu 16.04 and CentOS Linux release 7.3.1611, so far.

Hi, @mdurante1
Can you download the below file and run test script on you machine.
test.tar.gz

it will create a .pdf and .eps file by merging the line plot and weblogo file, if everything is working.

Thanks,

@mdurante1
Copy link
Author

Hi @lzj1769
I was able to fix this error by setting the environment variable GS_LIB.
Thanks for all of your help.

Best,
Michael

HINT automation moved this from TODO to Done Jan 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
HINT
  
Done
Development

No branches or pull requests

2 participants