Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
PrecomputeCommentEmbeddings
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jan Lukas Steimann
PrecomputeCommentEmbeddings
Commits
633bc756
Commit
633bc756
authored
3 years ago
by
Jan Lukas Steimann
Browse files
Options
Downloads
Patches
Plain Diff
Add S3 config and use real csv file
parent
c4166b64
Branches
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#64544
failed
3 years ago
Stage: test
Changes
2
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
.gitlab-ci.yml
+7
-0
7 additions, 0 deletions
.gitlab-ci.yml
ComputeCommentEmbeddings.py
+1
-1
1 addition, 1 deletion
ComputeCommentEmbeddings.py
with
8 additions
and
1 deletion
.gitlab-ci.yml
+
7
−
0
View file @
633bc756
image
:
"
python:3.7"
image
:
"
python:3.7"
before_script
:
-
wget https://dl.min.io/client/mc/release/linux-amd64/mc
-
chmod +x mc
-
mc alias set S3Uni $MINIO_HOST $MINIO_ACCESS_KEY $MINIO_SECRET_KEY
python_run
:
python_run
:
script
:
script
:
-
pip install flair
-
pip install flair
-
pip install torch
-
pip install torch
-
pip install pandas
-
pip install pandas
-
mc cp S3Uni/steimann/CommentsApril2017.csv .
-
python3 ComputeCommentEmbeddings.py
-
python3 ComputeCommentEmbeddings.py
-
mc cp embedded_comments.pt S3Uni/steimann/
tags
:
tags
:
-
"
ht"
-
"
ht"
\ No newline at end of file
This diff is collapsed.
Click to expand it.
ComputeCommentEmbeddings.py
+
1
−
1
View file @
633bc756
...
@@ -18,6 +18,6 @@ def compute_embedding(comments: dict) -> dict:
...
@@ -18,6 +18,6 @@ def compute_embedding(comments: dict) -> dict:
if
__name__
==
'
__main__
'
:
if
__name__
==
'
__main__
'
:
comments
=
get_argument_list
(
path
=
""
,
filename
=
"
CommentsApril2017
_DEV
.csv
"
)
comments
=
get_argument_list
(
path
=
""
,
filename
=
"
CommentsApril2017.csv
"
)
comments
=
compute_embedding
(
comments
)
comments
=
compute_embedding
(
comments
)
torch
.
save
(
comments
,
"
embedded_comments.pt
"
)
torch
.
save
(
comments
,
"
embedded_comments.pt
"
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment