PyTorch
PyTorch is a machine learning framework based on the Torch library. PyTorch and TensorFlow have much in common. However, PyTorch is more commonly used than TensorFlow nowadays.
PyTorch is a machine learning framework based on the Torch library. PyTorch and TensorFlow have much in common. However, PyTorch is more commonly used than TensorFlow nowadays.
Tensorflow is a free and open-source software library for machine learning and artificial intelligence. It has a particular focus on training and inference of neural networks.
Matplotlib is a plotting library for python and numpy. It supports multiple types of plot and style customization. Its main plot API is pyplot
Scikit-learn is an open-source machine learning library for python. It features traditional machine learning models, such as classification, regression and clustering algorithms including support-vector machines, random forests, gradient boosting, k-means and DBSCAN. It is designed to interoperate with the Python numerical and scientific libraries NumPy and SciPy.
NumPy is a library that extends the base capabilities of python to add a richer data set including mroe numeric types, vectors, matrices, and many matrix functions.
类似于C的printf和scanf,Python也支持字符串的格式化输出。但是,Python格式化字符串的能力更强,因为格式化实际上是Python的string对象的内置函数,而该函数的返回值是格式化后的字符串。换句话说,Python的格式化字符串操作产生一个新的字符串,而该字符串就是个string对象。Python格式化字符串常用的运算符/函数是%和format
与C++一样,Python中也存在浅拷贝(Copy)和深拷贝(Deepcopy)两种拷贝方式。然而,由于Python中的一切传递、赋值都是引用,其深浅拷贝也具有更为不同的特点。
zip() aggregates elements from two or more iterables and return a iterator whose elements are tuples.
math.gamma() calculates generalized factorial.
An anonymous function in Python is the one that has no name when it is defined. In Python, the lambda keyword is used to define anonymous functions rather than the def keyword, which is used for normal functions.