HNHacker News
TopNewBestAskShowJobs

tylermw

1,012 karma · joined January 8, 2018

https://www.tylermw.com
submissionscomments
tylermw··on Show HN: Pathtracing Neon Landscapes in R
Author here, just wanted to show off an example of using my pathtracing R package, rayrender. Here's a link to the Github page:

Github:

https://www.github.com/tylermorganwall/rayrender

And here's the pkgdown website that includes the documentation and examples:

https://www.rayrender.net

tylermw··on Show HN: A library for custom scientifically accurate 3D models of SARS CoV2
For R packages the license is specified in the DESCRIPTION file.

See https://cran.r-project.org/doc/manuals/r-release/R-exts.html...

tylermw··on Show HN: A library for custom scientifically accurate 3D models of SARS CoV2
I created this R package because I kept on seeing awful 3D models of the virus out there (worst offender: a ball with what looked like toilet plungers sticking out of it). When I tried to find a good model, I realized people had just been taking the first free resource they found. So I created a package to easily output OBJ files with custom vertex colors, using a model that was approved by the National Institute for Allergies and Infectious Diseases (NIAID).

Being an OBJ file, you can render it in whatever software you want, but I also included example code in the docs/README to show how you can render it with rayrender, a pathtracer in R. Only takes two lines of code to set up a scene and render it.

You can see some higher quality moving examples at this Twitter thread: https://twitter.com/tylermorganwall/status/12482377944404828...

tylermw··on Finland to give dads same parental leave as mums
Replace your child with a full grown adult and you BET I'm ignoring someone trying to chat me up while I'm hustling to work in the morning :)

Just saying, don't take other adults not interacting with your child as some overarching statement about gender in society.

tylermw··on You have a set amount of “weirdness points” – spend them wisely (2014)
And yet, some people are able to live remarkably "weird" lives, influence and change their communities, and not feel like they have to relegate their appearance to "bland tech office drone" because they choose to be passionate about some number of topics and they used up all their "weirdness points" and have none to delegate to appearance.

Life isn't the Skyrim avatar creator--passion isn't measured in points, and passion is what begets structural change.

tylermw··on About Bokeh
Thanks for the shoutout!
tylermw··on Why Taxpayers Pay McKinsey $3M a Year for a Recent College Graduate Contractor
> There are a lot of very "experienced" 23 year olds

By the definition of the word--no, there aren't. You can have talented, capable, and driven 23 year olds, but not "very experienced." Given a working adults life spans approximately 40-50 years, a 23 year old claiming that title is laughable (exceptions being musical prodigies and athletes who have trained from childhood).

tylermw··on Review of 737 Max Certification Finds Fault with Boeing and FAA
The Chemical Safety Board is great at this as well. Great reports and long animations explaining what led to industrial accidents.

Explosion and Fire at Williams Olefins Plant, Geismar, Louisiana, video (11 minutes long): https://youtu.be/Z1KaykPaF8M

tylermw··on R is a joy if you treat it like Awk
I was just doing this yesterday--the "base R" way would be to simply use readLines() and grep through the same way you would in the command line. You're right though, grep + awk are super useful and parsing larger-than-memory logs is where they really shine and the shortcomings of R become apparent.

However, if your data fits in memory and you have a non-trivial analysis to perform, R is a great choice. I had a file with tabular data interspersed with metadata at random points and it was straightforward to parse and store the data in a custom data structure.

tylermw··on R is a joy if you treat it like Awk
"R is only great if your data is already great."

Disagree. R has an incredible ecosystem for parsing, cleaning, and manipulating data. Even ignoring the tidyverse, base R provides more than enough functionality to clean and analyze data--you just need to spend some time learning it. If you use the tidyverse, it's even easier. The only other ecosystem that comes close to R is Julia, which was designed taking many of the best parts of R into consideration.

tylermw··on An opinionated view of the Tidyverse “dialect” of the R language
That was my comment, and the point wasn't that the R code still ran four years later--the point was that R Core's focus on backwards compatibility (in reference to R being hamstrung via its focus on "compatibility with S") isn't a bad thing. You're never going to get the 2.x - 3.x schism that python had with future version of R, assuming R core continues with that philosophy.
tylermw··on Matlab vs. Julia vs. Python
There's no such thing as a deterministic experiment. There are so many sources of uncertainty in all fields of experimental physics, and statistics can help quantify and even design better experiments. It's just a shame statistics has never become a part of the standard physicist's education.
tylermw··on Matlab vs. Julia vs. Python
> Most physicists I know would invoke "But we use probability in quantum mechanics all the time!"

I have absolutely heard that one before :-)

tylermw··on Matlab vs. Julia vs. Python
Oh, I know (I have a PhD in physics)--but I'd say the main reason statistics isn't used in most fields of physics isn't because it wouldn't help, but rather because most physicists don't know much about statistics.

And publication-wise, it's a bit of a chicken and the egg problem: since most reviewers are also not well-versed in statistics, they are less likely to accept a paper that uses statistical methods to confirm or reject a hypothesis. Thus, there's no institutional pressure for a physicist to learn statistics.

(And a graduate course in statistical mechanics does not count, saying that as someone who used to use that excuse)

tylermw··on Matlab vs. Julia vs. Python
R has interfaces for Fortran, C, and C++ as well. Quite good ones, in fact.
tylermw··on Matlab vs. Julia vs. Python
Except there's a whole field of statistics called Design of Experiments, which describes the mathematical basis for how to create a good experiment :-)
tylermw··on Matlab vs. Julia vs. Python
That's not a true statement. R has packages for a wide variety of fields--statistics is just the most well developed.

And an important aspect of scientific computation is data visualization, an area in which R is decidedly more advanced than other languages.

tylermw··on Matlab vs. Julia vs. Python
There is one nice thing about R core's focus on maintaining backwards compatibility, however: code from a decade ago (more often than not) will run without a hiccup on current versions of R.

Related tweets:

https://twitter.com/hrbrmstr/status/1124016682413039616

https://twitter.com/hrbrmstr/status/1122186751987073025

tylermw··on Show HN: 3D ggplots in R with rayshader
Not that computationally heavy--usually takes under a minute to draw all the polygons and render the shadow map.
tylermw··on Student Journalists Expose High School’s Use of Prison Labor
All fine and good until you're in that 1%. Then you might have a slightly different opinion on forced unpaid labor for someone else's profit, otherwise known as slavery.

But seriously, I see that 1% and it solidifies why prison populations should not be subject to forced labor for profit. That is not a low number.

tylermw··on Show HN: 3D ggplots in R with rayshader
Author here. Rayshader is an R package for mapping and 3D data visualization, and I've been working on this feature for a while now. Here are links to previous posts I've made on HN about the package:

Show HN: A raytracer to shade, plot, and 3D print topographic maps in R, part 4 http://www.tylermw.com/3d-printing-rayshader/

Show HN: A raytracer to shade and visualize topographic maps in R, part 3 http://www.tylermw.com/3d-maps-with-rayshader/

Show HN: A raytracer to shade topographic maps in R, Part 2 http://www.tylermw.com/making-beautiful-maps/

Show HN: A raytracer to shade topographic maps in R http://tylermw.com/throwing-shade/

tylermw··on Pock: Display macOS Dock in Touch Bar
The logos are completely different (curvature, colors, extra circle). I don't think there's anything to worry about here. Patreon doesn't have a monopoly on logos that look vaguely like a P.
tylermw··on Depth of Field
Nice. I created a package to generate similar depth of field images in R, using a depth map/image pair. Also offers customizable bokeh shape and some other nice features.

Github: https://github.com/tylermorganwall/rayfocus Blogpost: https://www.tylermw.com/portrait-mode-data/

tylermw··on A book to learn R and Python in parallel for Data Science
No, I'm not. I'm well aware of CUDA being used to accelerate raytracing. That cannot be accomplished by simply providing a GPU-accelerated data frame structure, as cuDF provides.
tylermw··on A book to learn R and Python in parallel for Data Science
The bottlenecks for raytracing are primarily in scene traversal/intersection testing--which does not benefit from a GPU-accelerated array structure.
tylermw··on A book to learn R and Python in parallel for Data Science
> That raytracing example you linked would run at interactive rates with cudf, I really don't see any basis for perf arguments in R's favour, and 'massive data' arguments are laughable here.

I don't see how the "GPU DataFrames" provided in cuDF would enhance a raytracer in any way.

tylermw··on A book to learn R and Python in parallel for Data Science
They are the same thing, minus the corner case of assignment within a function call:

e.g.

  divide = function(x, y) {
    return(x/y)
  }

  divide(y = 2, x = 1)
  divide(y <- 1, x <- 2)

These two calls give the same result, as the second results in assignment and then passing the argument by position. Other than this case, they are exactly interchangeable.
tylermw··on Show HN: Rayrender, an open source R package to craft and raytrace 3D scenes
Author here, you can see the repo and browse the documentation and see more examples using the links below.

Github:

https://github.com/tylermorganwall/rayrender

Website (browse the documentation and examples):

https://www.rayrender.net

tylermw··on Lego Mosaics Using R
This stems from a limitation of rgl—if rgl ever gets around to supporting a virtual frame buffer (which has been in rgl’s TODO document for a while), rayshader would support that feature.
tylermw··on Lego Mosaics Using R
The license information for R packages is specified in the DESCRIPTION file for a "standard" open source license--this project is licensed under MIT, as specified there. For the MIT license, you need an additional LICENSE file that just states the copyright holder and year, which is exactly what the author has provided.
← PreviousPage 4 of 6Next →