File size: 2,325 Bytes
c745dff
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>NumPy Matrix Lab</title>
    <link rel="stylesheet" href="styles.css" />
  </head>
  <body>
    <div class="bg-grid"></div>
    <main class="container">
      <nav class="top-nav">
        <a href="index.html">Back Home</a>
      </nav>

      <header class="hero compact">
        <p class="eyebrow">Page 1</p>
        <h1>NumPy Matrix Operations</h1>
        <p>
          Pick a natural-language operation, define matrix shapes (max 3D), and
          inspect input/output arrays plus executable NumPy code.
        </p>
        <p class="slice-label">
          Broadcasting is enabled. Example element-wise valid pair: (2,3) with (1,3). Example matmul valid pair: (2,3) with (4,3,2).
        </p>
      </header>

      <section class="panel controls">
        <div class="row">
          <label for="operationSelect">Operation</label>
          <select id="operationSelect"></select>
        </div>

        <div class="row">
          <label for="nlInput">Natural language query</label>
          <input
            id="nlInput"
            type="text"
            placeholder="Example: multiply matrix A and B"
          />
          <button id="matchBtn" type="button">Match Query</button>
        </div>

        <div id="operationInfo" class="operation-info"></div>
        <div id="shapeInputs" class="shape-grid"></div>
        <div id="operationOptions" class="shape-grid"></div>

        <div class="row">
          <button id="runBtn" type="button">Generate and Compute</button>
        </div>
      </section>

      <section class="panel output">
        <h2>Generated NumPy Code</h2>
        <pre id="codeOutput" class="code"></pre>
      </section>

      <section class="panel output">
        <h2>Input Matrices</h2>
        <div id="inputViz" class="viz-grid"></div>
      </section>

      <section class="panel output">
        <h2>Output Matrix</h2>
        <div id="outputViz" class="viz-grid"></div>
      </section>

      <section class="panel output">
        <h2>Computation Details</h2>
        <div id="detailViz" class="viz-grid"></div>
      </section>
    </main>

    <script src="app.js?v=20260812"></script>
  </body>
</html>