Skip to content

Commit f8207a9

Browse files
committed
Code review 1
1 parent f338032 commit f8207a9

File tree

3 files changed

+6
-8
lines changed

3 files changed

+6
-8
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ dist
77
*.swp
88
.idea
99
*.egg-info
10-
.venv
10+
.venv
Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,18 @@
1-
#!/usr/bin/env python
2-
# Run with : ./profile.sh <obj file>
31
import cProfile
42
import pstats
53
import sys
4+
65
try:
76
from StringIO import StringIO
87
except:
98
from io import StringIO
109

11-
print(len(sys.argv), sys.argv)
1210

1311
if len(sys.argv) < 2:
14-
print("Usage: ./profile.sh <obj file>")
12+
print("Usage: profiler.py <obj file>")
1513
exit(1)
1614

15+
# Run the profiler
1716
pr = cProfile.Profile()
1817
pr.enable()
1918
import pywavefront
@@ -26,4 +25,3 @@
2625
ps = pstats.Stats(pr, stream=s).sort_stats(sortby)
2726
ps.print_stats()
2827
print(s.getvalue())
29-

pywavefront/material.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ def __init__(self, name=None, is_default=False):
4242
"""
4343
Create a new material
4444
:param name: Name of the material
45-
:param is_default: It this an auto created default material?
45+
:param is_default: Is this an auto created default material?
4646
"""
4747
self.name = name
4848
self.diffuse = [.8, .8, .8, 1.]
@@ -150,7 +150,7 @@ def parse_map_Kd(self):
150150
def parse_Ni(self):
151151
# unimplemented
152152
pass
153-
153+
154154
@auto_consume
155155
def parse_Tr(self):
156156
# unimplemented

0 commit comments

Comments
 (0)