When we develop some applications we have to deal with data. The data is a collection of values and for storing the collection of values we need data structures. CPP provides built-in libraries of classes for all these data structures and that collection of classes are called STL (Standard Template Libraries ).
Numpy stands for Numerical Python .Numpy is an open source library which is used for numerical operations with respect to linear algebra and matrices .It is created by Travis Oliphant in 2005 .
Sorting means putting something in a sequence . Numpy comes with an inbuilt library which will allows us to sort an arrray in ascending order and retrurn us a copy of sorted array without modifying the actual instance .
numpy.sort(a, axis=-1, kind=None, order=None)
In this example the print statement will return the sorted version of an array (arr) along with…
PyTorch is a deep learning library as popular as Tensorflow , helps us to bulid deep learning models . It consist of many inbuilt functions and some of them will be discussed here .
Concatenates the given sequence of seq tensors in the given dimension. All tensors must either have the same shape (except in the concatenating dimension) or be empty.
torch.cat(tensors, dim=0, out=None)
In this example we are concatenating two (3,3) dimentional metrics. Here torch.zeros will fill all the values with zeros and torch.randn …