Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

cmap perlin noise python

import random
from perlin_noise import PerlinNoise
import matplotlib.pyplot as plt

noise = PerlinNoise(octaves=10, seed=random.randrange(1,1000000000000000))
xpix, ypix = 100, 100
pic = [[noise([i/xpix, j/ypix]) for j in range(xpix)] for i in range(ypix)]

plt.imshow(pic, cmap='gray')
plt.show()
Comment

PREVIOUS NEXT
Code Example
Python :: python get timestamp 2020-04-23T12:00:00Z 
Python :: extract column of n array 
Python :: how to convert data into numerical dataset 
Python :: python os path safe string 
Python :: how to make input box if else statement in tkinter 
Python :: scikit learn decistion tree 
Python :: how to make a window with tkinter 
Python :: zoom in librosa.display.specshow() 
Python :: matplotlib boxplot change size of outliers 
Python :: django trigger when an instance od data is deleted from model 
Python :: Access python http.server on google colab 
Python :: pandas assign value to row based on condition 
Python :: binary search iterative 
Python :: python defaultdict default value 
Python :: how i get url value in get_queryset function in drf 
Python :: To convert Date dtypes from Object to ns,UTC with Pandas 
Python :: merge two list of dictionaries python with string 
Python :: remove hh:mm:ss from pandas dataframe column 
Python :: pygame image get height 
Python :: call class function by string python 
Python :: how to install dependencies python 
Python :: python class with optional arguments 
Python :: python % meaning 
Python :: pytest snapshot update 
Python :: combinations 
Python :: tri fusion python code 
Python :: Merge 2 or more notebooks into one 
Python :: keras sequential layer without input shape 
Python :: ski learn decision tree 
Python :: convert plt.show to image to show opencv 
ADD CONTENT
Topic
Content
Source link
Name
5+2 =