Giter VIP home page Giter VIP logo

Comments (2)

floybix avatar floybix commented on August 30, 2024

Happily, clojure.spec came along. I'm starting work on using it to describe and test the code.

Starting in cells.cljc.

I already spec'd the layer parameters: floybix@1c75772
At the moment they are all listed together and checked once. I think the checking should be at the implementation level, checking the specific keys that are needed -- e.g. specific params needed by different inhibition algorithms or homeostasis algorithms.

I'm proposing to get rid of the defrecords and replace them with spec'd maps. I used records in the first place mainly just as a way to list the expected keys. While it is fine to spec records, you just end up listing the keys twice (once in the spec and once in defrecord).

This is, I think, a no-brainer in the case of LayerActiveState, LayerDistalState, etc. It's less clear however in the case of LayerOfCells. That record is defined with implementations of several protocols:

  • PLayerOfCells
  • PInterruptable
  • PTopological
  • PFeedForward
  • PFeedBack
  • PTemporal
  • PParameterised

So I guess I will keep it as a record.

I have a feeling that activate/learn/depolarise would be nicer as multi-methods, but I'm not sure.

from comportex.

floybix avatar floybix commented on August 30, 2024

Figuring out how to spec the generic functions in the org.nfrac.comportex.protocols namespace while leaving implementation details in their separate namespace. It can be done with multispec. As part of this it seemed more natural to replace the layer getters -- active-columns, bursting-columns, active-cells, etc -- with a single layer-state that returns a map. If anyone is watching please take a look and tell me if i'm crazy... floybix@6b5008d

from comportex.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.