From 71b49456c4b26ed49179fcf91b19ece3d5740d81 Mon Sep 17 00:00:00 2001 From: BigEpsilon Date: Sat, 12 Dec 2015 20:58:49 +0100 Subject: [PATCH 1/2] Fix compilation errors for julia 0.4.2 --- src/model.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/model.jl b/src/model.jl index d4b492333f9f..c208873e867f 100644 --- a/src/model.jl +++ b/src/model.jl @@ -43,7 +43,7 @@ function _split_inputs(batch_size :: Int, n_split :: Int) @assert(batch_size >= n_split) per_split = floor(Int, batch_size / n_split) counts = Base.zeros(Int, n_split)+per_split - extra = batch_size - sum(counts) + extra = batch_size - Base.sum(counts) counts[1:extra] += 1 cum = [0, cumsum(counts)...] From 8e879d74512d8ae2e7bc78fe9bd2f31eed4ef9a9 Mon Sep 17 00:00:00 2001 From: BigEpsilon Date: Sat, 12 Dec 2015 21:03:30 +0100 Subject: [PATCH 2/2] Fix compilation errors for julia 0.4.2 --- src/io.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/io.jl b/src/io.jl index 48e0a31e32a2..99fcd8516c6b 100644 --- a/src/io.jl +++ b/src/io.jl @@ -435,7 +435,7 @@ immutable ArrayDataBatch <: AbstractDataBatch idx :: UnitRange{Int} end function Base.next(provider :: ArrayDataProvider, state :: ArrayDataProviderState) - idx = state.curr_idx:min(state.curr_idx+provider.batch_size-1, provider.sample_count) + idx = state.curr_idx:Base.min(state.curr_idx+provider.batch_size-1, provider.sample_count) return (ArrayDataBatch(idx), ArrayDataProviderState(idx.stop+1)) end