Skip to content

Commit

Permalink
Revert "[Security] fix draw security problem (PaddlePaddle#61161) (Pa…
Browse files Browse the repository at this point in the history
…ddlePaddle#61338)"

This reverts commit aeaa0ca.
  • Loading branch information
hanhaowen-mt committed May 13, 2024
1 parent 912410e commit 5fe9414
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion python/paddle/base/framework.py
Original file line number Diff line number Diff line change
Expand Up @@ -5568,7 +5568,8 @@ def draw(self, save_path, name, marked_nodes=None, remove_ctr_var=True):
def _convert_to_pdf(dot_file_path):
pdf_save_path = os.path.splitext(dot_file_path)[0] + '.pdf'
exited_code = subprocess.call(
['dot', '-Tpdf', dot_file_path, '-o', pdf_save_path]
'dot -Tpdf ' + dot_file_path + ' -o ' + pdf_save_path,
shell=True,
)
if exited_code != 0:
print('The dot command is needed for creating pdf files.')
Expand Down

0 comments on commit 5fe9414

Please sign in to comment.