Skip to content

Commit

Permalink
fix(tree): fix to_float (#873)
Browse files Browse the repository at this point in the history
Co-authored-by: 杭卫强 <hangweiqiang@bytedance.com>
  • Loading branch information
hangweiqiang-uestc and 杭卫强 authored Aug 10, 2021
1 parent eed77f2 commit 0c25ce6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fedlearner/model/tree/trainer.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ def read_data(file_type, filename, require_example_ids, require_labels,
features = []
cat_features = []
def to_float(x):
float(x if x != '' else 'nan')
return float(x if x != '' else 'nan')
for line in reader:
if file_type == 'tfrecord':
line = parse_tfrecord(line)
Expand Down

0 comments on commit 0c25ce6

Please sign in to comment.