Skip to content

could snapvx handle global variables? #20

Open
@DanqingZ

Description

@DanqingZ

I have a decision variable that is shared among all all nodes. like below code:

W = Variable(3,name='W')
for i in range(500):
    b = Variable(1,name='b')
#     obj = logistic(-y[i]*x.T*A[i,:])
    obj = logistic(A[i,:].T*W+b-y[i])
    gvx.SetNodeObjective(i, Objective=obj)

Then I gave got a error concerning shared variables.

Exception: Objective at NId 1 shares a variable.

wondering how snapvx handle this shared variables problem. Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions