Class: Wandb::Api

Inherits:
Object
  • Object
show all
Defined in:
lib/wandb.rb

Overview

Api class

Instance Method Summary collapse

Constructor Details

#initialize(api) ⇒ Api



181
182
183
# File 'lib/wandb.rb', line 181

def initialize(api)
  @api = api
end

Instance Method Details

#project(name, entity = nil) ⇒ Object



190
191
192
193
# File 'lib/wandb.rb', line 190

def project(name, entity = nil)
  proj = @api.project(name, entity)
  Project.new(proj)
end

#projects(entity = nil) ⇒ Object



185
186
187
188
# File 'lib/wandb.rb', line 185

def projects(entity = nil)
  projects = @api.projects(entity)
  projects.map { |proj| Project.new(proj) }
end