Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Jaime Collado
/
textflow
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
1
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
aa03304c
authored
May 24, 2022
by
Estrella Vallecillo
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Some comments added
parent
bbc1cf52
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
17 additions
and
13 deletions
textflow/SequenceDirectory.py
textflow/SequenceFile.py
textflow/SequenceString.py
textflow/SequenceToken.py
textflow/SequenceDirectory.py
View file @
aa03304c
...
@@ -25,9 +25,10 @@ class SequenceDirectory(Sequence):
...
@@ -25,9 +25,10 @@ class SequenceDirectory(Sequence):
and for each file, create subsequence, splitting the text of the file into words.
and for each file, create subsequence, splitting the text of the file into words.
Args:
Args:
srcString: source string of the sequence
src: the path of the directory
labelSubSequence: the name of the children dictionary entry for the subsequence as string
listLabel: a list with different labels to create new levels in the children dictionary
formatSubSequence: the format of the subsequence in children dictionary entry as string
listClasses: a list with different classes that inicialize a sequence with sublevels
listTokenizer: a list with the tokenizer to inicialize the different subsequences
'''
'''
self
.
inicializeSequence
(
"directory"
)
self
.
inicializeSequence
(
"directory"
)
...
...
textflow/SequenceFile.py
View file @
aa03304c
...
@@ -22,9 +22,10 @@ class SequenceFile (Sequence):
...
@@ -22,9 +22,10 @@ class SequenceFile (Sequence):
By default, create subsequences splitting the text of the file into words.
By default, create subsequences splitting the text of the file into words.
Args:
Args:
srcString: source string of the sequence
src: the path of the file
labelSubSequence: the name of the children dictionary entry for the subsequence as string
listLabel: a list with different labels to create new levels in the children dictionary
formatSubSequence: the format of the subsequence in children dictionary entry as string
listClasses: a list with different classes that inicialize a sequence with sublevels
listTokenizer: a list with the tokenizer to inicialize the different subsequences
'''
'''
self
.
inicializeSequence
(
"file"
)
self
.
inicializeSequence
(
"file"
)
...
...
textflow/SequenceString.py
View file @
aa03304c
...
@@ -21,12 +21,13 @@ class SequenceString (Sequence):
...
@@ -21,12 +21,13 @@ class SequenceString (Sequence):
Initialize a Sequence from a string.
Initialize a Sequence from a string.
Args:
Args:
srcString: source string of the sequence
src: source string of the sequencesrc: the path of the directory
labelSubSequence: the name of the children dictionary entry for the subsequence as string
listLabel: a list with different labels to create new levels in the children dictionary
formatSubSequence: the format of the subsequence in children dictionary entry as string
listClasses: a list with different classes that inicialize a sequence with sublevels
listTokenizer: a list with the tokenizer to inicialize the different subsequences
Raises:
Raises:
ValueError: If src
String
isn't a string .
ValueError: If src isn't a string .
'''
'''
self
.
inicializeSequence
(
"string"
)
self
.
inicializeSequence
(
"string"
)
if
not
isinstance
(
src
,
str
):
if
not
isinstance
(
src
,
str
):
...
...
textflow/SequenceToken.py
View file @
aa03304c
...
@@ -20,9 +20,10 @@ class SequenceToken (Sequence):
...
@@ -20,9 +20,10 @@ class SequenceToken (Sequence):
Initialize a Sequence from a token
Initialize a Sequence from a token
Args:
Args:
srcString: source string of the sequence
src: source string of the sequence
labelSubSequence: the name of the children dictionary entry for the subsequence as string
listLabel: a list with different labels to create new levels in the children dictionary
formatSubSequence: the format of the subsequence in children dictionary entry as string
listClasses: a list with different classes that inicialize a sequence with sublevels
listTokenizer: a list with the tokenizer to inicialize the different subsequences
'''
'''
self
.
inicializeSequence
(
"token"
)
self
.
inicializeSequence
(
"token"
)
...
...
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