Skip to content

Commit

Permalink
v1.0.1 changes
Browse files Browse the repository at this point in the history
- Refactor gradient and shape inference design, added auto stub generator

Squashed commit of the following:

commit 88ebf504d44f5803a0b7d985c0a985e422096379
Author: Joseph Emmanuel Dayo <joseph.dayo@gmail.com>
Date:   Mon Mar 4 07:07:51 2019 +0800

    Refactor stub file

commit 5e291e8
Author: Joseph Emmanuel Dayo <joseph.dayo@gmail.com>
Date:   Wed Feb 13 07:51:47 2019 +0800

    wip

commit e7ed73e
Author: Joseph Emmanuel Dayo <joseph.dayo@gmail.com>
Date:   Wed Feb 13 07:44:07 2019 +0800

    op refactor wip

commit ec99338
Author: Joseph Dayo <joseph.dayo@gmail.com>
Date:   Fri Jan 11 16:00:45 2019 +0800

    Reorganized folders

commit 7317403
Author: Joseph Dayo <joseph.dayo@gmail.com>
Date:   Fri Jan 11 15:26:39 2019 +0800

    standardrb --fix

commit 191815d
Author: Joseph Dayo <joseph.dayo@gmail.com>
Date:   Fri Jan 11 15:18:22 2019 +0800

    Add standard gem

commit 17a1b4d
Merge: 1f881ba 480330a
Author: Joseph Dayo <joseph.dayo@gmail.com>
Date:   Fri Jan 11 15:07:41 2019 +0800

    Merge branch 'master' of https://github.com/jedld/tensor_stream

commit 1f881ba
Author: Joseph Dayo <joseph.dayo@gmail.com>
Date:   Tue Jan 8 17:08:26 2019 +0800

    Rearrange samples

commit ca1e057
Author: Joseph Dayo <joseph.dayo@gmail.com>
Date:   Tue Jan 8 16:54:36 2019 +0800

    Cleanup a bunch of test files
  • Loading branch information
jedld committed Mar 3, 2019
1 parent 72430c8 commit b57e728
Show file tree
Hide file tree
Showing 167 changed files with 4,209 additions and 16,662 deletions.
1 change: 1 addition & 0 deletions .rubocop.yml
@@ -1,4 +1,5 @@
AllCops:
TargetRubyVersion: 2.2
Exclude:
- samples/*
- bin/*
Expand Down
2 changes: 1 addition & 1 deletion Gemfile
@@ -1,4 +1,4 @@
source 'https://rubygems.org'
source "https://rubygems.org"

# Specify your gem's dependencies in cl-brains.gemspec
gemspec
6 changes: 3 additions & 3 deletions Rakefile
@@ -1,12 +1,12 @@
require "bundler/gem_tasks"
require "rspec/core/rake_task"
require 'rdoc/task'
require "rdoc/task"

RSpec::Core::RakeTask.new(:spec)

task :default => :spec
task default: :spec

RDoc::Task.new do |rdoc|
rdoc.main = "README.rdoc"
rdoc.rdoc_files.include("README.rdoc", "lib /*.rb")
end
end
20 changes: 20 additions & 0 deletions bin/stubgen
@@ -0,0 +1,20 @@
#!/usr/bin/env ruby

# Script to auto generate op stub file from the opdef folder

require "bundler/setup"
require "tensor_stream"
require "erb"

target = File.join(__dir__, '..', 'lib', 'tensor_stream', 'generated_stub')

FileUtils.mkdir_p(target)

stub_file = File.join(target, 'ops.rb')
File.delete(stub_file) if File.exist?(stub_file)

f = File.open(stub_file, 'wb')

template = File.read(File.join(target, 'stub_file.erb'))
f << ERB.new(template, nil, '%').result(binding)
f.close

0 comments on commit b57e728

Please sign in to comment.