diff options
Diffstat (limited to 'TestContribution/exampleCount.py')
-rwxr-xr-x | TestContribution/exampleCount.py | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/TestContribution/exampleCount.py b/TestContribution/exampleCount.py deleted file mode 100755 index f9c17511..00000000 --- a/TestContribution/exampleCount.py +++ /dev/null @@ -1,27 +0,0 @@ -import json -import os -import re - -class info: - notebook = '' - examples = [] -notebooks = os.listdir('.') -notebooks = sorted(notebooks) -print notebooks - -total = 0 - -for i in range(len(notebooks)): - ch_examples = 0 - if notebooks[i].endswith(".ipynb"): - f = open(notebooks[i],'r') - data = json.load(f) - for dic in data["worksheets"][0]["cells"][0:]: - if "level" in dic and dic["level"] == 2: - ch_examples += 1 - total += ch_examples - print i, " : " , ch_examples - - - -print "Total Examples : " , total |