Verfasst: Donnerstag 4. Februar 2010, 18:14
Wäre nett wenn du etwas Code posten würdest wenn du ein Beispiel mit OpenMP zum laufen gekriegt hast. Die Thematik interessiert mich schon seit längeren...
Seit 2002 Diskussionen rund um die Programmiersprache Python
https://www.python-forum.de/
Code: Alles auswählen
subroutine test(arrayin, arrayout, m, n)
implicit none
REAL, dimension(m, n), intent(in) :: arrayin
REAL, dimension(m, n), intent(out) :: arrayout
integer, intent(in) :: m, n
arrayout = arrayin + 3
end subroutine test
Code: Alles auswählen
import numpy
import test
a = numpy.arange(9).reshape(3, 3)
b = test.test(a)
print a
print b
Code: Alles auswählen
>C:\Programme\Python26\pythonw -u "testpy.py"
[[0 1 2]
[3 4 5]
[6 7 8]]
[[ 3. 4. 5.]
[ 6. 7. 8.]
[ 9. 10. 11.]]
>Exit code: 0