copapy.Target#
- class copapy.Target(arch='native', optimization='O3')#
Bases:
objectTarget device for compiling for and running on copapy code.
Initialize Target object
- Parameters:
arch (
str) – Target architectureoptimization (
str) – Optimization level
- compile(*values)#
Compiles the code to compute the given values.
- read_value(variables)#
- Overloads:
self, variables (value[T]) → T
self, variables (NumLike) → float | int | bool
self, variables (Iterable[T | value[T]]) → list[T]
self, variables (ArrayType[T]) → ArrayType[T]
Reads the numeric value of a copapy type.
- read_value_remote(variable)#
Reads the raw data of a value by the runner.
- Return type:
None
- run()#
Runs the compiled code on the target device.
- Return type:
None