Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

Python NumPy expand_dims Function Example

# welcome to softhunt.net
# import numpy
import numpy as np

# using Numpy.expand_dims() function
softhunt = np.array([1, 2])
print(softhunt.shape)

softhunt = np.expand_dims(softhunt, axis = 0)
print(softhunt.shape)
Source by softhunt.net #
 
PREVIOUS NEXT
Tagged: #Python #NumPy #Function #Example
ADD COMMENT
Topic
Name
2+7 =