Skip to main content

Posts

Tutorial - numpy for changing color of an image at pixel level.

import numpy as np import matplotlib.pyplot as plt import cv2 as cv #this program conversts color of certain sections of image #each pixel is checked for the r g b and modified using a numpy array image = cv.imread('rg.png') #print(image.shape) #print(np.asarray(image)) width , height , channels = image.shape #print(width) #print(height) #print(channels) plt.imshow(image) plt.show() #print(image[29][29]) zero_array = np.zeros((2, 3, 3)) for pixeli in range(width):     #print(pixeli)     for pixelj in range(height):        # print(pixeli,pixelj)         #print(image[pixeli][pixelj])         pixelvalue = image[pixeli][pixelj]         #print(pixelvalue)         if pixelvalue[0] == 76 and pixelvalue[1] == 177 and pixelvalue[2] == 34:             #print('mach')             r = 0             g = 0             b = 0             image[pixeli][pixelj] = [r, g, b]   plt.imshow(image) plt.show() The pixel level color are changed as y

Raspberry pi

Raspberry pi is a computer which can easily run on linux os uses: can be used as a controller for projects  controller meaning send and receive data using raspberry pi to devices  for testing. can be used for developing prototypes. simply buy and start exploring the world simple as that. https://www.raspberrypi.org/products/   if your are interested in LINUX install in pi and use as a desktop computer.   https://ubuntu.com/download/raspberry-pi  https://ubuntu.com/download/iot Buy the latest raspberry -5 Select your country and reseller to buy directly from the reseller. https://www.raspberrypi.com/products/raspberry-pi-5/ Raspberry keyboard can be bought but my experience with the keyboard was boring and some keys were not working  It’s better to use other keyboards rather than this.   buy the new raspberry with higher configuration  8 Gb/quad core  enjoy - https://www.raspberrypi.com/products/raspberry-pi-400/     

Tensor board for analysis

so what is the use of tensorboard ? we can use this tool to analyse the model we create using tensorflow so why we need to analyse the answer is we need to train model and pick the model which has a higher rate of accuracy and min loss. ok accuracy and loss what is this. how to create a model how to feed to it to tensor board ,it is not that difficult its simple easy and fun. before that i learned it from this guy who uses tensorboard like anything his name is sentdex https://www.youtube.com/watch?v=lV09_8432VA&t=129s. awesome tutorial man. before that if do not have any idea of python ,no problem u can learn it in a week and pick it up from there so enjoy python programming.

Welcome to Machine learning using tensorflow

here goes the open source machine learning technique https://www.tensorflow.org/ in this site u can try out the samples with node ,python and other stuff i tried things with python which seemed to be very easy for me. so what are we goin to do here i tried to run  a sample for object detection - that would be cat and dogs we are goin to train a model using convolutional neural network to identify whether the image that u process is a cat or dog. i went through videos and tutorials done by a guy sentdex ,he s a fantastic guy for most of the python tutorials. here is the link if u want to check out that . sendex. https://www.youtube.com/watch?v=BqgTU7_cBnk https://pythonprogramming.net/.