Skip to content

Instantly share code, notes, and snippets.

@riga
Last active August 6, 2020 13:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save riga/522d2d08dab617a46444213fe202d919 to your computer and use it in GitHub Desktop.
Save riga/522d2d08dab617a46444213fe202d919 to your computer and use it in GitHub Desktop.
Example gist to showcase the cms_gist_runner.
# coding: utf-8
"""
Example gist to be used with the cms_gist_runner. Execute via
> ~mrieger/public/bin/cms_gist_runner 522d2d08dab617a46444213fe202d919 -v CMSSW_11_1_2 -t
"""
import tensorflow as tf
@tf.function
def times_two(x):
return x * 2.
print(times_two(tf.constant([2., 4.])))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment