RSS Amplifier

Blog

Daniel's Assorted Musings

dannyadam.comRSS feed ↗10 posts

Latest posts

colortrans

colortrans is a color transfer Python library that I recently implemented. It includes an assortment of algorithms for transferring the colors from a reference image to a content image while preserving the qualitative appearance of the content image. I ve written a document, colortrans.pdf, that describes the implemented algorithms. The library is available on PyPI and can be [ ]

nvim-scrollview

I recently implemented nvim-scrollview, a Neovim plugin that displays interactive scrollbars. The scrollbars serve as a visual aid, which can be helpful in addition to the position information already provided in the status line. The main features are 1) handling for folds, 2) support for mouse dragging, and 3) partial transparency so that text is [ ]

Auto Highlight Updates

Auto Highlight—discussed in a prior post—was released over five years ago, on April 24, 2015. The browser extension is intended for automatically highlighting the important content on article web pages. As shown by the GitHub contributions chart below, development was mostly inactive for a few years following the initial release. I ve recently added additional features. [ ]

revdoor

revdoor is a single-file C++ library for visiting revolving door combinations. The combinations without replacement generator implements Algorithm R from TAOCP 7.2.1.3 [1]. The combinations with replacement generator implements the same algorithm, modified to support replacement. The algorithms visit combinations by indicating at most two pairs of items to swap in and out on each [ ]

vim-startuptime and vim-win

I recently implemented two Vim plugins (they also work on Neovim). vim-startuptime vim-startuptime is a plugin for viewing Vim startup event timing—reported in milliseconds. This can be helpful when trying to modify your configuration to improve Vim s startup time. Launch vim-startuptime with :StartupTime. Press space on events to get additional information. Press enter on sourcing [ ]

gifcast Color Profiles

gifcast—discussed in a prior post—now supports color profile selection. The following animated GIFs—generated with gifcast—show a sample of available profiles. Here is the asciinema cast file used to generate the animated GIFs: profile_demo.cast

gifcast

I implemented gifcast, a web page for converting asciinema casts to animated GIFs. Here’s the link:https://dstein64.github.io/gifcast/ The JavaScript source code is available on GitHub:https://github.com/dstein64/gifcast The example below was generated with gifcast. Here is the asciinema cast file used to generate the animated GIF: gifcast.cast

Compressing VGG for Style Transfer

32-bit float (no quantization) 8-bit 7-bit 6-bit 5-bit 4-bit 3-bit 2-bit 1-bit I recently implemented pastiche—discussed in a prior post—for applying neural style transfer. I encountered a size limit when uploading the library to PyPI, as a package cannot exceed 60MB. The 32-bit floating point weights for the underlying VGG model [1] were contained in [ ]

SMAWK in C++

I recently implemented kmeans1d—discussed in a prior post—for efficiently performing globally optimal 1D k-means clustering. The implementation utilizes the SMAWK algorithm (Aggarwal et al., 1987), which calculates argmin(i) for each row i of an arbitrary n × m totally monotone matrix, in O(m(1 + lg(n/m))). I ve factored out my SMAWK C++ code into the example [ ]

kmeans1d: Globally Optimal Efficient 1D k‑means Clustering

I implemented kmeans1d, a Python library for performing k-means clustering on 1D data, based on the algorithm from Xiaolin (1991), as presented by Grønlund et al. (2017, Section 2.2). Globally optimal k-means clustering is NP-hard for multi-dimensional data. Lloyd s algorithm is a popular approach for finding a locally optimal solution. For 1-dimensional data, there are [ ]