Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nltk
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
nltk
Commits
6440703b
Commit
6440703b
authored
Jun 13, 2007
by
Ewan Klein
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Easier display of grammars within the featgram chapter
svn/trunk@4668
parent
3efce839
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
1 deletions
+9
-1
nltk/parse/filebroker.py
+9
-1
No files found.
nltk/parse/filebroker.py
View file @
6440703b
...
@@ -194,6 +194,13 @@ def load(filename, verbose=False):
...
@@ -194,6 +194,13 @@ def load(filename, verbose=False):
"""
"""
b
=
Broker
()
b
=
Broker
()
return
b
.
open
(
filename
,
verbose
=
verbose
)
return
b
.
open
(
filename
,
verbose
=
verbose
)
def
pprint
(
filename
):
for
l
in
load
(
filename
):
if
l
.
startswith
(
'#'
):
continue
if
re
.
match
(
'^$'
,
l
):
continue
print
l
,
def
demo
():
def
demo
():
...
@@ -232,4 +239,5 @@ def demo():
...
@@ -232,4 +239,5 @@ def demo():
if
__name__
==
'__main__'
:
if
__name__
==
'__main__'
:
demo
()
#demo()
pprint
(
'feat0.cfg'
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment