Håvard Vegge <hava...@stud.ntnu.no> writes:

> I don't know what you mean with the issue "synchronization of program
> counters", but as far as my simple GUI application goes, it just
> works. At least for now...

Great! Tomas is currently lying at the beach in Barbados[1]..., but when
he get's back I hope he will share his experiences with GUI programs.

[1]: http://fc09.ifca.ai/

> Another question related to GUI; say we have n players which all have
> some secret input. Is it possible to make a progress bar of how many
> inputs that is currently submitted? Or is this information
> unavailable?

When you do

  a, b, c = runtime.shamir_share(range(1, n+1), Zp, my_input)

you can attach callbacks to the three shares. If self.pbar is a
gtk.ProgressBar something like this should do the trick:

  self.shares = 0

  def step(value):
      self.shares += 1
      self.pbar.set_fraction(self.shares / float(n))
      return value

  a.addCallback(step)
  b.addCallback(step)
  c.addCallback(step)

The idea is to make the callback update the progress bar, but otherwise
pass the value through unharmed.

-- 
Martin Geisler

VIFF (Virtual Ideal Functionality Framework) brings easy and efficient
SMPC (Secure Multiparty Computation) to Python. See: http://viff.dk/.

Attachment: pgpsjvv9AOgGF.pgp
Description: PGP signature

_______________________________________________
viff-devel mailing list (http://viff.dk/)
viff-devel@viff.dk
http://lists.viff.dk/listinfo.cgi/viff-devel-viff.dk

Reply via email to