Posts

Showing posts with the label PDF

tex2pdf: TeX Viewer Online - Compile LaTeX to PDF in Your Browser

Image
tex2pdf is a free, static web app that compiles LaTeX and shows the result as a PDF entirely inside your browser. There is no account, no install, no server, and nothing is uploaded. You drop in a .tex file and get a PDF back. It works by running busytex, a WebAssembly build of TeX Live, in a Web Worker. Your files are written into an in-memory filesystem, compiled locally, and the resulting PDF is rendered with PDF.js. Because everything runs client side, your document never leaves your machine. You can upload a single .tex file, several files together (figures, .bib, .cls), or a .zip of a whole project. It auto-detects the main file, runs BibTeX when a .bib is present, and offers two engines: XeLaTeX (the default, most reliable in the browser) and pdfLaTeX. A live timer and progress bar show loading and compilation. The site also bundles small client-side tools that load only when opened: a code beautifier and syntax highlighter, a file and PDF comparison (diff) tool, and a local...

Technical-eBooks: A Free Curated Collection of Programming eBooks

Image
Technical-eBooks A free, curated collection of programming eBooks Technical-eBooks is a free, openly shared collection of technical eBooks for learning new technologies. It is one of the most popular repositories in the Computer Tips organization, and it gathers programming and computer-science PDFs in one place so you can browse and download what you need. What it is The repository collects materials for learning new technologies, with individual books ranging from about 1 MB to 25 MB. Everything is shared under the GPL-3.0 license. How to browse and download Browse the catalog on the project page: com-puter-tips.github.io/Technical-eBooks Or open the repository directly and download any file: github.com/com-puter-tips/Technical-eBooks To grab everything at once, clone the repo (note it is large because it contains many PDFs): git clone https://github.com/com-puter-tips/Technical-eBooks.git Links Repository: github.com/com-puter-tips/Technical-eBooks Browsable index: c...

Where to Publish Your Research for Free: One Platform per Content Type

Image
When you want to share your research with the world for free, the trick is matching each type of output to the platform built for it. Posting a dataset to a preprint server, or a manuscript to a code host, only makes your work harder to find and cite. Here is a simple map: one well-established, free, public platform for each kind of academic content. Free Platforms for Public Academic Content One go-to tool for each type of research output arXiv Preprints — un-reviewed manuscripts Zenodo Datasets — raw research data ResearchGate Academic papers — author PDFs PubPub Open journals — academic HTML & rich text Figshare Supplementary media — figures & charts GitHub Research software — code & scripts OSF Study protocols — pre-registrations Protocols.io Lab methodologies — step-by-step recipes Wikiversity Open courseware — lecture notes & slides DSpace Institutional output — theses & dissertations Eve...

Remove Active Content (Links) from a LaTeX PDF Using Ghostscript

Image
Terminal — flatten a LaTeX PDF $ gs -dNOPAUSE -sDEVICE=pdfwrite \\ -sOUTPUTFILE=NEW_FILE.pdf -dBATCH in.pdf Processing pages 1 through 3. Page 1 ... Page 2 ... Page 3 NEW_FILE.pdf active links removed A PDF produced from LaTeX often carries "active" content: clickable hyperlinks, internal cross-reference links, bookmarks, and sometimes form fields or embedded JavaScript. When you need a flat, static PDF for printing, archiving, or submitting to a system that rejects interactive elements, the simplest reliable tool is Ghostscript. This tutorial shows how to strip that active content by re-distilling the file through Ghostscript's pdfwrite device. Step 1: Install Ghostscript On macOS, install it with Homebrew: brew install ghostscript On Debian or Ubuntu use sudo apt install ghostscript ; on most Linux distributions Ghostscript is packaged as ghostscript and provides the gs command. Step 2: Re-distill the PDF Run the source PDF back through Ghostscript...

[How To] Take ICAO 630*810 Photo

Image
ICAO Passport Photo: 630 x 810 px 630 px 810 px Specification ✓ Format: JPG ✓ Dimensions: 630 x 810 pixels (7:9) ✓ File size: about 10 KB to 250 KB ✓ Background: plain, light, no shadow ✓ Face: centred, neutral, eyes open ✓ No glasses glare; remove if unsure iPhone → convert HEIC to JPG → crop in Paint → compress Several Indian government photo uploads, including Passport Seva and OCI services, expect a digital photograph that is exactly 630 x 810 pixels, follows ICAO face-geometry rules, and stays under a strict file-size limit. You do not need a studio or paid software for this. With a recent iPhone, a plain wall, and the built in Paint app on Windows, you can produce a compliant photo in a few minutes. This tutorial walks through the full process. What the photo has to satisfy Before editing, it helps to know the target. An ICAO-style passport photo for these portals generally needs to be 630 pixels wid...

[How To] Print with staples in macOS

Image
Step 1/3: If you have opened a PDF from Google Chrome, go to the Print dialogue box and click on the link "Print using system dialog.." Step 2/3: Click on the dropdown menu that says "Media & Quality" and change it to "Finishing Options" Step 3/3: Click on Staple dropdown options and select the number of staples and the orientation where you want the pages to be stapled.

[How To] Save as an unlocked PDF

Image
Steps to save a locked (password protected) PDF as an unlocked PDF: Download / Save / Copy the locked PDF to a folder Open Google Chrome Go to File Menu >> Open File >> Select your locked PDF Enter password Click on the Print button and select Save as a PDF The saved PDF will be unlocked This trick removes the open password from a PDF you can already open, by opening it in Google Chrome, entering the password, and then printing it back to a new PDF without protection. It only works when you know the password and are allowed to access the file, so it is for convenience, not for bypassing protection you are not entitled to remove.

Create PDF from Python

Image
I was googling for a python library that I can use to write strings to a PDF file but mostly I found out programs to copy data from one PDF and write it to another PDF, another programs and solutions I found were for editing existing PDF, it was not what I was looking for. I wanted to create a PDF from scratch. After hours of searching finally I found my solution when I arrived on this page by David Fischer and it just uses one module called reportlab . Code is share via this gist on my GitHub.

TypeError: write() argument must be str, not bytes

Image
Recently I encountered this error: "TypeError: write() argument must be str, not bytes" when trying to write a PDF file from anaconda 3. The solution was to write stream in binary. Error: J:\>python pdf.py Traceback (most recent call last):   File "pdf.py", line 31, in <module>     fd.write(buf.getvalue()) TypeError: write() argument must be str, not bytes Problem code: # Write the PDF to a file with open('test.pdf', 'w' ) as fd:     fd.write(buf.getvalue()) Solution: # Write the PDF to a file with open('test.pdf', 'wb' ) as fd:     fd.write(buf.getvalue()) Ref.: http://stackoverflow.com/a/5513856 This Python error happens when binary data is written to a file opened in text mode, which is common when producing a PDF or other binary output. Opening the file in binary mode, for example with the wb flag, lets you write bytes directly and resolves it. Writing text to a file opened in binary mo...

Generate word cloud in R

Image
TEXT (.txt) This working script was tested on R 3.2.5 . Code is adapted from https://github.com/gimoya/theBioBucket-Archives/blob/master/R/txtmining_pdf.R . It reads a text file, processes it to remove unnecessary words and plots it. Code: library(tm) library(wordcloud) library(Rstem) filetxt <- "C:\\Users\\310211146\\Documents\\Other\\May_Report.txt" txt <- readLines(filetxt) txt <- tolower(txt) txt <- removeWords(txt, c("\\f", stopwords())) corpus <- Corpus(VectorSource(txt)) corpus <- tm_map(corpus, removePunctuation) tdm <- TermDocumentMatrix(corpus) m <- as.matrix(tdm) d <- data.frame(freq = sort(rowSums(m), decreasing = TRUE)) d$stem <- wordStem(row.names(d), language = "english") d$word <- row.names(d) d <- d[nchar(row.names(d)) < 20,] agg_freq <- aggregate(freq ~ stem, data = d, sum) agg_word <- aggregate(word ~ stem, data = d, function(x)   x[1]) d <- cbind(freq...

Introduction to R (Download PDF)

Image
Download Link: https://drive.google.com/file/d/0B_HnjRcH9aTpNG10ME1raW0zdTA/view?usp=sharing (Click this link to download pdf) This PDF is a part of Introduction to R workshop conducted by Chris Bruno , Dason Kurkiewicz and Adam Loy from Department of Statistics, IOWA State University on 15 July 2010. Reference: http://streaming.stat.iastate.edu/workshops/r-intro/ Breakdown of chapters is as following: 1. Introduction 2. Data Management 3. Graphics 4. Models 5. Programming 6. Advanced Manipulations Reference: http://streaming.stat.iastate.edu/workshops/r-intro/lectures/ This post shares a downloadable PDF introduction to R from a statistics workshop, aimed at newcomers to the language. R is a free environment widely used for statistics, data analysis, and graphics. A guided introduction like this is a good starting point before moving on to packages such as ggplot2 and dplyr for visualization and data wrangling.

375 Mime Types for Microsoft IIS (C#)

Image
File Extension Mime Type .323 text/h323 .3g2 video/3gpp2 .3gp2 video/3gpp2 .3gp video/3gpp .3gpp video/3gpp .aac audio/aac .aaf application/octet-stream .aca application/octet-stream .accdb application/msaccess .accde application/msaccess .accdt application/msaccess .acx application/internet-property-stream .adt audio/vnd.dlna.adts .adts audio/vnd.dlna.adts .afm application/octet-stream .ai application/postscript .aif audio/x-aiff .aifc audio/aiff .aiff audio/aiff .appcache text/cache-manifest .application application/x-ms-application .art image/x-jg .asd application/octet-stream .asf video/x-ms-asf .asi application/octet-stream .asm text/plain .asr video/x-ms-asf .asx video/x-ms-asf .atom application/atom+xml ...