Skip to content

Instantly share code, notes, and snippets.

View rdapaz's full-sized avatar

ricdeez rdapaz

View GitHub Profile
@daveebbelaar
daveebbelaar / document_intelligence.py
Created July 13, 2024 07:08
A service class for interacting with Azure Document Intelligence API.
import logging
import requests
import time
from typing import Union, Dict
from config.settings import get_settings
class DocumentIntelligenceService:
"""
A service class for interacting with Azure Document Intelligence API.
@rdapaz
rdapaz / passphrase.md
Last active February 28, 2023 08:57
Generate Secure Passphrases

Steps for generating a secure passphrase

  1. Go to https://xkpasswd.net/s/
  2. Use the following settings:
{
"num_words": 3,
"word_length_min": 4,
"word_length_max": 8,
"case_transform": "ALTERNATE",
@rdapaz
rdapaz / MSProject.py
Created April 12, 2018 03:30 — forked from zlorb/MSProject.py
MSProject - Python
import sys, time, datetime
from copy import copy, deepcopy
from collections import OrderedDict
import string
import math
import win32com.client
import traceback
# Sample code for accessing MSProject
# 2014 (C) Zohar Lorberbaum
@rdapaz
rdapaz / win32com.client.py
Last active May 23, 2024 07:03
Fix for module win32com.gen_py has no attribute 'CLSIDToPackageMap'
# If errors are found, do this
# clear contents of C:\Users\<username>\AppData\Local\Temp\gen_py
# that should fix it, to test it type
import win32com.client
app = win32com.client.gencache.EnsureDispatch('Word.Application')
app.Visible = True
@ChrisTM
ChrisTM / ip.py
Last active April 20, 2022 09:35
Convert IPv4 addresses to and from integers
"""
Convert between various representations of an IPv4 address.
`ip` refers to a dotted string, like: `'127.0.0.1'`.
`octets` are indexables, like `(127, 0, 0, 1)`.
`int` is the integer representation, like `2130706433`.
Written for Python 2.7.
"""
@bradley219
bradley219 / .gitignore
Last active July 22, 2024 14:04
PID C++ implementation
.DS_Store