yep, it is not possible actually to switch off the Ray using no-gui mode in
pymol ( i've just read another topic on this case). BTW I found that the
problem of the disappearing of carton is mor related to the transparency,
since it had already been set for the surface as well. In the case when I
set it both for cartoon and surface, the cartoon diagram is lost :-)
here is my script:
cmd.set('transparency_mode','1')
cmd.set('transparency', '0.7', '${output}* and polymer')
cmd.set('cartoon_transparency', '0.3', '${output}* and polymer')

пт, 21 янв. 2022 г. в 05:40, Saurabh Gayali <saurabh.gay...@gmail.com>:

> Have you tried setting ray_trace_mode?
> Info here: https://pymolwiki.org/index.php/Ray
>
> ------------------------------
>
> *Saurabh Gayali* / Post Doctoral Fellow
> saurabh.gay...@gmail.com / +91 8800412916
>
> *CSIR-IGIB*
> <http://example.com/>New Delhi, India
>
>
> [image: Mailtrack]
> <https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&;>
>  Sender
> notified by
> Mailtrack
> <https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11&;>
>  21/01/22,
> 10:10:28 am
>
> On Thu, Jan 20, 2022 at 11:02 PM Enrico Martinez <jmsstarli...@gmail.com>
> wrote:
>
>> Dear Pymol Users!
>> I've faced the problem of saving a PNG image without ray using the png
>> command in non-gui mode. First if I do it in pymol gui
>> #cmd.png('test.png',width=800,height=800,ray=0)
>> .. it produces fine image (without ray)
>>
>> However if I execute the same command inside of my bash sript:
>>
>> $pymol -c -d "
>> from pymol import cmd
>> from pymol import preset
>> cmd.load('my_pdb.pdb')
>> cmd.show('surface', 'my_pdb and polymer')
>> cmd.set('surface_color', 'default', 'my_pdb and polymer')
>> cmd.set('transparency', '0.8', 'my_pdb and polymer')
>> cmd.save('${vizu}/${output}_${lig_name}_rep${i}.pse')
>>
>> cmd.png('${vizu}/${output}_${lig_name}_interact_rep${i}.png',width=${image},height=${image},ray=0)
>> "
>>
>> Eventually It produces the correct pymol session but on the PNG image
>> I do not see any cartoon representation (only transparent surface) of
>> my protein. I did some tests and found that using non-gui mode (like
>> in the script shown above) pymol always sets the ray flag to ray=1
>> even if it is disabled in my script. Is there any way to disable ray
>> (ray=0) in my script besides setting it in the cmd.png?
>> Many thanks in advance!
>> Enrico
>>
>>
>> _______________________________________________
>> PyMOL-users mailing list
>> Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net
>> Unsubscribe:
>> https://sourceforge.net/projects/pymol/lists/pymol-users/unsubscribe
>>
>
_______________________________________________
PyMOL-users mailing list
Archives: http://www.mail-archive.com/pymol-users@lists.sourceforge.net
Unsubscribe: 
https://sourceforge.net/projects/pymol/lists/pymol-users/unsubscribe

Reply via email to