forked from jfreeze/ruby-gdsii
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathREADME.txt
119 lines (93 loc) · 4.63 KB
/
README.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
= Overview
---
The GDSII Ruby Library provides an easy-to-use interface using Ruby for reading
and writing GDSII files.
Details in HTML form of the package's API may be generated by running:
% rake doc
Contributors:
* Jim Freeze
* Ben Hoefer
* James Masters
* Matt Welland
* Dan White
Project webspace:
http://rubyforge.org/projects/gdsii/
This library is released under the MIT License (see LICENSE.txt)
---
== Installation
The "installation" is easy - simply add the contents in the "lib" directory
in this package to a directory where Ruby is installed or set the $RUBYLIB
environment variable to include the "lib" directory.
Alternatively, install it as a Ruby Gem and do something like this
in your Ruby files:
require 'gdsii'
class MyClass
include Gdsii
...
end
See the <i>samples</i> directory for an example.
---
== Unit Testing
The GDSII library has been tested on Windows XP, SuSE Linux, SunOS, and HP-UX.
To test the library on your own platform and configuration, a number of test
suites are located in the <i>test</i> directory of this installation package.
Those tests with file names beginning with <i>test_</i> can be run at once
by running:
% rake test
== Test Coverage
Test coverage may be analyzed by running:
% rake coverage
If your environment has the gem <i>Launchy</i> installed a page will be
opened in your browser showing the coverage report.
== Test Descriptions
test_gds_group.rb:: A unit test of the high-level GDSII methods.
test_gds_record.rb:: A unit test of the low-level GDSII methods.
test_h_pthru.rb:: Uses the GDSII high-level methods to read in a GDSII
file and then write out the same GDSII file. The file
should be identical - or at least just have just EOF
null-padding differences.
h_pthru.rb:: Stand-alone version of the above - accepts command line
args.
test_l_pthru.rb:: Uses the GDSII low-level methods to read in a GDSII
file and then write out the same GDSII file. The file
should be identical - or at least just have just EOF
null-padding differences.
l_pthru.rb:: Stand-alone version of the above - accepts command line
args.
test_h_write.rb:: Uses high-level GDSII methods to write out a number of
GDSII records using many of the available method calls.
This can be useful to verify that the GDSII library is
working and the output file can be compared against the
file found in ./test/baseline/h_write.gds to ensure that
the platform is reading and writing GDSII properly.
h_write.rb:: Stand-alone version of the above - accepts command line
args.
test_hs_pthru.rb:: Uses the GDSII high-level *streamlined* methods to read
in a GDSII file and write out the contents in one pass.
The resulting GDSII file should be identical - or at
least just have just EOF null-padding differences.
hs_pthru.rb:: Stand-alone version of the above - accepts command line
args.
---
== Utility Scripts
A few utility scripts have been included in the "bin" directory for general
purpose use and/or for reference in using the Ruby GDSII library:
gds2rb:: Translates a GDSII file into a Ruby script containing commands
to recreate the GDSII file. This might make custom edits to a
GDSII file easy by post- processing the script through
automation or by hand before running the script to produce
an output GDSII file.
gdsdebug:: A detailed GDSII "dump" program that can be used to debug issues
with a GDSII file that may be somehow corrupt or may be causing
the GDSII Ruby file read methods to fail.
gdsdump:: A conversion of GDSII data to the "L" file format (ASCII). This
can make quickly reviewing GDSII file contents through text very
easy.
gdslayers:: Lists all layer and data types in the GDSII file.
gdssremove:: Removes the specified structure(s) from the GDSII file.
gdsssplit:: Extracts the specified structure(s) from the GDSII file and
creates separate files for each of the extracted structures.
gdsstats:: Reads a GDSII file and produces a statistical summary of the
contents of each structure in the file.
gdsstructs:: Lists all structure names found in the GDSII file.
gdstree:: Prints a hierarchical tree of structures in a GDSII file.