fuzzyclust.large#

Fuzzy c-means for very large and streaming data.

Fuzzy c-means needs the whole data matrix and the \(N\times c\) partition in memory at every iteration. When \(N\) is in the millions, or when the data arrive as a stream, three schemes of Havens, Bezdek, Leckie, Hall and Palaniswami (2012) make FCM feasible while approximating its result:

Weighted, random-sample-extension, single-pass and online FCM.

Classes#

WeightedFCM([n_clusters, m, tol, max_iter, ...])

Weighted fuzzy c-means (wFCM): fuzzy c-means with a weight per sample.

RandomSampleFCM([n_clusters, sample_size, ...])

Random sample and extend FCM (rseFCM) for very large data.

SinglePassFCM([n_clusters, chunk_size, m, ...])

Single-pass fuzzy c-means (spFCM) for very large and streaming data.

OnlineFCM([n_clusters, chunk_size, m, tol, ...])

Online fuzzy c-means (oFCM) for very large and streaming data.

Functions#

extend_partition(X, V[, m, chunk_size])

Memberships of (many) samples in fixed prototypes (the extension step).

make_large_blobs([n_samples, n_clusters, ...])

Many samples from a few isotropic Gaussian clusters, in random order.

make_drifting_stream([n_chunks, chunk_size, ...])

A stream of chunks whose cluster centers drift from chunk to chunk.

plot_chunk_timeline(model[, feature, ax, ...])

Prototype coordinate against the chunk index for a chunked model.

plot_center_trajectories(X, model[, ax, ...])

Trajectories of the prototypes over the chunks on top of (a subsample of) the 2-D data.