Skip to content

Instantly share code, notes, and snippets.

View ajhwb's full-sized avatar

Ardhan Madras ajhwb

View GitHub Profile
cd projects/
rm -rf googlex
@ajhwb
ajhwb / .py
Created May 16, 2022 03:56
test_list_closest
def test_list_closest(self, test_client: Client, test_dataset: Dataset):
n_clusters = 10
clusterer = test_client.ClusterOps(
alias="new_clustering",
model=MiniBatchKMeans(n_clusters=n_clusters),
)
clusterer.run(
dataset_id=test_dataset.dataset_id,
vector_fields=["sample_1_vector_"],
)
@ajhwb
ajhwb / libevent-example.c
Created September 9, 2012 17:17
Asynchronous network I/O using libevent
/*
* Libevent is a high-performance and portable asynchronous networking I/O library (http://libevent.org)
* This is small program to demonstrate the basic of libevent programming
*
* Copyright (C) 2012, Ardhan Madras <[email protected]>
*/
#include <event.h>
#include <arpa/inet.h>
#include <netinet/in.h>
#include <stdio.h>
int main(void)
{
return puts("hello git!");
}