Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mhc_rank
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Patrick Skillman-Lawrence
mhc_rank
Commits
bbfd350d
Commit
bbfd350d
authored
7 years ago
by
Tim O'Donnell
Browse files
Options
Downloads
Patches
Plain Diff
support for inequalities in train command
parent
1a905bc8
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
downloads-generation/models_class1_no_mass_spec/GENERATE.sh
+3
-1
3 additions, 1 deletion
downloads-generation/models_class1_no_mass_spec/GENERATE.sh
mhcflurry/train_allele_specific_models_command.py
+12
-0
12 additions, 0 deletions
mhcflurry/train_allele_specific_models_command.py
with
15 additions
and
1 deletion
downloads-generation/models_class1_no_mass_spec/GENERATE.sh
+
3
−
1
View file @
bbfd350d
...
...
@@ -36,7 +36,9 @@ time mhcflurry-class1-train-allele-specific-models \
--hyperparameters
hyperparameters.yaml
\
--out-models-dir
models
\
--percent-rank-calibration-num-peptides-per-length
1000000
\
--min-measurements-per-allele
75
--min-measurements-per-allele
75
\
--ignore-inequalities
cp
$SCRIPT_ABSOLUTE_PATH
.
bzip2 LOG.txt
...
...
This diff is collapsed.
Click to expand it.
mhcflurry/train_allele_specific_models_command.py
+
12
−
0
View file @
bbfd350d
...
...
@@ -52,6 +52,11 @@ parser.add_argument(
action
=
"
store_true
"
,
default
=
False
,
help
=
"
Use only quantitative training data
"
)
parser
.
add_argument
(
"
--ignore-inequalities
"
,
action
=
"
store_true
"
,
default
=
False
,
help
=
"
Do not use affinity value inequalities even when present in data
"
)
parser
.
add_argument
(
"
--percent-rank-calibration-num-peptides-per-length
"
,
type
=
int
,
...
...
@@ -115,6 +120,10 @@ def run(argv=sys.argv[1:]):
]
print
(
"
Subselected to quantitative: %s
"
%
(
str
(
df
.
shape
)))
if
args
.
ignore_inequalities
and
"
measurement_inequality
"
in
df
.
columns
:
print
(
"
Dropping measurement_inequality column
"
)
del
df
[
"
measurement_inequality
"
]
allele_counts
=
df
.
allele
.
value_counts
()
if
args
.
allele
:
...
...
@@ -263,6 +272,9 @@ def process_work(
allele
=
allele
,
peptides
=
train_data
.
peptide
.
values
,
affinities
=
train_data
.
measurement_value
.
values
,
inequalities
=
(
train_data
.
measurement_inequality
.
values
if
"
measurement_inequality
"
in
train_data
.
columns
else
None
),
models_dir_for_save
=
save_to
,
progress_preamble
=
progress_preamble
,
verbose
=
verbose
)
...
...
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