diff options
author | Matei Zaharia <matei@eecs.berkeley.edu> | 2013-07-31 23:12:30 -0700 |
---|---|---|
committer | Matei Zaharia <matei@eecs.berkeley.edu> | 2013-07-31 23:12:30 -0700 |
commit | 5ac548397de9a71a308ec20dfdd6c449bd033f42 (patch) | |
tree | 8f33494e4d75cac2ec32613a0c571158591d8327 /python/examples | |
parent | 01f94931d5fe3121bb6413e6efba3473df975136 (diff) | |
download | spark-5ac548397de9a71a308ec20dfdd6c449bd033f42.tar.gz spark-5ac548397de9a71a308ec20dfdd6c449bd033f42.tar.bz2 spark-5ac548397de9a71a308ec20dfdd6c449bd033f42.zip |
Fix string parsing and style in LR
Diffstat (limited to 'python/examples')
-rwxr-xr-x | python/examples/logistic_regression.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/python/examples/logistic_regression.py b/python/examples/logistic_regression.py index 1e1b6d6e5b..1117dea538 100755 --- a/python/examples/logistic_regression.py +++ b/python/examples/logistic_regression.py @@ -39,7 +39,7 @@ def readPointBatch(iterator): strs = list(iterator) matrix = np.zeros((len(strs), D + 1)) for i in xrange(len(strs)): - matrix[i] = np.fromstring(strs[i], dtype=np.float32, sep = ' ') + matrix[i] = np.fromstring(strs[i].replace(',', ' '), dtype=np.float32, sep=' ') return [matrix] if __name__ == "__main__": |