Forums > MaxMSP

Is there a way to know the cost of certain objects on the processor before running the patch?

July 31, 2006 | 11:25 am

Like is there a list of most expensive to least expensive objects or something?


July 31, 2006 | 11:55 am

Hi,

I have maked in illustrator paths that i want to import and use in
Jitter. So i know that i have to convert this illustrator doc .ai
to .obj and import that in Jitter.
But i do not manage to do that properly. Which 3D program do i have
to use?

When i have managed to do that > Jitter question :
Is it possible to use this .obj 3d path in Jitter like a 3d path to
move other 3d objects along that path?

Is there some help or example patch to do that or to give me a hint.

Regards,
Bart



MJ
July 31, 2006 | 3:05 pm

maybe convert it to a text file ?
then load it into a coll

-mj

>Hi,
>
>I have maked in illustrator paths that i want to import and use in
>Jitter. So i know that i have to convert this illustrator doc .ai to
>.obj and import that in Jitter.
>But i do not manage to do that properly. Which 3D program do i have to use?
>
>
>When i have managed to do that > Jitter question :
>Is it possible to use this .obj 3d path in Jitter like a 3d path to
>move other 3d objects along that path?
>
>
>Is there some help or example patch to do that or to give me a hint.
>
>
>
>
>Regards,
>Bart
>


July 31, 2006 | 5:13 pm

not as far as I’ve ever seen, although that would make a great data
analysis/display assignment, if someone is looking for a school
project…

On Jul 31, 2006, at 12:25 PM, Robert wrote:

>
> Like is there a list of most expensive to least expensive objects
> or something?


August 9, 2006 | 11:09 am

Yes, but how do you do that properly?
I have tried that for other projects also but it takes to much time
and gives a lot of problems.
Is there a programme or way to do that fast and properly? So that i
do not have to clean 1000 code lines so that jitter can understand it
properly.

Regards,
Bart

On 31 Jul 2006, at 17:05, MJ wrote:

> maybe convert it to a text file ?
> then load it into a coll
>
> -mj
>
>
>> Hi,
>>
>> I have maked in illustrator paths that i want to import and use in
>> Jitter. So i know that i have to convert this illustrator doc .ai
>> to .obj and import that in Jitter.
>> But i do not manage to do that properly. Which 3D program do i
>> have to use?
>>
>>
>> When i have managed to do that > Jitter question :
>> Is it possible to use this .obj 3d path in Jitter like a 3d path
>> to move other 3d objects along that path?
>>
>>
>> Is there some help or example patch to do that or to give me a hint.
>>
>>
>>
>>
>> Regards,
>> Bart
>>
>


August 9, 2006 | 2:22 pm

Quote: Andross wrote on Mon, 31 July 2006 05:25
—————————————————-
> Like is there a list of most expensive to least expensive objects or something?
—————————————————-

no, because the "CPU cost" of an object depends on the
patch i.e. how often it is been instatiated and with
what other objects it is been used together.

try this:

make 10 copies of [zerox~].
look at the CPU % window in max.
then try 20, 30, 40, and 100.

dont try -110


August 9, 2006 | 7:56 pm

yeah, but, you can instantiate 10 copies of ‘method a’, (method a
being either an object or abstraction to processing something) and 10
copies of ‘method b’, and see which is most efficient. Granted, the
context of the parent patch obviously matters, but I still feel like
there could be a better way to write cleaner/faster code, yes?

v a d e //

http://www.vade.info
abstrakt.vade.info

On Aug 9, 2006, at 10:22 AM, Roman Thilenius wrote:

>
> Quote: Andross wrote on Mon, 31 July 2006 05:25
> —————————————————-
>> Like is there a list of most expensive to least expensive objects
>> or something?
> —————————————————-
>
>
> no, because the "CPU cost" of an object depends on the
> patch i.e. how often it is been instatiated and with
> what other objects it is been used together.
>
> try this:
>
> make 10 copies of [zerox~].
> look at the CPU % window in max.
> then try 20, 30, 40, and 100.
>
>
> dont try -110


August 9, 2006 | 10:27 pm

On 9-Aug-2006, at 21:56, vade wrote:
> yeah, but, you can instantiate 10 copies of ‘method a’, (method a
> being either an object or abstraction to processing something) and
> 10 copies of ‘method b’, and see which is most efficient. Granted,
> the context of the parent patch obviously matters, but I still feel
> like there could be a better way to write cleaner/faster code, yes?

Experience helps a lot. Not only experience in Max/MSP/Jitter, but if
you’ve worked with lower-level languages and/or studied some DSP,
then you’ve got added experience along the lines of "Fourier
Transforms are expensive, table-based waveshaping is cheap" and you
can extrapolate that to specific objects. (The last example is over-
simplified, but hopefully you get the idea.)

A table of objects sorted by relative expense is a nice idea but how
do you deal with objects that are cheap most of the time but have to
do heavy computation occasionally? What if the heavy computations
come up at regular intervals (FFT stuff, the lp.pvvv~ & friends
objects) or erratically, say when parameters change? Then some
objects pay a higher price if you use signals in control inlets,
others don’t notice much difference. On top of that, some of the
relative expense may change simply by using a different compiler,
different OS, or (gasp!) a different processor.

I’m not saying that the idea isn’t a good one. I’m just trying to
explain some of the difficulties involved. My suggestion to Robert is
to start a personal list. No matter what comes of the list, you’ll
learn a lot in the process. And that’s a good thing.

On 9-Aug-2006, at 16:22, Roman Thilenius wrote:
> look at the CPU % window in max.

For tracking CPU usage more precisely (which one presumably would
want to do in a project comparing CPU usage of different objects),
you might want to try the Running CPU Usage example distributed with
the free Litter Power Starter Pack. URI below.

– Peter

————– http://www.bek.no/~pcastine/Litter/ ————-
Peter Castine +–> Litter Power & Litter Bundle for Jitter
Universal Binaries on the way
iCE: Sequencing, Recording &
Interface Building for |home | chez nous|
Max/MSP Extremely cool |bei uns | i nostri|
http://www.dspaudio.com/ http://www.castine.de


August 10, 2006 | 8:30 am


August 10, 2006 | 8:45 am

For Max objects you can also take a look at the help file for the
cpuclock object. I have several times banged objects ad ridiculous and
used this approach to see how long that takes. One such example can be
found here:

http://www.jamoma.org/wiki/TestCases

Best,
Trond


Viewing 10 posts - 1 through 10 (of 10 total)