## Where communities thrive

• Join over 1.5M+ people
• Join over 100K+ communities
• Free without limits
##### Activity
Vincent Valenti
@vincentv18
to be clear, we haven't figured out how to find a "unique" output. we just essentially eliminate duplicate circuits that have the same output
Christopher Findeisen
@Atrus7
Hey, team JV, would you like to Skype with Sam and I real quick to go over any questions you might have, or would you rather just have space to work?
jeregoorlino
@jeregoorlino
yeah let's skype.
jeregoorlino
@jeregoorlino
sam/chris, can i give one of you guys a call real quick. i have a question about your suggestion about having a vector that stores all of the previous outputs.
Sam Gwydir
@gwydirsam
Can you write it?
jeregoorlino
@jeregoorlino
okay
Sam Gwydir
@gwydirsam
We're pairing
jeregoorlino
@jeregoorlino
I'm not sure if we need a vector that stores the previous outputs because at each level, after we generate a new set of permutations that we need, the outputs will change. The way we have our code set up now, is that we evaluate the output of each new permutation one at a time, and compare it to every output of every circuit in the vector. If it doesn't match, then we add it in and move onto the next permutation and do the same thing that way we don't get any duplicates. So i'm not sure where we'd need the outputs of circuits already deleted because it'll change with each permutation that we add.
Sam Gwydir
@gwydirsam
Your vector of output sets keeps the unique output sets. Thats what you check to see if your next circuit's output set is unique.
Christopher Findeisen
@Atrus7
Just clarifying your use of "outputs". Output sets are the things you should compare..That is the three output columns, all together. So if two output columns in A and B are the same, but the other output columns are different, the output sets are different. Make sense?
jeregoorlino
@jeregoorlino
yeah i understand that chris. and thanks sam that makes sense
Christopher Findeisen
@Atrus7
Just an example of two inequal ouput sets
-------A------           != -----------B--------------
1 1 1                                1 1 0
0 0 0                                 0 0 1
1 1 0                                 1 1 0
0 0 0                                 0 0 0
jeregoorlino
@jeregoorlino
yeah thats how i visualized it in my head
Christopher Findeisen
@Atrus7
kk
jeregoorlino
@jeregoorlino
i just came up with an idea and i wanted to run it by you guys first and see what you think. since we're gonna compare the columns, column by column, if at any point, we get a column to match, we need to map that with chris's function and then only start generating circuits from that circuit in which we mapped something.
Sam Gwydir
@gwydirsam
not necessarily and probably not.
also do you guys check if you've used more than two nots?
also -- have a way to print your final circuit
so you can test it
jeregoorlino
@jeregoorlino
why wouldn't we do that though? because say one permutation at level 4, we match one of the output columns, the other relative permutations at that level won't have a matching column at that level, so it'll reduce the amount of circuits we have to populate because we just have to populate the one at level 4 that has a matching column.
and damnit, we're doing that right now.
Sam Gwydir
@gwydirsam
because just because you have one matching column doesn't necessarily mean that branch will contain a permutation that has all the rest
jeregoorlino
@jeregoorlino
okay. just running it by then. thanks.
Vincent Valenti
@vincentv18
I think generating the mapGatetoOutput correctly but can yall explain what the desired output index would be?
I think gate_index would be equal to getGateCount() - 1, right?
Vincent Valenti
@vincentv18
nevermind i think i understand
Sam Gwydir
@gwydirsam
why is it less than 3 not gates?
not <= 2
Sam Gwydir
@gwydirsam
If you guys are around
get that -A -B -C test in there
jeregoorlino
@jeregoorlino
its there now sam. and wouldn't < 3 be logically the same as <= 2?
Sam Gwydir
@gwydirsam
of course. and so is <= ( 8 % 2) but it's clearer from the spec
Sam Gwydir
@gwydirsam
Hey just so you guys know, if you add good debug logging and still can figure out the problems by the time Chris and I get around to it -- but we figure it out from the debug logs and don't have to start from scratch it won't hurt nearly as much. Also I'd bet if you have good debug logging you figure it out
Sam Gwydir
@gwydirsam
rm eugenics.circuit;rm -rf build debug; ./build.sh && ./debug/eugenics/test-circuit && ./debug/eugenics/test-genetic; cat eugenics.circuit
Sam Gwydir
@gwydirsam
#include "this/package/foo.h"
#include "gtest/gtest.h"

namespace {

// The fixture for testing class Foo.
class FooTest : public ::testing::Test {
protected:
// You can remove any or all of the following functions if its body
// is empty.

FooTest() {
// You can do set-up work for each test here.
}

virtual ~FooTest() {
// You can do clean-up work that doesn't throw exceptions here.
}

// If the constructor and destructor are not enough for setting up
// and cleaning up each test, you can define the following methods:

virtual void SetUp() {
// Code here will be called immediately after the constructor (right
// before each test).
}

virtual void TearDown() {
// Code here will be called immediately after each test (right
// before the destructor).
}

// Objects declared here can be used by all tests in the test case for Foo.
};

// Tests that the Foo::Bar() method does Abc.
TEST_F(FooTest, MethodBarDoesAbc) {
const string input_filepath = "this/package/testdata/myinputfile.dat";
const string output_filepath = "this/package/testdata/myoutputfile.dat";
Foo f;
EXPECT_EQ(0, f.Bar(input_filepath, output_filepath));
}

// Tests that Foo does Xyz.
TEST_F(FooTest, DoesXyz) {
// Exercises the Xyz feature of Foo.
}

}  // namespace

int main(int argc, char **argv) {
return RUN_ALL_TESTS();
}
Sam Gwydir
@gwydirsam
# export CC="/usr/local/bin/gcc-4.9 -fdiagnostics-color=auto"
# export CXX="/usr/local/bin/g++-4.9 -fdiagnostics-color=auto"
Sam Gwydir
@gwydirsam
number of unique circuits :=  2^((2^num_inputs)*num_outputs)
Vincent Valenti
@vincentv18
Hey guys, we debug logged it and added the inverter. It still doesn't work but we're doing what we can.
Sam Gwydir
@gwydirsam
Cool. Keep going.
Christopher Findeisen
@Atrus7
Hey
@jeregoorlino @vincentv18
You there?
Vincent Valenti
@vincentv18
yea. whats up
Christopher Findeisen
@Atrus7
Do you add gates to all of the other gates, or do you only add gates to the end?
Vincent Valenti
@vincentv18
all the other gates
why? are you all looking at our code?
Sam Gwydir
@gwydirsam
No, we just figured out a way to generate circuits really fast, and it had to do with that
Vincent Valenti
@vincentv18
oh okay
Sam Gwydir
@gwydirsam
# Servers
Host unix.cse.tamu.edu sun.cs.tamu.edu sun
HostName unix.cse.tamu.edu
User gwydir
ForwardX11 yes
Host compute.cse.tamu.edu compute-linux1.cs.tamu.edu compute
User gwydir
ProxyCommand ssh gwydir@unix.cse.tamu.edu -W %h:%p
ForwardX11 yes
Host sun-new.cse.tamu.edu sun2.cs.tamu.edu sun-new sun2
User gwydir
ProxyCommand ssh gwydir@unix.cse.tamu.edu -W %h:%p
ForwardX11 yes
Host build.tamu.edu
HostName build.tamu.edu
User gwydir
ForwardX11 yes

Host git.samgwydir.com
HostName git.samgwydir.com
User git
PreferredAuthentications publickey
ForwardAgent no
ForwardX11 no

Host eru eru.samgwydir.com samgwydir.com
HostName eru.samgwydir.com
User sam
PreferredAuthentications publickey
ForwardAgent yes
ForwardX11 yes

#  #HostName 66.147.230.231
#   HostName Maiar.SamGwydir.com

# Host Olorin Gandalf olorin gandalf
#  #HostName  66.147.230.135
#   HostName  Olorin.SamGwydir.com

# Host Valar Ea NS0 SamGwydir.com valar ea ns1 samgwydir.com samgwydir
#  #HostName 66.147.230.23
#   HostName Valar.SamGwydir.com
#   Port 2022

# Local
Host Totoro totoro
#HostName 192.168.1.40
HostName Totoro.local

Host Hercules hercules
#HostName 192.168.1.50
HostName Hercules.local

Host OpenWRT Router openwrt router
HostName 192.168.1.1
# HostName OpenWrt.local
User root

Host ErnstGwydir Ernst
HostName Ernst.local
User ernstgwydir

Host github.com
User git
ForwardX11 no

# All LAN
Host 192.168.1.* OpenWRT Router openwrt router Totoro totoro Hercules hercules ErnstGwydir Ernst

StrictHostKeyChecking no
VerifyHostKeyDNS yes
VisualHostKey yes

ForwardAgent yes
ForwardX11 no

# Defaults
Host *
Protocol 2
ForwardAgent yes
ForwardX11 yes
ForwardX11Trusted yes

#XauthLocation /opt/X11/bin/xauth

ExitOnForwardFailure yes

GSSAPIAuthentication no

ServerAliveCountMax 4
ServerAliveInterval 15

ControlMaster auto
ControlPersist yes
ControlPath   /Users/sam/.ssh/tmp/%h_%p_%r

StrictHostKeyChecking no
EnableSSHKeysign yes
VerifyHostKeyDNS no
VisualHostKey yes

UserKnownHostsFile /Users/sam/.ssh/known_hosts
HashKnownHosts yes

IdentitiesOnly no

IdentityFile /Users/sam/.ssh/keys/id_%h_%r

TCPKeepAlive yes

Compression no

#Ciphers aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes192-ctr,aes128-ctr,arcfour256
#MACs hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256,hmac-sha1-etm@openssh.com,hmac-sha1,umac-128-etm@openssh.com,umac-64-etm@openssh.com,umac-128@openssh.com,hmac-ripemd160-etm@openssh.com,hmac-ripemd160
#KexAlgorithms ecdh-sha2-nistp521,ecdh-sha2-nistp384,ecdh-sha2-nistp256,diffie-hellman-group-exchange-sha256,diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1