Is compiling opencv with tbb relevant on processeur with 2 thread - opencv

I am using OpenCv with the following processor :
Intel(R) Atom(TM) CPU N455 # 1.66GHz
Intel indicates that this processeur has 1 core but 2 threads.
So would it be relevent to use OpenCv with TBB option and expect faster execution ?
Thank you

this might help.
TBB example works better using 2 threads even on my Megafon Mint phone that contains Intel(R) Atom(TM) CPU Z2460 # 1.6GHz processor which has 1 core but 2 threads also.
--Vladimir

Related

How to get correct number of logical processors

In Delphi, we need to know the number of CPUs for parallelization. Until now, we have used the GetNativeSystemInfo() function, which has worked fine, also with servers with hyperthreading.
But now, we have a server (Intel Xeon Gold 6230) with 40 physical processors and 80 logical processors with hyperthreading, and GetNativeSystemInfo() only shows 40 CPUs.
We made a small test program that uses 3 calls:
GetNativeSystemInfo()
GetLogicalProcessorInformation() (code from How to detect number of logical and physical processors efficiently?)
And looking into the Registry for number of CPUs:
Computer\HKEY_LOCAL_MACHINE\HARDWARE\DESCRIPTION\System\CentralProcessor
For all of our servers, these 3 calls give the same number of CPUs:
But for the Intel Xeon, only the Registry gives us the 80 CPUs:
Does anybody know why it is not working for the Intel server, or know a way to be sure to get the max number of CPUs?
In GetLogicalProcessorInformation documentation I found this part:
On systems with more than 64 logical processors, the
GetLogicalProcessorInformation function retrieves logical processor
information about processors in the processor group to which the
calling thread is currently assigned. Use the
GetLogicalProcessorInformationEx function to retrieve information
about processors in all processor groups on the system.
So try using GetLogicalProcessorInformationEx.
To query logical processor count greater than 64, you have to use the newer GetLogicalProcessorInformationEx API, which the NumCPULib4Pascal library wraps in an easy-to-use manner.
Unfortunately, I can't paste the full code here because it won't fit the word limit of StackOverflow.
Sample usage below:
uses
NumCPULib;
var
lcc, pcc: Int32;
begin
// count logical cpus
lcc := TNumCPULib.GetLogicalCPUCount();
// count physical cpus
pcc := TNumCPULib.GetPhysicalCPUCount();
end;

Tensorflow memory leak while using GPU but in CPU is OK

While using GPU to train my model, the memory of CPU would exhaust after a few epochs. However, if I use CPU instead, this behaviour wouldn't occur.
I tried a couple of different combinations, but none of them worked:
cuda8.0.44 cudnn5.1 tensorflow1.2.1
cuda8.0.44 cudnn6.0 tensorflow1.2.1
cuda8.0.44 cudnn6.0 tensorflow1.3.0
cuda8.0.61(with patch) cudnn6.0 tensorflow1.3.0
I'm using ubuntu14.0.4 with python2.7
Based on the suggestion in this related question, I already tried the following:
Calling tf.get_default_graph().finalize()
Use tcmalloc instead of malloc
Recompiled tensorflow with different hardcoded params

Lua and Torch issues with GPu

I am trying to run the Lua based program from the OpenNMT. I have followed the procedure from here : http://forum.opennmt.net/t/text-summarization-on-gigaword-and-rouge-scoring/85
I have used the command:
th train.lua -data textsum-train.t7 -save_model textsum1 -gpuid 0 1 2 3 4 5 6 7
I am using 8 GPUs but still the process is damn slow as if the process is working on the CPU. kindly, let me know what might be the solution for the optimizing the GPU usage.
Here is the stats of the GP usage:
Kindly, let me know how I can make the process run faster using the complete GPUs. I am available with 11GBs, but the process only consumes 2 GB or less. Hence the process is damn slow.
As per OpenNMT documentation, you need to remove 0 from right after the gpuid option since 0 stands for the CPU, and you are effectively reduce the training speed to that of a CPU-powered one.
To use data parallelism, assign a list of GPU identifiers to the -gpuid option. For example:
th train.lua -data data/demo-train.t7 -save_model demo -gpuid 1 2 4
will use the first, the second and the fourth GPU of the machine as returned by the CUDA API.

ImageMagick 'import' tool for MIPS Architecture

Have a digital media device that I'd like to get the ImageMagick command-line tool 'import' working on. Trying to run binaries from other systems gives a "cannot execute binary" error since the architecture differs (I'm guessing).
How would I get this tool functioning on this MIPS architecture - there is no compiler or package manager on the device.
End goal is to use import to take screen-shots of what is on the attached display at any given time.
uname -a
Linux 4310 2.6.22.19-27-sigma #2 PREEMPT Mon May 16 01:03:35 PDT 2011 mips GNU/Linux
more /proc/cpuinfo
system type : Sigma Designs TangoX
processor : 0
cpu model : MIPS 74K V4.9 FPU V0.0
Initial BogoMIPS : 330.13
wait instruction : yes
microsecond timers : yes
tlb_entries : 32
extra interrupt vector : yes
hardware watchpoint : yes
ASEs implemented : mips16 dsp
shadow register sets : 1
VCED exceptions : not available
VCEI exceptions : not available
System bus frequency : 330750000 Hz
CPU frequency : 661500000 Hz
DSP frequency : 330750000 Hz
Yes, the Mips has an entirely different instruction set.
Your best bet is to use a cross compiler and compile the program on a normal Linux or Windows development system. You can build gcc from scratch as a cross compiler for Mips, or you probably find downloadable pre-compiled compilers for Mips.
This would let you compile the sources on your development system. Of course you'll get the "cannot execute binary" if you try to run the binary there.
You can compare Mips and x86 compiles and look at the assembly language differences at http://ellcc.org/demo

Using SNMP to get Server Information

I'm using SNMP to get Server Infomation.
I want to get CPU/Process type, for example : Intel (R) Pentium (R) Dual CPU E2180 # 2.00GHz
I try very hard but I can't find suitable OID.
Can't anyone help me?
P/s : sorry about my lack Eng ability
The sysDescr table usually (but not always) contains information related to the machine's hardware, CPU included. However you should definitely take a look at the hrDevice table where the hrDeviceType is hrDeviceProcessor, here is what I get querying my laptop:
snmpwalk -v 2c -c ******* 192.168.*.* 1.3.6.1.2.1.25.3.2.1
HOST-RESOURCES-MIB::hrDeviceDescr.768 = STRING: GenuineIntel: Intel(R) Core(TM) i3 CPU M 330 # 2.13GHz

Resources