Skip to content

Commit

Permalink
Merge pull request #74 from stephenhky/aws_s3
Browse files Browse the repository at this point in the history
Using AWS S3 buckets instead of GCP buckets for datasets
  • Loading branch information
stephenhky authored Sep 24, 2019
2 parents 030f154 + 2b57eaf commit 14bde0c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions shorttext/data/data_retrieval.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ def inaugural():
:rtype: dict
"""
zfile = zipfile.ZipFile(get_or_download_data("USInaugural.zip",
"http://storage.googleapis.com/pyshorttext/USPresidentInaugural/USInaugural.zip",
"https://shorttext-data-northernvirginia.s3.amazonaws.com/trainingdata/USInaugural.zip",
asbytes=True),
)
address_jsonstr = zfile.open("addresses.json").read()
Expand Down Expand Up @@ -144,7 +144,7 @@ def nihreports(txt_col='PROJECT_TITLE', label_col='FUNDING_ICs', sample_size=512
raise KeyError('Undefined label column: '+label_col+'. Must be FUNDING_ICs or IC_NAME.')

zfile = zipfile.ZipFile(get_or_download_data('nih_full.csv.zip',
'http://storage.googleapis.com/pyshorttext/nih_grant_public/nih_full.csv.zip',
'https://shorttext-data-northernvirginia.s3.amazonaws.com/trainingdata/nih_full.csv.zip',
asbytes=True),
'r',
zipfile.ZIP_DEFLATED)
Expand Down
2 changes: 1 addition & 1 deletion test/test_var_nn_embedded_vec_classifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
class TestVarNNEmbeddedVecClassifier(unittest.TestCase):
def setUp(self):
print("Downloading word-embedding model....")
link = "http://storage.googleapis.com/pyshorttext/test_w2vmodel/test_w2v_model.bin"
link = "https://shorttext-data-northernvirginia.s3.amazonaws.com/trainingdata/test_w2v_model.bin"
filename = "test_w2v_model.bin"
if not os.path.isfile("test_w2v_model.bin"):
if sys.version_info[0]==2:
Expand Down

0 comments on commit 14bde0c

Please sign in to comment.