Skip to content

Commit

Permalink
fix bug in setting default numclusters
Browse files Browse the repository at this point in the history
  • Loading branch information
bquistorff committed Jul 9, 2017
1 parent c8b09cd commit 302d7d6
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 8 deletions.
3 changes: 3 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
2017-07-09 Brian Quistorff
* Fix Bug in setting default numprocessors

2017-06-28 Brian Quistorff
* Fix Mac CLI issue

Expand Down
2 changes: 1 addition & 1 deletion ado/makefile
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,6 @@ tests:

releaseinfo: check tests
@echo Make sure you run tests (on Stata v12)
@echo Make sure you bump the version
@echo Make sure you bump the version and -make inc_dist_date-
@echo Make sure you editted the Changelog
@echo After pushing to github, go to https://github.com/gvegayon/parallel/releases and make a release
8 changes: 4 additions & 4 deletions ado/parallel.ado
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*! version 1.18.2 20mar2017
*! version 1.18.3 09jul2017
*! PARALLEL: Stata module for parallel computing
*! by George G. Vega [cre,aut], Brian Quistorff [ctb]
*!
Expand Down Expand Up @@ -100,10 +100,10 @@ end
program def parallel_version, rclass
version 11.0
di as result "parallel" as text " Stata module for parallel computing"
di as result "vers" as text " 1.18.2 20mar2017"
di as result "vers" as text " 1.18.3 09jul2017"
di as result "auth" as text " George G. Vega [cre,aut], Brian Quistorff [ctb]"

return local pll_vers = "1.18.2"
return local pll_vers = "1.18.3"
end

/* Take a look to logfiles */
Expand Down Expand Up @@ -520,7 +520,7 @@ program parallel_setclusters
syntax anything(name=nclusters) [, Force Statapath(string asis) Gateway(string) Includefile(string) procexec(int 2)]

_assert inlist(`procexec',0,1,2), msg("procexec() must be 0, 1, or 2") rc(198)
cap parallel_setclusters
cap parallel_numprocessors
local nproc = int(real("`r(numprocessors)'"))
if "`nclusters'"=="default"{
_assert `nproc'!=., msg("Couldn't determine number of available processors for default configuration.")
Expand Down
2 changes: 1 addition & 1 deletion ado/parallel.sthlp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{smcl}
{* *! version 1.18.2 20mar2017}{...}
{* *! version 1.18.3 09jul2017}{...}
{cmd:help parallel}{right:also see: {net "describe miparallel, from(http://fmwww.bc.edu/RePEc/bocode/m)":miparallel}}
{hline}

Expand Down
2 changes: 1 addition & 1 deletion parallel.pkg
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ d KW: multiple imputations
d
d Requires: Stata version 10
d
d Distribution-Date: 20170320
d Distribution-Date: 20170709
d
d Author: George Vega Yon , California Institute of Technology, USA
d Support: email gvegayon@@caltech.edu
Expand Down
2 changes: 1 addition & 1 deletion test files/test.do
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ type __pll`r(pll_id)'_do0001.do
parallel clean, all

/* Testing cluster assigment */
parallel numprocessors
parallel setclusters default //just to check
parallel numprocessors
parallel setclusters 2, force
sort rep78
parallel, by(rep78) f keepl nog: gen n2 = _N
Expand Down

0 comments on commit 302d7d6

Please sign in to comment.