Profile

Cover photo
Shelby Shum
Works at JPMorgan Chase & Co.
Lives in NY, Syracuse
816 followers|2,429,028 views
AboutPostsPhotosYouTube+1's

Stream

Shelby Shum

Shared publicly  - 
 
With all these posts about how great the new Stock Android Camera is, I believe that LINE Camera definitely deserves some recognition. So what does LINE Camera provide over say, every other camera app? Fancy decorations, that's what. Frames, emoticons, cute cat pictures, and all the filters you can imagine. Does it provide point-shoot optimization? No, does it provide image blending technology for 50MP photography, or the fancy blur effect? No. Is it fun to use? Hell yeah. 

Video preview: [LINE Camera]
iOS: https://itunes.apple.com/us/app/line-camera/id516561342?mt=8
Android: https://play.google.com/store/apps/details?id=jp.naver.linecamera.android

#android   #LINECamera   #LINE   #iOS   #camera  
6
Rob Watkins's profile photoGahx Rose's profile photoShelby Shum's profile photo
4 comments
 
Nice
Add a comment...
 
Alright, so I'm facing a small dilemma here guys. 

OP: http://stackoverflow.com/questions/23146787/apache-poi-style-setting-stops-after-a-while

The post:

What I'm trying to do is to write a program that essentially translates an image into an Excel representation of that very image. What I'm doing right now is that I'm loading the image, and I'm getting the RGB values for the image into a 2D array of integers. 

The issue that I'm facing is this. My cells suddenly have no styling! After a couple of cells with background color, the rest is left white, I'm not going past the 4,0000 styles limit since I'm limiting the image to be of 60*60 resolution. So I'm not quite sure what I'm doing wrong.


My main class:

package excelArtist;

import java.io.FileOutputStream;
import java.io.IOException;

import org.apache.poi.hssf.usermodel.HSSFCellStyle;
import org.apache.poi.hssf.usermodel.HSSFPalette;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
import org.apache.poi.hssf.util.HSSFColor;
import org.apache.poi.ss.usermodel.Cell;
import org.apache.poi.ss.usermodel.CellStyle;
import org.apache.poi.ss.usermodel.Row;
import org.apache.poi.ss.usermodel.Sheet;

public class driver {

static HSSFWorkbook wb = new HSSFWorkbook();

public static void main(String[] args) throws IOException {

imageHandler handler = new imageHandler("test.jpg");
int[][] data = handler.convertImageToRGB();

Sheet sheet = wb.createSheet("drawing");

// start drawing
int width = handler.getWidth();
int height = handler.getHeight();

Row r;
Cell c;
HSSFPalette palette = wb.getCustomPalette();
HSSFColor color;

System.out.println("Width: " + width);
System.out.println("Height: " + height);
for (int y = 0; y < height; y++) {
r = sheet.createRow(y);
for (int x = 0; x < width; x++) {
int index = (y * width) + x;
palette.setColorAtIndex(HSSFColor.LAVENDER.index,
(byte) data[index][0], (byte) data[index][1],
(byte) data[index][2]);
color = palette.findSimilarColor(data[index][0],
data[index][1], data[index][2]);
short palIndex = color.getIndex();
c = r.createCell(x);
c.setCellValue("0");
HSSFCellStyle tempStyle = wb.createCellStyle();
tempStyle.setFillForegroundColor(palIndex);
tempStyle.setFillPattern(CellStyle.SOLID_FOREGROUND);
c.setCellStyle(tempStyle);
System.out.println("Going through array index: " + index);
}
}

FileOutputStream fileOut = new FileOutputStream("workbook.xls");
wb.write(fileOut);
fileOut.close();
}

}


my imageHandler class:

package excelArtist;

import java.awt.image.BufferedImage;
import java.io.File;
import java.io.IOException;

import javax.imageio.ImageIO;

import net.coobird.thumbnailator.Thumbnails;

public class imageHandler {

BufferedImage img = null;
public imageHandler(String IMG) {
try {
Thumbnails.of(new File(IMG))
.size(25, 25)
.toFile(new File("resized"+IMG));

img = ImageIO.read(new File("resized"+IMG));
} catch (IOException e) {
e.printStackTrace();
}
}

public int[][] convertImageToRGB() {

int[][] pixelData = new int[img.getHeight() * img.getWidth()][3];
int[] rgb;

int counter = 0;
for (int i = 0; i < img.getWidth(); i++) {
for (int j = 0; j < img.getHeight(); j++) {
rgb = getPixelData(img, i, j);

for (int k = 0; k < rgb.length; k++) {
pixelData[counter][k] = rgb[k];
}

counter++;
}
}

return pixelData;
}

public int getWidth(){
return img.getWidth();
}

public int getHeight(){
return img.getHeight();
}

private static int[] getPixelData(BufferedImage img, int x, int y) {
int argb = img.getRGB(x, y);

int rgb[] = new int[] { (argb >> 16) & 0xff, // red
(argb >> 8) & 0xff, // green
(argb) & 0xff // blue
};

//System.out.println("rgb: " + rgb[0] + " " + rgb[1] + " " + rgb[2]);
return rgb;
}

}
1
Add a comment...

Shelby Shum

Shared publicly  - 
 
http://www.usatoday.com/story/life/people/2014/04/16/rapper-attempts-suicide-in-most-bizarre-way-possible/7786821/

Guess he's starting a No-Wang-Clan, ain't got shit to fuck with. Literally.
Horrifying story emerging from LA about rapper who cut off penis and jumped off a building.
1
Add a comment...

Shelby Shum

Shared publicly  - 
 
Time to slim it down a tad fellas.
 
Had to post this. I just love it~
5
2
Shirley Shum's profile photoTy Stagg's profile photoJason M's profile photoRob Watkins's profile photo
2 comments
 
That's a fat pussy!
Add a comment...
 
EVERYONE, I NEED HALP. ESPECIALLY YOU CAT ENTHUSIASTS! 

So I've been in contact with http://www.sharlottcattery.com/ to try and acquire a Scottish Fold kitten some time this year. The pricing is as follows:

    "The price is 900 for straight red color boys, 1000 for cream straight boy and 1250 for folded ears girls."

Now then. I HAVE NO IDEA WHAT I SHOULD DO!!! I really like Scottish Fold cats, and I really want to get one. But everyone I talk to keeps telling me how steep the price is and how they would NEVER pay that price for a cat. Humans! Help me make my decision, or provide me some feedback as to what I should do. OR! If you know of a better alternative, I'm all ears! 

#scottishfold   #cat   #breeders   #inquiry  
1
Add a comment...
Have him in circles
816 people
 
Dear educators (especially you #TA 's, #Teachers / #Professors , and #Graders ), 

I offer you, a gradesheet generator. More specifically it takes an existing gradesheet (presumably in a .doc file) and generates a copy for each student. Of course it assumes certain parameters are set properly in the gradesheet before running. More specifically:

{Name}
{Section}
{Grader}

These fields within the document (sample in the rar file) will get replaced with the appropriate fields located in the graders and roster file. It is a purely console based program, so you'll have to bear with that. So what is this useful for? Say that you have 100 students, that means 100 homework submissions to grade. Now say that you have students from different sections..... And say you have several people grading these homeworks. Wouldn't it be annoying to have to manually copy and paste the gradesheet template and manually modifying the appropriate fields for each student? Well no longer. Just run the program, and all of the gradesheets will be generated for you. 

For all of those that are still: "wtf, why would I even use this?" don't worry. You probably won't find it useful. Only someone that has gone through the tedious hardships of manually copying and pasting the same file dozens times a week, and manually checking which section each student is in, would find this useful. 

Sample run:

Path for roster file: 
roster
Path to gradesheet: 
gr8.doc
Path to graders: 
graders
Which homework are we grading? 
8
ID: studentID
Name: FirstName LastName 
Section: 2
Group: 3
Ok
ID: fooba
Name: Foo Bar 
Section: 1
Group: 2
Ok
ID: bafoo
Name: Baa Foo 
Section: 2
Group: 1
Ok
ID: yawkitty
Name: Yawn Kitty 
Section: 2
Group: 2
Ok
ID: sdf
Name: Leo Lion 
Section: 1
Group: 3
Ok
ID: fhj
Name: Test Case 
Section: 1
Group: 2
Ok
ID: 3e5
Name: Rand Dom 
Section: 1
Group: 1
Ok
Your files have been saved to this directory: C:/Users/Shelby/git/gradesheetGenerator/gradesheetGenerator/allGradesheets


Feel free to tinker with it or do whatever you want. Will upload the source code to github some time in the future, for now, bear with google drive. 

How to run jar:
open terminal/cmd:
java -jar gradesheetGenerator.jar

Written in: Java
Used Libraries: Apache-POI 
Link to source code: http://goo.gl/dxIHpa
Link to Jar: http://goo.gl/dANvZm
1
Add a comment...

Shelby Shum

Shared publicly  - 
 
I have been inspired! So here's the deal, this is my own profile, and I don't really seem to have a niche, I post all sorts of random garbage, and they're all over the place. SO HERE'S WHAT I'VE DECIDED TO DO! 

From now on I will strictly follow these rules:

I will only make constructive posts about:

1. Programming/Software
2. Mobile Phones
3. Cats
4. Dark Souls.
5. Random life poopoo

Anything else will come in exceptionally rare. 

Why am I doing this? Well, I figured if someone's going to follow me because of a particular post -say Android related, I doubt they'll care about my problems in Puzzle and Dragons. As such, I will try and make my posts more constructive from now on. 
8
1
Caitlin Hanks's profile photoGahx Rose's profile photoShelby Shum's profile photo
2 comments
 
+Gahx Rose Don't worry, there will still be random life poopoo :D 
Add a comment...

Shelby Shum

Shared publicly  - 
 
Oh shit.. this one "hit" me hard.. heh... hehe... OK, inappropriate. Seriously, don't text and drive.
8
2
Alexander Moy's profile photowayne clark's profile photoGahx Rose's profile photoShelby Shum's profile photo
3 comments
 
+wayne clark :( it really is. 
Add a comment...

Shelby Shum

Shared publicly  - 
 
Some guy took his camera, put it in a plastic bottle... and recorded this. Pretty sick.
1
Add a comment...

Shelby Shum

Shared publicly  - 
 
Uhh... +T-Mobile I just got this text that redirects me to... A page not found?

EDIT: Ah! Nevermind, seems like I was clicking too fast. But wait! What changes am I getting?! I already had unlimited everything in the first place, am I getting a lower bill then? Also <3 you +T-Mobile 
4
Kevin Klerx's profile photoShelby Shum's profile photo
6 comments
 
+Kevin Klerx It's fine, need some hyper here and there. 
Add a comment...
People
Have him in circles
816 people
Work
Occupation
Software Developer
Skills
I code
Employment
  • JPMorgan Chase & Co.
    Software Developer, 2012 - present
    Software Developer
  • Syracuse University
    Grader, 2013 - present
    Introduction to Computer Engineering
  • Syracuse University
    AEW, 2011 - 2012
    Engineering Math and Introduction to Computer Engineering
Basic Information
Gender
Male
Other names
岑剑神, Shelby Shum, Stupid Fat Cat
Story
Tagline
“A perfect society is always found elsewhere”
Introduction
3DS FC: 3239-3632-8061
PAD/パズドラ: 385,008,305
モンスト: 245404760 
Dogecoin: DHkfkr2xo1jatXYUttuWVEL9qdb5i5Judj 

  • This hand of mine glows with an awesome power! Its burning grip TELLS ME TO DEFEAT YOU! TAKE THIS! My love, my anger, and ALL MY SORROW! SHINING FINGER SWORD! GO! GO! GO!


Bragging rights
I don't brag
Places
Map of the places this user has livedMap of the places this user has livedMap of the places this user has lived
Currently
NY, Syracuse
Shelby Shum's +1's are the things they like, agree with, or want to recommend.
ClipConverter.cc
plus.google.com

Free Online Media Conversion

Naughty Dog Salaries
www.glassdoor.com

190 Naughty Dog salary reports. A free inside look at Naughty Dog salaries posted anonymously by employees.

OnePlus
plus.google.com

We make smartphones. Help us make them the best the world has seen.

pymo
market.android.com

pymo (Python Memories Off) 是一个针对手机设计的AVG游戏引擎。可以使您不用懂得编程也可以较为方便地制作出一款简单的AVG游戏。 用户可以访问pymo.github.io获得pymo的开发文档,以及其他人制作好的游戏。

Find 7a Midnight (US Version)
oppostyle.com

Buy and view details about Find 7a Midnight (US Version)

OppoStyle.com
plus.google.com

Your online source for OPPO smartphones

Brave Frontier
market.android.com

DOWNLOAD FOR FREE the MOST ANTICIPATED classic style role-playing game for the Android!Venture forth into Grand Gaia, the world of the gods,

Online RPG Celes Arca
market.android.com

Online RPG (MMORPG) with 10 trillion dressing patterns Over 10 trillion character making patterns! Full-scale 3D online RPG playable on your

Office Mobile for Office 365
market.android.com

Please note: Office Mobile requires a qualifying Office 365 subscription. (See requirements below).Microsoft Office Mobile is the official O

┌(┌ ^o^)┐<ホモォいじり
market.android.com

人気キャラクター「ホモォ┌(┌ ^o^)┐」を育成するアプリです。 薄い本をあげると喜びますが、お風呂に入らないと世間体が下がってしまいます。 萌えゲージ・世間体ゲージを上げながらどんどん進化させていきましょう。※端末時刻の変更などは当アプリの正常動作保証外とさせていただきます。

The Wrath of Vajra
market.android.com

Former Shaolin monk and martial arts action star Xing Yu is Vajra, a child kidnapped and trained as an assassin during WWII. He escapes – an

マックスむらい 【毎日更新】むらいチャンネル・日記が読める!
market.android.com

『マックスむらい』は、マックスむらいの動画や日記をすぐに読めるアプリです。 === マックスむらいとは? === 1981年12月11日生まれ 石川県出身 AppBank株式会社 代表取締役 / AppBankGames株式会社 取締役 パズドラのニコ生やYoutuberとして活

瀬戸弘司 / Koji Seto
plus.google.com

瀬戸弘司のGoogle+ページです。

LINE: Llama y mensajea gratis
market.android.com

¡Llama y envía mensajes totalmente gratis y sin límites! LINE es una nueva aplicación con la que puedes llamar y mandar mensajes con emojis

RPGアヴァベルオンライン MMOアクションロールプレイング
market.android.com

Android端末、Androidタブレット、Google Play game service 「実績」「リーダーボード」対応 弊社最高峰グラフィックで遊べるアクションオンラインRPG「アヴァベルオンライン」 「アヴァベルオンライン(AVAVEL ONLINE)」はスマートフォン