Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
models
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
bitsoko services
models
Commits
5d758ef0
Commit
5d758ef0
authored
Mar 15, 2017
by
Neal Wu
Committed by
GitHub
Mar 15, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #924 from h4ck3rm1k3/master
untie
parents
7e465e4a
8b667903
Changes
16
Hide whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
17 additions
and
17 deletions
+17
-17
dp_pca.py
differential_privacy/dp_sgd/dp_optimizer/dp_pca.py
+1
-1
analysis.py
differential_privacy/multiple_teachers/analysis.py
+1
-1
deep_cnn.py
differential_privacy/multiple_teachers/deep_cnn.py
+2
-2
accountant.py
differential_privacy/privacy_accountant/tf/accountant.py
+1
-1
build_mscoco_data.py
im2txt/im2txt/data/build_mscoco_data.py
+1
-1
inception_distributed_train.py
inception/inception/inception_distributed_train.py
+1
-1
inception_eval.py
inception/inception/inception_eval.py
+1
-1
inception_train.py
inception/inception/inception_train.py
+1
-1
ops.py
inception/inception/slim/ops.py
+1
-1
data_utils.py
namignizer/data_utils.py
+1
-1
names.py
namignizer/names.py
+1
-1
data_utils.py
neural_programmer/data_utils.py
+1
-1
model.py
neural_programmer/model.py
+1
-1
model_deploy.py
slim/deployment/model_deploy.py
+1
-1
inception_resnet_v2.py
slim/nets/inception_resnet_v2.py
+1
-1
inception_v4.py
slim/nets/inception_v4.py
+1
-1
No files found.
differential_privacy/dp_sgd/dp_optimizer/dp_pca.py
View file @
5d758ef0
...
...
@@ -27,7 +27,7 @@ def ComputeDPPrincipalProjection(data, projection_dims,
Args:
data: the input data, each row is a data vector.
projection_dims: the projection dimension.
sanitizer: the sanitizer used for ach
ei
ving privacy.
sanitizer: the sanitizer used for ach
ie
ving privacy.
eps_delta: (eps, delta) pair.
sigma: if not None, use noise sigma; otherwise compute it using
eps_delta pair.
...
...
differential_privacy/multiple_teachers/analysis.py
View file @
5d758ef0
...
...
@@ -287,7 +287,7 @@ def main(unused_argv):
if
min
(
eps_list_nm
)
==
eps_list_nm
[
-
1
]:
print
"Warning: May not have used enough values of l"
# Data indpendent bound, as mechanism is
# Data ind
e
pendent bound, as mechanism is
# 2*noise_eps DP.
data_ind_log_mgf
=
np
.
array
([
0.0
for
_
in
l_list
])
data_ind_log_mgf
+=
num_examples
*
np
.
array
(
...
...
differential_privacy/multiple_teachers/deep_cnn.py
View file @
5d758ef0
...
...
@@ -84,7 +84,7 @@ def inference(images, dropout=False):
"""Build the CNN model.
Args:
images: Images returned from distorted_inputs() or inputs().
dropout: Boolean controling whether to use dropout or not
dropout: Boolean control
l
ing whether to use dropout or not
Returns:
Logits
"""
...
...
@@ -194,7 +194,7 @@ def inference_deeper(images, dropout=False):
"""Build a deeper CNN model.
Args:
images: Images returned from distorted_inputs() or inputs().
dropout: Boolean controling whether to use dropout or not
dropout: Boolean control
l
ing whether to use dropout or not
Returns:
Logits
"""
...
...
differential_privacy/privacy_accountant/tf/accountant.py
View file @
5d758ef0
...
...
@@ -152,7 +152,7 @@ class MomentsAccountant(object):
We further assume that at each step, the mechanism operates on a random
sample with sampling probability q = batch_size / total_examples. Then
E[exp(L X)] = E[(Pr[M(D)==x / Pr[M(D')==x])^L]
By distinguishi
gn two cases of w
ether D < D' or D' < D, we have
By distinguishi
ng two cases of wh
ether D < D' or D' < D, we have
that
E[exp(L X)] <= max (I1, I2)
where
...
...
im2txt/im2txt/data/build_mscoco_data.py
View file @
5d758ef0
...
...
@@ -424,7 +424,7 @@ def _load_and_process_metadata(captions_file, image_dir):
(
len
(
id_to_filename
),
captions_file
))
# Process the captions and combine the data into a list of ImageMetadata.
print
(
"Proc
c
essing captions."
)
print
(
"Processing captions."
)
image_metadata
=
[]
num_captions
=
0
for
image_id
,
base_filename
in
id_to_filename
:
...
...
inception/inception/inception_distributed_train.py
View file @
5d758ef0
...
...
@@ -89,7 +89,7 @@ RMSPROP_EPSILON = 1.0 # Epsilon term for RMSProp.
def
train
(
target
,
dataset
,
cluster_spec
):
"""Train Inception on a dataset for a number of steps."""
# Number of workers and parameter servers are infered from the workers and ps
# Number of workers and parameter servers are infer
r
ed from the workers and ps
# hosts string.
num_workers
=
len
(
cluster_spec
.
as_dict
()[
'worker'
])
num_parameter_servers
=
len
(
cluster_spec
.
as_dict
()[
'ps'
])
...
...
inception/inception/inception_eval.py
View file @
5d758ef0
...
...
@@ -77,7 +77,7 @@ def _eval_once(saver, summary_writer, top_1_op, top_5_op, summary_op):
# /my-favorite-path/imagenet_train/model.ckpt-0,
# extract global_step from it.
global_step
=
ckpt
.
model_checkpoint_path
.
split
(
'/'
)[
-
1
]
.
split
(
'-'
)[
-
1
]
print
(
'Succesfully loaded model from
%
s at step=
%
s.'
%
print
(
'Succes
s
fully loaded model from
%
s at step=
%
s.'
%
(
ckpt
.
model_checkpoint_path
,
global_step
))
else
:
print
(
'No checkpoint file found'
)
...
...
inception/inception/inception_train.py
View file @
5d758ef0
...
...
@@ -290,7 +290,7 @@ def train(dataset):
variable_averages
=
tf
.
train
.
ExponentialMovingAverage
(
inception
.
MOVING_AVERAGE_DECAY
,
global_step
)
# Another possib
l
ility is to use tf.slim.get_variables().
# Another possibility is to use tf.slim.get_variables().
variables_to_average
=
(
tf
.
trainable_variables
()
+
tf
.
moving_average_variables
())
variables_averages_op
=
variable_averages
.
apply
(
variables_to_average
)
...
...
inception/inception/slim/ops.py
View file @
5d758ef0
...
...
@@ -15,7 +15,7 @@
"""Contains convenience wrappers for typical Neural Network TensorFlow layers.
Additionally it maintains a collection with update_ops that need to be
updated after the ops have been computed, for ex
ma
ple to update moving means
updated after the ops have been computed, for ex
am
ple to update moving means
and moving variances of batch_norm.
Ops that have different behavior during training or eval have an is_training
...
...
namignizer/data_utils.py
View file @
5d758ef0
...
...
@@ -58,7 +58,7 @@ def _letter_to_number(letter):
def
namignizer_iterator
(
names
,
counts
,
batch_size
,
num_steps
,
epoch_size
):
"""Takes a list of names and counts like those output from read_names, and
makes an iterator yielding a batch_size by num_steps array of random names
separated by an end of name token. The names are cho
o
sen randomly according
separated by an end of name token. The names are chosen randomly according
to their counts. The batch may end mid-name
Args:
...
...
namignizer/names.py
View file @
5d758ef0
...
...
@@ -14,7 +14,7 @@
"""A library showing off sequence recognition and generation with the simple
example of names.
We use recurrent neural nets to learn complex functions able to recogize and
We use recurrent neural nets to learn complex functions able to recog
n
ize and
generate sequences of a given form. This can be used for natural language
syntax recognition, dynamically generating maps or puzzles and of course
baby name generation.
...
...
neural_programmer/data_utils.py
View file @
5d758ef0
...
...
@@ -223,7 +223,7 @@ def list_join(a):
def
group_by_max
(
table
,
number
):
#computes the most frequently occuring entry in a column
#computes the most frequently occur
r
ing entry in a column
answer
=
[]
for
i
in
range
(
len
(
table
)):
temp
=
[]
...
...
neural_programmer/model.py
View file @
5d758ef0
...
...
@@ -135,7 +135,7 @@ class Graph():
#Attention on quetsion to decide the question number to passed to comparison ops
def
compute_ans
(
op_embedding
,
comparison
):
op_embedding
=
tf
.
expand_dims
(
op_embedding
,
0
)
#dot product of operation embedding with hidden state to the left of the number occurence
#dot product of operation embedding with hidden state to the left of the number occur
r
ence
first
=
tf
.
transpose
(
tf
.
matmul
(
op_embedding
,
tf
.
transpose
(
...
...
slim/deployment/model_deploy.py
View file @
5d758ef0
...
...
@@ -304,7 +304,7 @@ def optimize_clones(clones, optimizer,
regularization_losses
=
None
# Compute the total_loss summing all the clones_losses.
total_loss
=
tf
.
add_n
(
clones_losses
,
name
=
'total_loss'
)
# Sum the gradients ac
c
ross clones.
# Sum the gradients across clones.
grads_and_vars
=
_sum_clones_gradients
(
grads_and_vars
)
return
total_loss
,
grads_and_vars
...
...
slim/nets/inception_resnet_v2.py
View file @
5d758ef0
...
...
@@ -191,7 +191,7 @@ def inception_resnet_v2(inputs, num_classes=1001, is_training=True,
end_points
[
'Mixed_6a'
]
=
net
net
=
slim
.
repeat
(
net
,
20
,
block17
,
scale
=
0.10
)
# Auxil
l
ary tower
# Auxil
i
ary tower
with
tf
.
variable_scope
(
'AuxLogits'
):
aux
=
slim
.
avg_pool2d
(
net
,
5
,
stride
=
3
,
padding
=
'VALID'
,
scope
=
'Conv2d_1a_3x3'
)
...
...
slim/nets/inception_v4.py
View file @
5d758ef0
...
...
@@ -269,7 +269,7 @@ def inception_v4(inputs, num_classes=1001, is_training=True,
reuse: whether or not the network and its variables should be reused. To be
able to reuse 'scope' must be given.
scope: Optional variable_scope.
create_aux_logits: Whether to include the auxil
l
iary logits.
create_aux_logits: Whether to include the auxiliary logits.
Returns:
logits: the logits outputs of the model.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment