GoogleCloudPlatform / GoogleCloudPlatform/training-data-analyst

`3_keras_basic_feat_eng.ipynb`, `get_scal` does nothing

Open
#1,995 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Jupyter Notebook
Stars
8.6k
Forks
6.1k
Avg merge
4h 44m
Merged PRs (30d)
2

Description

Wrong indentation on last line of `get_scal` definition means that function returns `None` instead of
returning the `minmax` closure.

Correct code would be:

```
def get_scal(feature):
def minmax(x):
mini = train[feature].min()
maxi = train[feature].max()
return (x - mini)/(maxi-mini)
return(minmax)
```

https://github.com/GoogleCloudPlatform/training-data-analyst/blob/ec4838a9f532185dcf98a82530b443252d8ae830/courses/machine_learning/deepdive2/feature_engineering/solutions/3_keras_basic_feat_eng.ipynb?short_path=7965270#L883

And

https://github.com/GoogleCloudPlatform/training-data-analyst/blob/ec4838a9f532185dcf98a82530b443252d8ae830/courses/machine_learning/deepdive2/feature_engineering/solutions/3_keras_basic_feat_eng.ipynb?short_path=7965270#L1629

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.