同步操作将从 Gitee 极速下载/Taichi 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
After v0.5.12: [Releases]
(April 11, 2020) v0.5.11 released
taichi-nightly
now covers CUDA 10.X on Windows and Linux (#756) (by Yuanming Hu)game_of_life.py
(#741) (by 彭于斌)examples/regression.py
(#757) (by Quan Wang)ti.GUI.circles
(#755) (by Yuanming Hu)continue
on all backends (#716) (by Ye Kuang)ti.random()
on Metal (#710) (by Ye Kuang)(Mar 29, 2020) v0.5.10 released
ti.static(ti.grouped(ti.ndrange(...)))
syntax checker false positive (#680) (by Yuanming Hu)ti test
now supports -t/--threads
for specifying number of testing threads (#674) (by Yuanming Hu)(Mar 28, 2020) v0.5.9 released
bitmasked
as the leaf block structure for 1x1x1
masks (#676) (by Yuanming Hu)bitmasked
as the leaf block structure for 1x1x1
masks (#676) (by Yuanming Hu)bitmasked
on Metal (#661) (by Ye Kuang)(Mar 24, 2020) v0.5.8 released. Visible/notable changes:
Expr.copy_from
(by Yuanming Hu)ti.Vector.unit
to generate unit vectors (by Yuanming Hu)a = ti.static(a_very_long_variable)
for easy aliasing [doc] (#587) (by 彭于斌 and KLozes)ti.atomic_min
, ti.atomic_max
, ti.atomic_bit_or
, ti.atomic_bit_and
, ti.atomic_bit_xor
(CPU and CUDA by KLozes, OpenGL by 彭于斌, Metal by Ye Kuang)ti format
now cover all files from upstream/master to the working tree (#629) (by Ye Kuang)ti test
now uses argparse
for better customizability (#601) (by 彭于斌)examples/mgpcg.py
(#573) (by KLozes)examples/sdf_renderer.py
(by Yuanming Hu)examples/mgpcg_advanced.py
(#573) (by Yuanming Hu)(Mar 4, 2020) v0.5.7 released
ti.classfunc
. Please simply use ti.func
, even if you are decorating a class member functionti test
on release mode(Mar 3, 2020) v0.5.6 released
ti.GUI.line
(by Mingkuan Xu [xumingkuan])arch=ti.arm64
is now supported. (Please build from source)(Mar 2, 2020) v0.5.5 released: Experimental CUDA 10.0/10.1 support on Windows. Feedbacks are welcome!
(Mar 1, 2020) v0.5.4 released
ti.imread/imwrite/imshow
for convenient image IO (by Yubin Peng [archibate])ti.GUI.set_image
now takes all numpy unsigned integer types (by Yubin Peng [archibate])1 < ti.append(...) < 3 < 4
) (by Mingkuan Xu [xumingkuan])@ti.classkernel
is deprecated. Always use ti.kernel
, no matter you are decorating a class member function or not (by Ye Kuang [k-ye])TI_USE_UNIFIED_MEMORY=0
to disable unified memory usageti.GUI.line
performance(Feb 25, 2020) v0.5.3 released
ti.warning
renamed to ti.warn
ti.x86_64
renamed to ti.x64
. ti.x86_64
is deprecated and will be removed in a future releaseu8, i8, u16, i16, u32
(by Yubin Peng [archibate])(Feb 20, 2020) v0.5.2 released
ti.pow
now supported (by Yubin Peng [archibate])ti.pow
(by Ye Kuang [k-ye])ti.normalized
now optionally takes a argument eps
to prevent division by zero in differentiable programmingTI_LOG_LEVEL
to trace
, debug
, info
, warn
, error
to filter out/increase verbosity. Default=info
ti.GUI.triangle
example
ti.cross
for 3D cross productsTI_TEST_THREADS
to override testing threadsti.init(print_processed=True)
renamed to ti.init(print_preprocessed=True)
(Feb 16, 2020) v0.5.1 released
ti
(ti.exe
) command supported on Windows after setting %PATH%
correctly (by Mingkuan Xu [xumingkuan])x ** y
now supported in Taichi kernels (by Yubin Peng [archibate]).dense(...).pointer()
now abbreviated as .pointer(...)
. pointer
now stands for a dense pointer array. This leads to cleaner code and better performance. (by Kenneth Lozes [KLozes])for i in X
now iterates all child instances of X
instead of X
itself. Skip this if you only use X=leaf node
such as ti.f32/i32/Vector/Matrix
.(Feb 14, 2020) v0.5.0 released with a new Apple Metal GPU backend for Mac OS X users! (by Ye Kuang [k-ye])
ti.init(..., arch=ti.metal)
and run Taichi on your Mac GPUs!dense
SNodes and 32-bit data types. It doesn't support ti.random()
or print()
.[]
operator in Python is slow in the current implementation. If you need to do a large number of reads, consider dumping all the data to a numpy
array via to_numpy()
as a workaround. For writes, consider first generating the data into a numpy
array, then copying that to the Taichi variables as a whole.(Feb 12, 2020) v0.4.6 released.
TAICHI_REPO_DIR
is not a valid path (by Yubin Peng [archibate])ti.require()
and ti.archs_excluding()
(by Ye Kuang [k-ye])ti.init(**kwargs)
now takes a parameter debug=True/False
, which turns on debug mode if trueTI_DEBUG=1
to turn on debug mode non-intrusivelyti.profiler_clear
GUI.line(begin, end, color, radius)
and ti.rgb_to_hex
ti.trace
(Matrix trace) to ti.tr
. ti.trace
is now for logging with ti.TRACE
levelti test_cpp
(thanks to Ye Kuang [k-ye])ti.INFO
instead of trace to make the world quiter(Feb 6, 2020) v0.4.5 released.
ti.init(arch=..., print_ir=..., default_fp=..., default_ip=...)
now supported. ti.cfg.xxx
is deprecatedti.init
. No need to wrap data layout definition with @ti.layout
anymore (unless you intend to do so)ti.is_active
, ti.deactivate
, SNode.deactivate_all
supported in the new LLVM x64/CUDA backend. Example
ti.global_var
(which duplicates ti.var
) is removedti.Matrix.rotation2d(angle)
added(Feb 5, 2020) v0.4.4 released.
f64
precision support of sin
and cos
on CUDA backends (by Kenneth Lozes [KLozes])Profiler
working on CPU devices. To enable, ti.cfg.enable_profiler = True
. Call ti.profiler_print()
to print kernel running times(Feb 3, 2020) v0.4.3 released.
GUI.circles
2.4x faster(Feb 2, 2020) v0.4.2 released.
mpm88.py
is 30% faster on CUDA due to reduced kernel launches(Jan 31, 2020) v0.4.1 released.
Dockerfile
(by Shenghang Tsai [jackalcooper])pbf2d.py
visualization performance boosted (by Ye Kuang [k-ye])GlobalTemporaryStmt
codegen(Jan 30, 2020) v0.4.0 released.
ti.deactivate
now supported on sparse data structuresGUI.circles
(batched circle drawing) performance improved by 30x(Jan 20, 2020) v0.3.25 released.
(Jan 19, 2020) v0.3.24 released.
%
and //
now follow Python semantics. Use ti.raw_mod
for C-style %
semantics (by Chujie Zeng [Psycho7])for i in range(bound[0])
is supported(Jan 18, 2020) v0.3.23 released.
(Jan 17, 2020) v0.3.22 released.
ti.atomic_add()
now returns the old value (by Ye Kuang [k-ye])ti.__version__
now returns the version triple, e.g. (0, 3, 22)
ti.cfg.print_ir = True
ti.cfg.print_accessor_ir
(Jan 11, 2020) v0.3.21 released.
(Jan 2, 2020) v0.3.20 released.
ti.static(ti.grouped(ti.ndrange(...)))
(Jan 2, 2020) v0.3.19 released.
ti.atan2(y, x)
(Jan 1, 2020) v0.3.18 released.
ti.GUI
classti.Matrix.fill
(Dec 31, 2019) v0.3.17 released.
ti.Matrix.T()
for transposing a matrixti.static(ti.ndrange)
ti.Matrix.identity()
ti.Matrix.one()
(create a matrix with 1 as all the entries)ir_printer
on SNodesdynamic
SNodes.
Struct-for's
on dynamic
nodes supportedti.length
and ti.append
to query and manipulate dynamic nodes(Dec 29, 2019) v0.3.16 released.
(Dec 28, 2019) v0.3.15 released.
ti.ndrange
: @ti.kernel
def fill_3d():
# Parallelized for all 3 <= i < 8, 1 <= j < 6, 0 <= k < 9
for i, j, k in ti.ndrange((3, 8), (1, 6), 9):
x[i, j, k] = i + j + k
ti
and tid
(debug mode) CLI commandsti.append
now returns the list length before appendingti.get_runtime().set_verbose_kernel_launch(True)
to log kernel launches/
and //
following the Python conventiondynamic
node support (ti.append
, ti.length
) in the new LLVM backendassert <condition>
statement supported in Taichi kernels.1 < x <3
) supported in Taichi kernels.ti.classfunc
decorator for functions within a data_oriented
class[Expr/Vector/Matrix].to_torch
now has a extra argument device
, which specifies the device placement for returned torch tensor, and should have type torch.device
. Default=None
.to_torch/from_torch
.matrix size
to 1
)ti.data_oriented
decorator introduced. Please decorate all your Taichi data-oriented objects using this decorator. To invoke the gradient versions of classmethod
, for example, A.forward
, simply use A.forward.grad()
instead of A.forward(__gradient=True)
(obsolete).R, S = ti.polar_decompose(A, ti.f32)
) and svd (U, sigma, V = ti.svd(A, ti.f32)
) support. Note that sigma
is a 3x3
diagonal matrix.expr_init
with ti.core.DataType
as inputs, so that ti.core.DataType
can be used as ti.func
parameterDiffTaichi
examples moved to a standalone repo
Vector.norm
now comes with a parameter eps
(=0
by default), and returns sqrt(\sum_i(x_i ^ 2) + eps)
. A non-zero eps
safe guards the operator's gradient on zero vectors during differentiable programming.glibc 2.27
break
statements supported in while loopsti.GUI.set_image(np.ndarray/Taichi tensor)
x[i] += j
is equivalent to ti.atomic_add(x[i], j)
ti.func
arguments are forced to pass by valuemin/max
can now take more than two arguments, e.g. max(a, b, c, d)
transposed
, trace
, polar_decompose
, determinant
promoted to ti
scope. I.e., users can now use ti.transposed(M)
instead of ti.Matrix.transposed(M)
ti.get_runtime().set_verbose(False)
to eliminate verbose outputsti.random(ti.i32/i64/f32/f64
)Taichi
, numpy
and PyTorch
taichi_scalar_tensor.to_numpy()/from_numpy(numpy_array)
taichi_scalar_tensor.to_torch()/from_torch(torch_array)
ti.ext_arr()
now takes PyTorch tensorsmin
/max
supprtMatrix.to_numpy
, Matrix.zero
, Matrix.identity
, Matrix.fill
ti.static
numpy
arrays passed as a ti.ext_arr()
[examples]
i32/f32/i64/f64
data type support for numpyTensor.to_numpy()
and Tensor.from_numpy(numpy.ndarray)
supported [examples]
ti.ext_arr()
. Please use numpy arrays as intermediate buffers for nowTensor.dim()
to retrieve the dimensionality of a global tensorTensor.shape()
to retrieve the shape of a global tensorstruct-for
(e.g. for i, j in x
) now supports iterating over tensors with non power-of-two dimensionsTensor.fill(x)
to set all entries to x
Matrix.fill(x)
to set all entries to x
, where x
can be a scalar or ti.Matrix
of the same sizestruct-for
with grouped indices for better metaprogramming, especially in writing dimensionality-independent code, in e.g. physical simulation: [examples]
for I in ti.grouped(x): # I is a vector of size x.dim() and data type i32
x[I] = 0
# If tensor x is 2D
for I in ti.grouped(x): # I is a vector of size x.dim() and data type i32
y[I + ti.Vector([0, 1])] = I[0] + I[1]
# is equivalent to
for i, j in x:
y[i, j + 1] = i + j
(Nov 27, 2019) v0.1.5 released.
ti.static
outside Taichi kernels(Nov 22, 2019) v0.1.3 released.
print
instead of ti.print
int()
instead of ti.cast(x, ti.i32)
(or ti.cast(x, ti.i64)
if your default integer precision is 64 bit)float()
instead of ti.cast(x, ti.f32)
(or ti.cast(x, ti.f64)
if your default float-point precision is 64 bit)abs
instead of ti.abs
ti.static_print
for compile-time printing(Nov 16, 2019) v0.1.0 released. Fixed PyTorch interface.
(Nov 12, 2019) v0.0.87 released.
(Nov 4, 2019) v0.0.85 released.
ti.stop_grad
for stopping gradients during backpropagation. [Example];The legacy Taichi library is an open-source computer graphics library written in C++14 and wrapped friendly with Python. It is no longer maintained since we have switched to the Taichi programming language and compiler.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。