Skip to content

Commit

Permalink
Add training folder to docstyle and linter checks
Browse files Browse the repository at this point in the history
  • Loading branch information
abs51295 committed Apr 7, 2019
1 parent 1c5ff13 commit 5fab1bd
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion check-docstyle.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env bash

directories="src tests"
directories="src tests training"
pass=0
fail=0

Expand Down
2 changes: 1 addition & 1 deletion run-linter.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

directories="src tests"
directories="src tests training"
pass=0
fail=0

Expand Down
6 changes: 3 additions & 3 deletions training/train.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ def run_recommender(train_df, latent_factor):


def validate_manifest_data(manifest_list):
"""Validates manifest packages with pypi."""
"""Validate manifest packages with pypi."""
for idx, manifest in enumerate(manifest_list):
filtered_manifest = bq_validator.validate_pypi(manifest)
# Even the filtered manifest is of length 0, we don't care about that here.
Expand Down Expand Up @@ -344,8 +344,8 @@ def train_model():
data = load_data(s3_obj)
hyper_params = load_hyper_params() or {}
lower_limit = int(hyper_params.get('lower_limit', 2))
upper_limit = int(hyper_params.get('upper_limit', 40))
latent_factor = int(hyper_params.get('latent_factor', 40))
upper_limit = int(hyper_params.get('upper_limit', 100))
latent_factor = int(hyper_params.get('latent_factor', 100))
_logger.info("Lower limit {}, Upper limit {} and latent factor {} are used."
.format(lower_limit, upper_limit, latent_factor))
package_id_dict, manifest_id_dict = preprocess_data(data, lower_limit, upper_limit)
Expand Down

0 comments on commit 5fab1bd

Please sign in to comment.