Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
ML
lib
Binary Storage
Commits
ea90038e
Commit
ea90038e
authored
Apr 07, 2020
by
Sasha Z
Browse files
Refactoring for packaging
parent
77a45bf7
Changes
3
Hide whitespace changes
Inline
Side-by-side
py/
test_read
.py
→
py/
read_binary
.py
100755 → 100644
View file @
ea90038e
...
...
@@ -5,7 +5,7 @@ Created on Mon Jan 27 16:11:06 2020
@author: az9
"""
from
read_storage
import
Binary
Storage
from
sns_rad.binary
import
Read
Storage
import
argparse
from
argparse
import
RawTextHelpFormatter
...
...
@@ -23,7 +23,7 @@ parser.add_argument('--index', '-i', action='append', default=[], type=int,
parser
.
add_argument
(
'file'
,
help
=
'file to read'
)
args
=
parser
.
parse_args
()
file
=
Binary
Storage
(
args
.
file
)
file
=
Read
Storage
(
args
.
file
)
print
(
args
.
file
,
'has'
,
len
(
file
),
'records'
)
...
...
py/sns_rad/__init__.py
0 → 100644
View file @
ea90038e
py/
read_storage
.py
→
py/
sns_rad/binary
.py
View file @
ea90038e
...
...
@@ -53,7 +53,7 @@ class Writer:
self
.
file
.
close
()
class
Binary
Storage
:
class
Read
Storage
:
def
__init__
(
self
,
path
):
self
.
file
=
open
(
path
,
'rb'
)
...
...
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