Another thread side by side with https://mathstodon.xyz/@j2kun/110164997568880627 for tasks it DID help me with
Task 1: I'm looking for a good name for a software project. The project is a software compiler, but it's also related to the topic of safety, privacy, and security. The name should be short and make reference to something in art, literature, film, or the real world (it doesn't need to be a commonly understood reference). The name should evoke a sense of preventing one from touching a dangerous item or substance, or should evoke a sense of building a foundation for something strong and sturdy.
Task 2: In the XLA library, the dot_general function takes as input "dimension_numbers" described as
dimension_numbers (Tuple[Tuple[Sequence[int], Sequence[int]], Tuple[Sequence[int], Sequence[int]]]) – a tuple of tuples of sequences of ints of the form ((lhs_contracting_dims, rhs_contracting_dims), (lhs_batch_dims, rhs_batch_dims))
I understand what the contracting_dims are for. What are the batch_dims for?
Task 3: Given a numpy array of shape (x,y) = (4, 4), how would I broadcast this into a numpy array of shape (a, b, c, d) = (4, 4, 4, 4), such that dimension x ends up in dimension b and dimension y ends up in dimension d?
Task 4: Write a neovim lua function that calls a given external program on the current buffer's input. It should replace the buffer text when the external program writes data to stdout, and otherwise do nothing.
Update: I did not end up using the LLM's suggested name. So it's helping, but only kinda.
@j2kun If `a` is the (x,y) array: ` np.broadcast_to(a[np.newaxis, :, np.newaxis, :], (4,4,4,4))`
@j2kun `np.broadcast_to(np.expand_dims(a, (0,2)), (4,4,4,4))` also works.
@j2kun Oh, I thought you were asking for help, oops.
@robbystk yeah, GPT-4 explained newaxis, and also that None works in place of newaxis.
@j2kun ovenmit, hotpad, guardrail