Skip to content

Commit

Permalink
Merge pull request #1 from codezoned/master
Browse files Browse the repository at this point in the history
Updating my repository
  • Loading branch information
shashankchakrawarty98 committed Sep 3, 2018
2 parents cbdb529 + 1545757 commit fb13b2c
Show file tree
Hide file tree
Showing 5 changed files with 66 additions and 20 deletions.
43 changes: 43 additions & 0 deletions Image_Processing/src/Binary_Image.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
%Binary Image by Master-Fury

clear all;

%Setting up the directory
fpath1=fullfile('C:\Users\Manish (Master)\Desktop\images'); % Add your directory
addpath(fpath1);
basefile=sprintf('*.png'); % Add format of image
all_images=fullfile(fpath1,basefile);
fnames=dir(all_images);


% READING OF IMAGE
for i = 1:length(fnames)
all_images = fullfile(fnames(i).folder, fnames(i).name);
I = imread(all_images); % Image reading using imread
figure
imshow(I) % To see original image
title('Original Image');
% The original image contains colors RGB (in matlab it stores in the format RBG)
% Conversion of image into gray-scale image can be done by removing any one color from image.

Gray_Scale=I(:,:,2); % Green color removed.
figure
imshow(Gray_Scale)
title('Grey-Scale Version of Image')

% Conversion of GRAY-SCALE to BINARY IMAGE
Binary_Image = imbinarize(Gray_Scale,'adaptive','ForegroundPolarity','dark','Sensitivity',0.4);
% You can use different methods like instead of adaptive you can use global(by default).
% Foreground Polarity can be dark or bright (refer documentaion for more info)
% Sensitivity can be from 0 to 1 , by default it is 0.5
figure
imshow(Binary_Image)
title('Binary Version of Image')
end
% SPECIAL NOTE
% There is major difference between gray-scale image and binary image. The
% differnce is - binary images consists only 0 & 1 (refer workspace) matrix
% 1 represents white and 0 represents black.
% A binary image is a digital image that has only two possible values for each pixel.
% In the case of gray scale image,
% for example 8-bit gray scale image (2^8=256) pixel value may vary between 0 to 256.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#by: shashank
#armstrong number
# ARMSTRONG NUMBER BY SHASHANK

num=int(input('Enter a Number:'))
Sum=0
Expand All @@ -8,13 +7,13 @@
digit=temp%10
Sum+=digit**3
temp//=10
# print(digit,temp,Sum)


if (num == Sum):
print('armstrong')
print('Hurray! It is a Armstrong Number')

else:
print('not armstrong')
print('Sorry! Try again, Its not a Armstrong Number')



34 changes: 19 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,40 +1,44 @@
# Scripts Dump!

> Your goto place to find and dump any script you want.


>
> **This is one of the first projects of codezoned, Show your :heart:**
>
> **[Make sure you join our community by clicking on this beautiful sentence](http://talk.codezoned.com) **
>
> or just visit http://talk.codezoned.com
ScriptsDump is a complete repository of all kind of scripts we and you can think of. Scripts written in any languages are welcomed but we at codezoned tend to lean towards **Python and Go** :wink:.

## Structure

ScriptsDump is a complete repository of all kind of scripts we and you can think of. Scripts written in any languages are welcomed but we at codezoned tend to lean towards **Python and Go** :wink:.
>Simplified structure of *ScriptsDump*
## Structure
Simplified structure of *ScriptsDump*
- **[Sorting](/Arrays-Sorting/src)**

* **[Sorting](/Arrays-Sorting/src)**
- **[Searching](/Arrays-searching/src)**

* **[Searching](/Arrays-searching/src)**
- **[Automation](Automation/src)**

* **[Automation](Automation/src)**
- **[Image Processing](/Image_Processing/src)**

* **[Filters](Filters/src)**
- **[FTP Stuff](/FTP_Stuff/src)**

* **[FTP Stuff](/FTP_Stuff/src)**
- **[Machine Learning](/Machine_Learning/src/)**

* **[Machine Learning](/Machine_Learning/src/)**
- **[Json Parser](/Json_Parser/src)**

* **[Json Parser](/Json_Parser/src)**
- **[Mathematical Algorithms](/Mathematical_Algorithms/src)**

## Maintainers

We're always looking out for people who're enthusiastic to work and collaborate with people. If you want to become a maintainer at ScriptsDump youu can contact us [email protected]

**The current maintainers are:**

- [Manish Kumar](https://github.com/master-fury)

- [Senthil Kumar (Rats12)](https://github.com/Rats12)

## Contributions

Expand Down

0 comments on commit fb13b2c

Please sign in to comment.