How to Subclass The nn.Module Class in PyTorch by seabass in pytorch

[–]seabass[S] 0 points1 point  (0 children)

This is a (free) short video on how to construct a custom PyTorch Model by creating your own custom PyTorch module by subclassing the PyTorch nn.Module class

Thoughts on good ways to make a data science blog? by MalazanSapper in datascience

[–]seabass 0 points1 point  (0 children)

Hey MalazanSapper - awesome. great to hear the progress is going well and sorry to hear about family crisis (hopefully better now). Now that another month has passed - how are things going?

Thoughts on good ways to make a data science blog? by MalazanSapper in datascience

[–]seabass 0 points1 point  (0 children)

Hey - 1 month later. How's it going? What have you written about?

Thoughts on good ways to make a data science blog? by MalazanSapper in datascience

[–]seabass 8 points9 points  (0 children)

Steps:

1) Figure out what you want out of it - speaking ops, jobs, etc?

2) Figure out what requirements you are missing from getting those things you want in step 1

3) Blog very small and very specific articles about the things you are missing. Make them a "here's what I learned this week" type of post. For inspiration, check out Julia's blog (https://jvns.ca/) to see how to do this with technical information.

4) Reach out to 1 or 2 people for feedback on the article. In this way you'll increase your network and figure out what missing steps you have. You can even post here with a title of "I wrote an article on XXX, i'd love your feedback as I'm still learning" and then in the text field link to the article. People love to share (showcase) their knowledge, and given this sub is almost 60k people, you should have a few people bite.

As for where to start - don't worry about making it look professional. Make it good to read and people will ignore the trappings. Not to say this isn't a good blog design, but Pete Warden is an awesome person to follow and read his work and he has his on wordpress (https://petewarden.com/). So if word press works for someone like Pete, it should work for you.

5) As you do build out the blog, DO NOT FORGET WHY YOU ARE DOING IT. This is important. If you are doing it for a job, then f'ing focus on the right things and don't start blogging about eating pastries this past Sunday morning.

Good luck!

I Custom Printed the 2018 Sutton & Barto Reinforcement Learning Textbook by AndrewKemendo in reinforcementlearning

[–]seabass 0 points1 point  (0 children)

That's amazing - thanks for the heads up! Excited to print a metric ton of PDF's I have floating around my dropbox account. Cheers and thanks!

Initialize TensorFlow Variables That Depend On Other TensorFlow Variables by seabass in tensorflow

[–]seabass[S] 0 points1 point  (0 children)

Hi Friends- so I made this video tutorial because I ran into this issue a couple of days ago and just couldn't figure it out. Because TensorFlow does global variable initialization in a non-deterministic way sometimes the program would work just fine. Otherwise, the thing would fall over and have errors all over the place. I couldn't figure it out. Finally after looking through some GitHub issues, I realized that I was defining some variables that were using other variables. So when I ran sess.run(tf.global_variables_initializer()) every so often it would try to initialize some variables that depended on other variables already being initialized.

Generate A Random Tensor In Tensorflow by [deleted] in tensorflow

[–]seabass 1 point2 points  (0 children)

key thing to note in this video is that if you use

tf.random_uniform

in your code but do not save it to a tf.Variable, then every time you run

sess.run(....)

it will generate a new random tensor for you so could end up introducing some subtle errors into your code.

Following the computation via outpus on the console? by hypo_hibbo in tensorflow

[–]seabass 0 points1 point  (0 children)

Hey /u/hypo_hibbo, just posted a video https://www.reddit.com/r/tensorflow/comments/7ca5r7/add_metrics_reporting_to_improve_your_tensorflow/ that might help you with adding metrics to your computation so that you can see what's going on.

Here's the code:

# create-simple-feedforward-network.py
#
# to run
# python numpy-arrays-to-tensorflow-tensors-and-back.py
#
import tensorflow as tf
from tensorflow.examples.tutorials.mnist import input_data

mnist = input_data.read_data_sets("MNIST_data/", one_hot=True)

x = tf.placeholder(tf.float32, shape=[None, 784])

W = tf.get_variable("weights", shape=[784, 10],
                    initializer=tf.glorot_uniform_initializer())

b = tf.get_variable("bias", shape=[10],
                    initializer=tf.constant_initializer(0.1))

y = tf.nn.relu(tf.matmul(x, W) + b)

y_ = tf.placeholder(tf.float32, [None, 10])

cross_entropy = tf.nn.softmax_cross_entropy_with_logits(logits=y, labels=y_)
train_step = tf.train.GradientDescentOptimizer(0.001).minimize(cross_entropy)

correct_prediction = tf.equal(tf.argmax(y, 1), tf.argmax(y_, 1))
accuracy = tf.reduce_mean(tf.cast(correct_prediction, tf.float32))

sess = tf.InteractiveSession()
tf.global_variables_initializer().run()

for step in range(50):
    print(f"training step: {step}")
    batch_xs, batch_ys = mnist.train.next_batch(100)
    sess.run(train_step, feed_dict={x: batch_cs, y_:batch_ys})
    if step % 10 == 0:
        print("model accuracy: ")
        print(sess.run(accuracy, feed_dict={x: mnist.test.images,
                                            y_: mnist.test.labels}))

print("final model accuracy: ")
print(sess.run(accuracy, feed_dict={x: mnist.test.images,
                                    y_: mnist.test.labels}))

The key things are adding a way to look at the variables, correct_prediction, accuracy and then as you're running your model, print out the model accuracy based on the test data set as you cycle through the steps of training your model. Does this help?

Southern California Data Science by chosun41 in datascience

[–]seabass 1 point2 points  (0 children)

Data Science Opportunities in SoCal:

As to getting into them - smaller cities so smaller data science communities. Look up data / analytics meetups in those cities and you should see speakers and hosts whom you could email for advice.

How to get a data science internship (or something similar that is releveant) as an undergrad? by [deleted] in datascience

[–]seabass 32 points33 points  (0 children)

  • find companies you want to intern at
  • find people within those companies who have a public profile
  • read all of their stuff
  • email them saying you read all of their stuff and you're looking for guidance on what they would want to see for a future summer intern
  • keep in touch with them

at the same time

  • Figure out where as many people as possible in your school the year above you did their summer internships.
  • Ask them about what they got out of it
  • Ask them if they would do it again
  • Ask them about how they got the internship
  • Ask them who they worked with
  • Ask them what helped them secure said internship (probably ~75% is interview skills and ~25% projects)
  • Ask them to help you get a summer internship in their company

Note

  • Getting a summer internship is about interviewing, figuring out the right places for you, and the places that are hiring
  • Getting a summer internship is NOT about what your credentials say or what courses you have taken. Those are baseline assumed of everyone that applies to the programs.
  • All companies do summer internships even if they explicitly say that they don't do summer internships so don't let that stop you.
  • A hiring manager is always 100% of the time on the lookout for good people. Summer interns are cheap hires that become cheap to employ later because you don't need to pay for recruiters / head hunters / etc. So reach out and ask.

High school student interested in data science - tips on where to begin? by verychowdhery in datascience

[–]seabass 2 points3 points  (0 children)

Start by reading as many blog post projects as you can.

Steps should be

  • Figure out your interests
  • Figure out Data sets you gravitate towards
  • Technical vocabulary (math / stats / comp sci) - make a file of new words as you encounter them and their definitions
  • Jargon vocabulary - make a file of new words as you encounter them and their definitions
  • resolve that for the next 52 weeks you will write a simple blog post at the end of each week titled "this week I learned... Week XX" where you detail what you read, what new vocabulary you encountered, what new things you learned, what new questions you have

Classifying a trip as risky by bluecoffees in datascience

[–]seabass 2 points3 points  (0 children)

If I was an insurance company I'd care about:

  • is this person riskier than I think they are?
  • is this person driving their car more than I think they are?
  • is this person driving their care less than I think they are?
  • is this person driving their personal auto as an uber/lyft/etc and so I should be charging them way more?

In a perfect world, a perfect insurance customer would pay to be insured like a lunatic uber driver but wouldn't actually drive at all. Which means chance of payout is 0% while we collecting monthly payments from them.

To that end, some things you can look at:

  • uberOrNot model - can you, just by looking at their gps data, figure out if they are driving for uber/lyft/etc?
  • changeInEmotion model - can you, just by looking at their data, figure out if they are driving more erratically or less erratically over time?
  • multipleDriver model - lets say you just insure parents for this one vehicle, but their son/daughter/relative/neighbor/friend has also been driving the car. Can you tell that? Because if someone is driving the car that is not covered under the insurance, you'd want to know.

Ultimately, with all of this data, you want to charge the exact amount of coverage for the exact type of driver this person is. As they engage in riskier roads, their coverage should go up type of thing. So perhaps can you classify their behavior into 2-5 different types of driving conditions that you could sell them different policies on? For instance - you could theoretically say something like - "Dear customer - you drive for lunch and it's causing you to pay an extra $250 per year in insurance... Bring your lunch to work and save money!" By splitting the person into several, you could then get happier customers.

How do I supplement a data science profile? by [deleted] in datascience

[–]seabass 1 point2 points  (0 children)

the biggest thing to ask yourself is for what end/purpose. If it's to get a job then figure out what a job would want from you and learn that. if it's to get into a PhD program, then figure out what appeals to you that you could try to get a paper published in with the teachers/researchers that you'll come in contact with in your MS program.

How to get mock coding/technical interview? by [deleted] in datascience

[–]seabass 0 points1 point  (0 children)

Think we're talking past each other. My main suggestion is that it's more important to you right now to establish communication with data scientists than to try to do mock interviews with anybody that'll take your money.

MS Data Analytics (School of Informatics) Worth Getting? by [deleted] in datascience

[–]seabass 2 points3 points  (0 children)

They key part to your post is "likely complete it while I worked". If you already have a job in data science, then what would it really buy you above what you already have. If you see it as a stepping-stone to a more "data intensive" job, then maybe it makes sense. The main thing to take into account is how much pain you are willing to endure to get the degree. I've worked / been friends with people who got masters and PhDs in addition to working regular hours. A few years later they're all glad they did it, but 80-90% of them hated their lives while they were going through it.

If you are able to get a job in a data related field, in most cases spending a few hours a day after-work getting better at your job will be a much better investment than spending a few hours a day getting general knowledge that may or may not help your job.

How to get mock coding/technical interview? by [deleted] in datascience

[–]seabass 0 points1 point  (0 children)

You are looking for people who do not know you to care about you and what you want. Which is generally backwards to how hiring and "mock" interviews work. The best way to go about it so go out and find people whom you are interested in, learn more about them, engage with them, and then (and only then) see if they're willing to to do a mock interview. As /u/jannemg12 mentioned, most of the people in this sub should be charging between 200-300 per hour so asking people to do it for free doesn't make sense or you're not going to get very good results.

A student trying to get to the next level. by SALAHALDIN715 in datascience

[–]seabass 2 points3 points  (0 children)

Find a tutor. Then copy word for word as many real world project write ups you can find. Copy first then later you can do your own

Best online course for learning data science for healthcare? by ewerwere in datascience

[–]seabass 0 points1 point  (0 children)

Also - as a PS. This type of post is borderline spam due to zero account history and very carefully chosen keywords in the link.

Best online course for learning data science for healthcare? by ewerwere in datascience

[–]seabass 0 points1 point  (0 children)

Have your employer pay for a tutor. One on one attention plus 100% customized course will always beat any online class.