Search Results
|
Post |
Author |
Forum |
Replies |
Views |
Posted
[asc]
|
|
|
Thread: How to parallel executing a command using subprocess?
Post: How to parallel executing a command using subproce...
./PoreDy is the command I want to execute, and jobname and 1001 is the argument it required.
My code is as follows:
TotalThread=24
CheckInterval=2
for i in range(CasesCount):
jobname=Name(FolderNam... |
|
larkypython |
General Coding Help |
0 |
2,156 |
Nov-28-2019, 03:49 PM |
|
|
Thread: How to write a script to execute a program need passing additional input?
Post: RE: How to write a script to execute a program nee...
Thank you very much, scidam!
While I am actually looking for a solution of changing on the Python side. The C++ code is mature and I prefer to leave it there.
Best! |
|
larkypython |
General Coding Help |
2 |
2,537 |
Nov-23-2019, 04:38 AM |
|
|
Thread: How to write a script to execute a program need passing additional input?
Post: How to write a script to execute a program need pa...
I would like the python test.py to run a program after it been compiled to a.out and to read test.dat file:
import subprocess
import os
cmd='./a.out'
subprocess.call(cmd, shell=True)
cmd='test.data'... |
|
larkypython |
General Coding Help |
2 |
2,537 |
Nov-22-2019, 02:32 AM |
|
|
Thread: How do I map a list of values to specified colors?
Post: RE: How do I map a list of values to specified col...
Thanks MckJohan, but nope. What I want to do is to specify a certain value to a specified color, maybe through RGB values.
establish the connections like the following:
-1 ---------------> R200 G1... |
|
larkypython |
General Coding Help |
4 |
2,572 |
Nov-05-2019, 09:22 AM |
|
|
Thread: How do I map a list of values to specified colors?
Post: RE: How do I map a list of values to specified col...
Thanks, Larz60+, What I am thinking about is mapping the list
[-1, 1, -2, 2, -3, 3, -4, 4, -5, 5, -6, 6, -7, 7, -8, 8, -9, 9, 0] to another list
[255//19*i for i in range(19)] first
and then use
plt... |
|
larkypython |
General Coding Help |
4 |
2,572 |
Nov-05-2019, 02:34 AM |
|
|
Thread: How do I map a list of values to specified colors?
Post: How do I map a list of values to specified colors?
Here is what I want to do:
a list of 19 values:
[-1, 1, -2, 2, -3, 3, -4, 4, -5, 5, -6, 6, -7, 7, -8, 8, -9, 9, 0]
I would like the color grey gradual from white to black in the order in the list. How... |
|
larkypython |
General Coding Help |
4 |
2,572 |
Nov-04-2019, 02:59 AM |
|
|
Thread: cannot import scipy.optimize.Bounds
Post: RE: cannot import scipy.optimize.Bounds
Problem solved, looks like I just need to upgrade scipy from 0.19 to 1.1 or above. |
|
larkypython |
General Coding Help |
2 |
7,246 |
May-05-2019, 04:09 AM |
|
|
Thread: Relations between python 2.7 3 3.7, scipy, pip?
Post: Relations between python 2.7 3 3.7, scipy, pip?
Basically, I don't understand is scipy, numpy an extension on all python or a particular version of python? cause I installed python 2.7, 3.6 together with my ubuntu, and I installed pip and scipy, wh... |
|
larkypython |
General Coding Help |
2 |
2,438 |
May-05-2019, 03:58 AM |
|
|
Thread: cannot import scipy.optimize.Bounds
Post: RE: cannot import scipy.optimize.Bounds
I wrote a very simple program to test the optimize of scipy, it all works for unconstrained optimizations, but when it comes to constrained optimization, the Bounds, LinearConstraint module will be ne... |
|
larkypython |
General Coding Help |
2 |
7,246 |
May-05-2019, 02:48 AM |
|
|
Thread: cannot import scipy.optimize.Bounds
Post: cannot import scipy.optimize.Bounds
I used this:
from scipy import optimize
then it is ok to use optimize.minimize
but cannot use optimize.Bounds, cannot use optimize.LinearConstraint, saying no this module
then I tried
from scipy.optim... |
|
larkypython |
General Coding Help |
2 |
7,246 |
Apr-29-2019, 01:17 AM |