LoginSignup
1
1

More than 5 years have passed since last update.

mrubyでCPUの論理コア数を取得する俺以外が思いつかない方法

Last updated at Posted at 2016-07-24

背景

俺以外が思いつかない方法なので、メモに残しますw

mruby-juliaを使う

mruby-juliaを使い、PyCallを経由して、Pythonのmultiprocessingパッケージのcpu_countを使う。

Julia.eval("using PyCall;@pyimport multiprocessing as mp;string(mp.cpu_count())")

関連記事

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1