gmmkmsock: gmmkmsock

Description Usage Arguments Value Note Author(s) References Examples

View source: R/interfaces.R

Description

perform k-means specifically designed for a set of GMM (see references). At each iteration, sends information about current prototypes to a server via a socket connection (see references) for info about protocol.

Usage

1
gmmkmsock(models, names, ngroups, rho = new.env(), host = "127.0.0.1")

Arguments

models

list of GMM objects.

names

character vector with respective names of the GMM objects.

ngroups

(maximal) number of clusters.

rho

R environment object, used for calls to R functions within C code.

host

IP address of the server for the socket (port 1979).

Value

a set of GMM prototypes, and inferred labels (i.e. associated to the input objects).

Note

gmmkmsock includes a socket client that sends formatted data to a server. Detailed information about this protocol may be found in the source package (inst/doc/old_manual.pdf). Simple standalone client and server are also provided (socket/socketclient.cpp and socketserver.cpp). These can be build by running make in the source folder.

Author(s)

Pierrick Bruneau

References

Bruneau, P. , Picarougne, F. and Gelgon, M. (2010) _Interactive unsupervised classication and visu- alization for browsing an image collection_, Pattern Recognition, Volume 43, Number 2, Pages 485-493.

Examples

1
2
3
4
5
6
temp1 <- sample(1:200, 150)
temp2 <- list()
for(i in 1:length(temp1)) temp2 <- appendToList(temp2, imgmods[[temp1[i]]])
temp3 <- imgnames[temp1]
# next command may be executed only if a server is running on 127.0.0.1:1979.
# temp4 <- gmmkmsock(temp2, temp3, 5)

VBmix documentation built on May 30, 2017, 2:34 a.m.

Related to gmmkmsock in VBmix...