For compressing pdfs, ghostscript works great. I use a command similar to this one,
Today I learned / realized / released.
See these posts by tags here.
See only the TIL photography posts here.
Sometimes I write something for a future date, and I want to then generate my website so I can see the new pages and check them, set up a script to rege...
I found out from the maintainer of the jekyll-scholar plugin that the way to change the style file or csl is with the --style flag. Link to GH issue.
I use predefined macros frequently for print debugging in C++,
I looked up screencasting today. This is something I do not do very often. This article HowtoGeek was good, and after fiddling around with some things, I go...
I used the ‘raw bitstream method’ of ffmpeg to increase the framerate of a video, see trac.ffmpeg.org for more details and options.
I wanted to slice one image into a bunch of smaller images – tiles – and of course did not want to do this manually. That means … ImageMagick! I’m going to ...
Today I learned about the history command. To get all of the options, type help history. Want to see a file of the history? That’s ~/.bash_history.
I am reading Richter-Gebert’s book (1, Richter-Gebert, 2011) and I keep on going back to the cross ratio formula. I’ll sketch some notes here for my o...
I was looking for a definition of the signature of a matrix, and Nick Higham had straightforward definition, The inertia of a real symmetric \(n \t...
I am reading Richter-Gebert’s book (1, Richter-Gebert, 2011) and I’m in the section on Involutions and Quadrilateral Sets (chapter 8). The involution ...
My Hyde configuration for this website never had the related posts working properly. I went on a mission to get related posts working, and thankfully Michell...
Back in 2020, I switched from Google Analytics to StatCounter for analytics of this website (AT: prior post). Since then, emphasis on privacy has increased ...
_site
directory?
08 Feb 2023
I’ve been asking the question in the title for a little while, in a couple of ways. It turns out it is easy to change the default directories when using Jek...
I discovered by accident some time ago, wandering through some .h files (solver.h), that the reason I couldn’t get Ceres to run in parallel despite having Op...
A short TIL – from a while ago, but I was reminded of it recently. Eigen has a page that describes how Eigen implements generalized matrix multiplation (GEMM...
Suppose you are setting up some heinous expression and you want Octave to simplify it, and that doesn’t happen. Why?
I forgot that I wrote a short MWE for getting videos to play in Beamer, the LaTeX presentation class, until someone forked the repository. The MWE is from 20...
I learned from Conor O’Sullivan that there is a post scheduler available for Mastodon. I was thrilled as I have been searching for a post scheduler since I ...
This is a short TIL about to rename photo files such that the date is appended to the beginning of the filename. In other words,
Mostly a page with a link – the reference page for if() and logical expressions is here, from CMake’s docs.
Disclosure: I’m having trouble getting preview cards to work. I’ll update this post when I figure it out. Hints? Let me know on Mastodon.
I read Gerrit Vyn’s Photography Birds: Field Techniques and the Art of the Image. 2020. ISBN13: 9781680510997.
In a TIL from yesterday, I mentioned that when I’m changing around the CMakeLists.txt file, my go-to troubleshooting strategy is to delete everything in the ...
Setting the compiler for a CMake project is a couple lines in the CMakeLists.txt file, and they have to go in a very specific place – before the project comm...
I had to mix C and C++ because I was using a C library for something, and forgot the syntax. IsoCPP has the guide; the short answer is to declare C functions...
I found the Graßmann-Plücker Relations / Grassmann-Plücker Relations / Grassmann-Pluecker Relations surprising when I read about them in Jürgen Richter...
I have wrangled with CMake for a few days; I needed to set compile options for all but one file in the target. After blundering for a while, it seemed like s...
It takes me a few days to write longer posts and I had this idea that there’s probably a way to generate the post locally, so I could see the formatting, but...
Cutting out a segment of video using ffmpeg is not hard, but I always forget the flags. NO MORE once I have written this today-I-learned / today-I-remembered...
It is possible to align equations to multiple places in latex, using alignat. However, the answers I found are mostly example-based. However however, I got ...
I recently learned how to create tables in latex that would allow a panel for notes at the bottom, in the style of many biology papers. The tool? threepartt...
Sometimes when compiling a document – say you’re added to the .bib file or really changed the sections – the document will not compile with pdlflatex because...
I want to be able to link to a pdf, and open at a certain page. This task was straightforward and worked on my machine! From Adobe, To target an HTML li...
I looked at a few methods for splitting a cell into multiple rows. I use tabular, and the easiest method for non-regular splits is to nest the desired split ...
I have never learned the keyboard shortcuts for Firefox – specifically switching tabs. I get frustrated if I need to do a lot of switching. But! The...
In computer vision, I find myself needing unit vectors, a lot. In other words, doing the following in C++, Vector3d v; // v's unnormalized value is c...
I love using the Ceres solver, but couldn’t figure out why when I computed the value of the cost function using my code, it was different from final_co...
I always forget the cmake syntax if it is anything below cmake ../src. Here are some common combinations, I usually create an Eclipse project with cmake and...
I have a paper that is getting long, and wanted to temporarily add a Table of Contents before the paper so I can see how the content is organized. This is p...
This post will contain some examples of numerically instable and stable methods for computing the sample mean and variance, with some references. Firs...
Today I learned about the condition number, \(\kappa\), of a sample \(\{ x_i \}\) of \(N\) data points, with respect to computing the variance. Previously,...
Previously, I learned about how in C++11 there are distribution generators (normal, uniform, etc.). The code examples for using those distributions used the...
When setting up cron jobs, there is a dow field, and I did not know how the days were numbered. For instance, what is the first day of the week? Sunday is ...
I learned from Twitter, Boris Knyazev that getting page numbers in the reference section where a reference occurred takes an argument to hyperref: \usepacka...
I was playing around on the Nikon site and noticed I could update the firmware of my camera, from Nikon’s download page. My camera is an older model, so I j...
Following up on a previous post about converting images to a TIFF with a specific dots-per-inch, or DPI, for large images it may be necessary to compress the...
Suppose you want to create a matrix (or vector) that has some scalars and some symbolic types, in Octave. (Short post about Octave’s symbolic computation pac...
I had this problem with beamer recently: I was using \begin{enumerate}, and I got this error:
I didn’t know the difference between a unitary and orthogonal matrix. They seemed to behave the same, so …?
To change directory in Windows from the command line, you need an extra flag: cd /d d:\myUsbDrive The /d changes the drive and the directory. Relevant St...
I was happy to learn that Octave has a symbolic computation package! I last used Matlab’s version in grad school to compute analytical Jacobians. To use, ha...
Some publications will request an image with a specific dots-per-inch, or DPI. You can do this conversion with ImageMagick: convert -density 600 image1.png ...
I had something like a | b that I wanted to use in MathJax. Usual latex will allow you to use |, but in my case, Markdown was interpreting the | as a ...
Given a \(m \times n\) matrix \(\mathbf{A}\), \(m \geq n\), what are the dimensions / sizes of the QR decomposition (full and reduced), and the SVD (fu...
I don’t do any development work on Windows. When a collaborator asked me how to rename a bunch of files on Windows, I didn’t know how to do it. Thankfully, ...
I saw a paper on arXiv, Lim2022, that used the ‘Atlanta world assumption,’ and since I didn’t know what that was, I learned about it today. From SD2004, the...
This is a today I learned and released – I updated an existing example to call a LAPACK function, and use Eigen data structures (MatrixXd, etc.), and output ...
I forget this one frequently. To write an assert in C++ with an error message, the following works: assert(a >= b && "a was less than b"); Rele...
In a previous post, I mentioned Eigen’s block function, which allows you to extract submatrices. But, in that post I was only aware and only wrote about th...
How do you get MathJax to output equation numbers, and maybe reference them with a number and hyperlink? Links: MathJax equation numbers docs. Ma...
I’ve had to change a lot of repositories to use ssh (instead of https), and I always forget how to do it. A real, in-depth post is from pandammonium. What ...
I’ve been going into this numerical methods vortex for a couple months, which may or may not turn out to have been a good thing – and am learning a lot. In ...
The pseudoinverse, sometimes more formally called the Moore-Penrose inverse ( Wikipedia ) is a general inverse for non-square matrices. When I encountered...
I’m fooling around more with Eigen, and remembered that the storage order is column-major, but wanted to confirm. Yes, the default storage order is column-m...
I typically use \quad to get more space in latex, and knew there were other space commands to use in-text, but had never remembered them past one use. Well,...
I went looking around for generators to produce normal distributions in C++. It turns out this has been a thing since C++11! and is in the std namespace. Yo...
How do you create two more more lines of text in one TikZ node? You need to include an align option, and use double backslashes. \node[draw, align=left] {Th...
Two issues come up on occasion with focus and auto-focus so I decided to write about them. The first is when I’m working with different lenses, but more fre...
I’m calling a program that I wrote, so it is under development and uses some print debugging. When I have runtime errors I can’t figure out, I use Valgrind. ...
Context: you’re writing in latex, and you want to crop an image used in a figure. Sure, you could do this in an editor, but cropping through latex allows yo...
I wondered how to create variables within a single HTML page. Why? I am working on a refactor of parts of my website, and in the process I want to make it ...
Whenever I needed to copy a submatrix in Eigen (the matrix library in C++), I would just walk through it with two for loops like it was 1998. BUT recent ex...
I relearned today that if you’re using an image for a Twitter card, the largest that image size can be is 2 MB. (I have some posts from 2018 on Twitter cards...
I was thinking that maybe C++ had some support for paths by now … something like Python. And it does, std::filesystem! It is in C++17, and a little funky to...
[photography]. A general frustration I’ve had out hiking with my 200-500mm lens is keeping the thing attached to the tripod or monopod. For some specs, this ...
I’ve been having trouble getting a Jekyll-generated site to generate locally on Ubuntu 20.04, and after a few weeks of using my container instead, finally go...
I had heard this long ago, and very recently tried it – that modern MS Office files can be renamed with the .zip extension, and then extracted. The result i...
I use the std::sort() function a lot for vectors in C++; I need a functor that compares the elements of the vector as the third argument. I knew there was so...
[photography]. The first time I cleaned the sensor on my camera, I freaked a little bit. I got it done! but then got quite intense about keeping the sensor ...
I wanted to have a listing of my TIL posts by tag or category, and it turns out that doing so is not too bad. Some links and the process below. I wanted to ...
[photography]. When digging through the manual I found another setting I could use while in manual mode, auto-ISO. For some reason, I had thought that manua...
As an answer to this question: “How do I copy files matching a pattern, all to a directory?”, the answer is: cp box*.JPG images in linux, where box*.JPG a...
I am redoing some segments of my website – probably a bad idea – and wanted to put in place some redirects in case people have bookmarks or something like th...
Even since I have learned about C++’s conditional ternary operators I have been using the heck out of them to create short code where if / then loops would...
[photography]. I’ve been shooting in manual mode for quite a while because I understood how shutter, aperture, and ISO values all combined to give the image’...
There’s this neat little tool to track down dead links in websites that I used a couple years ago and then somehow forgot about, LinkChecker. Install with ...
I’ve been transitioning over to a machine with Ubuntu 20.04 on it, tried to install Docker with sudo apt install docker and remembered, slowly, that is not...
[photography] A quick note, I was rather late in getting UV filters for all of my lenses. They are a lot less expensive than lenses, and many people use them...
Exiftool is this neat command line utility written in perl that can pull out a bunch of the metadata associated with images acquired by consumer-type devices...
I have been using OpenCV’s Rect class a lot this week and needed to really know what was going on with it. I suspected that in the absence of explicitly for...
This is a photography post. I have a new long lens for my DSLR camera, and especially with moving subjects the autofocus just spins and spins and never ‘cov...
Today, I wanted to change the width on an image, in a webpage, that was written in Github-flavored Markdown. Like, groan. I had read this page at some pre...
Eigen, the matrix library in C++, is so cool. Having written some of these functions during the 00s in my own code, agonizing about whether I got the subsc...
Supposing you want to see a whole directory of images, resized and smooshed together into one image. (Having a crash? New section.) This is easily done in ...
I have a weird configuration, one older GPU that is unsupported by PyTorch and one newer GPU that is supported by PyTorch. With Docker, I was able to specify...
Ever wondered what all the possible arguments to mogrify, ImageMagick’s batch command are? Check out this link. Then, to rotate a directory of images, the co...
Igal Tabachnik had a shitpost about YAML on Twitter. I didn’t totally get it, so I keep reading and was rewarded with not only understanding the shitpost, bu...
So I like to use \uncover commands to create dynamic presentations. But sometimes I just want to know how many pages the .pdf is without the additional pages...
This is a release – I released my version of Michael Kaess’ version of his AprilTags library, on Github. (Got that?) Michael Kaess’ version was public on Bi...
This is the Python newbie section. So I had a working virtualenv going, and I could import with a .py file, but put all of that in a Jupyter notebook and sud...
I was working on my personal computer and got a low disk space warning while playing around with some Docker images. So I went back to this blog post, Keepi...
I wanted to freeze a file in git, so that when someone commits, this file is not updated. The file is a user log file, so while we’re testing, it gets bigger...
Something that occasionally happens is there’s a version of software that is not compatible with your OS. Ok, just launch it with Docker! Well, not so fast,...
I wanted to add some small text to images, and got on this kick of using ImageMagick create small watermarks on a directory of images. Here’s the steps to d...
I love Image Magick and have been trying to learn more about it so I can use it more frequently. In particular, I resize directories of images so that I can...
You’re going to find some utterly newbie / neophyte - python / FastAI stuff in the TIL section (I don’t know, maybe I need more slashes?!) in the coming week...
In the days of yore, one had to go through this agonizing process of installing the NVIDIA (GPU) drivers, cuda, cuDNN libraries, and PyTorch. Ok, those days...
[This is more last week I learned …] about a new tool called Blacklight. The gist of Blacklight is, Who is peeking over your shoulder while you work, wat...
There’s been some discussion on Twitter about FastAI and Docker containers, so I went looking yesterday in the fastai section of GitHub to see if there were ...
If you are unlucky enough to have to use Microsoft’s Teams, and you use Linux, I am crying with you. This is how I got the desktop client to install. (The ...
I have been wanting to get rid of Google Analytics on my website. One, I am trying to reduce the Google-influence in my life, and two, I have to disconnect ...
I am a new user of RSS, and I wanted to set it up on my website. The template I use allows this easily in an atom.xml file for blog posts. But I have longe...
It took a while to pull up from the depths of memory this – how to get an image and text on the same line in HTML. Sounds easy, right? And really it is, wh...
(This is a ‘Today I Realized’.. post) I couldn’t get my website to generate locally with jekyll serve, which is a pain. I was playing around with another Je...
I’ve been working with two different AprilTag libraries. AprilTags are a 2D bar code used in robotics research mainly, originating from Edwin Olson’s lab (p...
I needed to do some video processing, as the videos were rotated 90 degrees. Turns out this is not a problem for ffmpeg! First, strip the sound, ffmpeg -i...
So part of getting this ‘Today I learned’ part of site going was getting a blog-style page generating, but not at the root page of the site. I had disabled ...
I saw a tweet from Hamel Husain, who mentioned Simon Willison’s TIL Github repository. (It turns out Simon was inspired by something he saw from someone else...
I discovered today that Image Magick has a C++ API! I’ve been using Image Magick’s command line tool more and more to do various tasks. Some of these things...