examples: remove any ref to Users/pa/

nix
Pierre Alexandre Tremblay 5 years ago
parent b21d6a5c8d
commit da54b52102

@ -63,7 +63,7 @@ t = Main.elapsedTime;
// or write to file a human readable, sorted version of the database after sorting it by index.
(
a = File("/Users/pa/Desktop/sc-loading.json","w");
a = File("/tmp/sc-loading.json","w");
~stuffsorted = Array.newFrom(~loader.index.keys).sort{|a,b| ~loader.index[a][\bounds][0]< ~loader.index[b][\bounds][0]}.do{|k|
v = ~loader.index[k];
a.write(k.asString ++ "\n");
@ -99,7 +99,7 @@ t = Main.elapsedTime;
///// write to file in human readable format, in order.
(
a = File("/Users/pa/Desktop/sc-spliting.json","w");
a = File("/tmp/sc-spliting.json","w");
~stuffsorted = Array.newFrom(~slicer.index.keys).sort{|a,b| ~slicer.index[a][\bounds][0]< ~slicer.index[b][\bounds][0]}.do{|k|
v = ~slicer.index[k];
a.write(k.asString ++ "\n");

@ -11,14 +11,11 @@
~flatbuf = 4.collect{Buffer.new};
// here we instantiate a loader as per example 0
~loader = FluidLoadFolder("/Volumes/machins/projets/newsfeed/sons/smallnum/");
// ~loader = FluidLoadFolder("/Volumes/machins/projets/newsfeed/sons/segments/");
// ~loader = FluidLoadFolder("/Users/pa/Desktop/RodDrums/Training/");
// ~loader = FluidLoadFolder("/Users/pa/Desktop/HansPiano/Pianoteq-subset/");
~loader = FluidLoadFolder(File.realpath(FluidBufPitch.class.filenameSymbol).dirname.withTrailingSlash ++ "../AudioFiles/");
// here we instantiate a further slicing step as per example 0
~slicer = FluidSliceCorpus({ |src,start,num,dest|
FluidBufOnsetSlice.kr(src,start,num,metric: 9, minSliceLength: 17, indices:dest, threshold:2,blocking: 1)
FluidBufOnsetSlice.kr(src,start,num,metric: 9, minSliceLength: 17, indices:dest, threshold:0.2,blocking: 1)
});
// here we instantiate a process of description and dataset writing, as per example 0
@ -140,17 +137,14 @@ t = Main.elapsedTime;
~treeCW.fit(~curatedW,{"Fitted".postln;});
//select a sound to match
// EITHER retrieve a random slice
~targetsound = Buffer(s);
// EITHER retrieve the last slice
~targetname = ~slicer.index.keys.asArray.last.asSymbol;
~targetname = ~slicer.index.keys.asArray.scramble.last.asSymbol;
#a,b = ~slicer.index[~targetname][\bounds];
// OR a given source item
#a,b = ~slicer.index["subset_Pno-PteqRand03_1s_HT-Bb4-p.wav".asSymbol][\bounds];
// retrieve compose a buffer
FluidBufCompose.process(s,~loader.buffer,a,(b-a),numChans: 1, destination: ~targetsound,action: {~targetsound.play;})
// or just load a file in that buffer
~targetsound = Buffer.read(s,"/Users/pa/Desktop/RodDrums/Testing/TestingSnareHits_351_TRIMMED.wav");
// OR just load a file in that buffer
~targetsound = Buffer.read(s,Platform.resourceDir +/+ "sounds/a11wlk01.wav");
//describe the sound to match
(

@ -1,6 +1,6 @@
//load a part of a sound that has 3 clear components: a clear pitch component to start, a noisy pitchless ending and DC offset silence on both ends
(
b = Buffer.read(s,"/Users/pa/Documents/documents@hudd/research/projects/fluid corpus navigation/research/flucoma-pd/help/media/Tremblay-ASWINE-ScratchySynth-M.wav",42250,44100);
b = Buffer.read(s,File.realpath(FluidBufPitch.class.filenameSymbol).dirname.withTrailingSlash ++ "../AudioFiles/Tremblay-ASWINE-ScratchySynth-M.wav",42250,44100);
~pitches = Buffer(s);
~stats = Buffer(s);
~loud = Buffer(s);

Loading…
Cancel
Save