Skip to content

Commit

Permalink
fix pytorch featureset, total train sample is incorrect. (intel-analy…
Browse files Browse the repository at this point in the history
…tics#2421)

* fix pytorch featureset

* fix style check
  • Loading branch information
qiuxin2012 authored Jul 2, 2020
1 parent 0447f20 commit dee5f81
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion python/dllib/src/bigdl/dllib/feature/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,8 @@ def pytorch_dataloader(cls, dataloader, bigdl_type="float"):
if dataloader.batch_size % node_num != 0:
true_bs = math.ceil(dataloader.batch_size / node_num) * node_num
warning_msg = "Detect dataloader's batch_size is not divisible by node number(" + \
node_num + "), will adjust batch_size to " + true_bs + " automatically"
str(node_num) + "), will adjust batch_size to " + str(true_bs) + \
" automatically"
warnings.warn(warning_msg)

bys = CloudPickleSerializer.dumps(CloudPickleSerializer, dataloader)
Expand Down

0 comments on commit dee5f81

Please sign in to comment.